Skip to main content

Crate deep_causality_quantum

Crate deep_causality_quantum 

Source
Expand description

Quantum causal models on the causal monad.

This crate carries the quantum-information layer of DeepCausality: the QuantumGates/QuantumOps traits and gate kernels migrated out of deep_causality_physics, with HilbertState (the pure-state ket) staying in deep_causality_multivector as the foundational carrier.

Two quantum senses share this crate but are kept strictly apart by modality: the verifiable path (deterministic simulated Choi–Jamiołkowski operators, checked at the freeze boundary) is the default build and the target of the Lean proofs; the emergent path (a physical QPU call as a monadic effect) is a seam only.

All metric signatures come from deep_causality_metric, the single source of truth; this crate defines no metric type of its own.

Structs§

Abstraction
A downward abstraction from a low-level model L to a high-level model H.
Adjudication
What adjudicate examined and concluded.
AlignmentEntry
One aligned type: high-level wires, the low-level wires they abstract, the channel and its section.
AlignmentStructure
What check_alignment_structure computed.
BoundaryWarrant
What a boundary check certifies: the measured hypothesis and the bound it buys.
CausalStructure
A causal structure: a bipartite influence relation between input systems and output systems. contains(i, o) holds when input i influences output o.
Channel
A quantum channel, CPTP-checked once, at construction.
Check
One decision: a measured quantity against a threshold, with the margin and the verdict.
CheckReport
The records of one decision, with the count of what it examined.
CircuitModel
A compositional model in QC. See the module documentation.
CircuitSubject
A compositional model in QC: the circuit is the stored object, and its dilation is what the structural stages screen. The one subject that can enter an abstraction.
ClassInvariance
What a class-invariance check examined and concluded.
CliffordAction
What a Clifford-action check examined and concluded.
CodeAbstraction
A CSS code as an abstraction. See the module documentation.
CodeSubject
A chain complex, evaluated exactly. No probes, no evidence.
CommutatorCheck
One recorded commutator check (the shared B1(c)/Q-TOL telemetry).
CommutatorTolerance
The depth-aware, condition-driven commutator tolerance (Q-TOL): an incremental first-order forward-error budget over the real unit roundoff u. The pair test accepts [ρ_j, ρ_k] = 0 iff ‖[ρ_j,ρ_k]‖_F ≤ C · (‖ρ_j‖·budget_k + ‖ρ_k‖·budget_j + 2·γ_n·‖ρ_j‖·‖ρ_k‖) with γ_n = n·u/(1−n·u) and C the safety factor. Per-node budgets default to u·‖ρ‖_F; deeper/nested models can supply larger budgets that grew through their construction.
Config
A built configuration: a subject that passed its preconditions, and what the stages share.
ConfigBuilder
A configuration under construction.
Control
The control stage: observe, gate, fork, predict, compare, design, adjudicate. Failure is sticky and is carried out by finalize as the structured error.
ControlReport
The report control finalizes into: the root ledger, every world’s ledger side by side, the plan and the adjudication.
ControlWorld
One live world after fork: a candidate, the plant under it, and its own ledger.
CountHistogram
The concrete outcome-count histogram returned by the in-process simulator.
CssCode
A CSS code read off a chain complex: n qubits from the 1-cells, k logical qubits from β₁ over 𝔽₂, and the two check families as the raw columns of ∂₂ and δ₀.
DensityMatrix
A validated density matrix: Hermitian, positive semidefinite (checked via the dense Hermitian eigendecomposition), and unit trace — every constructor enforces the invariants and returns a typed QuantumError on violation.
DesignPlan
What design returns: the ordered experiments, their total cost, what each resolves, what no experiment resolves, and the separation report over every pair examined.
DiagonalPhase
A diagonal logical gate: exp(2πi · Q(a(γ)) / M) with M a power of two.
DiamondBound
The two-sided bound a Frobenius residual on Choi operators places on the diamond distance.
Dilated
A dilated circuit: the factorization, its supports, the default instruments and the wiring.
Draw
One draw against a budget: the shots granted and the seed they are drawn at.
EnvironmentalPrep
A read-only handle to the environmental preparation ρ_A. Cloneable and comparable, but never mutable: the only way to obtain one is Self::new, and it exposes no write methods, keeping the simulated-CJ model in the verifiable region.
Evidence
What a configuration declares: how many shots, at which seed.
ExactNaturality
The exact naturality check of a code abstraction over its gates.
ExactProgram
A program the exact semantics can evaluate.
Experiment
An experiment a plan may choose: its cost, the shots it would take, and the read-out each hypothesis predicts for it.
FactorSupports
The Hilbert support of each factor: the ordered leg-ids it acts on (ascending, the row-major factor layout) plus each leg’s dimension. For the flat QCM the leg-id of a single-system node is the node index itself, and support(Aᵢ) = {Aᵢ} ∪ Pa(Aᵢ).
Fault
One fault: a Pauli error on distinct wires, inserted after a node of the low-level circuit or, with no node named, before its first box.
FaultRecord
One fault’s verdict.
FaultSet
A finite signature of fault queries over the low-level model.
FaultToleranceReport
The fault-tolerance report of one gate or one abstraction under a fault set.
GateNaturality
One gate’s exact naturality verdict.
GaugeFieldGate
A diagonal gate in the algebra of its blocks’ logical s. See the module documentation.
HarunaFilter
The Haruna filter: which Table 1 gates of a code tolerate every weight-one Pauli fault.
Hypothesis
A structural or mechanism candidate.
IdealRecovery
The isometry and the recovery of a code.
InducedDag
The open DAG a compositional model induces (Lorenz & Tull, arXiv:2602.16612, Example 61): one vertex per node of the model’s grouping, one edge per wire leaving one node and entering another. Derived, never stored beside the model.
InvarianceWitness
The basis state that witnessed a class-invariance failure.
LdpcWeights
What check_ldpc_weights examined and concluded.
Ledger
The threaded state of a run: what was spent on the device, and what was only computed.
LogicalBasis
The logical operators of a CSS code at one grade: a basis of H_k and one of H^k.
LogicalPauli
A Pauli operator on the physical qubits, in symplectic form.
LogicalProgram
A logical gate as a physical-gate program, with the global phase the construction carries.
Marginalised
What a marginalisation returns when its warrant holds.
Mechanisms
Marker: the plant’s candidates are mechanisms, which carry no structural claim.
MinCostCover
The objective design solves: cover every hypothesis pair at floor_bits of separation at least cost, refusing above max_hypotheses.
ModelSubject
A Choi–Jamiołkowski factorization over a frozen graph: the degenerate plant with one structural candidate and no evidence, and what the shipped freeze_quantum callers map onto.
NaturalityReport
What check_naturality examined and concluded.
NoCandidates
Marker: the plant has no candidates yet.
NoSubject
The builder before a subject is named.
NodeLeg
One node’s leg: its wires ascending, their dimensions, and the node dimension d.
NumericCaps
The two caps of the numeric semantics, both counted and refused before allocating.
Observable
A named projector carrying its own read-out.
PlanEntry
One chosen experiment and the pairs it resolves.
PlantSubject
A system that evolves and is measured, with the observables it exposes and its candidates.
ProcessFactors
The node-keyed store of CJ factors. Keys are intrinsic graph node indices (never enumeration/insertion order); an absent key denotes a node with no operator factor. This is an external parameter to the freeze, mirroring LambdaEdges<V>; it is never carried on the runtime arity-5 STATE channel.
Projection
A projection (Hermitian idempotent) on a fixed D-dimensional Hilbert space. The type-level dimension is what lets Verdict::bottom/top (which take no arguments) know the space they live in.
ProjectionFold
The projection lattice’s fold of a commuting family: the meet and the join of every verdict.
Propagated
A Pauli pushed through an exact program: the Pauli it became and the diagonal remainder the non-Clifford layers left, U P U† = pauli · remainder up to the remainder’s own phases.
QcMorphism
A morphism of QC carried at the Kraus level: for each pair of classical input values x and classical output values y, a family of Kraus operators d_out × d_in, the completely positive map f(y | x) of Lorenz & Tull’s Example 57. The Choi operator of a block is formed only when asked for, under the entry cap.
QclBuilder
The one origin of every configuration, and the entry to each stage.
QpuParams
The requested-parameter summary routed to the STATE channel by qpu_effect.
QuantumCircuit
A storable circuit: a num_qubits register, an ordered gate program, and a computational-basis measurement over a subset of qubits. Clone + Debug + PartialEq; carries no amplitudes.
QuantumError
The crate-local quantum error: an outer newtype over QuantumErrorEnum, mirroring the repo convention (CausalityError(CausalityErrorEnum::…)).
QuantumMarkovReport
The instrumented report of a Markov check: one entry per intersecting-support factor pair.
QuantumPlant
A sealed, validated state that evolves by operation.
QubitOperator
A single-qubit unitary, built by name and owning its shape.
QuerySignature
A set of queries validated against the DAG they will be asked of.
QueryType
The wires a query’s morphism runs between, in the order the morphism’s legs take them: quantum wires ascending, classical wires in declaration order.
Screened
What validate terminates in: the config, the admitted candidates, and the report.
ShotBudget
The ledger of a shot budget: what remains, what was spent, and the run seed.
ShotEstimate
A Bernoulli point estimate from a histogram, with its standard error and the shots behind it.
SimCalibration
The calibration surfaced to the context channel by qpu_effect.
SimQpu
A deterministic dense state-vector simulator. Amplitudes never leave the simulator — sample returns only a classical CountHistogram.
Structural
Marker: the plant’s candidates are structural, and must be screened before control.
Survivor
The hypothesis that survived, and how far it stood from its nearest rival.
TypeAlignment
The type alignment of an abstraction. See the module documentation.
Validate
The validate stage: checks accumulate, the first failure is sticky, and finalize terminates in a Screened or carries the structured error out.
World
One live world after a fork: the hypothesis it ran under, the verdict it came back with, and the read-out the verdict was taken from.

Enums§

AlignmentSide
Which side of a query’s type an entry aligns. A query has an input type and an output type (Lorenz & Tull, footnote 19), and a code’s low-level model in the shape of Example 58, encoder then gate, aligns its logical inputs by the identity and its physical outputs by the decoder.
Ambiguity
Why no single hypothesis survived.
Axis
The axis of a single-qubit rotation.
CheckItem
What one Check examined: the identifier the decision form is generic over.
CheckMatrix
Which check matrix an LDPC item came from.
CheckVerdict
The three states a report can be in. Vacuous is an acceptance that examined nothing.
CircuitBox
One box of a CircuitModel: a morphism of QC (Lorenz & Tull, arXiv:2602.16612, Figure 2) on the wires it names.
ExactLayer
One layer of an exact program.
Factorization
Where the factors a Markov report certifies came from.
FaultOrigin
Which constructor produced a fault set.
GateOp
A single reified gate over the migrated gate alphabet. Plain data — no function pointers, no amplitudes.
LdpcItem
Whether an LDPC item is a column, one check, or a row, one qubit.
LogicalGate
A logical gate of Table 1 on the code’s logical qubits, by index.
PauliKind
A single-qubit Pauli error.
QuantumErrorEnum
Detailed classification of quantum errors. Typed variants name the exact failure; a String payload carries the operation-specific context.
Query
A query on a compositional model, Lorenz & Tull, arXiv:2602.16612, §3.2 and §7.2.
ScreenOrigin
Where a screened subject’s factorization came from.
ScreenStatus
Why a screened report is or is not current.
SemanticsPath
Which semantics decided a value derived from a CircuitModel.
Spec
A real-valued specification a read-out is judged against.
StructureScope
What the predicates license.
Tolerance
The tolerance family: the policies the crate’s checks derive their thresholds from, named.
WireSource
Where a wire enters a node from.
WireType
The type of a wire in the category QC (Lorenz & Tull, arXiv:2602.16612, Example 57): a finite-dimensional Hilbert space, drawn thick, or a finite set of classical outcomes, drawn thin.
WorldVerdict
The verdict a forked world came back with. Verdicts are extracted at the measurement boundary, so there is no constructor from an operator: a world that reaches adjudicate carrying an operator no observe turned into a verdict has nothing to fold.

Constants§

ATOM_ENUMERATION_CAP
The largest block-occupancy enumeration check_class_invariance will attempt per shift.
DEFAULT_MAX_HYPOTHESES
The default cap on the hypotheses design will cover exactly. 2^C(7,2) = 2^21 subsets.
DILATION_ENTRY_CAP
The most entries one factor is allowed to occupy: a factor on legs of dimension each is dense on their product, and three two-qubit nodes already reach 2^24.
FAULT_SET_CAP
The default cap on the number of faults a set may enumerate.
FROBENIUS_ON_CHOI
The norm a naturality report measured in.
IDEAL_RECOVERY_MAX_QUBITS
The widest register the dense construction takes.
MAX_GATE_QUBITS
The widest gate a unitary is formed for: a 2^12 × 2^12 matrix is the numeric semantics’ default entry cap, and a wider Cmz would allocate before any cap could refuse it.
MAX_GAUGE_BLOCKS
The most blocks one gate carries, so the phase table stays 2^m ≤ 2^16 entries.
TUPLE_ENUMERATION_CAP
The largest tuple enumeration logical_t and logical_multi_cz attempt by default. About a million tuples: under it, a weight-180 ; over it, the cost is reported rather than paid.

Traits§

BuildSubject
What build() checks of a subject before any stage runs.
ControlSource
What may enter control: a plant config whose candidates are mechanisms, or a screen. A plant config with structural candidates has no implementation, which is the compiler saying that structural candidates enter control only through validate.
QcModel
A compositional model in QC that can answer queries: the low-level or high-level side of an Abstraction. Static dispatch: each model type implements it directly.
QpuSampler
The generic sampler seam. Implementations return measurement shots as classical ShotHistogram data at the Kleisli cut; no concrete vendor adapter is shipped by this crate. Used only as a bound S: QpuSampler.
QuantumGates
Standard Quantum Gates interface.
QuantumOps
Core Quantum State Operations (Dirac Notation), parameterized over the underlying real field $R$ so the operations can be carried out at f32, f64, f128, or any other real-field precision.
ShotHistogram
A classical measurement histogram: outcome bitstrings (packed LSB-first over the circuit’s measured qubits) to shot counts. Never exposes amplitudes.
SubjectOrigin
The origin a subject type reports.

Functions§

adjudicate
Fold the worlds’ verdicts under the verdict law, and separate the survivor from its rivals.
apply_choi
Applies a channel to a state through its Choi operator: E(ρ)[j,l] = Σ_{ik} ρ[i,k] · J[(i,j),(k,l)].
apply_gate
Causal wrapper for mechanics::apply_gate_kernel.
apply_gate_kernel
Applies a quantum gate to a state: $|\psi’\rangle = U |\psi\rangle$.
apply_kraus
Applies a channel to a state through its Kraus family: E(ρ) = Σ K ρ Kᴴ.
bhattacharyya_bits_per_shot
The per-shot Bhattacharyya distance between two Bernoulli distributions, in bits: −log₂(√(pq) + √((1−p)(1−q))) (Bhattacharyya, Bull. Calcutta Math. Soc. 35, 1943). Zero when p = q, and the coefficient inside the logarithm is the overlap of the two distributions.
born_probability
Causal wrapper for mechanics::born_probability_kernel.
born_probability_kernel
Calculates the Born probability: $P = |\langle \text{basis} | \text{state} \rangle|^2$.
born_projective_prob
The Born-rule probability as the Prob MV-algebra verdict — the boundary where a quantum measurement becomes a classical (fuzzy) verdict.
born_projective_probability
The Born-rule probability of the measurement outcome projection on state rho: Tr(P ρ), clamped to [0, 1]. Real for a Hermitian P and ρ; a non-negligible imaginary part signals a malformed input and errors.
channel_compose
Causal wrapper for Channel::compose.
channel_from_kraus
Causal wrapper for Channel::from_kraus.
channel_unitary
Causal wrapper for Channel::unitary.
check_alignment_structure
Definition 49’s predicates on a partition. partition[X] lists the low-level vertices of the high-level vertex X; high_inputs are the high-level input vertices, whose blocks fullness does not ask about.
check_completely_positive
Complete positivity check: E is CP iff its Choi operator is PSD (spectrum ≥ −tol via the Hermitian eigendecomposition).
check_completely_positive_report
The report-returning form of check_completely_positive.
check_ldpc_weights
Both weights of both check matrices against one declared bound.
check_trace_preserving
Trace-preservation check: E is TP iff Tr_out(J) = I_in, computed with the named-subset partial trace over the out leg.
check_trace_preserving_report
The report-returning form of check_trace_preserving.
choi_compose
Composes two channels through their Choi operators.
choi_from_kraus
Builds the Choi operator J(E) from a Kraus family {K_κ} of d_out×d_in matrices: J[(i,j),(k,l)] = Σ_κ K_κ[j,i]·conj(K_κ[l,k]).
choi_identity
The Choi operator of the identity channel on a d-dimensional space.
clifford_conjugate
The image U P U† of a Pauli under a Clifford program, up to phase.
clifford_conjugation
The Clifford conjugation with coefficient conjugation: the grade-k blade picks up the sign (−1)^(k(k+1)/2) (grade involution ∘ reversion) and every coefficient is complex-conjugated. On a negative-signature metric this is the adjoint whose minimal-left-ideal restriction matches the matrix-column Hermitian adjoint.
commutator
Causal wrapper for mechanics::commutator_kernel.
commutator_kernel
Calculates commutator $[A, B] = AB - BA$.
derive_code
The CSS code of a chain complex at grade 1, composed from the shipped counts and columns.
design
The exact minimum-cost cover of the C(n, 2) hypothesis pairs by the offered experiments.
dirac_bracket_kernel
The metric-correct Dirac inner product ⟨φ|ψ⟩ on kets: the scalar part of adj(φ)·ψ, where adj is QuantumOps::dag (reversion + conjugation) for a positive-signature metric and clifford_conjugation for a negative-signature metric. On the minimal left ideal this equals the raw column inner product of to_ket(φ) and to_ket(ψ).
embed_on_legs
Embeds an operator acting on the legs op_legs into the full space (leg → dimension, ascending leg order = factor order), acting as the identity on every other leg — the Kronecker-with-identity alignment the freeze commutator uses to compare factors on their support union.
expectation_value
Causal wrapper for mechanics::expectation_value_kernel.
expectation_value_kernel
Calculates the expectation value: $\langle A \rangle = \langle \psi | A | \psi \rangle$.
fidelity
Causal wrapper for mechanics::fidelity_kernel.
fidelity_kernel
Calculates Quantum Fidelity: $F = |\langle \psi_{\text{ideal}} | \psi_{\text{actual}} \rangle|^2$.
freeze_quantum
Freezes graph with the built-in Stage-4 checks and the quantum Markov commutativity check as the level-specific hook, returning the instrumented report on success. On a quantum-check failure the graph is rolled back to the dynamic state (the hook’s unfreeze) and the structured QuantumError is recovered via an internal stash — not merely its Display message. A failure in the built-in checks (acyclicity / single-writer) surfaces as a QuantumError::CalculationError carrying the graph error’s message.
frobenius_norm
The Frobenius norm ‖M‖_F = √(Σ |m_ij|²).
gate_unitary
The unitary matrix of one gate over its qubits in ascending order, the first qubit most significant, which is the row-major leg order embed_on_legs and the numeric semantics use.
haruna_cz_gate
Causal wrapper for gates_haruna::logical_cz.
haruna_hadamard_gate
Causal wrapper for gates_haruna::logical_hadamard.
haruna_s_gate
Causal wrapper for gates_haruna::logical_s.
haruna_t_gate
Causal wrapper for gates_haruna::logical_t.
haruna_x_gate
Causal wrapper for gates_haruna::logical_x.
haruna_z_gate
Causal wrapper for gates_haruna::logical_z.
hermiticity_defect
The Hermiticity defect max_ij |M_ij − conj(M_ji)| (zero iff M = Mᴴ).
identity_channel
An identity channel on d dimensions, the box a noiseless wire carries.
identity_matrix
The d×d complex identity matrix.
is_clifford_gate
Whether a gate is Clifford.
is_diagonal_gate
Whether a gate is diagonal in the computational basis.
kraus_from_choi
Recovers a Kraus family from a (PSD) Choi operator via the Hermitian eigendecomposition: K_κ = √λ_κ · unvec(v_κ) for λ_κ > tol.
logical_cz
The logical CZ gate, Table 1 row 5 and Eq. (3.42):
logical_hadamard
The logical Hadamard, Table 1 row 4 and Eq. (3.27):
logical_multi_cz
The logical multi-controlled Z, Table 1 row 6:
logical_multi_cz_with_cap
logical_multi_cz under an explicit cap on the tuple enumeration.
logical_s
The logical S gate, Table 1 row 3 and Eq. (3.17):
logical_t
The logical T gate, Table 1 row 7 and Eq. (3.59):
logical_t_with_cap
logical_t under an explicit cap on the tuple enumeration.
logical_x
The logical X gate, Table 1 row 2: X̄(γ̃) = ∏_k X_{ĩ_k} over supp(γ̃).
logical_z
The logical Z gate, Table 1 row 1: Z̄(γ) = ∏_k Z_{i_k} over supp(γ).
markov_certificate
The certificate a Markov report grants, or the error its first rejection means.
matrix_commutator
The operator commutator [A, B] = A·B − B·A on complex matrices.
matrix_trace
The matrix trace Tr(M).
max_modulus
The largest modulus over a sequence of complex numbers, or zero over an empty one.
multi_cz_tuple_count
The number of tuples logical_multi_cz emits over: the product of the supports’ weights. Saturates rather than overflowing. An empty support makes the product empty, so the count is zero wherever that chain sits, saturated prefix or not.
observable_from_ket
Causal wrapper for Observable::from_ket.
observable_read_out
Causal wrapper for Observable::read_out.
partial_trace
The partial trace over a named subset of tensor legs.
partial_trace_preservation_boundary
The sound path past partial_trace’s non-preservation: given Z on the kept factor and M on the whole space, measure how nearly Z ⊗ 1_B commutes with M, and return the bound that buys on [Z, Tr_B(M)].
plant_evolve
Causal wrapper for QuantumPlant::evolve.
plant_from_ket
Causal wrapper for QuantumPlant::from_ket.
qpu_effect
Lifts a physical-QPU call into a causaloid f at the Kleisli boundary: on success the shot histogram rides the VALUE channel, the requested parameters the STATE channel, the device calibration the CONTEXT channel, and the provenance the LOG channel; a job failure rides the ERROR channel with the value absent. Generic over S: QpuSampler (no dyn).
quantum_markov_check
Runs the quantum Markov commutativity check over the external factor store, pair by pair, on intersecting Hilbert supports only. Returns the instrumented report on success, or a QuantumError::CommutatorNonZero naming the first offending pair. Sound: it never accepts a pair whose commutator exceeds the Q-TOL threshold.
quantum_markov_check_report
The report-returning form of quantum_markov_check, on the model’s own factors.
quantum_markov_check_report_as
quantum_markov_check_report with the provenance of the factors stated.
qubit_phase
Causal wrapper for QubitOperator::phase.
qubit_rotation
Causal wrapper for QubitOperator::rotation.
reduce_turns
t reduced to [0, 1) turns.
sample_projector
shots Bernoulli draws at Tr(Pρ), seeded, as a one-bit histogram: outcome 1 is the projector accepting, 0 rejecting.
sample_within_budget
request shots of a projector read-out, drawn against budget.
separation_bits
The separation of two Bernoulli read-outs at shots independent draws, in bits. The Bhattacharyya distance is additive over a product of independent samples, so this is shots times bhattacharyya_bits_per_shot; it is what a floor in bits is compared against.
shots_to_observable
An observable Uncertain<f64> from the histogram: each outcome is mapped to a real value by value_of, and the empirical mean and unbiased (n−1) sample variance are summarized as a normal Uncertain. O(distinct outcomes) — the statistics are accumulated directly from the (outcome, count) entries, never by materializing one sample per shot.
shots_to_qubit_bernoulli
A per-qubit UncertainBool<f64> from the histogram: the Bernoulli distribution whose success probability is the measured frequency of 1 on the bit_index-th measured qubit (LSB-first in measurement order).
supports_intersect
Whether two Hilbert supports (sets of leg indices) intersect — the freeze check computes a commutator only for intersecting supports.
swap_channel
The swap of two d-dimensional systems as a channel.
symplectic_dual_basis
A symplectic dual basis: one cocycle γ̃_j per homology generator, with ⟨γ_i, γ̃_j⟩ = δ_ij.
t_tuple_count
C(w, 2) + C(w, 3): the pair and triple tuples logical_t emits over for a chain of weight w. Saturates rather than overflowing, so a count that does not fit reads as “above any cap”.

Type Aliases§

AlignmentSpec
One alignment entry as given to TypeAlignment::new: (high wires, low wires, τ, E).
BoxId
A box’s index in a CircuitModel.
CjFactor
A single Choi–Jamiołkowski factor ρ_{Aᵢ|Pa(Aᵢ)} — a complex matrix on the composite Hilbert space of node Aᵢ and its parents.
ClassicalValues
Classical values on a list of classical wires, in wire order.
Gate
NodeId
A node’s index in a CircuitModel’s grouping.
Operator
Turns
The phase a diagonal logical gate applies, as an exact rational multiple of .
WireId
A wire’s index in a CircuitModel.
Word
The word width of the 𝔽₂ chains the code stages carry.