Hi,
I have declared two similar equations in GAMS over two similar indices.
Q_SU_GENLIMITLOW_TRAJECTORY1(MIN_GEN_GEN,INTERVAL)$(ORD(INTERVAL) LE CARD(INTERVAL) - SHUTDOWN_PERIOD(MIN_GEN_GEN) AND (ORD(INTERVAL) GE STARTUP_PERIOD(MIN_GEN_GEN)-INTERVALS_STARTED_AGO(MIN_GEN_GEN)))…
GEN_SCHEDULE(MIN_GEN_GEN,INTERVAL)
- SUM(RESERVETYPE$(RESERVEVALUE(RESERVETYPE,“RESERVE_ON”)EQ 1 AND (RESERVEVALUE(RESERVETYPE,“RESERVE_DIR”) EQ 2 OR RESERVEVALUE(RESERVETYPE,“RESERVE_DIR”) EQ 3)),
GEN_RESERVE_SCHEDULE(MIN_GEN_GEN,INTERVAL,RESERVETYPE)) =G= GENVALUE(MIN_GEN_GEN,“MIN_GEN”)*(UNIT_STATUS(MIN_GEN_GEN,INTERVAL)…
;
*MG
Q_SU_GENLIMITLOW_TRAJECTORY1_MG(MIN_GEN_GEN_MG,INTERVAL)$(ORD(INTERVAL) LE CARD(INTERVAL) - SHUTDOWN_PERIOD_MG(MIN_GEN_GEN_MG) AND (ORD(INTERVAL) GE STARTUP_PERIOD_MG(MIN_GEN_GEN_MG)-INTERVALS_STARTED_AGO_MG(MIN_GEN_GEN_MG)))…
GEN_SCHEDULE_MG(MIN_GEN_GEN_MG,INTERVAL)
- SUM(RESERVETYPE$(RESERVEVALUE_MG(RESERVETYPE,“RESERVE_ON”)EQ 1 AND (RESERVEVALUE_MG(RESERVETYPE,“RESERVE_DIR”) EQ 2 OR RESERVEVALUE_MG(RESERVETYPE,“RESERVE_DIR”) EQ 3)),
GEN_RESERVE_SCHEDULE_MG(MIN_GEN_GEN_MG,INTERVAL,RESERVETYPE)) =G= GENVALUE_MG(MIN_GEN_GEN_MG,“MIN_GEN”)*(UNIT_STATUS_MG(MIN_GEN_GEN_MG,INTERVAL)…
;
However when I was looking how they got executed in the .lst file , I have found that they got executed quite in a different way,
---- Q_SU_GENLIMITLOW_TRAJECTORY1 =G=
Q_SU_GENLIMITLOW_TRAJECTORY1(CT NG 05,1)… GEN_SCHEDULE(CT NG 05,1) - GEN_RESERVE_SCHEDULE(CT NG 05,1,REGULATION) - 0.15UNIT_STATUS(CT NG 05,1) + 0.15UNIT_SHUTDOWN(CT NG 05,1) =G= 0 ; (LHS = 0.35)
Q_SU_GENLIMITLOW_TRAJECTORY1(CT NG 05,2)… GEN_SCHEDULE(CT NG 05,2) - GEN_RESERVE_SCHEDULE(CT NG 05,2,REGULATION) - 0.15UNIT_STATUS(CT NG 05,2) + 0.15UNIT_SHUTDOWN(CT NG 05,2) =G= 0 ; (LHS = 0.033)
Q_SU_GENLIMITLOW_TRAJECTORY1(CT NG 05,3)… GEN_SCHEDULE(CT NG 05,3) - GEN_RESERVE_SCHEDULE(CT NG 05,3,REGULATION) - 0.15UNIT_STATUS(CT NG 05,3) + 0.15UNIT_SHUTDOWN(CT NG 05,3) =G= 0 ; (LHS = 0.0995)
REMAINING 4252 ENTRIES SKIPPED
And the other one,
---- Q_SU_GENLIMITLOW_TRAJECTORY1_MG =G=
Q_SU_GENLIMITLOW_TRAJECTORY1_MG(NUC 01,12)… GEN_SCHEDULE_MG(NUC 01,12) - GEN_RESERVE_SCHEDULE_MG(NUC 01,12,REGULATION) - UNIT_STATUS_MG(NUC 01,12) + 0.0833333333333334UNIT_STARTUP_MG(NUC 01,2) + 0.166666666666667UNIT_STARTUP_MG(NUC 01,3) + 0.25UNIT_STARTUP_MG(NUC 01,4) + 0.333333333333333UNIT_STARTUP_MG(NUC 01,5) + 0.416666666666667UNIT_STARTUP_MG(NUC 01,6) + 0.5UNIT_STARTUP_MG(NUC 01,7) + 0.583333333333333UNIT_STARTUP_MG(NUC 01,8) + 0.666666666666667UNIT_STARTUP_MG(NUC 01,9) + 0.75UNIT_STARTUP_MG(NUC 01,10) + 0.833333333333333UNIT_STARTUP_MG(NUC 01,11) + 0.916666666666667UNIT_STARTUP_MG(NUC 01,12) + UNIT_SHUTDOWN_MG(NUC 01,12) + 0.916666666666667UNIT_SHUTDOWN_MG(NUC 01,13) + 0.833333333333333UNIT_SHUTDOWN_MG(NUC 01,14) + 0.75UNIT_SHUTDOWN_MG(NUC 01,15) + 0.666666666666667UNIT_SHUTDOWN_MG(NUC 01,16) + 0.583333333333333UNIT_SHUTDOWN_MG(NUC 01,17) + 0.5UNIT_SHUTDOWN_MG(NUC 01,18) + 0.416666666666667UNIT_SHUTDOWN_MG(NUC 01,19) + 0.333333333333333UNIT_SHUTDOWN_MG(NUC 01,20) + 0.25UNIT_SHUTDOWN_MG(NUC 01,21) + 0.166666666666667UNIT_SHUTDOWN_MG(NUC 01,22) + 0.0833333333333334UNIT_SHUTDOWN_MG(NUC 01,23) =G= 0 ; (LHS = 1)
As it is clear , where the first one executes it in a chronological way, the second integrates all the intervals in a single line execution.
Since, it is a part of very big code so I am expecting suggestions from you guys about where to look at or to what should I look at to dig out the problem.
Regards,
Jubeyer