Hello! I am quite new to this world so I hope someone here can help me understand my problem.
I want to pass a mathematical model formed by 3 arrays of different dimensions (e.g. X, Y, Z), I want these arrays to respect some constraints in the specific i want:
-sum(X) == 450;
-sum(Y) == 800;
-sum(Z) == 650;
-sum(X)+sum(Y)+sum(Z) <= 1600
I know that all the constraints cannot be respected simultaneously, I want to maximize the sum of the 3 arrays, considering that if sum(array) is not equal to the declared value, then its values will all be 0.
In this case for example, i want the model to discard X given that sum(Y)+sum(Z) is the maximum obtainable respecting the constraints.
First I thought the solver would handle the case by itself but by my surprise it doesn’t.
Can someone please help me?
Thank you in advance