Hi,
I am a pretty new user of GAMS. Recently I have come across a code snippet which is follows:
IFI '%SUSD_TRAJECTORY_CHECK%' == YES Q_SU_PUMP_RAMPDOWN_TRAJECTORY0(CONVENTIONAL_STORAGE_GEN,INTERVAL)(ORD(INTERVAL) EQ 1)…
$IFI ‘%SUSD_TRAJECTORY_CHECK%’ == YES STORAGEVALUE(CONVENTIONAL_STORAGE_GEN,“INITIAL_PUMP_MW”) - CONVENTIONAL_PUMP_SCHEDULE(CONVENTIONAL_STORAGE_GEN,INTERVAL)
$IFI ‘%SUSD_TRAJECTORY_CHECK%’ == YES =L= INTERVAL_LENGTH60STORAGEVALUE(CONVENTIONAL_STORAGE_GEN,“PUMP_RAMP_RATE”)*
$IFI ‘%SUSD_TRAJECTORY_CHECK%’ == YES (STORAGEVALUE(CONVENTIONAL_STORAGE_GEN,“INITIAL_PUMP_STATUS”)
IFI '%SUSD_TRAJECTORY_CHECK%' == YES - SUM(H(ORD(H) GE ORD(INTERVAL) AND (ORD(H) LE (ORD(INTERVAL) )))
$IFI ‘%SUSD_TRAJECTORY_CHECK%’ == YES ;
Now I would like to know why it is written in this way, since it is only a single equation but why the conditional statements are written that many times instead of just once.
Regards,