Type Definition nalgebra::base::OVector

source ·
pub type OVector<T, D> = Matrix<T, D, U1, Owned<T, D, U1>>;
Expand description

An owned D-dimensional column vector.

Implementations§

source§

impl<T, R> OVector<T, R>where R: ToTypenum + DimName, T: Scalar + Zero + One, DefaultAllocator: Allocator<T, R>,

source

pub fn ith(i: usize, val: T) -> Self

The column vector with val as its i-th component.

source

pub fn ith_axis(i: usize) -> Unit<Self>

The column unit vector with T::one() as its i-th component.

source

pub fn x() -> Selfwhere R::Typenum: Cmp<U0, Output = Greater>,

The column vector with a 1 as its first component, and zero elsewhere.

source

pub fn y() -> Selfwhere R::Typenum: Cmp<U1, Output = Greater>,

The column vector with a 1 as its second component, and zero elsewhere.

source

pub fn z() -> Selfwhere R::Typenum: Cmp<U2, Output = Greater>,

The column vector with a 1 as its third component, and zero elsewhere.

source

pub fn w() -> Selfwhere R::Typenum: Cmp<U3, Output = Greater>,

The column vector with a 1 as its fourth component, and zero elsewhere.

source

pub fn a() -> Selfwhere R::Typenum: Cmp<U4, Output = Greater>,

The column vector with a 1 as its fifth component, and zero elsewhere.

source

pub fn b() -> Selfwhere R::Typenum: Cmp<U5, Output = Greater>,

The column vector with a 1 as its sixth component, and zero elsewhere.

source

pub fn x_axis() -> Unit<Self>where R::Typenum: Cmp<U0, Output = Greater>,

The unit column vector with a 1 as its first component, and zero elsewhere.

source

pub fn y_axis() -> Unit<Self>where R::Typenum: Cmp<U1, Output = Greater>,

The unit column vector with a 1 as its second component, and zero elsewhere.

source

pub fn z_axis() -> Unit<Self>where R::Typenum: Cmp<U2, Output = Greater>,

The unit column vector with a 1 as its third component, and zero elsewhere.

source

pub fn w_axis() -> Unit<Self>where R::Typenum: Cmp<U3, Output = Greater>,

The unit column vector with a 1 as its fourth component, and zero elsewhere.

source

pub fn a_axis() -> Unit<Self>where R::Typenum: Cmp<U4, Output = Greater>,

The unit column vector with a 1 as its fifth component, and zero elsewhere.

source

pub fn b_axis() -> Unit<Self>where R::Typenum: Cmp<U5, Output = Greater>,

The unit column vector with a 1 as its sixth component, and zero elsewhere.

source§

impl<T: ComplexField, D: DimName> OVector<T, D>where DefaultAllocator: Allocator<T, D>,

source

pub fn orthonormalize(vs: &mut [Self]) -> usize

Orthonormalizes the given family of vectors. The largest free family of vectors is moved at the beginning of the array and its size is returned. Vectors at an indices larger or equal to this length can be modified to an arbitrary value.

source

pub fn orthonormal_subspace_basis<F>(vs: &[Self], f: F)where F: FnMut(&Self) -> bool,

Applies the given closure to each element of the orthonormal basis of the subspace orthogonal to free family of vectors vs. If vs is not a free family, the result is unspecified.

Trait Implementations§

source§

impl<T: Scalar + Zero + One, const D: usize> From<Point<T, D>> for OVector<T, DimNameSum<Const<D>, U1>>where Const<D>: DimNameAdd<U1>, DefaultAllocator: Allocator<T, DimNameSum<Const<D>, U1>>,

source§

fn from(t: Point<T, D>) -> Self

Converts to this type from the input type.