← Lesson diary · Process Identification and Control
Process Identification and Control · Lesson 14
An aggregator operates the chargers of a fleet of electric vehicles. It has sold the grid a power profile it promises the fleet will follow, and at the same time every driver has asked for a charge by a given hour. The two goals pull against each other, and the controller has to choose. This is the aggregator problem of the lesson, solved in your browser.
| Strategy | Mean deviation | Worst deviation | Energy delivered | Drivers left short | Missing energy | Peak power |
|---|
One optimization over the day, with the arrivals, departures and requests of every vehicle known. In closed loop it is re-solved at every step on the vehicles connected at that moment, which is the set PEVi|k of the lesson.
min d1 Σi (Pi|k − Prefi|k)2 + d3 Σp εp
Pi|k = Σp (Pchi|k,p − Pdisi|k,p)
xi+1|k,p = xi|k,p + ηch T Pchi|k,p − (1/ηdis) T Pdisi|k,p
xFp|k,p ≥ xrefp − εp εp ≥ 0 0 ≤ xi|k,p ≤ xmaxp
The deadline of each driver is the relaxed constraint of the lesson: the slack εp is free to be positive, and it is paid for in the cost with the weight d3, which is what the priority slider moves. A small d3 lets the controller disappoint a driver to follow the grid better; a large one makes it disappoint a driver only when the request cannot be met at all.
Two notes on how this page differs from the blackboard. The square of the deviation is replaced by the largest of a family of tangent lines to it, which keeps the problem linear and is exact to within a fraction of a percent here; switching the penalty to the plain absolute value, with the checkbox, changes the shape of the solution, because the square spreads the error over many hours while the absolute value concentrates it in few. And the minimum charging power of a real charger — the semi-continuous variable of the lesson — is left out: it would turn this linear program into a mixed-integer one, as in the Building Energy Lab.
The solver is the same simplex written for the building lab, checked against the Cbc solver on random instances of this model.