pub trait QuantumErrorCode {
// Required methods
fn get_stabilizers(&self) -> Vec<StabilizerGroup>;
fn get_logical_operators(&self) -> Vec<LogicalOperator>;
fn distance(&self) -> usize;
fn num_data_qubits(&self) -> usize;
fn num_ancilla_qubits(&self) -> usize;
fn logical_qubit_count(&self) -> usize;
fn encode_logical_state(
&self,
logical_state: &Array1<Complex64>,
) -> QECResult<Array1<Complex64>>;
}Expand description
Trait defining a quantum error correction code
Required Methods§
Sourcefn get_stabilizers(&self) -> Vec<StabilizerGroup>
fn get_stabilizers(&self) -> Vec<StabilizerGroup>
Get the stabilizer generators for this code
Sourcefn get_logical_operators(&self) -> Vec<LogicalOperator>
fn get_logical_operators(&self) -> Vec<LogicalOperator>
Get the logical operators for this code
Sourcefn num_data_qubits(&self) -> usize
fn num_data_qubits(&self) -> usize
Get the number of physical data qubits
Sourcefn num_ancilla_qubits(&self) -> usize
fn num_ancilla_qubits(&self) -> usize
Get the number of ancilla qubits for syndrome measurement
Sourcefn logical_qubit_count(&self) -> usize
fn logical_qubit_count(&self) -> usize
Get the number of logical qubits encoded