I wrote the attached model below, but I got an infeasible integer solution and am working on debugging the model. Thesis Model Replication.gms (9.78 KB)
In the pre-solve stage, I got the below error.
So, I thought I was missing indicating in the constraint that (j, i)∈A_j^- and j ∈ S. My question is, how to write these two conditions in the constraint?
But when I’m using the dollar option, it gives me error 148.
Would someone help me to solve this condition?
I couldn’t be familiar in your code, but, as I know, if you want to use a set indices in the $ condition, you should use with “ord”.
For example;
sum(i$(ord(AMinus) > 5), x(i,j)) .....etc
Because you defined “AMinus” as a set. (but, still, I am not quite sure this is what you mean)
But, I dont know how you can write the condition for “∈”.
Send you entire model, so we can reproduce. Looking at the equation in isolation makes no sense. We don’t even know what Aminus is in your code. -Michael