Lemonergy · Studio block

Variant source

Selects an input branch before execution and removes unused inactive producers.

Implementation ID
variant-source
Reviewed
2026-10-27

Behavior

One configured input remains in the compiled graph. Inactive producers are removed only when no live consumer still uses them.

Interface

Variant source interfaceInputs or arguments on the left, observed outputs on the right. Conserving terminals appear below the component. The tables give units and behavior.Variant sourceStudio blockin0in1out0
Original Lemonergy interface view. Lines identify ports; they are not a completed simulation circuit.
Ports and observed outputs
NameDirectionUnitMeaning
in0input1Branch 0; real signal.
in1input1Branch 1; real signal.
out0output1Branch 0; real signal.

Parameters

Defaults are initial model values. Select values for your own model and operating conditions.

Configuration fields
ParameterUnitDefaultMeaning and limits
selected
selected
10Explicit selected in the worked model.
count
count
12Explicit count in the worked model.
signal quantity
signal.quantity
1dimensionlessExplicit signal quantity in the worked model.
signal shape
signal.shape
1[]Explicit signal shape in the worked model.
signal element Type
signal.elementType
1realExplicit signal elementType in the worked model.

Equations and rules

  • y = selected branch input

Worked example

Variant source — executable model

Selecting the first source3 and applying gain2 produces6; selecting source7 produces14.

Open Studio example after release →
Numerical checks for the bundled synthetic example
OutputTime (s)Expected valueUnitAbsolute tolerance
Result
Result
0.2611e-09

Use in a workflow

Variant source — executable model

Selects an input branch before execution and removes unused inactive producers.

  1. Variant source: One configured input remains in the compiled graph. Inactive producers are removed only when no live consumer still uses them.
    • Use the block reference for settings and connections.
    • Implementation tested locally; public release pending.
Open Studio example after release

Connected concepts

Limits and interpretation

  • Static zero-based selection among1–32 fixed typed branches. Shared live producers are preserved.

Reference basis

This compiler and software type contract is defined by the documented behavior and executable example; no external research result or full external API parity is claimed.

Implementation sources

This reference follows the public interface and locally verified numerical checks for an upcoming release.

Contract: Lemonergy Studio public contract · Verification record: verification-2026-10-27

  • docs/glossary/native-block-verification.json

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