Lemonergy · Studio block
Shared site power allocator
Share one grid-side power budget among one to eight requests.
- Implementation ID
site-power-allocator- Reviewed
- 2026-10-27
Behavior
Proportional allocation scales all nonnegative demands together. Input-priority allocation fills request 1 before request 2 and subsequent requests. It outputs allocated power for each configured input plus total demand, total allocation and unused power.
Interface
| Name | Direction | Unit | Meaning |
|---|---|---|---|
limit | input | W | Typed signal input; its quantity must match the connected output. |
demand1 | input | W | Nonnegative request. Only demand1 through the configured ports count may be connected. |
demand2 | input | W | Nonnegative request. Only demand1 through the configured ports count may be connected. |
demand3 | input | W | Nonnegative request. Only demand1 through the configured ports count may be connected. |
demand4 | input | W | Nonnegative request. Only demand1 through the configured ports count may be connected. |
demand5 | input | W | Nonnegative request. Only demand1 through the configured ports count may be connected. |
demand6 | input | W | Nonnegative request. Only demand1 through the configured ports count may be connected. |
demand7 | input | W | Nonnegative request. Only demand1 through the configured ports count may be connected. |
demand8 | input | W | Nonnegative request. Only demand1 through the configured ports count may be connected. |
totalDemand | output | W | Observed result from the solved component or sampled controller. |
totalAllocated | output | W | Observed result from the solved component or sampled controller. |
unusedPower | output | W | Observed result from the solved component or sampled controller. |
allocation1 | output | W | Allocated power; outputs exist through the configured ports count. |
allocation2 | output | W | Allocated power; outputs exist through the configured ports count. |
allocation3 | output | W | Allocated power; outputs exist through the configured ports count. |
allocation4 | output | W | Allocated power; outputs exist through the configured ports count. |
allocation5 | output | W | Allocated power; outputs exist through the configured ports count. |
allocation6 | output | W | Allocated power; outputs exist through the configured ports count. |
allocation7 | output | W | Allocated power; outputs exist through the configured ports count. |
allocation8 | output | W | Allocated power; outputs exist through the configured ports count. |
Parameters
Defaults are initial model values. Select values for your own model and operating conditions.
| Parameter | Unit | Default | Meaning and limits |
|---|---|---|---|
Portsports | count | 2 | Configured model parameter; the default is an initial editor value, not an operating recommendation. Minimum 1; Maximum 8 |
Limit WlimitW | W grid-side | 11000 | Configured model parameter; the default is an initial editor value, not an operating recommendation. Minimum 0; Maximum 1000000000 |
Allocationallocation | 0 proportional, 1 input priority | 0 | Configured model parameter; the default is an initial editor value, not an operating recommendation. Minimum 0; Maximum 1 |
Equations and rules
P_i = max(0, demand_i) * min(1, P_limit / sum(max(0, demand_j))), when total demand > 0
Worked example
Compare charging policies
Connect a vehicle for eight hours with a cheaper window from hour 1 to hour 7.
Open the Studio example →Use in a workflow
Share a site supply
Multiple branches share one power cap.
- Shared site power allocator: Shares grid-side power
- limitW
- ports
- allocation
Compare charging policies
Compare authored schedules on the same hardware.
- Shared site power allocator: Shares grid-side power
- limitW
- ports
- allocation
Connected concepts
Limits and interpretation
- This is deterministic policy comparison, not a forecast or economic optimum.
- Downstream unused capacity is not silently redistributed.
Implementation sources
This reference follows Lemonergy implementation sources. Scientific articles support the linked concepts separately.
Repository: battery-design · Revision: ef9802329b75bc15bb96885f8ed5d49425106696
js/charging-control.jsjs/charging-scenarios.jsdocs/CHARGING_BLOCKS_SPEC.mdjs/physical-network.jsrust-core/src/charging_control.rs
This implementation and its workflow uses (JSON) · Knowledge graph (JSON-LD)