Complex

Struct Complex 

Source
pub struct Complex<T> {
    pub re: T,
    pub im: T,
}

Fields§

§re: T§im: T

Implementations§

Source§

impl<T> Complex<T>

Source

pub fn as_ref(&self) -> Complex<&T>

Source§

impl<T> Complex<T>

Source

pub fn map_ref<U>(&self, f: impl Fn(&T) -> U) -> Complex<U>

Source

pub fn map<U>(self, f: impl Fn(T) -> U) -> Complex<U>

Source

pub fn map_mut(&mut self, f: impl FnMut(&mut T))

Source

pub fn map_ref_mut<U>(&mut self, f: impl FnMut(&mut T) -> U) -> Complex<U>

Source

pub fn new(re: T, im: T) -> Complex<T>

Source

pub fn new_re(re: T) -> Complex<T>
where T: RefZero,

Source

pub fn new_im(im: T) -> Complex<T>
where T: RefZero,

Source

pub fn new_zero() -> Self
where T: Constructible,

Source

pub fn new_i() -> Self
where T: Constructible,

Source

pub fn ref_i(&self) -> Complex<T>
where T: RefOne + RefZero,

Source

pub fn pow<'a>(&'a self, e: u64) -> Self
where T: RefOne + RefZero + for<'c> RefMul<&'c T, Output = T> + for<'c> RefAdd<&'c T, Output = T> + for<'c> RefSub<&'c T, Output = T>,

Source

pub fn conj(&self) -> Complex<T>
where T: Clone + Neg<Output = T>,

Source

pub fn i() -> Complex<T>
where T: Zero + One,

Source

pub fn norm_squared(&self) -> T
where T: for<'a> RefMul<&'a T, Output = T> + Add<T, Output = T>,

Source

pub fn inv(&self) -> Self
where T: for<'a> RefMul<&'a T, Output = T> + Add<T, Output = T> + for<'a> RefDiv<&'a T, Output = T> + Neg<Output = T>,

Trait Implementations§

Source§

impl<'a, T> Add<&'a Complex<T>> for &Complex<T>
where T: Add<T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &'a Complex<T>) -> Self::Output

Performs the + operation. Read more
Source§

impl<'a, T> Add<&'a Complex<T>> for Complex<T>
where T: Add<T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &'a Complex<T>) -> Self::Output

Performs the + operation. Read more
Source§

impl<'a, T> Add<&'a T> for &Complex<T>
where T: for<'c> RefAdd<&'c T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &'a T) -> Self::Output

Performs the + operation. Read more
Source§

impl<'a, T> Add<&'a T> for Complex<T>
where T: for<'c> RefAdd<&'c T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: &'a T) -> Self::Output

Performs the + operation. Read more
Source§

impl<T> Add<Complex<T>> for &Complex<T>
where T: Add<T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Complex<T>) -> Self::Output

Performs the + operation. Read more
Source§

impl<T> Add<T> for &Complex<T>
where T: RefAdd<T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: T) -> Self::Output

Performs the + operation. Read more
Source§

impl<T> Add<T> for Complex<T>
where T: Add<T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: T) -> Self::Output

Performs the + operation. Read more
Source§

impl<T> Add for Complex<T>
where T: Add<T, Output = T>,

Source§

type Output = Complex<T>

The resulting type after applying the + operator.
Source§

fn add(self, rhs: Self) -> Self::Output

Performs the + operation. Read more
Source§

impl<T> AddAssign<&Complex<T>> for Complex<T>
where for<'a> T: AddAssign<&'a T>,

Source§

fn add_assign(&mut self, rhs: &Self)

Performs the += operation. Read more
Source§

impl<T> AddAssign<&T> for Complex<T>
where T: for<'a> RefAdd<&'a T, Output = T>,

Source§

fn add_assign(&mut self, rhs: &T)

Performs the += operation. Read more
Source§

impl<T, U> AddAssign<RealOrComplexRef<'_, T>> for Complex<U>
where U: for<'a> AddAssign<&'a T> + RefZero, Complex<U>: for<'a> AddAssign<&'a Complex<T>> + for<'a> AddAssign<&'a T>,

Source§

fn add_assign(&mut self, rhs: RealOrComplexRef<'_, T>)

Performs the += operation. Read more
Source§

impl<T> AddAssign<T> for Complex<T>
where T: AddAssign<T>,

Source§

fn add_assign(&mut self, rhs: T)

Performs the += operation. Read more
Source§

impl<T> AddAssign for Complex<T>
where for<'a> T: AddAssign<&'a T>,

Source§

fn add_assign(&mut self, rhs: Self)

Performs the += operation. Read more
Source§

impl<T: Clone> Clone for Complex<T>

Source§

fn clone(&self) -> Complex<T>

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl CompiledNumber for Complex<f64>

Source§

const SUFFIX: &'static str = "complexf64"

A unique suffix for the evaluation function for this particular number type.
Source§

type Evaluator = CompiledComplexEvaluatorSpenso

Source§

type Settings = ()

Source§

fn get_default_compile_options() -> CompileOptions

Get the default compilation options for C++ code generated for this number type.
Source§

fn export_cpp<N: ExportNumber + SingleFloat>( eval: &ExpressionEvaluator<N>, function_name: &str, settings: ExportSettings, ) -> Result<String, String>

Export an evaluator to C++ code for this number type.
Source§

fn construct_function_name(function_name: &str) -> String

Source§

impl<T: Debug> Debug for Complex<T>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<T, __Context> Decode<__Context> for Complex<T>
where T: Decode<__Context>,

Source§

fn decode<D: Decoder<Context = __Context>>( decoder: &mut D, ) -> Result<Self, DecodeError>

Attempt to decode this type with the given Decode.
Source§

impl<T: Default> Default for Complex<T>

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl<'de, T> Deserialize<'de> for Complex<T>
where T: Deserialize<'de>,

Source§

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<T: Display> Display for Complex<T>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'a, T> Div<&'a Complex<T>> for &Complex<T>
where T: Clone + Sub<T, Output = T> + Div<T, Output = T> + for<'r> RefMul<&'r T, Output = T> + Add<T, Output = T>,

Source§

type Output = Complex<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &'a Complex<T>) -> Self::Output

Performs the / operation. Read more
Source§

impl<'a, T> Div<&'a Complex<T>> for Complex<T>
where T: Clone + Sub<T, Output = T> + Div<T, Output = T> + for<'b> RefMul<&'b T, Output = T> + Add<T, Output = T>,

Source§

type Output = Complex<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &'a Complex<T>) -> Self::Output

Performs the / operation. Read more
Source§

impl<T, U, Out> Div<&RealOrComplex<T>> for Complex<U>
where Complex<U>: for<'a> Div<&'a Complex<T>, Output = Complex<Out>> + for<'a> Div<&'a T, Output = Complex<Out>>,

Source§

type Output = Complex<Out>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &RealOrComplex<T>) -> Complex<Out>

Performs the / operation. Read more
Source§

impl<'a, T> Div<&'a T> for &Complex<T>
where T: for<'c> RefDiv<&'c T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &'a T) -> Self::Output

Performs the / operation. Read more
Source§

impl<'a, T> Div<&'a T> for Complex<T>
where T: for<'c> Div<&'c T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: &'a T) -> Self::Output

Performs the / operation. Read more
Source§

impl<T> Div<Complex<T>> for &Complex<T>
where T: Clone + Sub<T, Output = T> + Div<T, Output = T> + for<'b> RefMul<&'b T, Output = T> + Add<T, Output = T>,

Source§

type Output = Complex<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: Complex<T>) -> Self::Output

Performs the / operation. Read more
Source§

impl<T, U, Out> Div<RealOrComplexRef<'_, T>> for Complex<U>
where Complex<U>: for<'a> Div<&'a Complex<T>, Output = Complex<Out>> + for<'a> Div<&'a T, Output = Complex<Out>>,

Source§

type Output = Complex<Out>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: RealOrComplexRef<'_, T>) -> Complex<Out>

Performs the / operation. Read more
Source§

impl<T> Div<T> for &Complex<T>
where T: RefDiv<T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: T) -> Self::Output

Performs the / operation. Read more
Source§

impl<T> Div<T> for Complex<T>
where T: Div<T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: T) -> Self::Output

Performs the / operation. Read more
Source§

impl<T> Div for Complex<T>
where T: Clone + Sub<T, Output = T> + Div<T, Output = T> + for<'a> RefMul<&'a T, Output = T> + Add<T, Output = T>,

Source§

type Output = Complex<T>

The resulting type after applying the / operator.
Source§

fn div(self, rhs: Self) -> Self::Output

Performs the / operation. Read more
Source§

impl<T> DivAssign<&Complex<T>> for Complex<T>
where T: Clone + Sub<T, Output = T> + Div<T, Output = T> + for<'a> RefMul<&'a T, Output = T> + Add<T, Output = T>,

Source§

fn div_assign(&mut self, rhs: &Self)

Performs the /= operation. Read more
Source§

impl<T> DivAssign<&T> for Complex<T>
where T: for<'a> RefDiv<&'a T, Output = T>,

Source§

fn div_assign(&mut self, rhs: &T)

Performs the /= operation. Read more
Source§

impl<T> DivAssign<T> for Complex<T>
where T: DivAssign<T> + Clone,

Source§

fn div_assign(&mut self, rhs: T)

Performs the /= operation. Read more
Source§

impl<T> DivAssign for Complex<T>
where T: Clone + Sub<T, Output = T> + Div<T, Output = T> + for<'a> RefMul<&'a T, Output = T> + Add<T, Output = T>,

Source§

fn div_assign(&mut self, rhs: Self)

Performs the /= operation. Read more
Source§

impl<T> Encode for Complex<T>
where T: Encode,

Source§

fn encode<__E: Encoder>(&self, encoder: &mut __E) -> Result<(), EncodeError>

Encode a given type.
Source§

impl<S: TensorStructure, K: Clone, FK: Clone, Aind: AbsInd> Evaluate<NetworkStore<EvalTensor<CompiledComplexEvaluatorSpenso, S>, CompiledComplexEvaluatorSpenso>, K, FK, S, Complex<f64>, Aind> for Network<NetworkStore<CompiledEvalTensor<S>, CompiledComplexEvaluatorSpenso>, K, FK, Aind>

Source§

fn evaluate( &mut self, params: &[Complex<f64>], ) -> Network<NetworkStore<DataTensor<Complex<f64>, S>, Complex<f64>>, K, FK, Aind>

Source§

impl EvaluatorLoader<Complex<f64>> for CompiledComplexEvaluatorSpenso

Source§

fn load_with_settings( file: impl AsRef<Path>, function_name: &str, settings: (), ) -> Result<Self, String>

Source§

fn load(file: impl AsRef<Path>, function_name: &str) -> Result<Self, String>

Load a compiled evaluator from a shared library.
Source§

impl<T: ExportNumber + SingleFloat> ExportNumber for Complex<T>

Source§

fn export(&self) -> String

Export the number as a string.
Source§

fn is_real(&self) -> bool

Check if the number is real.
Source§

fn export_wrapped(&self) -> String

Export the number wrapped in a C++ type T.
Source§

fn export_wrapped_with(&self, wrapper: &str) -> String

Export the number wrapped in a C++ type wrapper.
Source§

impl<T: Float + for<'a> RefMul<&'a T, Output = T> + Add<T, Output = T>> FloatDerived<T> for Complex<T>

Source§

fn norm(&self) -> T

Source§

fn to_polar_coordinates(self) -> (T, T)
where T: Float,

Source§

fn from_polar_coordinates(r: T, phi: T) -> Complex<T>

Source§

impl<T> FloatLike for Complex<T>
where T: for<'a> RefMul<&'a T, Output = T> + for<'a> RefAdd<&'a T, Output = T> + for<'a> RefSub<&'a T, Output = T> + for<'a> RefDiv<&'a T, Output = T> + FloatLike,

Source§

fn is_fully_zero(&self) -> bool

Return true if the number is exactly equal to zero (in all components).
Source§

fn mul_add(&self, a: &Self, b: &Self) -> Self

Perform (self * a) + b.
Source§

fn neg(&self) -> Self

Source§

fn zero(&self) -> Self

Source§

fn new_zero() -> Self

Create a zero that should only be used as a temporary value, as for some types it may have wrong precision information.
Source§

fn one(&self) -> Self

Source§

fn pow(&self, e: u64) -> Self

Source§

fn inv(&self) -> Self

Source§

fn from_usize(&self, a: usize) -> Self

Source§

fn from_i64(&self, a: i64) -> Self

Source§

fn get_precision(&self) -> u32

Get the number of precise binary digits.
Source§

fn get_epsilon(&self) -> f64

Source§

fn fixed_precision(&self) -> bool

Return true iff the precision is fixed, or false if the precision is changed dynamically.
Source§

fn sample_unit<R: Rng + ?Sized>(&self, rng: &mut R) -> Self

Sample a point on the interval [0, 1].
Source§

impl<F: ToFloat> From<&Complex<F>> for Coefficient

Source§

fn from(value: &Complex<F>) -> Self

Converts to this type from the input type.
Source§

impl<T: Clone> From<&Complex<T>> for Complex<T>

Source§

fn from(value: &Complex<T>) -> Self

Converts to this type from the input type.
Source§

impl From<&Complex<i128>> for Coefficient

Source§

fn from(value: &Complex<i128>) -> Self

Converts to this type from the input type.
Source§

impl From<&Complex<i32>> for Coefficient

Source§

fn from(value: &Complex<i32>) -> Self

Converts to this type from the input type.
Source§

impl From<&Complex<i64>> for Coefficient

Source§

fn from(value: &Complex<i64>) -> Self

Converts to this type from the input type.
Source§

impl From<&Complex<isize>> for Coefficient

Source§

fn from(value: &Complex<isize>) -> Self

Converts to this type from the input type.
Source§

impl From<&Complex<u128>> for Coefficient

Source§

fn from(value: &Complex<u128>) -> Self

Converts to this type from the input type.
Source§

impl From<&Complex<u32>> for Coefficient

Source§

fn from(value: &Complex<u32>) -> Self

Converts to this type from the input type.
Source§

impl From<&Complex<u64>> for Coefficient

Source§

fn from(value: &Complex<u64>) -> Self

Converts to this type from the input type.
Source§

impl From<&Complex<usize>> for Coefficient

Source§

fn from(value: &Complex<usize>) -> Self

Converts to this type from the input type.
Source§

impl<F: ToFloat> From<Complex<F>> for Coefficient

Source§

fn from(value: Complex<F>) -> Self

Converts to this type from the input type.
Source§

impl<T: Real> From<Complex<T>> for Complex<T>

Available on crate feature shadowing only.
Source§

fn from(complex: Complex<T>) -> Self

Converts to this type from the input type.
Source§

impl<T: Real> From<Complex<T>> for Complex<T>

Available on crate feature shadowing only.
Source§

fn from(complex: SymComplex<T>) -> Self

Converts to this type from the input type.
Source§

impl From<Complex<f64>> for Complex<Rational>

Available on crate feature shadowing only.
Source§

fn from(value: Complex<f64>) -> Self

Converts to this type from the input type.
Source§

impl From<Complex<i128>> for Coefficient

Source§

fn from(value: Complex<i128>) -> Self

Converts to this type from the input type.
Source§

impl From<Complex<i32>> for Coefficient

Source§

fn from(value: Complex<i32>) -> Self

Converts to this type from the input type.
Source§

impl From<Complex<i64>> for Coefficient

Source§

fn from(value: Complex<i64>) -> Self

Converts to this type from the input type.
Source§

impl From<Complex<isize>> for Coefficient

Source§

fn from(value: Complex<isize>) -> Self

Converts to this type from the input type.
Source§

impl From<Complex<u128>> for Coefficient

Source§

fn from(value: Complex<u128>) -> Self

Converts to this type from the input type.
Source§

impl From<Complex<u32>> for Coefficient

Source§

fn from(value: Complex<u32>) -> Self

Converts to this type from the input type.
Source§

impl From<Complex<u64>> for Coefficient

Source§

fn from(value: Complex<u64>) -> Self

Converts to this type from the input type.
Source§

impl From<Complex<usize>> for Coefficient

Source§

fn from(value: Complex<usize>) -> Self

Converts to this type from the input type.
Source§

impl<T: RefZero> From<RealOrComplex<T>> for Complex<T>

Source§

fn from(value: RealOrComplex<T>) -> Self

Converts to this type from the input type.
Source§

impl<T> From<T> for Complex<T>
where T: RefZero,

Source§

fn from(re: T) -> Self

Converts to this type from the input type.
Source§

impl From<f64> for Complex<Rational>

Available on crate feature shadowing only.
Source§

fn from(re: f64) -> Self

Converts to this type from the input type.
Source§

impl<'a> FromPyObject<'_, 'a> for Complex<f64>

Available on crate feature python only.
Source§

type Error = PyErr

The type returned in the event of a conversion error. Read more
Source§

fn extract(ob: Borrowed<'_, 'a, PyAny>) -> Result<Self, Self::Error>

Extracts Self from the bound smart pointer obj. Read more
Source§

impl<T: Hash> Hash for Complex<T>

Source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · Source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
Source§

impl<T: LowerExp> LowerExp for Complex<T>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'a, T> Mul<&'a Complex<T>> for &Complex<T>
where T: for<'c> RefMul<&'c T, Output = T> + for<'c> RefAdd<&'c T, Output = T> + for<'c> RefSub<&'c T, Output = T>,

Source§

type Output = Complex<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &'a Complex<T>) -> Self::Output

Performs the * operation. Read more
Source§

impl<'a, T> Mul<&'a Complex<T>> for Complex<T>
where for<'b> T: Mul<&'b T, Output = T> + Add<T, Output = T> + Sub<T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &'a Complex<T>) -> Self::Output

Performs the * operation. Read more
Source§

impl<'a, T> Mul<&'a T> for &Complex<T>
where T: for<'c> RefMul<&'c T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &'a T) -> Self::Output

Performs the * operation. Read more
Source§

impl<'a, T> Mul<&'a T> for Complex<T>
where T: for<'c> RefMul<&'c T, Output = T>,

Source§

type Output = Complex<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: &'a T) -> Self::Output

Performs the * operation. Read more
Source§

impl<T> Mul<Complex<T>> for &Complex<T>
where T: Mul<T, Output = T> + Add<T, Output = T> + Sub<T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Complex<T>) -> Self::Output

Performs the * operation. Read more
Source§

impl<T> Mul<T> for &Complex<T>
where T: RefMul<T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: T) -> Self::Output

Performs the * operation. Read more
Source§

impl<T> Mul<T> for Complex<T>
where T: Mul<T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: T) -> Self::Output

Performs the * operation. Read more
Source§

impl<T> Mul for Complex<T>
where T: Mul<T, Output = T> + Add<T, Output = T> + Sub<T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the * operator.
Source§

fn mul(self, rhs: Self) -> Self::Output

Performs the * operation. Read more
Source§

impl<T> MulAssign<&Complex<T>> for Complex<T>
where T: for<'c> RefMul<&'c T, Output = T> + for<'c> RefAdd<&'c T, Output = T> + for<'c> RefSub<&'c T, Output = T>,

Source§

fn mul_assign(&mut self, rhs: &Self)

Performs the *= operation. Read more
Source§

impl<T> MulAssign<&T> for Complex<T>
where T: for<'c> RefMul<&'c T, Output = T>,

Source§

fn mul_assign(&mut self, rhs: &T)

Performs the *= operation. Read more
Source§

impl<T, U> MulAssign<RealOrComplexRef<'_, T>> for Complex<U>
where U: for<'a> MulAssign<&'a T> + RefZero, Complex<U>: for<'a> MulAssign<&'a Complex<T>> + for<'a> MulAssign<&'a T>,

Source§

fn mul_assign(&mut self, rhs: RealOrComplexRef<'_, T>)

Performs the *= operation. Read more
Source§

impl<T> MulAssign<T> for Complex<T>
where T: MulAssign<T> + Clone,

Source§

fn mul_assign(&mut self, rhs: T)

Performs the *= operation. Read more
Source§

impl<T> MulAssign for Complex<T>
where T: Mul<T, Output = T> + Add<T, Output = T> + Sub<T, Output = T> + Clone,

Source§

fn mul_assign(&mut self, rhs: Self)

Performs the *= operation. Read more
Source§

impl<'a, T> Neg for &'a Complex<T>
where &'a T: Neg<Output = T>,

Source§

type Output = Complex<T>

The resulting type after applying the - operator.
Source§

fn neg(self) -> Complex<T>

Performs the unary - operation. Read more
Source§

impl<T> Neg for Complex<T>
where T: Neg<Output = T>,

Source§

type Output = Complex<T>

The resulting type after applying the - operator.
Source§

fn neg(self) -> Complex<T>

Performs the unary - operation. Read more
Source§

impl<T: Float> NumTraitComplex for Complex<T>

Source§

type R = T

Source§

fn arg(&self) -> T

Source§

impl<T: Zero + One + PartialEq + Sub<Output = T> + Clone> One for Complex<T>

Source§

fn is_one(&self) -> bool
where Self: PartialEq,

Returns true if self is equal to the multiplicative identity. Read more
Source§

fn one() -> Self

Returns the multiplicative identity element of Self, 1. Read more
Source§

fn set_one(&mut self)

Sets self to the multiplicative identity element of Self, 1.
Source§

impl<T: Ord> Ord for Complex<T>

Source§

fn cmp(&self, other: &Complex<T>) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · Source§

fn max(self, other: Self) -> Self
where Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · Source§

fn min(self, other: Self) -> Self
where Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 · Source§

fn clamp(self, min: Self, max: Self) -> Self
where Self: Sized,

Restrict a value to a certain interval. Read more
Source§

impl<T: PartialEq> PartialEq for Complex<T>

Source§

fn eq(&self, other: &Complex<T>) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl<T: PartialOrd> PartialOrd for Complex<T>

Source§

fn partial_cmp(&self, other: &Complex<T>) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · Source§

fn lt(&self, other: &Rhs) -> bool

Tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · Source§

fn le(&self, other: &Rhs) -> bool

Tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · Source§

fn gt(&self, other: &Rhs) -> bool

Tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · Source§

fn ge(&self, other: &Rhs) -> bool

Tests greater than or equal to (for self and other) and is used by the >= operator. Read more
Source§

impl PyStubType for Complex<f64>

Available on crate feature python_stubgen only.
Source§

fn type_output() -> TypeInfo

The type to be used in the output signature, i.e. return type of the Python function or methods.
Source§

fn type_input() -> TypeInfo

The type to be used in the input signature, i.e. the arguments of the Python function or methods. Read more
Source§

impl<T> Real for Complex<T>
where T: for<'a> RefMul<&'a T, Output = T> + for<'a> RefAdd<&'a T, Output = T> + for<'a> RefSub<&'a T, Output = T> + for<'a> RefDiv<&'a T, Output = T> + RefOne + RefZero + Real,

Available on crate feature shadowing only.
Source§

fn conj(&self) -> Self

Source§

fn i(&self) -> Option<Self>

The imaginary unit, if it exists.
Source§

fn e(&self) -> Self

Euler’s number, 2.7182818…
Source§

fn pi(&self) -> Self

The constant π, 3.1415926535…
Source§

fn phi(&self) -> Self

The golden ratio, 1.6180339887…
Source§

fn euler(&self) -> Self

The Euler-Mascheroni constant, 0.5772156649…
Source§

fn norm(&self) -> Self

Source§

fn sqrt(&self) -> Self

Source§

fn log(&self) -> Self

Source§

fn exp(&self) -> Self

Source§

fn sin(&self) -> Self

Source§

fn cos(&self) -> Self

Source§

fn tan(&self) -> Self

Source§

fn asin(&self) -> Self

Source§

fn acos(&self) -> Self

Source§

fn atan2(&self, x: &Self) -> Self

Source§

fn sinh(&self) -> Self

Source§

fn cosh(&self) -> Self

Source§

fn tanh(&self) -> Self

Source§

fn asinh(&self) -> Self

Source§

fn acosh(&self) -> Self

Source§

fn atanh(&self) -> Self

Source§

fn powf(&self, e: &Self) -> Self

Source§

impl<T> Ref for Complex<T>

Source§

type Ref<'a> = &'a Complex<T> where Self: 'a

Source§

fn refer(&self) -> Self::Ref<'_>

Source§

impl<T: RefZero + RefOne> RefOne for Complex<T>

Source§

fn ref_one(&self) -> Self

Source§

impl<T: RefZero> RefZero for Complex<T>

Source§

fn ref_zero(&self) -> Self

Source§

impl<I, T> ScalarMul<Complex<T>> for MixedTensor<T, I>
where I: TensorStructure + Clone, T: FallibleMul<Complex<T>, Output = Complex<T>> + Clone, Atom: FallibleMul<Complex<T>, Output = Atom>, Complex<T>: FallibleMul<Complex<T>, Output = Complex<T>>,

Source§

impl<U, S> ScalarMul<Complex<U>> for RealOrComplexTensor<U, S>
where DataTensor<U, S>: ScalarMul<Complex<U>, Output = DataTensor<Complex<U>, S>>, DataTensor<Complex<U>, S>: ScalarMul<Complex<U>, Output = DataTensor<Complex<U>, S>>, S: TensorStructure + Clone,

Source§

type Output = RealOrComplexTensor<U, S>

Source§

fn scalar_mul(&self, rhs: &Complex<U>) -> Option<Self::Output>

Source§

impl<T> Serialize for Complex<T>
where T: Serialize,

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl<T> SingleFloat for Complex<T>
where T: for<'a> RefMul<&'a T, Output = T> + for<'a> RefAdd<&'a T, Output = T> + for<'a> RefSub<&'a T, Output = T> + for<'a> RefDiv<&'a T, Output = T> + SingleFloat,

Source§

fn is_finite(&self) -> bool

Source§

fn is_one(&self) -> bool

Source§

fn is_zero(&self) -> bool

Source§

fn from_rational(&self, rat: &Rational) -> Self

Convert a rational to a float with the same precision as the current float.
Source§

impl<'a, T> Sub<&'a Complex<T>> for &Complex<T>
where T: Sub<T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &'a Complex<T>) -> Self::Output

Performs the - operation. Read more
Source§

impl<'a, T> Sub<&'a Complex<T>> for Complex<T>
where T: Sub<T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &'a Complex<T>) -> Self::Output

Performs the - operation. Read more
Source§

impl<'a, T> Sub<&'a T> for &Complex<T>
where T: for<'c> RefSub<&'c T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &'a T) -> Self::Output

Performs the - operation. Read more
Source§

impl<'a, T> Sub<&'a T> for Complex<T>
where T: for<'c> RefSub<&'c T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: &'a T) -> Self::Output

Performs the - operation. Read more
Source§

impl<T> Sub<Complex<T>> for &Complex<T>
where T: Sub<T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Complex<T>) -> Self::Output

Performs the - operation. Read more
Source§

impl<T> Sub<T> for &Complex<T>
where T: RefSub<T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: T) -> Self::Output

Performs the - operation. Read more
Source§

impl<T> Sub<T> for Complex<T>
where T: Sub<T, Output = T> + Clone,

Source§

type Output = Complex<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: T) -> Self::Output

Performs the - operation. Read more
Source§

impl<T> Sub for Complex<T>
where T: Sub<T, Output = T>,

Source§

type Output = Complex<T>

The resulting type after applying the - operator.
Source§

fn sub(self, rhs: Self) -> Self::Output

Performs the - operation. Read more
Source§

impl<T> SubAssign<&Complex<T>> for Complex<T>
where for<'a> T: SubAssign<&'a T>,

Source§

fn sub_assign(&mut self, rhs: &Self)

Performs the -= operation. Read more
Source§

impl<T> SubAssign<&T> for Complex<T>
where T: for<'a> RefSub<&'a T, Output = T>,

Source§

fn sub_assign(&mut self, rhs: &T)

Performs the -= operation. Read more
Source§

impl<T> SubAssign<T> for Complex<T>
where T: SubAssign<T>,

Source§

fn sub_assign(&mut self, rhs: T)

Performs the -= operation. Read more
Source§

impl<T> SubAssign for Complex<T>
where for<'a> T: SubAssign<&'a T>,

Source§

fn sub_assign(&mut self, rhs: Self)

Performs the -= operation. Read more
Source§

impl<T: Real> SymbolicaComplex for Complex<T>

Available on crate feature shadowing only.
Source§

type R = T

Source§

fn arg(&self) -> T

Source§

impl ToAtom for Complex<f64>

Source§

fn to_atom(self) -> Atom

Source§

impl<T> TrySmallestUpgrade<Atom> for Complex<T>
where T: TrySmallestUpgrade<Atom, LCM = Atom>,

Source§

type LCM = Atom

Source§

fn try_upgrade(&self) -> Option<Cow<'_, Self::LCM>>

Source§

impl TrySmallestUpgrade<Complex<Fraction<IntegerRing>>> for Complex<Rational>

Available on crate feature shadowing only.
Source§

type LCM = Complex<Fraction<IntegerRing>>

Source§

fn try_upgrade(&self) -> Option<Cow<'_, Self::LCM>>
where Self::LCM: Clone,

Source§

impl TrySmallestUpgrade<Complex<Fraction<IntegerRing>>> for Rational

Source§

type LCM = Complex<Fraction<IntegerRing>>

Source§

fn try_upgrade(&self) -> Option<Cow<'_, Self::LCM>>
where Self::LCM: Clone,

Source§

impl TrySmallestUpgrade<Complex<Integer>> for Complex<Integer>

Available on crate feature shadowing only.
Source§

type LCM = Complex<Integer>

Source§

fn try_upgrade(&self) -> Option<Cow<'_, Self::LCM>>
where Self::LCM: Clone,

Source§

impl<T> TrySmallestUpgrade<Complex<T>> for Atom
where Atom: TrySmallestUpgrade<T, LCM = Atom>,

Source§

type LCM = Atom

Source§

fn try_upgrade(&self) -> Option<Cow<'_, Self::LCM>>

Source§

impl<O: R + Clone, U, T> TrySmallestUpgrade<Complex<T>> for Complex<U>
where U: TrySmallestUpgrade<T, LCM = O> + R, T: TrySmallestUpgrade<U, LCM = O> + R,

Source§

type LCM = Complex<O>

Source§

fn try_upgrade(&self) -> Option<Cow<'_, Self::LCM>>
where Self::LCM: Clone,

Source§

impl TrySmallestUpgrade<Complex<f64>> for SerializableAtom

Source§

type LCM = SerializableAtom

Source§

fn try_upgrade(&self) -> Option<Cow<'_, Self::LCM>>
where Self::LCM: Clone,

Source§

impl TrySmallestUpgrade<Complex<f64>> for f64

Source§

type LCM = Complex<f64>

Source§

fn try_upgrade(&self) -> Option<Cow<'_, Self::LCM>>
where Self::LCM: Clone,

Source§

impl TrySmallestUpgrade<Fraction<IntegerRing>> for Complex<Rational>

Source§

type LCM = Complex<Fraction<IntegerRing>>

Source§

fn try_upgrade(&self) -> Option<Cow<'_, Self::LCM>>
where Self::LCM: Clone,

Source§

impl TrySmallestUpgrade<SerializableAtom> for Complex<f64>

Available on crate feature shadowing only.
Source§

impl TrySmallestUpgrade<f64> for Complex<f64>

Source§

type LCM = Complex<f64>

Source§

fn try_upgrade(&self) -> Option<Cow<'_, Self::LCM>>
where Self::LCM: Clone,

Source§

impl<T: Zero> Zero for Complex<T>

Source§

fn zero() -> Self

Returns the additive identity element of Self, 0. Read more
Source§

fn is_zero(&self) -> bool

Returns true if self is equal to the additive identity.
Source§

fn set_zero(&mut self)

Sets self to the additive identity element of Self, 0.
Source§

impl<T: Copy> Copy for Complex<T>

Source§

impl<T: Eq> Eq for Complex<T>

Source§

impl<T> StructuralPartialEq for Complex<T>

Auto Trait Implementations§

§

impl<T> Freeze for Complex<T>
where T: Freeze,

§

impl<T> RefUnwindSafe for Complex<T>
where T: RefUnwindSafe,

§

impl<T> Send for Complex<T>
where T: Send,

§

impl<T> Sync for Complex<T>
where T: Sync,

§

impl<T> Unpin for Complex<T>
where T: Unpin,

§

impl<T> UnwindSafe for Complex<T>
where T: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Az for T

Source§

fn az<Dst>(self) -> Dst
where T: Cast<Dst>,

Casts the value.
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<Src, Dst> CastFrom<Src> for Dst
where Src: Cast<Dst>,

Source§

fn cast_from(src: Src) -> Dst

Casts the value.
Source§

impl<T> CheckedAs for T

Source§

fn checked_as<Dst>(self) -> Option<Dst>
where T: CheckedCast<Dst>,

Casts the value.
Source§

impl<Src, Dst> CheckedCastFrom<Src> for Dst
where Src: CheckedCast<Dst>,

Source§

fn checked_cast_from(src: Src) -> Option<Dst>

Casts the value.
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<Q, K> Comparable<K> for Q
where Q: Ord + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn compare(&self, key: &K) -> Ordering

Compare self to key and return their ordering.
Source§

impl<T, U, Out> ContractableWith<T> for U
where U: FallibleMul<T, Output = Out> + TrySmallestUpgrade<T, LCM = Out>, Out: FallibleAddAssign + FallibleSubAssign<Out> + Clone + RefZero,

Source§

type Out = Out

Source§

impl<T> Conv for T

Source§

fn conv<T>(self) -> T
where Self: Into<T>,

Converts self into T using Into<T>. Read more
Source§

impl<T> DynClone for T
where T: Clone,

Source§

fn __clone_box(&self, _: Private) -> *mut ()

Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
Source§

impl<T, U> FallibleAdd<T> for U
where U: TrySmallestUpgrade<T>, T: TrySmallestUpgrade<U, LCM = <U as TrySmallestUpgrade<T>>::LCM>, <U as TrySmallestUpgrade<T>>::LCM: for<'b> RefAdd<&'b <U as TrySmallestUpgrade<T>>::LCM, Output = <U as TrySmallestUpgrade<T>>::LCM>,

Source§

type Output = <U as TrySmallestUpgrade<T>>::LCM

Source§

fn add_fallible(&self, rhs: &T) -> Option<<U as FallibleAdd<T>>::Output>

Source§

impl<T, U> FallibleAddAssign<T> for U
where T: TrySmallestUpgrade<U, LCM = U>, <U as TrySmallestUpgrade<T>>::LCM: Clone + for<'b> RefAdd<&'b <U as TrySmallestUpgrade<T>>::LCM, Output = <U as TrySmallestUpgrade<T>>::LCM>, U: TrySmallestUpgrade<T, LCM = U>,

Source§

fn add_assign_fallible(&mut self, rhs: &T)

Source§

impl<T, U> FallibleMul<T> for U
where U: TrySmallestUpgrade<T>, T: TrySmallestUpgrade<U, LCM = <U as TrySmallestUpgrade<T>>::LCM>, <U as TrySmallestUpgrade<T>>::LCM: Clone + for<'b> RefMul<&'b <U as TrySmallestUpgrade<T>>::LCM, Output = <U as TrySmallestUpgrade<T>>::LCM>,

Source§

type Output = <U as TrySmallestUpgrade<T>>::LCM

Source§

fn mul_fallible(&self, rhs: &T) -> Option<<U as FallibleMul<T>>::Output>

Source§

impl<T, U> FallibleSub<T> for U
where U: TrySmallestUpgrade<T>, T: TrySmallestUpgrade<U, LCM = <U as TrySmallestUpgrade<T>>::LCM>, <U as TrySmallestUpgrade<T>>::LCM: Clone + for<'b> RefSub<&'b <U as TrySmallestUpgrade<T>>::LCM, Output = <U as TrySmallestUpgrade<T>>::LCM>,

Source§

type Output = <U as TrySmallestUpgrade<T>>::LCM

Source§

fn sub_fallible(&self, rhs: &T) -> Option<<U as FallibleSub<T>>::Output>

Source§

impl<T, U> FallibleSubAssign<T> for U
where T: TrySmallestUpgrade<U, LCM = U>, <U as TrySmallestUpgrade<T>>::LCM: Clone + for<'b> RefSub<&'b <U as TrySmallestUpgrade<T>>::LCM, Output = <U as TrySmallestUpgrade<T>>::LCM>, U: TrySmallestUpgrade<T, LCM = U>,

Source§

fn sub_assign_fallible(&mut self, rhs: &T)

Source§

impl<T> FmtForward for T

Source§

fn fmt_binary(self) -> FmtBinary<Self>
where Self: Binary,

Causes self to use its Binary implementation when Debug-formatted.
Source§

fn fmt_display(self) -> FmtDisplay<Self>
where Self: Display,

Causes self to use its Display implementation when Debug-formatted.
Source§

fn fmt_lower_exp(self) -> FmtLowerExp<Self>
where Self: LowerExp,

Causes self to use its LowerExp implementation when Debug-formatted.
Source§

fn fmt_lower_hex(self) -> FmtLowerHex<Self>
where Self: LowerHex,

Causes self to use its LowerHex implementation when Debug-formatted.
Source§

fn fmt_octal(self) -> FmtOctal<Self>
where Self: Octal,

Causes self to use its Octal implementation when Debug-formatted.
Source§

fn fmt_pointer(self) -> FmtPointer<Self>
where Self: Pointer,

Causes self to use its Pointer implementation when Debug-formatted.
Source§

fn fmt_upper_exp(self) -> FmtUpperExp<Self>
where Self: UpperExp,

Causes self to use its UpperExp implementation when Debug-formatted.
Source§

fn fmt_upper_hex(self) -> FmtUpperHex<Self>
where Self: UpperHex,

Causes self to use its UpperHex implementation when Debug-formatted.
Source§

fn fmt_list(self) -> FmtList<Self>
where &'a Self: for<'a> IntoIterator,

Formats each item in a sequence. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> FunctionArgument for T
where T: Into<Coefficient> + Clone,

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

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
Source§

impl<T> IsZero for T
where T: RefZero + PartialEq,

Source§

fn is_zero(&self) -> bool

Source§

fn is_non_zero(&self) -> bool

Source§

impl<T> OverflowingAs for T

Source§

fn overflowing_as<Dst>(self) -> (Dst, bool)
where T: OverflowingCast<Dst>,

Casts the value.
Source§

impl<Src, Dst> OverflowingCastFrom<Src> for Dst
where Src: OverflowingCast<Dst>,

Source§

fn overflowing_cast_from(src: Src) -> (Dst, bool)

Casts the value.
Source§

impl<T> Pipe for T
where T: ?Sized,

Source§

fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> R
where Self: Sized,

Pipes by value. This is generally the method you want to use. Read more
Source§

fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> R
where R: 'a,

Borrows self and passes that borrow into the pipe function. Read more
Source§

fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> R
where R: 'a,

Mutably borrows self and passes that borrow into the pipe function. Read more
Source§

fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
where Self: Borrow<B>, B: 'a + ?Sized, R: 'a,

Borrows self, then passes self.borrow() into the pipe function. Read more
Source§

fn pipe_borrow_mut<'a, B, R>( &'a mut self, func: impl FnOnce(&'a mut B) -> R, ) -> R
where Self: BorrowMut<B>, B: 'a + ?Sized, R: 'a,

Mutably borrows self, then passes self.borrow_mut() into the pipe function. Read more
Source§

fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
where Self: AsRef<U>, U: 'a + ?Sized, R: 'a,

Borrows self, then passes self.as_ref() into the pipe function.
Source§

fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
where Self: AsMut<U>, U: 'a + ?Sized, R: 'a,

Mutably borrows self, then passes self.as_mut() into the pipe function.
Source§

fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
where Self: Deref<Target = T>, T: 'a + ?Sized, R: 'a,

Borrows self, then passes self.deref() into the pipe function.
Source§

fn pipe_deref_mut<'a, T, R>( &'a mut self, func: impl FnOnce(&'a mut T) -> R, ) -> R
where Self: DerefMut<Target = T> + Deref, T: 'a + ?Sized, R: 'a,

Mutably borrows self, then passes self.deref_mut() into the pipe function.
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T, Rhs, O> RefAdd<Rhs> for T
where &'a T: for<'a> Add<Rhs, Output = O>, T: ?Sized,

Source§

type Output = O

The resulting type after applying add operation.
Source§

fn ref_add(&self, rhs: Rhs) -> O

Performs add operation.
Source§

impl<T, Rhs, O> RefDiv<Rhs> for T
where &'a T: for<'a> Div<Rhs, Output = O>, T: ?Sized,

Source§

type Output = O

The resulting type after applying div operation.
Source§

fn ref_div(&self, rhs: Rhs) -> O

Performs div operation.
Source§

impl<T, Rhs, O> RefMul<Rhs> for T
where &'a T: for<'a> Mul<Rhs, Output = O>, T: ?Sized,

Source§

type Output = O

The resulting type after applying mul operation.
Source§

fn ref_mul(&self, rhs: Rhs) -> O

Performs mul operation.
Source§

impl<T, O> RefNeg for T
where &'a T: for<'a> Neg<Output = O>, T: ?Sized,

Source§

type Output = O

The resulting type after applying neg operation.
Source§

fn ref_neg(&self) -> O

Performs neg operation.
Source§

impl<T, Rhs, O> RefSub<Rhs> for T
where &'a T: for<'a> Sub<Rhs, Output = O>, T: ?Sized,

Source§

type Output = O

The resulting type after applying sub operation.
Source§

fn ref_sub(&self, rhs: Rhs) -> O

Performs sub operation.
Source§

impl<T> SaturatingAs for T

Source§

fn saturating_as<Dst>(self) -> Dst
where T: SaturatingCast<Dst>,

Casts the value.
Source§

impl<Src, Dst> SaturatingCastFrom<Src> for Dst
where Src: SaturatingCast<Dst>,

Source§

fn saturating_cast_from(src: Src) -> Dst

Casts the value.
Source§

impl<T> Tap for T

Source§

fn tap(self, func: impl FnOnce(&Self)) -> Self

Immutable access to a value. Read more
Source§

fn tap_mut(self, func: impl FnOnce(&mut Self)) -> Self

Mutable access to a value. Read more
Source§

fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
where Self: Borrow<B>, B: ?Sized,

Immutable access to the Borrow<B> of a value. Read more
Source§

fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
where Self: BorrowMut<B>, B: ?Sized,

Mutable access to the BorrowMut<B> of a value. Read more
Source§

fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
where Self: AsRef<R>, R: ?Sized,

Immutable access to the AsRef<R> view of a value. Read more
Source§

fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
where Self: AsMut<R>, R: ?Sized,

Mutable access to the AsMut<R> view of a value. Read more
Source§

fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
where Self: Deref<Target = T>, T: ?Sized,

Immutable access to the Deref::Target of a value. Read more
Source§

fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
where Self: DerefMut<Target = T> + Deref, T: ?Sized,

Mutable access to the Deref::Target of a value. Read more
Source§

fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self

Calls .tap() only in debug builds, and is erased in release builds.
Source§

fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self

Calls .tap_mut() only in debug builds, and is erased in release builds.
Source§

fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
where Self: Borrow<B>, B: ?Sized,

Calls .tap_borrow() only in debug builds, and is erased in release builds.
Source§

fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
where Self: BorrowMut<B>, B: ?Sized,

Calls .tap_borrow_mut() only in debug builds, and is erased in release builds.
Source§

fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
where Self: AsRef<R>, R: ?Sized,

Calls .tap_ref() only in debug builds, and is erased in release builds.
Source§

fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
where Self: AsMut<R>, R: ?Sized,

Calls .tap_ref_mut() only in debug builds, and is erased in release builds.
Source§

fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
where Self: Deref<Target = T>, T: ?Sized,

Calls .tap_deref() only in debug builds, and is erased in release builds.
Source§

fn tap_deref_mut_dbg<T>(self, func: impl FnOnce(&mut T)) -> Self
where Self: DerefMut<Target = T> + Deref, T: ?Sized,

Calls .tap_deref_mut() only in debug builds, and is erased in release builds.
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T> TryConv for T

Source§

fn try_conv<T>(self) -> Result<T, Self::Error>
where Self: TryInto<T>,

Attempts to convert self into T using TryInto<T>. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryFromUpgrade<T> for U
where T: TrySmallestUpgrade<U, LCM = U>, U: Clone,

Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T, U> TryIntoUpgrade<U> for T
where U: TryFromUpgrade<T>,

Source§

impl<T> UnwrappedAs for T

Source§

fn unwrapped_as<Dst>(self) -> Dst
where T: UnwrappedCast<Dst>,

Casts the value.
Source§

impl<Src, Dst> UnwrappedCastFrom<Src> for Dst
where Src: UnwrappedCast<Dst>,

Source§

fn unwrapped_cast_from(src: Src) -> Dst

Casts the value.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

impl<T> WrappingAs for T

Source§

fn wrapping_as<Dst>(self) -> Dst
where T: WrappingCast<Dst>,

Casts the value.
Source§

impl<Src, Dst> WrappingCastFrom<Src> for Dst
where Src: WrappingCast<Dst>,

Source§

fn wrapping_cast_from(src: Src) -> Dst

Casts the value.
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<'py, T> FromPyObjectOwned<'py> for T
where T: for<'a> FromPyObject<'a, 'py>,

Source§

impl<T> Op for T
where T: Clone + Eq + Ord,

Source§

impl<T, Base> RefNum<Base> for T
where T: NumOps<Base, Base> + for<'r> NumOps<&'r Base, Base>,

Source§

impl<T> RuleType for T
where T: Copy + Debug + Eq + Hash + Ord,

Source§

impl<T> Ungil for T
where T: Send,