NoiseChannel

Trait NoiseChannel 

Source
pub trait NoiseChannel: Send + Sync {
    // Required methods
    fn kraus_operators(&self) -> Vec<Array2<Complex64>> ;
    fn name(&self) -> &str;
    fn num_qubits(&self) -> usize;

    // Provided methods
    fn apply(
        &self,
        state: &ArrayView1<'_, Complex64>,
    ) -> NoiseResult<Array1<Complex64>> { ... }
    fn verify_completeness(&self) -> bool { ... }
}
Expand description

Trait for quantum noise channels

A noise channel is characterized by its Kraus operators {K_i}, which satisfy the completeness relation: ∑_i K_i† K_i = I

Required Methods§

Source

fn kraus_operators(&self) -> Vec<Array2<Complex64>>

Returns the Kraus operators for this noise channel

Source

fn name(&self) -> &str

Returns the name of this noise channel

Source

fn num_qubits(&self) -> usize

Returns the number of qubits this channel acts on

Provided Methods§

Source

fn apply( &self, state: &ArrayView1<'_, Complex64>, ) -> NoiseResult<Array1<Complex64>>

Apply the noise channel to a quantum state using Kraus operators

For a state |ψ⟩, the noisy state is: ρ = ∑_i K_i |ψ⟩⟨ψ| K_i†

Source

fn verify_completeness(&self) -> bool

Check if Kraus operators satisfy completeness relation

Implementors§