Struct dvec::Complex [] [src]

pub struct Complex<T> {
    pub a: T,
    pub b: T,
}

Complex number with form (a + bi).

Fields

Methods

impl<T> Complex<T>
[src]

Trait Implementations

impl<T: Clone> Clone for Complex<T>
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl<T: Copy> Copy for Complex<T>
[src]

impl<T: Debug> Debug for Complex<T>
[src]

Formats the value using the given formatter.

impl<T: Default> Default for Complex<T>
[src]

Returns the "default value" for a type. Read more

impl<T: Eq> Eq for Complex<T>
[src]

impl<T: Hash> Hash for Complex<T>
[src]

Feeds this value into the given [Hasher]. Read more

Feeds a slice of this type into the given [Hasher]. Read more

impl<T: PartialEq> PartialEq for Complex<T>
[src]

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

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

The resulting type after applying the + operator

The method for the + operator

impl<T> From<T> for Complex<T> where
    T: Zero
[src]

Performs the conversion.

impl<T> From<(T, T)> for Complex<T>
[src]

Performs the conversion.

impl<T> From<Vec2<T>> for Complex<T>
[src]

Performs the conversion.

impl<T> Mul for Complex<T> where
    T: Copy + Add<Output = T> + Sub<Output = T> + Mul<Output = T>, 
[src]

The resulting type after applying the * operator

The method for the * operator

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

The resulting type after applying the - operator

The method for the - operator