@lelantos-org/sdk / circuit / flatten
Function: flatten() โ
ts
function flatten(input): bigint[];Defined in: @lelantos-org/sdk/dist/circuit/compression.d.ts:26
Flatten the logical PIs into the PolyEval coefficient vector, in PubInputs.compress(Transact) order:
9 scalar slots + 3ยทN_IN (nullifier, in_cv) + 8ยทN_OUT (out_cm, out_cv, out_cv_dep, 3 clue slots) โ see coeffCount in core/shape.ts, which is 31 at 2ร2 and 42 at 3ร3.
The shape is read off the input arrays rather than hardcoded, so a witness for any Transact(DEPTH, N_IN, N_OUT) instance flattens correctly. Only the 2ร2 circuit is deployed today; the 3ร3 vectors exercise the rest.
Parameters โ
| Parameter | Type |
|---|---|
input | FlattenInput |
Returns โ
bigint[]