Documentation

Complexitylib.Circuits.BasisHom.Defs

Semantics-preserving maps between circuit bases -- definitions #

A Basis.Hom B₁ B₂ maps every operation-and-arity pair of B₁ to a B₂ operation that accepts that arity and has exactly the same Boolean semantics. The target label may depend on arity: for example, an unbounded AND of fan-in n maps to the threshold operation "at least n." The map changes only gate labels; fan-in, wiring, negation flags, gate count, and circuit topology are preserved exactly.

structure Complexity.Basis.Hom (source target : Basis) :

A semantics-preserving operation map between Boolean bases.

  • mapOp : source.Optarget.Op

    Translate a source operation at a specified gate arity.

  • mapArity (op : source.Op) (n : ) : (source.arity op).satisfiedBy n(target.arity (self.mapOp op n)).satisfiedBy n

    Every legal source arity is legal for the translated operation.

  • eval_map (op : source.Op) (n : ) (arityOk : (source.arity op).satisfiedBy n) (inputs : BitString n) : target.eval (self.mapOp op n) n inputs = source.eval op n arityOk inputs

    Operation translation preserves semantics exactly.

Instances For
    def Complexity.Gate.mapBasis {source target : Basis} {W : } (hom : source.Hom target) (gate : Gate source W) :
    Gate target W

    Relabel a gate along a basis homomorphism without changing its topology.

    Equations
    Instances For
      def Complexity.Circuit.mapBasis {N M : } {source target : Basis} {G : } [NeZero N] [NeZero M] (hom : source.Hom target) (circuit : Circuit source N M G) :
      Circuit target N M G

      Relabel every gate of a circuit along a basis homomorphism.

      Equations
      • One or more equations did not get rendered due to their size.
      Instances For
        def Complexity.CircuitFamily.mapBasis {source target : Basis} (hom : source.Hom target) (family : CircuitFamily source) :

        Relabel every positive-length circuit in a nonuniform family.

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