Three ways to dispatch a battery in a study
- Perfect foresight: a linear programme over the year (or month by month) that knows every quarter-hour of load, solar and price. It finds the cheapest possible bill. Use it as the upper bound, always labelled as such.
- Rolling horizon: re-optimise every day over the next 24–48 hours using forecasts, such as the same weekday last week, and commit only the first part. Day-ahead prices are known about a day ahead, so the price forecast is good; the peak-load forecast is where it loses most for peak shaving.
- Rule-based: fixed rules of the kind commercial EMSs use. It needs no forecast of the whole year and behaves the same way every time, which makes it the expected case for a business case.
Open-source EMS software shows what real controllers look like: OpenEMS has separate controllers for peak shaving, time-slot peak shaving and time-of-use tariffs (OpenEMS repository).
How a rule-based controller decides
In Zorowatt's design, the controller works in this order every quarter-hour:
- Peak guard: if the site's load is above the month's threshold, discharge the difference, as far as power and stored energy allow.
- Solar surplus: if the site is exporting, charge from the surplus, up to the battery's power and free capacity; export the rest.
- Arbitrage, on a dynamic or time-of-use contract: from the known day-ahead prices, mark the cheapest quarter-hours to charge and the dearest to discharge — only when the spread after losses beats a threshold, only without breaking the peak threshold, and never below the energy reserved for the next risky window.
- Otherwise idle.
The threshold for each month is the lowest one at which every day's energy above it fits in the usable capacity, with a safety margin (10% by default, an assumption). In the realistic case it is set from earlier data, not from the month itself, so the controller cannot see the future. A breach it cannot avoid becomes the month's new peak, and it is billed.
Why the optimiser is always ahead
- It knows which day will set the month's or the year's peak, and keeps exactly enough energy for it.
- It sets the threshold to the exact kW, with no safety margin.
- It trades on prices it already knows. In Zorowatt's scenario notes, arbitrage is valued at half the average 2-hour day-ahead spread over 300 cycles a year: €17.72 per kWh of capacity a year in the Netherlands (0.11812 × 0.5 × 300). The perfect-foresight bound from Modo Energy's 2025 Dutch spread of €83,000 per MW a year is about €41.5 per kWh a year for a 2-hour battery (Modo Energy): the assumption is 17.72 ÷ 41.5 ≈ 43% of the bound.
The capture ratio
Capture ratio = rule-based savings ÷ perfect-foresight savings. Illustrative: if the optimiser finds €20,000 a year and the rule-based controller €14,000, the ratio is 14,000 ÷ 20,000 = 70%. It tells the client how much a smarter controller could add, and it is a credibility number in its own right: a study that shows it is a study that did not hide the gap.
What the evidence says
- A model of office buildings found day-ahead optimisation of the battery and building setpoints could cut monthly peaks by up to 26% (Meinrenken & Mehmani, Applied Energy 2019); a PNNL study found a price-informed heuristic beat a rule of thumb for an office battery (PNNL, 2023). Both are models, not measured sites.
- A dispatch that ignores the bill cannot be trusted on demand charges. On the SAM forum, the tool's own team explained that its peak-shaving algorithm is not aware of the bill calculation and so cannot respond to ratcheted demand charges (SAM forum).
Rules every simulation should keep
- The battery starts the year empty and may not end it emptier, so stored energy never flatters the savings.
- Every dispatch — rule-based or optimised — is billed by the same bill engine as the baseline, line by line.
- Energy balances in every quarter-hour: grid import minus export equals load minus solar plus charging minus discharging.
- No charging and discharging in the same quarter-hour. An optimiser can do it at negative prices to burn energy through the losses; detect it and say how it was handled.
What it means for the numbers in a report
- Headline: the rule-based expected case.
- Next to it: the perfect-foresight upper bound and the capture ratio.
- Size on the rule-based case. A size chosen by the optimiser is sized for a year it knew in advance.
The Workspace runs both — the rule-based controller and the optimiser — and bills both with the same engine. The free peak-shaving calculator uses the rule-based dispatch.
Frequently asked questions
- Which number goes in the report?
- The rule-based expected case as the headline, with the perfect-foresight result next to it as the upper bound and the ratio between them. Never the upper bound as the forecast.
- Why not just use the optimiser's result?
- Because no real controller knows next year in advance. The optimiser's savings assume it hit every peak exactly and traded every price perfectly; the first year's bills would show the difference.
- Can a real EMS get close to the optimum?
- A controller that forecasts and re-plans daily can close part of the gap, especially on arbitrage, where day-ahead prices are known. Zorowatt's research found no measured capture ratio for C&I sites, so treat any claimed figure as an estimate.
- Does the controller need price data?
- Only for arbitrage on a dynamic or time-of-use contract. Peak shaving, solar storage and holding a connection limit work on the site's own load.
Related guides
- How to size a battery for peak shaving
- What makes a battery report survive the CFO
- Arbitrage on a dynamic contract
Sources
- OpenEMS repository
- Modo Energy, Netherlands BESS spreads and grid charges, 10 Aug 2026
- Synertics, Europe battery storage potential, updated 29 Jul 2026 (the €118.12 per MWh Dutch spread)
- Meinrenken & Mehmani, Applied Energy 254 (2019)
- PNNL, price-informed operation of a battery in an office building, 2023
- SAM forum, standalone battery peak-shaving dispatch
Last checked: 2026-10-30. Every figure in this guide comes from the source linked next to it, with the retrieval date Zorowatt's research recorded (28–30 October 2026), or from arithmetic shown step by step. The capture-ratio example is illustrative; the 10% safety margin and the arbitrage assumption are Zorowatt's own estimates.
Stuck on something else? Ask the community.
Poser une questionLes nouveaux guides dans votre boîte mail
Environ un e-mail par mois : nouveaux guides et vidéos, solutions aux problèmes sur lesquels on nous interroge, et actualités Zorowatt.
