Lemonergy Wiki

Worked examples

Synthetic battery pulse: two relaxation branches

Excite a hypothetical two-RC cell with independently chosen current amplitudes and durations, then compare its voltage with a closed-form edge response.

Document created Updated
Draft explanationSource record reviewed

What this model teaches

Excite a hypothetical two-RC cell with independently chosen current amplitudes and durations, then compare its voltage with a closed-form edge response.

The current is 0 A for 12 s, 2 A for 6 s, 0 A for 36 s, 6 A for 96 s, 0 A for 120 s, 4 A for 24 s, then 0 A for 96 s. Step sources sum into current. Resistance gains drive two first-order states, and terminal voltage is OCV − I·R0 − v1 − v2.

Original idealized fixed-parameter forward model. Positive current means discharge. Initial polarization is zero. The independently shaped fitting holdout is a separate experiment, not the trace executed here. The inputs are authored synthetic teaching choices. No measured cell, material dataset or external software trace is reproduced. Passing verifies these numerical implementations against analytical equations; it does not establish hardware accuracy, safety or parity with another product. Maximum-error gates are fixed before execution. RMSE weights accepted solver samples equally; it is not a uniform-time integral. OCV and all parameters remain fixed. The capacity, initial SOC and ambient labels belong to the separate fitting exercise; this forward graph does not predict SOC or temperature. At current switches the ohmic term is right-continuous, while the two RC states remain continuous.

Open and run

Open prepared examples and select Synthetic battery pulse: two relaxation branches. Choose Run prepared model for a fresh native solve. The public viewer is read-only; the displayed Pro editor is a separate product and may require a separately saved model. Download the complete model and retained run to inspect the exact graph and outputs.

This original graph has 16 blocks, 17 connections and 2 compared signals. It carries reference version 2.

Prescribed inputs

InputValueUnit
OCV4V
R00.012Ω
R10.006Ω
Fast time constant3s
R20.018Ω
Slow time constant24s

Blocks and parameters

Block IDTypeParameters
currentsuminputs=6
negative-rc1gaingain=-1; inputQuantity=voltage
negative-rc2gaingain=-1; inputQuantity=voltage
ocvconstantvalue=4
ohmic-dropgaingain=-0.012; inputQuantity=current
pulse-edge-1stepafter=2; atS=12; before=0
pulse-edge-2stepafter=-2; atS=18; before=0
pulse-edge-3stepafter=6; atS=54; before=0
pulse-edge-4stepafter=-6; atS=150; before=0
pulse-edge-5stepafter=4; atS=270; before=0
pulse-edge-6stepafter=-4; atS=294; before=0
rc1-targetgaingain=0.006; inputQuantity=current
rc1-voltagefirst-orderinitial=0; tauS=3
rc2-targetgaingain=0.018; inputQuantity=current
rc2-voltagefirst-orderinitial=0; tauS=24
terminal-voltagesuminputs=4

The runtime connections in the downloaded model are authoritative. A gain changes the mathematical coefficient only when it is wired to the stated signal.

Original numerical plot

Original generated plot of the new synthetic native result and analytical reference.
Original generated numerical plot for Synthetic battery pulse: two relaxation branches. The native trace and independently evaluated analytical reference come from the retained execution report; this is not a screenshot or measured waveform. Captured .

This is an original plot generated from the retained native trace, not a screenshot and not a downloaded external waveform. The overlaid reference is evaluated independently at each accepted solver time.

Recorded numerical checks

A fresh run on 2026-10-28T17:13:51.851Z retained 1740 output points. The execution report includes every native point, analytical comparison and source fingerprint.

SignalMaximum absolute errorFixed gatePoints
Terminal voltage8.477663016037695e-130.0000011740
Discharge current01e-101740

Errors and gates use each signal's stated unit. The check requires the complete 0–390 s interval, every accepted output point, finite values, correct block quantities, current reference binding and exact solver settings. It rejects missing current-switch instants for the pulse model.

Try an edit carefully

Changing a prescribed input creates a different mathematical experiment. The original comparison should then fail; do not enlarge its gate to accept changed equations. Create a separately justified contract and oracle for a new experiment.

Equations and provenance

Read the original input contract, how to interpret comparisons and model workflow. These numbers are hypothetical choices. Passing establishes numerical agreement for these equations only. No measured accuracy, safety or external-software parity is claimed.

Models and evidence

  • Open prepared model
  • Download model and run 704721 bytes
    Artifact provenance

    Repository origin: outputs/synthetic-reference/models/lemonergy-synthetic-2rc-pulse-v1.lemon.json

    SHA-256: 4bdd4abe36b26ced501bc0434c4a2fbb927a49c0e48af6faab89a1941f1ac2aa

  • Download numerical evidence 2994324 bytes
    Artifact provenance

    Repository origin: outputs/synthetic-reference/native-synthetic-reference-report.json

    SHA-256: 64ea006f1dac1f2ec11c6366ee3393729dc76d6ad5a21c4cf094231806a8a1f6

Downloads preserve recorded inputs and results. Opening a saved result does not run a new simulation.