Executable coverage
151 tests and 372 subtests passed across P-Q allocation, Volt-VAR, frequency-watt, filtering, ramping, derating, SOC, reserves, and multi-interval sequences.
Executable playbook · Executable playbook
Trace a grid-support request through every constraint that can change it.
Dependency-free Python references compose voltage, frequency, ramp, temperature, energy, reserve, and P-Q limits while preserving each intermediate request and curtailment for review.
Engineering question
Follow active power, reactive power, voltage, frequency, temperature, ramp, and SOC requests through visible constraint layers.
System and evidence boundary
The order of operations matters. The playbook records the request at each layer instead of presenting only the final active and reactive power.
Verified results
Every visual below points to its source data or retained source format and to the release- or commit-specific implementation behind it.
Generated from the committed four-quadrant CSV. The values deliberately differ by direction to demonstrate the allocator and are not a PCS rating or grid-code setting.
python scripts/generate-open-engineering-figures.py --sources-root <audit-root>Validation and evidence
One hundred fifty-one tests and 372 subtests passed across capability, support, filtering, ramp, derating, SOC, reserve, and sequence references.
151 tests and 372 subtests passed across P-Q allocation, Volt-VAR, frequency-watt, filtering, ramping, derating, SOC, reserves, and multi-interval sequences.
Default Volt-VAR, frequency-watt, capability, and temperature tables are educational test inputs, visibly labeled and replaceable.
Sequence results separate AC and stored-energy throughput, conversion loss, standing losses, SOC balance, and a non-degradation equivalent-cycle normalization.
The references do not model network dynamics, converter switching, PLL or grid-forming control loops, protection, voltage feedback, or electromagnetic transients.
Shortest verified path
git clone https://github.com/mohammadrezwankhan/smart-grid-storage-playbook.git
cd smart-grid-storage-playbook
git checkout 3ce0b4b2fd4af2bea743013eac2eee1042b6bdd3
python models/pq_capability.py --active-mw -65 --reactive-mvar -70 --directional-curve-csv models/data/illustrative_directional_capability.csv --priority active
python models/grid_support_sequence.py --frequency-hz-profile 50,49.5,50.5 --voltage-pu-profile 1,0.92,1.08 --baseline-active-mw-profile 20,20,20 --duration-minutes-profile 15,15,15 --limit-mva 100 --energy-capacity-mwh 100 --initial-soc 0.50 --minimum-soc 0.20 --charge-efficiency 1 --discharge-efficiency 1
python -m unittest discover -s tests -v
Verification environment: Python 3.14.6 on Windows 11. Commands are concise entry points; repository documentation remains authoritative for setup details.
Documentation map
Engineering boundary
Related professional context