Vector

Type Alias Vector 

Source
pub type Vector = Vec2;
Expand description

The vector type.

Aliased Type§

#[repr(C)]
pub struct Vector { pub x: f32, pub y: f32, }

Fields§

§x: f32§y: f32

Trait Implementations§

Source§

impl VectorExt for Vector

Source§

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

Creates a vector with the i-th component set to val and all others to zero.
Source§

fn angle(self, other: Self) -> f32

Computes the angle between two vectors in radians.
Source§

fn kronecker(self, other: Self) -> Matrix

Computes the kronecker product between two vectors.