Struct vecmat::Matrix[][src]

#[repr(transparent)]
pub struct Matrix<T, const M: usize, const N: usize> { /* fields omitted */ }
Expand description

Matrix with fixed dimensions.

Implementations

impl<T, const M: usize, const N: usize> Matrix<T, M, N>[src]

impl<T, const M: usize, const N: usize> Matrix<T, M, N>[src]

pub fn as_vector_of_vectors(&self) -> &Vector<Vector<T, N>, M>[src]

pub fn as_mut_vector_of_vectors(&mut self) -> &mut Vector<Vector<T, N>, M>[src]

pub fn as_array_of_vectors(&self) -> &[Vector<T, N>; M][src]

pub fn as_mut_array_of_vectors(&mut self) -> &mut [Vector<T, N>; M][src]

pub fn as_array_of_arrays(&self) -> &[[T; N]; M][src]

pub fn as_mut_array_of_arrays(&mut self) -> &mut [[T; N]; M][src]

impl<T, const M: usize, const N: usize> Matrix<T, M, N>[src]

pub fn try_from_iter_of_vectors<I>(i: I) -> Option<Self> where
    I: Iterator<Item = Vector<T, N>>, 
[src]

pub fn try_from_iter<I>(i: I) -> Option<Self> where
    I: Iterator<Item = T>, 
[src]

impl<T, const M: usize, const N: usize> Matrix<T, M, N>[src]

pub fn uninit() -> Matrix<MaybeUninit<T>, M, N>[src]

Create a matrix with uninitialized content.

impl<T, const M: usize, const N: usize> Matrix<MaybeUninit<T>, M, N>[src]

pub unsafe fn assume_init(self) -> Matrix<T, M, N>[src]

Assume that matrix content is initialized.

impl<T, const M: usize, const N: usize> Matrix<T, M, N>[src]

pub fn init<F: FnMut() -> T>(f: F) -> Self[src]

Initialize matrix by closure.

impl<T, const M: usize, const N: usize> Matrix<T, M, N> where
    T: Default
[src]

pub fn new() -> Self[src]

Create default matrix.

impl<T, const M: usize, const N: usize> Matrix<T, M, N> where
    T: Copy
[src]

pub fn fill(v: T) -> Self[src]

Create matrix which elements are filled with scalar value.

pub fn fill_ref(v: &T) -> Self[src]

Fill with a scalar value reference.

impl<T, const M: usize, const N: usize> Matrix<T, M, N>[src]

pub fn row_ref(&self, i: usize) -> &Vector<T, N>[src]

pub fn row_mut(&mut self, i: usize) -> &mut Vector<T, N>[src]

impl<T, const M: usize, const N: usize> Matrix<T, M, N> where
    T: Copy
[src]

pub fn row(&self, i: usize) -> Vector<T, N>[src]

pub fn col(&self, j: usize) -> Vector<T, M>[src]

impl<T, const M: usize, const N: usize> Matrix<T, M, N>[src]

pub fn as_ptr(&self) -> *const T[src]

Get pointer to the first element.

pub fn as_mut_ptr(&mut self) -> *mut T[src]

Get mutable pointer to the first element.

pub unsafe fn get_unchecked(&self, i: usize, j: usize) -> &T[src]

pub unsafe fn get_unchecked_mut(&mut self, i: usize, j: usize) -> &mut T[src]

impl<T, const M: usize, const N: usize> Matrix<T, M, N>[src]

pub fn iter(&self) -> impl Iterator<Item = &T>[src]

Returns iterator over matrix element refrences.

pub fn iter_mut(&mut self) -> impl Iterator<Item = &mut T>[src]

Returns iterator over matrix element mutable refrences.

impl<const M: usize, const N: usize> Matrix<(usize, usize), M, N>[src]

pub fn indices() -> Self[src]

Create matrix which elements are tuples (j, i) where j and i are coordinates of the matrix cell.

impl<T, const M: usize, const N: usize> Matrix<T, M, N>[src]

pub fn for_each<F: FnMut(T)>(self, f: F)[src]

Call closure for each element of the matrix passing it by value.

pub fn map<U, F: FnMut(T) -> U>(self, f: F) -> Matrix<U, M, N>[src]

Map matrix elements.

pub fn zip<U>(self, other: Matrix<U, M, N>) -> Matrix<(T, U), M, N>[src]

Zip two matrices into one.

impl<T, U, const M: usize, const N: usize> Matrix<(T, U), M, N>[src]

pub fn unzip(self) -> (Matrix<T, M, N>, Matrix<U, M, N>)[src]

Unzip matrix of tuples into two matrices.

impl<T, const M: usize, const N: usize> Matrix<T, M, N>[src]

pub fn fold<S, F: Fn(S, T) -> S>(self, s: S, f: F) -> S[src]

pub fn fold_first<F: FnMut(T, T) -> T>(self, f: F) -> T[src]

pub fn scan<S, U, F: FnMut(&mut S, T) -> U>(self, s: S, f: F) -> Matrix<U, M, N>[src]

impl<T, const M: usize, const N: usize> Matrix<T, M, N>[src]

pub fn sum(self) -> T where
    T: Add<Output = T>, 
[src]

pub fn max(self) -> T where
    T: PartialOrd
[src]

pub fn min(self) -> T where
    T: PartialOrd
[src]

impl<const M: usize, const N: usize> Matrix<bool, M, N>[src]

pub fn any(self) -> bool[src]

impl<const M: usize, const N: usize> Matrix<bool, M, N>[src]

pub fn all(self) -> bool[src]

impl<T, const M: usize, const N: usize> Matrix<T, M, N> where
    T: Integer
[src]

pub fn div_floor(self, other: Matrix<T, M, N>) -> Matrix<T, M, N>[src]

pub fn mod_floor(self, other: Matrix<T, M, N>) -> Matrix<T, M, N>[src]

pub fn div_mod_floor(
    self,
    other: Matrix<T, M, N>
) -> (Matrix<T, M, N>, Matrix<T, M, N>)
[src]

impl<T, const M: usize, const N: usize> Matrix<T, M, N> where
    T: PartialEq
[src]

pub fn veq(self, other: Matrix<T, M, N>) -> Matrix<bool, M, N>[src]

pub fn vne(self, other: Matrix<T, M, N>) -> Matrix<bool, M, N>[src]

impl<T, const M: usize, const N: usize> Matrix<T, M, N> where
    T: PartialOrd
[src]

pub fn vlt(self, other: Matrix<T, M, N>) -> Matrix<bool, M, N>[src]

pub fn vle(self, other: Matrix<T, M, N>) -> Matrix<bool, M, N>[src]

pub fn vgt(self, other: Matrix<T, M, N>) -> Matrix<bool, M, N>[src]

pub fn vge(self, other: Matrix<T, M, N>) -> Matrix<bool, M, N>[src]

impl<T, const N: usize> Matrix<T, N, N> where
    T: Zero
[src]

pub fn diagonal(diag: Vector<T, N>) -> Self[src]

Create diagonal matrix.

impl<T, const N: usize> Matrix<T, N, N> where
    T: Neg<Output = T> + Num + Copy
[src]

pub fn cofactor(&self, i: usize, j: usize) -> T[src]

Cofactor of the matrix at (i, j).

pub fn det(&self) -> T[src]

Determinant of the matrix.

pub fn adj(&self) -> Self[src]

Adjugate matrix.

pub fn inv(&self) -> Self[src]

Inverse matrix.

impl<T, const M: usize, const N: usize> Matrix<T, M, N>[src]

pub fn transpose(self) -> Matrix<T, N, M>[src]

Trait Implementations

impl<T, const M: usize, const N: usize> AbsDiffEq<Matrix<T, M, N>> for Matrix<T, M, N> where
    T: AbsDiffEq<Epsilon = T> + Copy
[src]

type Epsilon = T

Used for specifying relative comparisons.

fn default_epsilon() -> Self::Epsilon[src]

The default tolerance to use when testing values that are close together. Read more

fn abs_diff_eq(&self, other: &Self, epsilon: Self::Epsilon) -> bool[src]

A test for equality that uses the absolute difference to compute the approximate equality of two numbers. Read more

fn abs_diff_ne(&self, other: &Rhs, epsilon: Self::Epsilon) -> bool[src]

The inverse of AbsDiffEq::abs_diff_eq.

impl<T, const M: usize, const N: usize> Add<Matrix<T, M, N>> for Matrix<T, M, N> where
    T: Add<Output = T>, 
[src]

type Output = Matrix<T, M, N>

The resulting type after applying the + operator.

fn add(self, vec: Matrix<T, M, N>) -> Self::Output[src]

Performs the + operation. Read more

impl<T, const M: usize, const N: usize> AddAssign<Matrix<T, M, N>> for Matrix<T, M, N> where
    T: AddAssign
[src]

fn add_assign(&mut self, vec: Matrix<T, M, N>)[src]

Performs the += operation. Read more

impl<T, const M: usize, const N: usize> AsMut<Vector<Vector<T, N>, M>> for Matrix<T, M, N>[src]

fn as_mut(&mut self) -> &mut Vector<Vector<T, N>, M>[src]

Performs the conversion.

impl<T, const M: usize, const N: usize> AsRef<Vector<Vector<T, N>, M>> for Matrix<T, M, N>[src]

fn as_ref(&self) -> &Vector<Vector<T, N>, M>[src]

Performs the conversion.

impl<T, const M: usize, const N: usize> BitAnd<Matrix<T, M, N>> for Matrix<T, M, N> where
    T: BitAnd<Output = T>, 
[src]

type Output = Matrix<T, M, N>

The resulting type after applying the & operator.

fn bitand(self, other: Matrix<T, M, N>) -> Self::Output[src]

Performs the & operation. Read more

impl<T, const M: usize, const N: usize> BitAndAssign<Matrix<T, M, N>> for Matrix<T, M, N> where
    T: BitAndAssign
[src]

fn bitand_assign(&mut self, other: Matrix<T, M, N>)[src]

Performs the &= operation. Read more

impl<T, const M: usize, const N: usize> BitOr<Matrix<T, M, N>> for Matrix<T, M, N> where
    T: BitOr<Output = T>, 
[src]

type Output = Matrix<T, M, N>

The resulting type after applying the | operator.

fn bitor(self, other: Matrix<T, M, N>) -> Self::Output[src]

Performs the | operation. Read more

impl<T, const M: usize, const N: usize> BitOrAssign<Matrix<T, M, N>> for Matrix<T, M, N> where
    T: BitOrAssign
[src]

fn bitor_assign(&mut self, other: Matrix<T, M, N>)[src]

Performs the |= operation. Read more

impl<T, const M: usize, const N: usize> BitXor<Matrix<T, M, N>> for Matrix<T, M, N> where
    T: BitXor<Output = T>, 
[src]

type Output = Matrix<T, M, N>

The resulting type after applying the ^ operator.

fn bitxor(self, other: Matrix<T, M, N>) -> Self::Output[src]

Performs the ^ operation. Read more

impl<T, const M: usize, const N: usize> BitXorAssign<Matrix<T, M, N>> for Matrix<T, M, N> where
    T: BitXorAssign
[src]

fn bitxor_assign(&mut self, other: Matrix<T, M, N>)[src]

Performs the ^= operation. Read more

impl<T: Clone, const M: usize, const N: usize> Clone for Matrix<T, M, N>[src]

fn clone(&self) -> Matrix<T, M, N>[src]

Returns a copy of the value. Read more

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

Performs copy-assignment from source. Read more

impl<T, const M: usize, const N: usize> Debug for Matrix<T, M, N> where
    T: Debug
[src]

fn fmt(&self, f: &mut Formatter<'_>) -> FmtResult[src]

Formats the value using the given formatter. Read more

impl<T, const M: usize, const N: usize> Default for Matrix<T, M, N> where
    T: Default
[src]

fn default() -> Self[src]

Create matrix filled with default values.

impl<T, const M: usize, const N: usize> Display for Matrix<T, M, N> where
    T: Display
[src]

fn fmt(&self, f: &mut Formatter<'_>) -> FmtResult[src]

Formats the value using the given formatter. Read more

impl<D: Distribution<T>, T, const M: usize, const N: usize> Distribution<Matrix<T, M, N>> for MatrixDistribution<D, T, M, N>[src]

fn sample<R: Rng + ?Sized>(&self, rng: &mut R) -> Matrix<T, M, N>[src]

Generate a random value of T, using rng as the source of randomness.

fn sample_iter<R>(self, rng: R) -> DistIter<Self, R, T> where
    R: Rng
[src]

Create an iterator that generates random values of T, using rng as the source of randomness. Read more

impl<T, const M: usize, const N: usize> Distribution<Matrix<T, M, N>> for Normal where
    Normal: Distribution<T>, 
[src]

fn sample<R: Rng + ?Sized>(&self, rng: &mut R) -> Matrix<T, M, N>[src]

Generate a random value of T, using rng as the source of randomness.

fn sample_iter<R>(self, rng: R) -> DistIter<Self, R, T> where
    R: Rng
[src]

Create an iterator that generates random values of T, using rng as the source of randomness. Read more

impl<T, const N: usize> Distribution<Matrix<T, N, N>> for Invertible where
    Normal: Distribution<Matrix<T, N, N>>,
    T: Neg<Output = T> + Num + NormL1 + Copy,
    <T as NormL1>::Output: Epsilon
[src]

fn sample<R: Rng + ?Sized>(&self, rng: &mut R) -> Matrix<T, N, N>[src]

Generate a random value of T, using rng as the source of randomness.

fn sample_iter<R>(self, rng: R) -> DistIter<Self, R, T> where
    R: Rng
[src]

Create an iterator that generates random values of T, using rng as the source of randomness. Read more

impl<T, const M: usize, const N: usize> Div<Matrix<T, M, N>> for Matrix<T, M, N> where
    T: Div<Output = T>, 
[src]

type Output = Matrix<T, M, N>

The resulting type after applying the / operator.

fn div(self, vec: Matrix<T, M, N>) -> Self::Output[src]

Performs the / operation. Read more

impl<T, const M: usize, const N: usize> Div<T> for Matrix<T, M, N> where
    T: Div<Output = T> + Copy
[src]

type Output = Matrix<T, M, N>

The resulting type after applying the / operator.

fn div(self, a: T) -> Self::Output[src]

Performs the / operation. Read more

impl<T, const M: usize, const N: usize> DivAssign<Matrix<T, M, N>> for Matrix<T, M, N> where
    T: DivAssign
[src]

fn div_assign(&mut self, vec: Matrix<T, M, N>)[src]

Performs the /= operation. Read more

impl<T, const M: usize, const N: usize> DivAssign<T> for Matrix<T, M, N> where
    T: DivAssign + Copy
[src]

fn div_assign(&mut self, a: T)[src]

Performs the /= operation. Read more

impl<T, const M: usize, const N: usize> Dot<Matrix<T, M, N>> for Vector<T, M> where
    T: Mul<Output = T> + Add<Output = T> + Copy
[src]

type Output = Vector<T, N>

Dot product output type.

fn dot(self, mat: Matrix<T, M, N>) -> Self::Output[src]

Perform dot product.

impl<T, const L: usize, const M: usize, const N: usize> Dot<Matrix<T, M, N>> for Matrix<T, L, M> where
    T: Mul<Output = T> + Add<Output = T> + Copy
[src]

type Output = Matrix<T, L, N>

Dot product output type.

fn dot(self, mat: Matrix<T, M, N>) -> Self::Output[src]

Perform dot product.

impl<T, const M: usize, const N: usize> Dot<Vector<T, N>> for Matrix<T, M, N> where
    T: Mul<Output = T> + Add<Output = T> + Copy
[src]

type Output = Vector<T, M>

Dot product output type.

fn dot(self, vec: Vector<T, N>) -> Self::Output[src]

Perform dot product.

impl<T, const M: usize, const N: usize> From<&'_ [[T; N]; M]> for Matrix<T, M, N> where
    T: Copy
[src]

fn from(ar: &[[T; N]; M]) -> Self[src]

Performs the conversion.

impl<T, const M: usize, const N: usize> From<&'_ [Vector<T, N>; M]> for Matrix<T, M, N> where
    T: Copy
[src]

fn from(ar: &[Vector<T, N>; M]) -> Self[src]

Performs the conversion.

impl<T, const M: usize, const N: usize> From<&'_ Vector<Vector<T, N>, M>> for Matrix<T, M, N> where
    T: Copy
[src]

fn from(ar: &Vector<Vector<T, N>, M>) -> Self[src]

Performs the conversion.

impl<'a, T, const M: usize, const N: usize> From<&'a Matrix<T, M, N>> for &'a Vector<Vector<T, N>, M>[src]

fn from(mr: &'a Matrix<T, M, N>) -> Self[src]

Performs the conversion.

impl<'a, T, const M: usize, const N: usize> From<&'a mut Matrix<T, M, N>> for &'a mut Vector<Vector<T, N>, M>[src]

fn from(mr: &'a mut Matrix<T, M, N>) -> Self[src]

Performs the conversion.

impl<T, const M: usize, const N: usize> From<[[T; N]; M]> for Matrix<T, M, N>[src]

fn from(a: [[T; N]; M]) -> Self[src]

Performs the conversion.

impl<T, const M: usize, const N: usize> From<[Vector<T, N>; M]> for Matrix<T, M, N>[src]

fn from(a: [Vector<T, N>; M]) -> Self[src]

Performs the conversion.

impl<T, const N: usize> From<Linear<T, N>> for Matrix<T, N, N>[src]

fn from(lin: Linear<T, N>) -> Matrix<T, N, N>[src]

Performs the conversion.

impl<T> From<Matrix<T, 2_usize, 2_usize>> for Moebius<T>[src]

fn from(mat: Matrix2x2<T>) -> Self[src]

Performs the conversion.

impl<T, const M: usize, const N: usize> From<Matrix<T, M, N>> for Vector<Vector<T, N>, M>[src]

fn from(mat: Matrix<T, M, N>) -> Self[src]

Performs the conversion.

impl<T, const N: usize> From<Matrix<T, N, N>> for Linear<T, N>[src]

fn from(lin: Matrix<T, N, N>) -> Self[src]

Performs the conversion.

impl<T, const M: usize, const N: usize> From<Vector<Vector<T, N>, M>> for Matrix<T, M, N>[src]

fn from(a: Vector<Vector<T, N>, M>) -> Self[src]

Performs the conversion.

impl<T, const M: usize, const N: usize> Index<(usize, usize)> for Matrix<T, M, N>[src]

type Output = T

The returned type after indexing.

fn index(&self, (j, i): (usize, usize)) -> &T[src]

Performs the indexing (container[index]) operation. Read more

impl<T, const M: usize, const N: usize> IndexMut<(usize, usize)> for Matrix<T, M, N>[src]

fn index_mut(&mut self, (j, i): (usize, usize)) -> &mut T[src]

Performs the mutable indexing (container[index]) operation. Read more

impl<T, const M: usize, const N: usize> IntoIterator for Matrix<T, M, N>[src]

type Item = T

The type of the elements being iterated over.

type IntoIter = FlatIter<<Vector<Vector<T, N>, M> as IntoIterator>::IntoIter, Vector<T, N>, <Vector<T, N> as IntoIterator>::IntoIter>

Which kind of iterator are we turning this into?

fn into_iter(self) -> Self::IntoIter[src]

Creates an iterator from a value. Read more

impl<'a, T, const M: usize, const N: usize> IntoIterator for &'a Matrix<T, M, N>[src]

type Item = &'a T

The type of the elements being iterated over.

type IntoIter = FlatIter<Iter<'a, Vector<T, N>>, &'a Vector<T, N>, Iter<'a, T>>

Which kind of iterator are we turning this into?

fn into_iter(self) -> Self::IntoIter[src]

Creates an iterator from a value. Read more

impl<'a, T, const M: usize, const N: usize> IntoIterator for &'a mut Matrix<T, M, N>[src]

type Item = &'a mut T

The type of the elements being iterated over.

type IntoIter = FlatIter<IterMut<'a, Vector<T, N>>, &'a mut Vector<T, N>, IterMut<'a, T>>

Which kind of iterator are we turning this into?

fn into_iter(self) -> Self::IntoIter[src]

Creates an iterator from a value. Read more

impl<T, const N: usize> Inv for Matrix<T, N, N> where
    T: Neg<Output = T> + Num + Copy
[src]

type Output = Self

The result after applying the operator.

fn inv(self) -> Self::Output[src]

Returns the multiplicative inverse of self. Read more

impl<T, const M: usize, const N: usize> Mul<Matrix<T, M, N>> for Matrix<T, M, N> where
    T: Mul<Output = T>, 
[src]

type Output = Matrix<T, M, N>

The resulting type after applying the * operator.

fn mul(self, vec: Matrix<T, M, N>) -> Self::Output[src]

Performs the * operation. Read more

impl<T, const M: usize, const N: usize> Mul<T> for Matrix<T, M, N> where
    T: Mul<Output = T> + Copy
[src]

type Output = Matrix<T, M, N>

The resulting type after applying the * operator.

fn mul(self, a: T) -> Self::Output[src]

Performs the * operation. Read more

impl<T, const M: usize, const N: usize> MulAssign<Matrix<T, M, N>> for Matrix<T, M, N> where
    T: MulAssign
[src]

fn mul_assign(&mut self, vec: Matrix<T, M, N>)[src]

Performs the *= operation. Read more

impl<T, const M: usize, const N: usize> MulAssign<T> for Matrix<T, M, N> where
    T: MulAssign + Copy
[src]

fn mul_assign(&mut self, a: T)[src]

Performs the *= operation. Read more

impl<T, const M: usize, const N: usize> Neg for Matrix<T, M, N> where
    T: Neg<Output = T>, 
[src]

type Output = Matrix<T, M, N>

The resulting type after applying the - operator.

fn neg(self) -> Self::Output[src]

Performs the unary - operation. Read more

impl<T, const M: usize, const N: usize> NormL1 for Matrix<T, M, N> where
    T: NormL1<Output = T> + Add<Output = T>, 
[src]

type Output = T

Type of the norm.

fn norm_l1(self) -> T[src]

Norm of the element.

impl<T, const M: usize, const N: usize> NormL2 for Matrix<T, M, N> where
    T: Float
[src]

type Output = T

Type of the norm.

fn norm_l2_sqr(self) -> T[src]

Square norm of the element.

fn norm_l2(self) -> T[src]

Norm of the element.

impl<T, const M: usize, const N: usize> NormLInf for Matrix<T, M, N> where
    T: NormLInf<Output = T> + PartialOrd
[src]

type Output = T

Type of the norm.

fn norm_l_inf(self) -> T[src]

Norm of the element.

impl<T, const M: usize, const N: usize> Not for Matrix<T, M, N> where
    T: Not<Output = T>, 
[src]

type Output = Matrix<T, M, N>

The resulting type after applying the ! operator.

fn not(self) -> Self::Output[src]

Performs the unary ! operation. Read more

impl<T, const N: usize> One for Matrix<T, N, N> where
    T: One + Zero
[src]

fn one() -> Self[src]

Create identity matrix.

fn set_one(&mut self)[src]

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

fn is_one(&self) -> bool where
    Self: PartialEq<Self>, 
[src]

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

impl<T: PartialEq, const M: usize, const N: usize> PartialEq<Matrix<T, M, N>> for Matrix<T, M, N>[src]

fn eq(&self, other: &Matrix<T, M, N>) -> bool[src]

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

fn ne(&self, other: &Matrix<T, M, N>) -> bool[src]

This method tests for !=.

impl<T, const M: usize, const N: usize> Rem<Matrix<T, M, N>> for Matrix<T, M, N> where
    T: Rem<Output = T>, 
[src]

type Output = Matrix<T, M, N>

The resulting type after applying the % operator.

fn rem(self, vec: Matrix<T, M, N>) -> Self::Output[src]

Performs the % operation. Read more

impl<T, const M: usize, const N: usize> Rem<T> for Matrix<T, M, N> where
    T: Rem<Output = T> + Copy
[src]

type Output = Matrix<T, M, N>

The resulting type after applying the % operator.

fn rem(self, a: T) -> Self::Output[src]

Performs the % operation. Read more

impl<T, const M: usize, const N: usize> RemAssign<Matrix<T, M, N>> for Matrix<T, M, N> where
    T: RemAssign
[src]

fn rem_assign(&mut self, vec: Matrix<T, M, N>)[src]

Performs the %= operation. Read more

impl<T, const M: usize, const N: usize> RemAssign<T> for Matrix<T, M, N> where
    T: RemAssign + Copy
[src]

fn rem_assign(&mut self, a: T)[src]

Performs the %= operation. Read more

impl<T, const M: usize, const N: usize> Sub<Matrix<T, M, N>> for Matrix<T, M, N> where
    T: Sub<Output = T>, 
[src]

type Output = Matrix<T, M, N>

The resulting type after applying the - operator.

fn sub(self, vec: Matrix<T, M, N>) -> Self::Output[src]

Performs the - operation. Read more

impl<T, const M: usize, const N: usize> SubAssign<Matrix<T, M, N>> for Matrix<T, M, N> where
    T: SubAssign
[src]

fn sub_assign(&mut self, vec: Matrix<T, M, N>)[src]

Performs the -= operation. Read more

impl<'a, T, const M: usize, const N: usize> TryFrom<&'a [T]> for Matrix<T, M, N> where
    T: Copy
[src]

type Error = ()

The type returned in the event of a conversion error.

fn try_from(s: &'a [T]) -> Result<Self, ()>[src]

Performs the conversion.

impl<'a, T, const M: usize, const N: usize> TryFrom<&'a [Vector<T, N>]> for Matrix<T, M, N> where
    T: Copy
[src]

type Error = ()

The type returned in the event of a conversion error.

fn try_from(s: &'a [Vector<T, N>]) -> Result<Self, ()>[src]

Performs the conversion.

impl<T, const M: usize, const N: usize> Zero for Matrix<T, M, N> where
    T: Zero
[src]

fn zero() -> Self[src]

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

fn is_zero(&self) -> bool[src]

Returns true if self is equal to the additive identity.

fn set_zero(&mut self)[src]

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

impl<T: Copy, const M: usize, const N: usize> Copy for Matrix<T, M, N>[src]

impl<T, const M: usize, const N: usize> StructuralPartialEq for Matrix<T, M, N>[src]

Auto Trait Implementations

impl<T, const M: usize, const N: usize> RefUnwindSafe for Matrix<T, M, N> where
    T: RefUnwindSafe

impl<T, const M: usize, const N: usize> Send for Matrix<T, M, N> where
    T: Send

impl<T, const M: usize, const N: usize> Sync for Matrix<T, M, N> where
    T: Sync

impl<T, const M: usize, const N: usize> Unpin for Matrix<T, M, N> where
    T: Unpin

impl<T, const M: usize, const N: usize> UnwindSafe for Matrix<T, M, N> where
    T: UnwindSafe

Blanket Implementations

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

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

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

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

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

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

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

pub fn from(t: T) -> T[src]

Performs the conversion.

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

pub fn into(self) -> U[src]

Performs the conversion.

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

type Owned = T

The resulting type after obtaining ownership.

pub fn to_owned(&self) -> T[src]

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

pub fn clone_into(&self, target: &mut T)[src]

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

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

impl<T> ToString for T where
    T: Display + ?Sized
[src]

pub default fn to_string(&self) -> String[src]

Converts the given value to a String. Read more

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

type Error = Infallible

The type returned in the event of a conversion error.

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

Performs the conversion.

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

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

The type returned in the event of a conversion error.

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

Performs the conversion.

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

pub fn vzip(self) -> V

impl<T, Rhs> NumAssignOps<Rhs> for T where
    T: AddAssign<Rhs> + SubAssign<Rhs> + MulAssign<Rhs> + DivAssign<Rhs> + RemAssign<Rhs>, 
[src]

impl<T, Rhs, Output> NumOps<Rhs, Output> for T where
    T: Sub<Rhs, Output = Output> + Mul<Rhs, Output = Output> + Div<Rhs, Output = Output> + Add<Rhs, Output = Output> + Rem<Rhs, Output = Output>, 
[src]