Documentation

Complexitylib.Circuits.Encoding.Fragment.Defs

Primitive raw-circuit fragment gates #

This definitions layer provides the small proof-free gates shared by raw circuit fragment builders. A duplicated-input gate copies or negates an existing wire, while a wire paired with its negation supplies either Boolean constant.

Copy an existing wire, optionally negating it for free on both input edges.

Equations
Instances For

    Produce a Boolean constant from an existing wire and its negation.

    Equations
    Instances For

      Append one final gate whose output is true exactly when the original circuit output equals expected. The reference is the original last-gate wire, so semantic use requires the original circuit to be nonempty.

      Equations
      Instances For

        Append two final gates whose output is true exactly when the original circuit output equals expected. Unlike appendOutputMatch, the first new gate contains expected without negating it, which is useful when serializing a circuit whose expected bit is supplied by a live input wire.

        Equations
        • One or more equations did not get rendered due to their size.
        Instances For