Reversible compilation with a designated output #
Compile a De Morgan circuit into NOT, CNOT and Toffoli gates, then move its first output to qubit zero. The compiler uses one fresh qubit per Boolean gate and a final zero qubit. It also handles malformed Boolean codes using the existing default-false evaluation semantics.
This is the compiler previously placed with P ⊆ BQP; its implementation and correctness
statements are unchanged. The underlying gate simulation follows Arora, Barak,
Chapter 10. Concrete bounds for the emitted code are in Reversible.Resources.
Main definitions #
Cslib.Quantum.Reversible.circuitCodes: compilation followed by output relocation.Cslib.Quantum.UniformCircuitFamily.ofBooleanCircuits: the compiled uniform family.
Main results #
Cslib.Quantum.Reversible.acceptProb_circuitCodes: exact output semantics.Cslib.Quantum.Reversible.computableInPolyTime_circuitCodes: native uniform compilation.Cslib.Quantum.UniformCircuitFamily.acceptProb_ofBooleanCircuits: family correctness.
References #
The compiled circuit reads the De Morgan circuit's output: started from the input x of
length n, it accepts with probability 1 when the first output wire of the code is true on x,
and 0 otherwise.
The compilation of circuit codes runs in polynomial time.
The quantum family of a polynomial-time uniform family of De Morgan circuits: the circuit
for inputs of length n compiled into reversible gates.
The family of compiled circuits accepts with probability 1 or 0, according to the output of
the De Morgan circuit for the input's length.