#[repr(u8)]pub enum Pauli {
I = 0,
X = 1,
Y = 3,
Z = 2,
}
Expand description
An element of the single-qubit Pauli group.
Variants§
I = 0
The identity operator.
X = 1
The Pauli $X$ operator.
Y = 3
The Pauli $Y$ operator.
Z = 2
The Pauli $Z$ operator.
Trait Implementations§
Source§impl AsUnitary for Pauli
impl AsUnitary for Pauli
Source§fn as_unitary(&self) -> Array2<C64>
fn as_unitary(&self) -> Array2<C64>
Returns a representation as a unitary matrix.
Source§impl<'de> Deserialize<'de> for Pauli
impl<'de> Deserialize<'de> for Pauli
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl IntoPauliMixture for Pauli
impl IntoPauliMixture for Pauli
Source§impl TryFromPrimitive for Pauli
impl TryFromPrimitive for Pauli
impl Copy for Pauli
Auto Trait Implementations§
impl Freeze for Pauli
impl RefUnwindSafe for Pauli
impl Send for Pauli
impl Sync for Pauli
impl Unpin for Pauli
impl UnwindSafe for Pauli
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more