Lemonergy · Studio block

Electrical reference

Define the zero-voltage potential of an electrical island.

Implementation ID
electrical-reference
Reviewed
2026-10-27

Behavior

Connect its p terminal to the intended reference net. Every disconnected electrical island needs a reference to give the conserving network a determinate voltage datum.

Interface

Electrical reference interfaceInputs or arguments on the left, observed outputs on the right. Conserving terminals appear below the component. The tables give units and behavior.Electrical referenceStudio blockp
Original Lemonergy interface view. Lines identify ports; they are not a completed simulation circuit.
Ports and observed outputs
NameDirectionUnitMeaning
pconservingV, AElectrical terminal: potential and charge-conserving current.

Parameters

No configurable parameters for this component.

Equations and rules

  • V_reference = 0

Worked example

Build CC–CV charging

An illustrative 100 Ah battery with a 420 V ceiling can use a 32 A cap. At the ceiling, current falls as OCV rises.

Open the Studio example →

Use in a workflow

Build CC–CV charging

Native current and voltage regulation act against an explicit battery.

  1. Electrical reference: Sets zero potential
    • Connect p to reference net
Open the Studio example

Connect SOC and voltage

The battery integrates charge and combines OCV with resistance.

  1. Electrical reference: Sets zero potential
    • Connect p to reference net
Open the Studio example

Relate current and voltage

Conserving components solve constitutive relations and node balance.

  1. Electrical reference: Sets zero potential
    • Connect p to reference net
Open the electrical circuit

Observe an RC time constant

An RC circuit uses source, resistor, capacitor and reference blocks.

  1. Electrical reference: Sets zero potential
    • Connect p to reference net
Open the RC example

Model signed grid exchange

Explicit battery and converter exchange average power.

  1. Electrical reference: Sets zero potential
    • Connect p to reference net
Open the Studio example

Connected concepts

Limits and interpretation

  • The battery uses linear OCV and fixed resistance. It does not automatically add aging, thermal dynamics or balancing.
  • Internal model SOC is not an estimate of an unknown physical battery. OCV is linear and resistance fixed.
  • This excludes AC waveforms, synchronization, communications and certification.
  • The RC example includes a capacitor: transient current varies and source voltage is not always resistor voltage.
  • This generic circuit does not identify cell parameters from measurements.

Implementation sources

This reference follows Lemonergy implementation sources. Scientific articles support the linked concepts separately.

Repository: battery-design · Revision: ef9802329b75bc15bb96885f8ed5d49425106696

  • js/charging-control.js
  • js/charging-scenarios.js
  • docs/CHARGING_BLOCKS_SPEC.md
  • js/physical-network.js
  • js/studio-examples.js

This implementation and its workflow uses (JSON) · Knowledge graph (JSON-LD)