I am really struggling with the Error 150 which pops up when I run my simple script. I am a beginner with GAMS. I am using the elements of a set (within quotes) to define the individual equations, but it is giving me the error. I think it has got something to do with domain violation, but I can’t figure out a way to write it. Every single one of the equations are different, so I don’t know of a way to define them other than defining them individually. Here I am showing only 6 equations, but I have over 35 in my actual script. I will really appreciate if you can help me out here.
Thank you,
Anby
Script
Sets
ii actual masses /m26, m27, m28, m29, m30, m31/
j contributions / d1, d2, d3, d4/;
If you define an equation over a set, in Gams you can’t write down the single equations. For this you should have defined every single equation like eq_28, eq_29.
It is easier to define a table with the coefficients for the X-Variables and write down one equation definition like this:
On another note, does GAMS allow table elements to be functions of variables ? For example, when x1, x3 and x3 are variables is the following permitted ?
On another note, does GAMS permit tables whose elements consists of variables ? For example, if x1, x2, x3 are variables, then is the following permitted ?