pub struct Matrix<const R: usize, const C: usize>(/* private fields */)
where
Zero<R>: Failed,
Zero<C>: Failed;
Implementations§
Source§impl<const R: usize, const C: usize> Matrix<R, C>
impl<const R: usize, const C: usize> Matrix<R, C>
pub fn new(closure: impl Fn(usize, usize) -> f32) -> Self
pub fn zero() -> Self
pub const fn is_square(&self) -> bool
pub fn rows(&self) -> [[f32; C]; R]
pub fn columns(&self) -> [[f32; R]; C]
pub fn transpose(&self) -> Matrix<C, R>
pub fn map<F>(&self, f: F) -> Self
pub fn merge<F>(&self, other: Matrix<R, C>, f: F) -> Self
Trait Implementations§
impl<const R: usize, const C: usize> Copy for Matrix<R, C>
impl<const R: usize, const C: usize> StructuralPartialEq for Matrix<R, C>
Auto Trait Implementations§
impl<const R: usize, const C: usize> Freeze for Matrix<R, C>
impl<const R: usize, const C: usize> RefUnwindSafe for Matrix<R, C>
impl<const R: usize, const C: usize> Send for Matrix<R, C>
impl<const R: usize, const C: usize> Sync for Matrix<R, C>
impl<const R: usize, const C: usize> Unpin for Matrix<R, C>
impl<const R: usize, const C: usize> UnwindSafe for Matrix<R, C>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more