Gate counts for sorting and detecting records #
A family of records is available when every bit of every encoded record is (Record.wireSet).
Sorting an available array inserts one Batcher circuit (Record.synthesis_sorted); its native
gate count is at most 18 * d ^ 2 * 2 ^ d per record bit and comparison layer. Testing every
adjacent pair for a collision and selecting one costs linearly in the array
(Record.synthesis_detect).
Main definitions #
Cslib.Circuits.Boolean.Iteration.wires: the coordinate functions of a family of bit strings.Cslib.Circuits.Boolean.Iteration.Record.wireSet,Record.recordsWires: available records.
Main results #
Cslib.Circuits.Boolean.Iteration.Record.size_sortCircuit_le: the native sorter's size.Cslib.Circuits.Boolean.Iteration.Record.synthesis_sorted: sorting an available array.Cslib.Circuits.Boolean.Iteration.Record.synthesis_detect: detecting a colliding pair.
References #
- Adapted from lean/Proofs/{RecordCircuits,Construction}.lean in S. Schlesinger, Square-root circuit bounds for iterated functions.
The coordinate functions of a family of bit strings.
Instances For
Equality of two available bit strings, by the native equality formula.
Choosing between two constructions by a third adds four gates per output bit.
The bits of an available family of records.
Instances For
The bits of an available family of pairs of records.
Instances For
Testing all adjacent pairs and selecting a colliding one.
The bits of every record of an available array.
Instances For
Sorting an available array inserts one native sorting circuit.