my code in Gams:
con5(s,T)… sum((t,r,c)$( ord(t) le ord(T)+3 and (RR(s,c) eq 1)),x(s,r,t,c))=l=3;
I guess t=T in first summation has problem
please check my first summation(from t=T to T+3) and help me to find the right code.
thanks
–
To unsubscribe from this group and stop receiving emails from it, send an email to gamsworld+unsubscribe@googlegroups.com.
To post to this group, send email to gamsworld@googlegroups.com.
Visit this group at http://groups.google.com/group/gamsworld.
For more options, visit https://groups.google.com/d/optout.
Hello
- GAMS is not case sensitive, so your identifiers “t” and “T” are indistinguishable to GAMS
- You are summing over T, therefore your set of equations con5(c,T) cannot be indexed by T.
- You surely got error messages. Did you try to interpret them? They are usually helpful, if one reads them carefully.
- You didn’t tell us what you are trying to achieve, so we cannot suggest how to achieve it.
Best regards and good luck
Paul
From: mohsen >
Reply-To: “gamsworld@googlegroups.com” >
Date: Thursday, February 12, 2015 9:03 AM
To: “gamsworld@googlegroups.com” >
Subject: please check my code
[https://lh6.googleusercontent.com/-cdHDAURHnv8/VNyxF6uKVQI/AAAAAAAAAL0/2uL0REB4CTE/s1600/con%2B5.jpg]
my code in Gams:
con5(s,T)… sum((t,r,c)$( ord(t) le ord(T)+3 and (RR(s,c) eq 1)),x(s,r,t,c))=l=3;
I guess t=T in first summation has problem
please check my first summation(from t=T to T+3) and help me to find the right code.
thanks
–
To unsubscribe from this group and stop receiving emails from it, send an email to gamsworld+unsubscribe@googlegroups.com.
To post to this group, send email to gamsworld@googlegroups.com.
Visit this group at http://groups.google.com/group/gamsworld.
For more options, visit https://groups.google.com/d/optout.
\
Reply-to: gamsworld@googlegroups.com
it is about examination timetabling.
t is time(number of permitted days for examination time tabling) and it is from 1 to 20
and T is from 1 to 17
it means we are not going to have more than 3 exams in each 4 day.
then in first constraint it(t) starts from 1 to 4
in second constraint it starts from 2 to 5
in third constraint it starts from 3 to 6
…
and in 17th constraint it starts from 17 to 20 ( because we have just 20 day)
\
To unsubscribe from this group and stop receiving emails from it, send an email to gamsworld+unsubscribe@googlegroups.com.
To post to this group, send email to gamsworld@googlegroups.com.
Visit this group at http://groups.google.com/group/gamsworld.
For more options, visit https://groups.google.com/d/optout.