pub trait Matrix<F: Float, const R: usize, const C: usize, const RC: usize>:
ArrayBasic
+ ArrayRef<F, RC>
+ ArrayIndex<F>
+ ArrayConvert<F, RC>
+ ArrayAddSubNeg<F, RC>
+ ArrayScale<F> {
// Provided methods
fn is_zero(&self) -> bool { ... }
fn set_zero(&mut self) -> &mut Self { ... }
fn transpose<M: Matrix<F, C, R, RC>>(&self) -> M { ... }
}Expand description
The Matrix trait describes an R-by-C matrix of Float type that operates on a Vector.
Such Matrix support basic arithmetic using addition and subtraction, scaling, indexing (linearly, row major).
The ‘transform vector’ methods are tricky to put in here as type inference fails more frequently then it does for square matrices (whwre R*C is always D^2)
Provided Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".