Index change for constraints

Hello everybody,

I need to write an equation for my model.
I m trying to write T(i) > T(i-1) for every i .
T is decision variable and i is index for T variable.
i is a set which includes 1,2,3,…,N. N is very big integer.

Can you help me please?

Thanks a lot.

Hi, Is T a binary or continuous variable?
Is “T(i)” greater (>) or greater than or equal (>=) than “T(i-1)” ?
Bye

Hi,
T is continuous and positive variable.
Constraint has equality.
In gams code is like " eq(i)… T(i) =g= T(i-1)"
However for the i-1 case it can not run.
Thanks.

Ok, you must start with the second value of i

eq(i)$(ord(i) ge 2)… T(i) =g= T(i-1);

Bye!

That is worked. Thanks a lot :slight_smile: