[go: up one dir, main page]

Trait SquareMatrixMut

Source
pub trait SquareMatrixMut: SquareMatrix + MatrixMut<Row = <Self as SquareMatrix>::Vector, Column = <Self as SquareMatrix>::Vector, Transpose = Self> {
    // Required methods
    fn from_diagonal(diag: &Self::Vector) -> Self;
    fn set_diagonal_mut(&mut self, diag: &Self::Vector);

    // Provided method
    fn set_diagonal(&self, diag: &Self::Vector) -> Self { ... }
}
Expand description

The monoid of all mutable square matrices that are stable under modification of its diagonal.

Required Methods§

Source

fn from_diagonal(diag: &Self::Vector) -> Self

Constructs a new diagonal matrix.

Source

fn set_diagonal_mut(&mut self, diag: &Self::Vector)

In-place sets the matrix diagonal.

Provided Methods§

Source

fn set_diagonal(&self, diag: &Self::Vector) -> Self

Sets the matrix diagonal.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§