[−][src]Trait aljabar::SquareMatrix
Defines a matrix with an equal number of elements in either dimension.
Square matrices can be added, subtracted, and multiplied indiscriminately together. This is a type constraint; only Matrices that are square are able to be multiplied by matrices of the same size.
I believe that SquareMatrix should not have parameters, but associated types and constants do not play well with const generics.
Required methods
fn determinant(&self) -> Scalar
Returns the determinant of the Matrix.
fn invert(self) -> Option<Self>
Attempt to invert the matrix.
fn diagonal(&self) -> Vector<Scalar, { N }>
Return the diagonal of the matrix.
Implementors
impl<Scalar, const N: usize> SquareMatrix<Scalar, N> for Matrix<Scalar, { N }, { N }> where
Scalar: Clone + One + Zero,
Scalar: Neg<Output = Scalar>,
Scalar: Add<Scalar, Output = Scalar> + Sub<Scalar, Output = Scalar>,
Scalar: Mul<Scalar, Output = Scalar> + Div<Scalar, Output = Scalar>,
Self: Add<Self>,
Self: Sub<Self>,
Self: Mul<Self>,
Self: Mul<Vector<Scalar, { N }>, Output = Vector<Scalar, { N }>>,
[src]
Scalar: Clone + One + Zero,
Scalar: Neg<Output = Scalar>,
Scalar: Add<Scalar, Output = Scalar> + Sub<Scalar, Output = Scalar>,
Scalar: Mul<Scalar, Output = Scalar> + Div<Scalar, Output = Scalar>,
Self: Add<Self>,
Self: Sub<Self>,
Self: Mul<Self>,
Self: Mul<Vector<Scalar, { N }>, Output = Vector<Scalar, { N }>>,