Linear-size segmented propagation #
Given source bits and links between consecutive records, this circuit
computes value[i] = source[i] OR (link[i] AND value[i-1]), with a false
initial value. Earlier values are shared circuit wires. Exactly two charged
gates are used per record, independent of the lengths of equal-key runs.
The propagated value after processing a prefix of the records.
Equations
- Algebraic.MassProduction.Nonuniform.Propagation.value source link 0 = false
- Algebraic.MassProduction.Nonuniform.Propagation.value source link count.succ = (source count || link count && Algebraic.MassProduction.Nonuniform.Propagation.value source link count)
Instances For
Source bits occupy the first input block.
Equations
- Algebraic.MassProduction.Nonuniform.Propagation.sourceInput input index = if bound : index < count then input (Fin.castAdd count ⟨index, bound⟩) else false
Instances For
Link bits occupy the second input block.
Equations
- Algebraic.MassProduction.Nonuniform.Propagation.linkInput input index = if bound : index < count then input (Fin.natAdd count ⟨index, bound⟩) else false
Instances For
Two shared gates per processed record, preceded by one free false constant. The program always reads the original fixed-size input array.
Equations
- One or more equations did not get rendered due to their size.
- Algebraic.MassProduction.Nonuniform.Propagation.program count 0 x_2 = Cslib.Circuits.Program.empty.gate { op := Algebraic.DeMorgan.Op.false, wires := Fin.elim0 }
Instances For
The program's even-numbered gate after each prefix is its propagated value; in particular the zero-prefix gate is false.
Every processed record contributes one AND and one OR gate.
All propagated values, in the same order as the input records.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The concrete circuit implements the segmented recurrence.
The exact charged size is linear in the number of records.
A propagated true bit has a source connected to the current position by an uninterrupted interval of true links.