Battery knowledge · State estimation

State of charge

How full a cell is, as a fraction of its available capacity. State of charge, like temperature, affects how fast a stored cell ages. [1]

Abbreviation
SOC
Unit
%

Example

Interpret a charge inventory

If available capacity is 5 Ah and 3 Ah remains by the chosen estimator, SOC is 60%. A different estimate of available capacity changes this percentage, so compare SOC values only with the capacity convention recorded.

Explore the graph

SOC rises with accumulated charge; depth of discharge falls by the same amount.

Complementary charge fractions
Complementary charge fractionsTime (h) versus Capacity fraction (%). SOC; DOD. Interpretation follows the graphs.002515027531004Time (h)Capacity fraction (%)
SOCDOD (dashed)

From 20% SOC, ideal full charge takes 48 min. Integration stops at 100%.

SOC = SOC₀ + ∫ I_charge dt / Q; DOD = 1 − SOC

Illustrative model. Current is positive into the cell. Constant capacity and 100% charge efficiency; no CC-CV taper.

Use in Lemonergy

Lemonergy Studio blocks

Cell-delta SOC EKF worked example

Estimates deviation from a supplied average. Average-error variance enters voltage uncertainty under an explicit independent-error assumption.

Blocks to use

  1. Cell-delta SOC EKF

    Estimates the target cell SOC deviation from a supplied pack average. The variable-resistance version accepts the target resistance as an input. Average-estimate variance enters the voltage uncertainty under an independent-error assumption.

    Inputs & settings
    • Use the parameter values in the block reference.
    • Bundled example verified on the production release of 28 October 2026.

This overview identifies the components to use. Follow the example in Lemonergy for their connections and settings.

  1. Review the block inputs, units and model limits.
  2. Open the Studio example and run its bundled model.
  3. Compare the output channels with the numerical checks; change one input and run again.

Example. Use the defaults below with Series current = 1 A, Measured cell voltage = 3.73 V, Average SOC = 0.8 1 (fraction), Average SOC variance = 0 1, Aligned measurements valid = 1 true / false, Reset = 0 true / false. At 0 s, SOC deviation from average is -0.01 1. Additional checks are listed below.

Observe. Inspect the outputs and numerical checks on the block reference page.

One-state extended Kalman observers, without an unscented transform, RC polarization states or automatic cell identification. SOE requires its own energy-fraction-to-OCV calibration. Synthetic filter settings are not accuracy guarantees. No jointly estimated correlated covariance between the average and the cell deviation. The example verifies numerical behavior for synthetic parameters. Cell characterization and validation for an intended use are separate tasks.

Open Studio example →

Lemonergy Studio blocks

Cell-delta SOC EKF with resistance input worked example

Estimates deviation from a supplied average. Average-error variance enters voltage uncertainty under an explicit independent-error assumption.

Blocks to use

  1. Cell-delta SOC EKF with resistance input

    Estimates the target cell SOC deviation from a supplied pack average. The variable-resistance version accepts the target resistance as an input. Average-estimate variance enters the voltage uncertainty under an independent-error assumption.

    Inputs & settings
    • Use the parameter values in the block reference.
    • Bundled example verified on the production release of 28 October 2026.

This overview identifies the components to use. Follow the example in Lemonergy for their connections and settings.

  1. Review the block inputs, units and model limits.
  2. Open the Studio example and run its bundled model.
  3. Compare the output channels with the numerical checks; change one input and run again.

Example. Use the defaults below with Series current = 1 A, Measured cell voltage = 3.73 V, Average SOC = 0.8 1 (fraction), Average SOC variance = 0 1, Aligned measurements valid = 1 true / false, Reset = 0 true / false, Cell resistance (ohm) = 0.05 1. At 0 s, SOC deviation from average is -0.01 1. Additional checks are listed below.

Observe. Inspect the outputs and numerical checks on the block reference page.

One-state extended Kalman observers, without an unscented transform, RC polarization states or automatic cell identification. SOE requires its own energy-fraction-to-OCV calibration. Synthetic filter settings are not accuracy guarantees. No jointly estimated correlated covariance between the average and the cell deviation. The example verifies numerical behavior for synthetic parameters. Cell characterization and validation for an intended use are separate tasks.

Open Studio example →

Lemonergy Studio blocks

Charge counter worked example

Integrates signed throughput. Changing capacity preserves fraction and reports revaluation separately.

Blocks to use

  1. Charge counter

    Integrates signed discharge current or power over elapsed sample time. Charge efficiency applies during charging. The initial sample has zero elapsed time. Variable-capacity variants preserve the current fraction when capacity changes and report the resulting amount revaluation separately. Reset restores the initial fraction without integrating that event.

    Inputs & settings
    • Use the parameter values in the block reference.
    • Bundled example verified on the production release of 28 October 2026.

This overview identifies the components to use. Follow the example in Lemonergy for their connections and settings.

  1. Review the block inputs, units and model limits.
  2. Open the Studio example and run its bundled model.
  3. Compare the output channels with the numerical checks; change one input and run again.

Example. Use the defaults below with Signed battery current = 2 A, Reset = 0 true / false. At 0 s, State of charge is 0.8 1 (fraction). Additional checks are listed below.

Observe. Inspect the outputs and numerical checks on the block reference page.

Current or power bias accumulates. Fraction clipping is reported as a boundary amount; it does not make the connected plant respect that boundary. Energy variants need capacity in joules. The example verifies numerical behavior for synthetic parameters. Cell characterization and validation for an intended use are separate tasks.

Open Studio example →

Learn it in Lesson 4 · Battery aging →

All connected Lemonergy block references

References & further reading

Technical references

  1. Extended Kalman filtering for battery management systems of LiPB-based HEV battery packs: Part 3. State and parameter estimation

    Gregory L. Plett · Journal of Power Sources · 2004

    Technical reference · Model-based battery state-of-charge and parameter estimation with extended Kalman filtering, including uncertainty and model dependence.

Further reading on this topic

These sources provide broader context; they are not presented as citations for every statement in this entry.

  1. Extended Kalman filtering for battery management systems of LiPB-based HEV battery packs: Part 2. Modeling and identification

    Gregory L. Plett · Journal of Power Sources · 2004

    Topic background · Battery charge balance, open-circuit voltage, ohmic loss, polarization dynamics and model identification; parameters require cell-specific data.