Trait nalgebra::Diag
[−]
[src]
pub trait Diag<V> { fn from_diag(diag: &V) -> Self; fn diag(&self) -> V; }
Trait to get the diagonal of square matrices.
Required Methods
fn from_diag(diag: &V) -> Self
Creates a new matrix with the given diagonal.
fn diag(&self) -> V
The diagonal of this matrix.
Implementors
impl<N: Copy + Clone + Zero> Diag<DVec<N>> for DMat<N>
impl<N: Copy + Zero> Diag<Vec1<N>> for Mat1<N>
impl<N: Copy + Zero> Diag<Vec2<N>> for Mat2<N>
impl<N: Copy + Zero> Diag<Vec3<N>> for Mat3<N>
impl<N: Copy + Zero> Diag<Vec4<N>> for Mat4<N>
impl<N: Copy + Zero> Diag<Vec5<N>> for Mat5<N>
impl<N: Copy + Zero> Diag<Vec6<N>> for Mat6<N>
impl<N: Copy + Zero> Diag<Vec2<N>> for Rot2<N>
impl<N: Copy + Zero> Diag<Vec3<N>> for Rot3<N>
impl<N: Copy + Zero> Diag<Vec4<N>> for Rot4<N>