Скачать презентацию System planning 2013 Lecture L 10 Short Скачать презентацию System planning 2013 Lecture L 10 Short

d03950f4223fbe19f0bb5d4ed9d6416c.ppt

  • Количество слайдов: 23

System planning 2013 • Lecture L 10: Short term planning of hydrothermal systems Chapter System planning 2013 • Lecture L 10: Short term planning of hydrothermal systems Chapter 5. 2. 5, 5. 3. 4, 5. 4. 1, Appendix B Contents: • • – – – Dual variables GAMS, example Home assignment 3 1

Dual variables • LP problem on standard form: • The solution of the problem Dual variables • LP problem on standard form: • The solution of the problem will result (except of the optimal solution itself) in one dual variable per constraint • The dual variables are measurements of how much the objective function will change if the right-hand side of the constraints are changed 2

Dual variables x 2 4 z = 40 3 z = 30 x 1+x Dual variables x 2 4 z = 40 3 z = 30 x 1+x 2 7 z = 20 2 3 1 x 2 0 x 1 0 1 2 3 x 1+x 2 2 1 x 1 4 4 x 1+12 x 2 12 In optimum: 1 > 0 (active) 2 > 0 (active) 3 = 0 (not active) 2 3

Dual variables 1 • Hydrological constraints: 2 – Hydrological constraints have units HE – Dual variables 1 • Hydrological constraints: 2 – Hydrological constraints have units HE – Objective function has unit currency (SEK, $, £. . . ) – Increase of V more water available larger income/more stored water optimal objective value increase The dual variables corresponds the water value [SEK/HE]. 4

Dual variables • Contracted load constraints for hour t: – Constraints have unit MWh Dual variables • Contracted load constraints for hour t: – Constraints have unit MWh – Objective function has unit SEK – Increase of Dk increased production cost or less water available at end of planning period optimal objective function value decreases Dual variables correspond the marginal cost for production, i. e. the power price [SEK/MWh]. 5

Dual variables - Example 1 • Assume hydropower planning for 6 hours. – The Dual variables - Example 1 • Assume hydropower planning for 6 hours. – The hydro system consists of 2 power stations. – The problem includes contracted load constraints. 2 • Solving the problem resulted in the following dual variables: 82. 4304 42. 6585 -190. 0389 -200. 0410 hydr. balance for station 1, k = 1, . . . , 6 hydr. balance for station 2, k = 1, . . . , 6 load balance, k = 1, 2, 3, 5, 6 load balance, k = 4 • Questions: – What can be said about the structure of the hydro system? – Assume that a customer want to buy another 5 MWh hour 2. How high must the price be for this to be profitable for the producer? 6

Home assignment 2 • Short term hydro-thermal planning • Solved by using the software Home assignment 2 • Short term hydro-thermal planning • Solved by using the software GAMS (www. gams. com) 7

GAMS • Software specialized for solving optimization problems. • Typical structure of GAMS program: GAMS • Software specialized for solving optimization problems. • Typical structure of GAMS program: 1. 2. 3. 4. 5. 6. Define sets Define parameters Declare optimization variables Declare equations Define variable limits 8

Example Known: • • • 1 Two power stations, Degerforsen (1) and Edensforsen (2). Example Known: • • • 1 Two power stations, Degerforsen (1) and Edensforsen (2). Have sold power to the power 2 exchange. Contracted load for the next 6 hours: 90, 98, 104, 112, 100, 80 MWh. Reservoirs filled to 80% at the beginning Stored water can be used at best efficiency and power generated in the future can be sold for 185 SEK/MWh. Neglect the delay time between stations 9

Example Power plant Maximal active storage of reservoir [m 3] Marginal production equivalents [MWh/HE] Example Power plant Maximal active storage of reservoir [m 3] Marginal production equivalents [MWh/HE] Mean flow, wi [m 3/s] Degerforsen 5*106 0. 209, 0 Q 225 HE 0. 199, 225 Q 300 163 Edensforsen 4*106 0. 236, 0 Q 202. 5 HE 0. 224, 202. 5 Q 270 164 10

Example • Known parameters: • Calculated parameters: • Optimization variables: = discharge, station i, Example • Known parameters: • Calculated parameters: • Optimization variables: = discharge, station i, segment j, during hour t, i=1, 2, j=1, 2, t=1, . . . , 6 = spillage, station i, during hour t, i=1, 2, j=1, 2, t=1, . . . , 6 = reservoir contents, station i, end of hour t, i=1, 2, j=1, 2, t=1, . . . , 6 11

Example • Objective: • Constraints: 12 Example • Objective: • Constraints: 12

Example • Variable limits: 13 Example • Variable limits: 13

GAMS Sets i power stations /Degerforsen, Edensforsen/ j segments /segment 1*segment 2/ t time GAMS Sets i power stations /Degerforsen, Edensforsen/ j segments /segment 1*segment 2/ t time /hour 1*hour 6/ ; Parameters Mmax(i) lambdaf w(i) maximum contents /Degerforsen 5 e 6 Edensforsen 4 e 6/ future price /185/ mean flow /Degerforsen 163 Edensforsen 164/ 14

GAMS D(t) Qmax(i, j) mu(i, j) V(i) Mstart(i) contracted load /hour 1 90, hour GAMS D(t) Qmax(i, j) mu(i, j) V(i) Mstart(i) contracted load /hour 1 90, hour 2 98, hour 3 104, hour 4 112, hour 5 100, hour 6 80/ maximum discharge station i segment j /Degerforsen. segment 1 225, Degerforsen. segment 2 75, Edensforsen. segment 1 202. 5, Degerforsen. segment 2 67. 5/ prod equivalent station i segmen j /Degerforsen. segment 1 0. 209, Degerforsen. segment 2 0. 199 Edensforsen. segment 1 0. 236 Degerforsen. segment 2 0. 224/ local inflow start contents of reservoir i ; 15

GAMS Mmax(i) = Mmax(i)/3600; V(i) = w(i)-w(i-1); Mstart(i) = 0. 5*Mmax(i); Positive variables Q(i, GAMS Mmax(i) = Mmax(i)/3600; V(i) = w(i)-w(i-1); Mstart(i) = 0. 5*Mmax(i); Positive variables Q(i, j, t) discharge station i, segment j, hour t S(i, t) spillage station i, hour t M(i, t) reservoir contents station i, hour t ; Free variable z ; objective value of stored water 16

GAMS equation types 17 GAMS equation types 17

GAMS Equation objfnc objective function; objfnc. . z =e= lambdaf*((mu(”Degerforsen”, ”segment 1”) + mu(”Edensforsen”, GAMS Equation objfnc objective function; objfnc. . z =e= lambdaf*((mu(”Degerforsen”, ”segment 1”) + mu(”Edensforsen”, ”segment 1”))*M(”Degerforsen”, ”hour 6”) + mu(”Edensforsen”, ”segment 1”)* M(”Edensforsen”, ”hour 6”)) ; 18

GAMS Equations hydbal(i, t) Hydrological balance constraints loadbal(t) Load balance constraints ; hydbal(i, t). GAMS Equations hydbal(i, t) Hydrological balance constraints loadbal(t) Load balance constraints ; hydbal(i, t). . M(i, t) =e= M(i, t-1) + Mstart(i)$(ord(t)=1) – sum(j, Q(i, j, t)) – S(i, t) + sum(j, Q(i-1, j, t)) – S(i-1, t) + V(i); loadbal(t). . sum((i, j), mu(i, j)*Q(i, j, t)) =e= D(t); 19

20 20

GAMS Q. up(i, j, ”hour 1”) = Qmax(i, j); M. up(i, ”hour 1”) = GAMS Q. up(i, j, ”hour 1”) = Qmax(i, j); M. up(i, ”hour 1”) = Mmax(i); etc. . . Alternatively: loop(t, Q. up(i, j, t) = Qmax(i, j); M. up(i, t) = Mmax(i)); 21

GAMS model hydroplanning /all/; solve hydroplanning using lp maximizing z; Structuring output: Parameters Qtot(i, GAMS model hydroplanning /all/; solve hydroplanning using lp maximizing z; Structuring output: Parameters Qtot(i, t) total discharge per station and hour H(i, t) power production per station and hour ; loop((i, t), Qtot(i, t) = sum(j, Q. L(i, j, t)); H(i, t) = sum(j, mu(i, j)*Q. L(i, j, t))); display M. L, Qtot, H, S. L; display hydbal. M, loadbal. M; 22

Discharge plan 23 Discharge plan 23