Eeb 561 Lab 2 Report

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 12

FACULTY OF ENGINEERING AND TECHNOLOGY

DEPARTMENT OF ELECTRICAL ENGINEERING


[
D
a
t
e
]

EEB 561: Power System Operation


Laboratory Work Two: Unit Commitment by Mixed Integer Linear
Programming

Group Members:

Obakeng Mabe 201700231


Shepherd Berele 201702151
Lentibile Obuseng 201700295

SUBMISSION DATE: 15/05/2022


TABLE OF CON [1]TENTS

OBJECTIVES............................................................................................................................................3
INTRODUCTION.....................................................................................................................................3
THEORY AND BACKGROUND INFORMATION..............................................................................3
METHODOLOGY....................................................................................................................................6
REFERENCES..........................................................................................................................................8

1|Page
ABSTRACT
The task of determining an ideal schedule and production level for each producing unit in a
power system for a certain period of time while fulfilling device and operating restrictions is
known as unit commitment. Matlab was used to formulate and solved the MILP and an optimal
schedule was found for the six generating units.

2|Page
OBJECTIVES
 Studying the Unit Commitment of thermal units
 To use MATLAB MILP function to solve the unit commitment problem of a power
system

INTRODUCTION
Power systems are one of the most important infrastructures in a country since the commodity
involved is essential to everyday life. Nowadays, its availability and price are critical to many
companies and business. With the increasing importance of the role the power sector plays in the
modern society, a lot of effort has been put into developing a secure, reliable, and economic
power supply. The Unit commitment is crucial in achieving this goal; thus, the quality of its
solution is of the highest importance. The power generation industry utilizes unit commitment
and economic dispatch to help make generation scheduling decisions. The objective of a UC
problem is to identify a schedule of committing units to minimize the joint cost of committing
and decommitting units and economic dispatch. At the same time, it meets the forecasted
demand and spinning reserve requirements, that allow for uncertainty compensation and
technological generating unit constraints. The unit commitment problem is computationally
challenging due to the nonlinear objective function, the mixed-integer features, and the large
dimension. For this reason, obtaining an optimal or even a good sub-optimal solution is a great
challenge [1].

THEORY AND BACKGROUND INFORMATION


For many years, approaches to solving the Unit Commitment Problem were based on Lagrangian
relaxation and heuristics. This was due to the non-existence of exact approaches capable of
coping with the computational complexity of the problem using reasonable resources. However,
the dramatic improvement of Mixed Integer Problem solvers in recent years suggested that an
effort should be applied to studying good mathematical formulations of the problem, so that it
can be handled by relevant solvers. The first requirement is the linearisation of the various
nonlinearities in the problem; namely, minimum up and down time constraints, minimum and
maximum power production constraints, and the objective function. Several efforts have been
made to improve and strengthen the formulation of the Unit Commitment Problem. This work
considers three sets of binary variables that model the state of each unit, start-ups, and
shutdowns. The quadratic fuel cost function is represented by a piecewise-linear cost function.
Initial attempts to solve the problem with standard branch-and-bound proved to be inefficient [2]
.
It has been recognized that critical decisions associated with the operation of the power system
can effectively be represented by integer (binary) variables and, therefore, classical linear
programming approaches are not able to clearly model and solve such problems. In MILP
formulations, the commitment decisions indicating the ON/OFF status of the generating units in
various operating phases (offline, start-up, dispatch, and shutdown) are modelled using binary

3|Page
variables, while the power output, reserve contribution, and flow decisions are represented using
continuous variables. The dramatic increase in efficiency of mixed integer programming (MIP)
solvers encourages thorough exploitation of their capabilities
THE MILP Formulation of Unit Commitment
The MILP formulation of UC with start-up/shut down indicators [3]
𝑂𝐶 = ∑∑ 𝐹𝐶𝑖𝑡(𝑃𝑖𝑡)𝐼𝑖𝑡 + 𝑁𝐼𝑖𝑡 + 𝑆𝑇𝑖𝑡 + 𝑆𝐷𝑖𝑡 𝑇 𝑡=1 𝑁 𝑖=1
𝑂𝐶: Operating cost
𝑁: No. of generating units
𝑇: Time Horizon (24Hrs)
𝐼𝑖𝑡: A binary variable modelling UC decision of unit 𝑖 at hour 𝑡.
𝐹𝐶𝑖𝑡(𝑃𝑖𝑡): Fuel cost,
𝑁𝐼𝑖𝑡: The no-load cost of unit 𝑖.
𝑆𝑇𝑖𝑡 and 𝑆𝐷𝑖𝑡are the start-up and shutdown costs of unit 𝑖 at 𝑡.
𝐹𝐶𝑖𝑡: is the I/O curve that is modelled with a quadratic function of the power output.
𝐹𝐶𝑖𝑡(𝑃𝑖𝑡) = 𝑎𝑖𝑃𝑖𝑡 2 + 𝑏𝑖𝑃𝑖𝑡 + 𝑐𝑖
𝑎𝑖, 𝑏𝑖, 𝑐𝑖: are cost coefficients
𝑆𝑖𝑡: The cost for restarting a de-committed thermal unit, which is dependent on the temperature
of the boiler.
The number of the start-up and shutdown and their type (hot or cold) changes in function of the
ON/OFF status of the units. t is expressed as follows;
𝑆𝑇𝑖𝑡 = { 𝐻𝑆𝑁𝑖 , 𝑖𝑓 𝑀𝐷𝑇𝑖 ≤ 𝑇𝑜𝑓𝑓,𝑖 (𝑡) ≤ 𝑀𝐷𝑇𝑖 + 𝑇𝑐𝑜𝑙𝑑,𝑖
𝐶𝑆𝑁𝑖 , 𝑖𝑓 𝑇𝑜𝑓𝑓,𝑖 (𝑡) > 𝑀𝐷𝑇𝑖 + 𝑇𝑐𝑜𝑙𝑑,𝑖
where 𝐻𝑆𝑁𝑖 and 𝐶𝑆𝑁𝑖are respectively the hot and cold start-up cost of unit 𝑖. 𝑀𝐷𝑇𝑖 is the
minimum downtime of unit i. 𝑇𝑜𝑓𝑓, 𝑖 is the continuous offline period of unit i at hour t. 𝑇𝑐𝑜𝑙𝑑, 𝑖
is the cold start hour of unit i. ‘
The shutdown costs are usually neglected and have been taken to be equal to zero for all units
Constraints
1. Generation limits 𝑃𝑖𝑡(𝑚𝑖𝑛) < 𝑃𝑖𝑡 < 𝑃𝑖𝑡(𝑚𝑎𝑥)
2. Power balance ∑𝑃𝑖(max)(𝑡).𝐼𝑖 (𝑡) = 𝐷𝑡
𝐷𝑡: Total demand
3. Min up/down time constraints

4|Page
min up-time is the min number of hours of operation at or above the min generation capacity. It
is expressed as;
𝑇𝑖 𝑜𝑛 > 𝑀𝑈𝑇𝑖
where 𝑇𝑖 𝑜𝑛 and 𝑀𝑈𝑇𝑖 are the total up-time and minimum up-time of unit i.
Minimum downtime is the minimum number of hours once the generator is shut down before it
can be brought online again to generate power
𝑇𝑖 𝑜𝑓𝑓 > 𝑀𝐷𝑇𝑖
where 𝑇𝑖 𝑜𝑓𝑓and 𝑀𝐷𝑇𝑖 are the total downtime and the minimum downtime of unit i.
4. Ramp rate up/down
The generator power output is not changing instanteously. Its variation depends on ramp rate
limits. These constraints are formulated based on the following conditions;
𝑃𝑖,𝑡 − 𝑃𝑖,𝑡−1 ≤ 𝑈𝑅𝑖
𝑃𝑖,𝑡−1 − 𝑃𝑖,𝑡 ≤ 𝐷𝑅𝑖
where 𝑈𝑅𝑖 and 𝐷𝑅𝑖 are the ramping up and ramping down of unit i.
5. Spinning reserve SR is an indicator of the amount of power that is required to fulfil percentage
of forecasted peak demand or capable of making up the loss of the most important loaded unit in
each time. The formulation for SR can be expressed as;
∑ (𝐼𝑖𝑡.𝑃𝑖𝑡) ≥ (𝐷𝑡 + 𝑅𝑡) 𝑁 𝑖 , 1 ≤ 𝑡 ≤ 𝑇
where 𝑅𝑡 is the SR at hour t.
6. Must run and must shut units Must run units are a pre-scheduled unit which must be online,
due to operating reliability or economic purposes. The RES units for example are necessary run
units for better economic system operation. Must shut units are the units unavailable for
commitment because of forced outages or maintenance.
7. Transmission Constraints
Transmission constraints are to satisfy customer load demands and maintain transmission flows
and bus voltages within admissible limits. Generally, linear DC (direct current) transmission
constraints are integrated in UC problem formulation for system security considerations.
8. Crew constraints
In a plant with many units, there may not be enough personnel to attend both the units if both are
starting up and/or shutting down simultaneously. Such constraints would be set by the times
required to start-up and to shut down the unit.

5|Page
METHODOLOGY
EQUIPMENT USED
 Computer with MATLAB R2022a,

PROCEDURE
 A Matlab was used in to formulate and solve the unit commitment problem.The code was
ran using the Matlab to obtain the generation states for the specified duration of 24hrs.

Figure 1 Flowchart for MILP Solution

RESULTS AND ANALYSIS.

Table 1: Optimum Daily Output for 6 Generators

Hour Unit1 Unit2 Unit3 Unit4 Unit5 Unit6 Demand


1 156.33 187.59 170.54 150.00 170.54 120.00 955
2 138.31 165.97 150.88 165.96 150.88 170.00 942
3 0 163.92 149.02 163.91 312.1 172.54 935
4 0 163.04 148.22 298.01 148.22 171.61 930
5 136.60 163.92 149.02 163.91 149.01 172.54 935
6 140.69 168.82 153.48 168.82 153.48 177.70 963
7 145.21 174.25 158.41 174.24 158.41 178.48 989
8 150.2 180.24 163.86 180.23 163.85 184.62 1023
9 165.33 198.38 180.35 198.38 180.35 203.20 1126
10 168.84 202.617 184.20 202.61 184.20 207.54 1150
11 176.34 211.60 192.36 211.60 192.36 216.74 1201

6|Page
12 181.33 217.59 197.81 217.58 197.81 222.88 1235
13 174.72 209.66 190.60 209.65 190.60 214.75 1190
14 183.68 220.41 200.37 220.40 200.37 225.76 1251
15 183.97 222.53 202.29 222.51 202.29 227.93 1263
16 183.53 220.24 200.21 220.22 200.21 225.58 1250
17 179.27 215.13 195.57 215.11 195.57 220.35 1221
18 176.48 211.78 192.52 211.77 192.52 216.92 1202
19 170.17 204.20 185.63 204.19 185.63 209.16 1159
20 160.33 192.40 174.91 192.39 174.91 197.07 1092
21 150.20 180.24 163.85 180.23 163.85 184.62 1023
22 150.20 173.37 157.61 173.36 157.61 177.58 984
23 143.16 171.78 156.17 171.77 156.17 175.96 975
24 140.95 169.14 153.76 169.13 153.76 173.25 960

Figure 2 GENERATOR 3 LOADING COMMITMENT SCHEDULE

DISCUSSION

7|Page
This work presented a linear formulation of the thermal unit commitment problem with
constraints using a computationally efficient mixed integer. The best solution includes the best
generating unit schedule and production levels, as well as the best regulating and contingency
reserve schedules and levels at the lowest overall cost. It must be noted that in this case the
demand does not change as it is extracted from the load demand profile. The model integrates the
market for energy and related services into a single problem. It also optimizes fuel, start-up, shut-
down, and auxiliary services to reduce overall production costs.
CONCLUSION
An optimal unit commitment schedule was found for the generating units using the MILP solver.
The optimal solution provides the optimal generating units schedule with their production levels,
as well as the regulating reserves and contingency reserves schedule and levels at least total cost

REFERENCES

[1] M. Koller, "Mixed-Integer Linear Programming Formulation of Combined Heat and Power Units for
the Unit Commitment Problem," Journal of Sustainable Development of Energy, Water and
Environment Systems , vol. VI, no. 4, p. 755, 2018.

[2] B. Ju, "An Improved Mixed Integer Linear Programming Approach Based on Symmetry Diminishing
for Unit Commitment of Hybrid Power System," MDPI, p. 875, 2019.

[3] B. F. W. ALLEN J .WOOD, "4.2.3 Mixed Integer Linear Programming," in POWER GENERATION
OPERATION AND CONTROL, NEW YORK, WILEY, 2014, p. 166.

8|Page
APPENDICES
CODE

N=5 t=6 %Number of iterations and time periods

H=2*[240 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 200 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 220 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 200 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 220 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 240 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 200 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 220 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 200 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 220 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 240 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 200 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 220 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 200 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 220 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 240 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 200 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 220 0 0 0 0 0 0 0
0 0 0 0 0 0 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 0 0 0 0 0 0 0 0 -1 0 0 0 0 1 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 -1 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -1 0 0 0 0 1 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 -1 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -1 0 0 0 0 1 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 -1 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -1 0 0 0 0 1 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 -1
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -1 0 0 0 0 1];

b=[80; 50; 65; 50; 50; 80; 50; 65; 50; 50; 80; 50; 65; 50;
50; 80; 50; 65; 50; 50; 80; 50; 65; 50; 50; 80; 50; 65; 50;
50; 80; 50; 65; 50; 50; 80; 50; 65; 50; 50;];
Aeq=[ 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1];

beq=[955; 942; 935; 930; 935];


10 | P a g e
lb=[100; 50; 80; 50; 50]; %Lower bounds for the generating
units
ub=[500; 200; 300; 150; 200];%Upper bounds for generating
units

%MILP Solver
[X,J]=quadprog(H,f,A,b,Aeq,beq,lb,ub);

11 | P a g e

You might also like