Energy Project
Energy Project
1 Introduction
This project builds on the energy writeups we have covered in the course, with some simplifications.
The raw data is provided in the three csv files that come with this project (Buses, Branches, and
Generators). Note: all indexing is done starting from 0 rather than 1 (i.e., there is a bus 0, a branch
0 and a generator 0).
Data is as follows:
• Generators. For each generator h we provide its ID, the bus that it is housed at, the value
Uh and the cost function Ch (Phg ). This cost function is piecewise linear and given by three
parameters σ1,h , σ2,h and Xh , with the following interpretation:
Ch (Phg ) = σ1,h Phg , when 0 ≤ Phg ≤ Xh (1)
= σ1,h Xhg + σ2,h (Phg − Xhg ) when Xh ≤ Phg ≤ Uh (2)
Note: the cost function is convex, meaning σ1,h ≤ σ2,h (or we have a data error). Wind
generators have zero operating cost.
• Buses. For each bus k we have its demand Pkd .
• Branches. For each branch we provide its ID, its “from” and “to” buses, its y parameter,
and its limit.
In the attached data, the network has 1814 buses, 2023 branches and 395 generators.
is modified as follows:
Phg − (Pkd − Sk ),
X X X
fℓ − fℓ = (4)
ℓ∈F (k) ℓ∈T (k) h∈G(k)
Here, Sk is a new variable; it models demand that is being ’lost’ or ’shed’. This quantity should be
kept as small as possible. We impose
0 ≤ Sk ≤ Pkd , (5)
and the objective function becomes accordingly, we add to the objective a penalty term:
P g 6
P
Minimize h∈G Ch (Ph ) + 10 k Sk (6)
For completeness, we also write all the constraints
1
1. For any line ℓ = (i, j)
fℓ = yℓ (θi − θj ) (7)
Phg − (Pkd − Sk ),
X X X
fℓ − fℓ = (8)
ℓ∈F (k) ℓ∈T (k) h∈G(k)
0 ≤ Sk ≤ Pkd , (9)
0 ≤ Phg ≤ Uh (10)
|fℓ | ≤ Lℓ . (11)
2 The project
2.1 First task
Solve the real-time problem, i.e. the optimization problem given above. Is any demand lost?
where the sum is over all the buses, and for each bus k,
In this part of the project we study the impact on cost of wind variability. To that effect,
1. Assume that the ’U’ quantity for ’wind’ generators (indicated as such in ’generators.csv’) is
in fact the expectation of maximum available power.
2. Assume that the output of wind generators is multivariate Gaussian, with mean as just
indicated, and covariance as per the matrix ’covariance.txt’.
3. Repeat the following experiment at least 1000 times: sample output for the wind farms as
just indicated (please remember that output cannot be negative). Solve the resulting LP.
Then compute the cost as indicated above in formula (12).
5. The public cost defined above becomes a random variable under the distribution I asked you
to simulate. Estimate the value-at-risk of this quantity at the 95 % level.
2
6. In the default case of the optimization problem introduce above (i.e. with wind output at the
original values), it should be the case that some (or many?) generators reach their output
limit. This suggests that at least some of these generators are more efficient than others –
hence if we could increase their capacity, the public cost would decrease. Investigate this
possibility: double the capacity of every non-wind generator whose output is at
the output limit as originally stated – does the VAR decrease? By how much?
Fri.Apr.18.205302.2025@freestyle