Lemonergy · Studio block
Same-type constraint
Requires two independent signals to have the same numeric type; forwards the first.
- Implementation ID
type-duplicate- Reviewed
- 2026-10-27
Behavior
Checks the numeric type of two independent signals and forwards the first without changing its value.
Interface
| Name | Direction | Unit | Meaning |
|---|---|---|---|
in0 | input | 1 | Input 1; i32 signal. |
in1 | input | 1 | Input 2; i32 signal. |
out0 | output | 1 | Output 1; i32 signal. |
Parameters
Defaults are initial model values. Select values for your own model and operating conditions.
| Parameter | Unit | Default | Meaning and limits |
|---|---|---|---|
first quantityfirst.quantity | 1 | dimensionless | Explicit first quantity in the worked model. |
first shapefirst.shape | 1 | [] | Explicit first shape in the worked model. |
first element Typefirst.elementType | 1 | real | Explicit first elementType in the worked model. |
second quantitysecond.quantity | 1 | dimensionless | Explicit second quantity in the worked model. |
second shapesecond.shape | 1 | [] | Explicit second shape in the worked model. |
second element Typesecond.elementType | 1 | real | Explicit second elementType in the worked model. |
Equations and rules
type(first) = type(second); y = first
Worked example
Same-type constraint — executable model
Two signed32 inputs10 and20 pass; the output is10. Changing the second input to real-valued storage is rejected.
Open Studio example after release →| Output | Time (s) | Expected value | Unit | Absolute tolerance |
|---|---|---|---|---|
ResultResult | 0.2 | 10 | 1 | 1e-09 |
Use in a workflow
Same-type constraint — executable model
Requires two independent signals to have the same numeric type; forwards the first.
- Same-type constraint: Checks the numeric type of two independent signals and forwards the first without changing its value.
- Use the block reference for settings and connections.
- Implementation tested locally; public release pending.
Connected concepts
Limits and interpretation
- Type equality includes enumeration identity and scaled-integer metadata. Different quantities or dimensions may still be independent inputs; this is a numeric-type constraint.
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)