My objective function for the Xpress-IVE (Mosel lang) model is
where a and b the number of elements in the decision variables which are arrays.
Since there is no function to calculate the absolute value, i want to get something of the form
objective = max(a,b) - min(a,b)
and then minimize the objective
What I have tried: introduced two variables x and y with the following constraints: x >= a x >= b y => a y => b and re-written the objective as x-y
But this gives me zero as the solution.
Could I please get a hint on what i am doing wrong?