[][src]Struct adtensor::ADScalar

pub struct ADScalar<T, P> where
    P: ArrayLength<T>, 
{ pub v: T, pub g: GenericArray<T, P>, }

Fields

v: Tg: GenericArray<T, P>

Methods

impl<T, P1> ADScalar<T, P1> where
    P1: Unsigned + ArrayLength<T>, 
[src]

pub fn zip<P2, F>(
    self,
    rhs: ADScalar<T, P2>,
    f: F
) -> ADScalar<T, <P1 as Max<P2>>::Output> where
    P1: Max<P2>,
    P2: Unsigned + ArrayLength<T>,
    <P1 as Max<P2>>::Output: ArrayLength<T>,
    ADScalar<T, <P1 as Max<P2>>::Output>: Default,
    F: Fn(T, T) -> T,
    T: Default + Clone
[src]

Trait Implementations

impl<T, P> Clone for ADScalar<T, P> where
    P: ArrayLength<T>,
    T: Clone
[src]

fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

impl<T, P> Copy for ADScalar<T, P> where
    P: ArrayLength<T>,
    T: Copy,
    GenericArray<T, P>: Copy
[src]

impl<T, P> Default for ADScalar<T, P> where
    P: ArrayLength<T>,
    T: Default
[src]

impl<T, P> Add<T> for ADScalar<T, P> where
    P: ArrayLength<T>,
    T: Add<T, Output = T>, 
[src]

type Output = Self

The resulting type after applying the + operator.

impl<T, P1, P2> Add<ADScalar<T, P2>> for ADScalar<T, P1> where
    P1: Unsigned + Max<P2> + ArrayLength<T>,
    P2: Unsigned + ArrayLength<T>,
    <P1 as Max<P2>>::Output: ArrayLength<T>,
    ADScalar<T, <P1 as Max<P2>>::Output>: Default,
    T: Add<T, Output = T> + Default + Clone
[src]

type Output = ADScalar<T, <P1 as Max<P2>>::Output>

The resulting type after applying the + operator.

impl<T, P> Sub<T> for ADScalar<T, P> where
    P: ArrayLength<T>,
    T: Sub<T, Output = T>, 
[src]

type Output = Self

The resulting type after applying the - operator.

impl<T, P1, P2> Sub<ADScalar<T, P2>> for ADScalar<T, P1> where
    P1: Unsigned + Max<P2> + ArrayLength<T>,
    P2: Unsigned + ArrayLength<T>,
    <P1 as Max<P2>>::Output: ArrayLength<T>,
    ADScalar<T, <P1 as Max<P2>>::Output>: Default,
    T: Sub<T, Output = T> + Default + Clone
[src]

type Output = ADScalar<T, <P1 as Max<P2>>::Output>

The resulting type after applying the - operator.

impl<T, P> Mul<T> for ADScalar<T, P> where
    P: ArrayLength<T>,
    T: Mul<T, Output = T> + Clone
[src]

type Output = Self

The resulting type after applying the * operator.

impl<T, P1, P2> Mul<ADScalar<T, P2>> for ADScalar<T, P1> where
    P1: Unsigned + Max<P2> + ArrayLength<T>,
    P2: Unsigned + ArrayLength<T>,
    <P1 as Max<P2>>::Output: ArrayLength<T>,
    ADScalar<T, <P1 as Max<P2>>::Output>: Default,
    T: Add<T, Output = T> + Mul<T, Output = T> + Default + Clone
[src]

type Output = ADScalar<T, <P1 as Max<P2>>::Output>

The resulting type after applying the * operator.

impl<T, P> Div<T> for ADScalar<T, P> where
    P: ArrayLength<T>,
    T: Div<T, Output = T> + Clone
[src]

type Output = Self

The resulting type after applying the / operator.

impl<T, P1, P2> Div<ADScalar<T, P2>> for ADScalar<T, P1> where
    P1: Unsigned + Max<P2> + ArrayLength<T>,
    P2: Unsigned + ArrayLength<T>,
    <P1 as Max<P2>>::Output: ArrayLength<T>,
    ADScalar<T, <P1 as Max<P2>>::Output>: Default,
    T: Sub<T, Output = T> + Div<T, Output = T> + Mul<T, Output = T> + Default + Clone + One
[src]

type Output = ADScalar<T, <P1 as Max<P2>>::Output>

The resulting type after applying the / operator.

impl<T, P> Debug for ADScalar<T, P> where
    P: ArrayLength<T>,
    T: Debug
[src]

Auto Trait Implementations

impl<T, P> Send for ADScalar<T, P> where
    T: Send

impl<T, P> Sync for ADScalar<T, P> where
    T: Sync

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> From for T[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Same for T[src]

type Output = T

Should always be Self