Dimension Different Error
Posted: Sat Nov 18, 2017 1:02 pm
Hi
i am trying to do modelling in gams but i faced such a problem:
in one of my equations i write
precedence(i).. sum(k, x(i,k)*k) =L= something for example.
When i write like this it gives dimension different error. But if i write this equation in opened form for i=1 for example, it doesnt give any error. But i need to write this in closed form.
By the way, the error happens only if i multiply k with x (k*x(i,k))
Related information:
k is a set /1*5/
i is a set /1*5/
x(i,k) is a binary variable
i am trying to do modelling in gams but i faced such a problem:
in one of my equations i write
precedence(i).. sum(k, x(i,k)*k) =L= something for example.
When i write like this it gives dimension different error. But if i write this equation in opened form for i=1 for example, it doesnt give any error. But i need to write this in closed form.
By the way, the error happens only if i multiply k with x (k*x(i,k))
Related information:
k is a set /1*5/
i is a set /1*5/
x(i,k) is a binary variable