DED-PB : Price based Dynamic Economic Load Dispatch

Reference

  • Alireza Soroudi, Power System Optimization Modelling in GAMS, Model DED-PB (Gcode4.5) in chapter Dynamic Economic Dispatch, 2017

Category : GAMS PSOPT library


Mainfile : DED-PB.gms

$title Price based Dynamic Economic Load Dispatch

$onText
For more details please refer to Chapter 4 (Gcode4.5), of the following book:
Soroudi, Alireza. Power System Optimization Modeling in GAMS. Springer, 2017.
--------------------------------------------------------------------------------
Model type: QCP
--------------------------------------------------------------------------------
Contributed by
Dr. Alireza Soroudi
IEEE Senior Member
email: alireza.soroudi@gmail.com
We do request that publications derived from the use of the developed GAMS code
explicitly acknowledge that fact by citing
Soroudi, Alireza. Power System Optimization Modeling in GAMS. Springer, 2017.
DOI: doi.org/10.1007/978-3-319-62350-4
$offText

Set
   t 'hours'         / t1*t24 /
   i 'thermal units' / p1*p4  /;

Scalar lim / inf /;

Table gendata(i,*) 'generator cost characteristics and limits'
       a     b      c    d     e     f     Pmin  Pmax  RU0  RD0
   p1  0.12  14.80  89   1.2  -5     3     28    200   40   40
   p2  0.17  16.57  83   2.3  -4.24  6.09  20    290   30   30
   p3  0.15  15.55  100  1.1  -2.15  5.69  30    190   30   30
   p4  0.19  16.21  70   1.1  -3.99  6.2   20    260   50   50;

Table data(t,*)
        lambda  load
   t1   32.71   510
   t2   34.72   530
   t3   32.71   516
   t4   32.74   510
   t5   32.96   515
   t6   34.93   544
   t7   44.9    646
   t8   52      686
   t9   53.03   741
   t10  47.26   734
   t11  44.07   748
   t12  38.63   760
   t13  39.91   754
   t14  39.45   700
   t15  41.14   686
   t16  39.23   720
   t17  52.12   714
   t18  40.85   761
   t19  41.2    727
   t20  41.15   714
   t21  45.76   618
   t22  45.59   584
   t23  45.56   578
   t24  34.72   544;

Variable
   OF          'objective (revenue)'
   costThermal 'cost of thermal units'
   p(i,t)      'power generated by thermal power plant'
   EM          'emission calculation';

p.up(i,t) = gendata(i,"Pmax");
p.lo(i,t) = gendata(i,"Pmin");

Equation Genconst3, Genconst4, costThermalcalc, balance, EMcalc, EMlim, benefitcalc;

costThermalcalc.. costThermal =e= sum((t,i), gendata(i,'a')*power(p(i,t),2)
                                           + gendata(i,'b')*p(i,t) + gendata(i,'c'));

Genconst3(i,t)..  p(i,t+1) - p(i,t) =l= gendata(i,'RU0');

Genconst4(i,t)..  p(i,t-1) - p(i,t) =l= gendata(i,'RD0');

balance(t)..      sum(i,p(i,t))     =l= data(t,'load');

EMcalc..          EM =e= sum((t,i), gendata(i,'d')*power(p(i,t),2)
                                  + gendata(i,'e')*p(i,t) + gendata(i,'f'));

EMlim..           EM =l= lim;

benefitcalc..     OF =e= sum((i,t), 1*data(t,'lambda')*p(i,t)) - costThermal;

Model DEDPB / all /;
solve DEDPB using qcp maximizing of;

embeddedCode Connect:
- GAMSReader:
    symbols: [ { name: p } ]
- Projection:
    name: p.l(i,t)
    newName: p_l(i,t)
- ExcelWriter:
    file: DEDPB.xlsx
    symbols: [ { name: p_l, range: report!A1 } ]
endEmbeddedCode