General

QuantumCircuitDraw.new_circuit_plotMethod
new_circuit_plot(N::Int, steps::Int; qubit_names=[], grid=false, dpi=300)

Initializes a plot for a quantum circuit with N qubits and steps steps. If qubit_names is empty, the qubits are named q₁, q₂, etc. Set grid=true to show a grid.

source
QuantumCircuitDraw.circuit_plotMethod
circuit_plot(N::Int, circuit::Vector{Tuple{String, Vector{Real}}}; qubit_names=[], grid=false, dpi=300)

Plots a circuit of the form circuit = [(gate, sites), ...].

source

Gates

QuantumCircuitDraw.SingleMethod
Single(i::Int, j::Int, name::String; color=default_color)

Draws a single-qubit gate at step i and qubit j with name name.

source
QuantumCircuitDraw.ControlledMethod
Controlled(i::Int, control::Int, target::Int, name::String; color=default_color)

Draws a controlled gate with control qubit and target qubit at step i.

source
QuantumCircuitDraw.MCZMethod
MCZ(i::Int, sites::Vector{Int}; color=default_color)

Draws a multi-controlled Z gate acting on sites qubits at step i.

source
QuantumCircuitDraw.MCXMethod
MCX(i::Int, controls::Vector{Int}, target::Int; color=default_color)

Draws a multi-controlled X gate acting on sites qubits at step i.

source
QuantumCircuitDraw.CNOTMethod
CNOT(i::Int, control::Int, target::Int; color=default_color)

Draws a CNOT gate at step i with control and target qubits.

source
QuantumCircuitDraw.CCNOTMethod
CCNOT(i::Int, control1::Int, control2::Int, target::Int; color=default_color)

Draws a CCNOT gate at step i with control1, control2, and target qubits.

source
QuantumCircuitDraw.CXMethod
CX(i::Int, control::Int, target::Int; color=default_color)

Draws a controlled X gate at step i with control and target qubits.

source
QuantumCircuitDraw.CYMethod
CY(i::Int, control::Int, target::Int; color=default_color)

Draws a controlled Y gate at step i with control and target qubits.

source
QuantumCircuitDraw.CZMethod
CZ(i::Int, control::Int, target::Int; color=default_color)

Draws a controlled Z gate at step i with control and target qubits.

source