pub struct Complex<T> {
pub re: T,
pub im: T,
}Expand description
Generic complex number.
Fields§
§re: T§im: TImplementations§
Trait Implementations§
source§impl<T: Add<Output = T>> Add for Complex<T>
impl<T: Add<Output = T>> Add for Complex<T>
Addition of two generic complex numbers.
source§impl Mul<Complex<f64>> for f64
impl Mul<Complex<f64>> for f64
Multiplication Complex<f64> * f64.
source§impl Mul<f64> for Complex<f64>
impl Mul<f64> for Complex<f64>
source§impl<T: Mul<Output = T> + Add<Output = T> + Sub<Output = T> + Copy> Mul for Complex<T>
impl<T: Mul<Output = T> + Add<Output = T> + Sub<Output = T> + Copy> Mul for Complex<T>
Multiplying two generic complex numbers.
source§impl<T: PartialEq> PartialEq for Complex<T>
impl<T: PartialEq> PartialEq for Complex<T>
source§impl<T: Sub<Output = T>> Sub for Complex<T>
impl<T: Sub<Output = T>> Sub for Complex<T>
Subtracts two generic complex numbers.
impl<T: Copy> Copy for Complex<T>
impl<T> StructuralPartialEq for Complex<T>
Auto Trait Implementations§
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> 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