pub struct Bivector<T> {
pub xy: T,
}
Expand description
The 2D bivector type.
Fields
xy: T
The component representing the xy plane.
Implementations
Trait Implementations
sourceimpl<T: AddAssign> AddAssign<Bivector<T>> for Bivector<T>
impl<T: AddAssign> AddAssign<Bivector<T>> for Bivector<T>
sourcefn add_assign(&mut self, rhs: Bivector<T>)
fn add_assign(&mut self, rhs: Bivector<T>)
Performs the
+=
operation. Read moresourceimpl<T> DivAssign<T> for Bivector<T>where
T: DivAssign + Copy,
impl<T> DivAssign<T> for Bivector<T>where
T: DivAssign + Copy,
sourcefn div_assign(&mut self, other: T)
fn div_assign(&mut self, other: T)
Performs the
/=
operation. Read moresourceimpl<T: Real> DotProduct<Bivector<T>> for Bivector<T>
impl<T: Real> DotProduct<Bivector<T>> for Bivector<T>
sourceimpl<T: Real> DotProduct<Bivector<T>> for Rotor<T>
impl<T: Real> DotProduct<Bivector<T>> for Rotor<T>
sourceimpl<T: Real> DotProduct<Bivector<T>> for Vector<T>
impl<T: Real> DotProduct<Bivector<T>> for Vector<T>
sourceimpl<T: Real> DotProduct<Rotor<T>> for Bivector<T>
impl<T: Real> DotProduct<Rotor<T>> for Bivector<T>
sourceimpl<T: Real> DotProduct<Vector<T>> for Bivector<T>
impl<T: Real> DotProduct<Vector<T>> for Bivector<T>
sourceimpl<T: Real> InnerSpace for Bivector<T>
impl<T: Real> InnerSpace for Bivector<T>
sourcefn magnitude2(self) -> T
fn magnitude2(self) -> T
The squared magnitude. Read more
sourcefn with_magnitude(self, magnitude: Self::Scalar) -> Self
fn with_magnitude(self, magnitude: Self::Scalar) -> Self
Sets the magnitude of a vector.
sourcefn with_direction(self, dir: Self) -> Self
fn with_direction(self, dir: Self) -> Self
Sets the direction of a vector.
sourcefn query_axis(self, dir: Self) -> Self::Scalar
fn query_axis(self, dir: Self) -> Self::Scalar
The value of the vector along the specified axis.
sourcefn normalized_project(self, dir: Self) -> Self
fn normalized_project(self, dir: Self) -> Self
Projects a vector onto an already normalized direction vector.
sourcefn normalized_reject(self, dir: Self) -> Self
fn normalized_reject(self, dir: Self) -> Self
Rejects a vector from an already normalized direction vector.
sourcefn normalized_reflect(self, dir: Self) -> Self
fn normalized_reflect(self, dir: Self) -> Self
Reflects a vector from an already normalized direction vector.
sourceimpl<T> MulAssign<T> for Bivector<T>where
T: MulAssign + Copy,
impl<T> MulAssign<T> for Bivector<T>where
T: MulAssign + Copy,
sourcefn mul_assign(&mut self, other: T)
fn mul_assign(&mut self, other: T)
Performs the
*=
operation. Read moresourceimpl<T: PartialEq> PartialEq<Bivector<T>> for Bivector<T>
impl<T: PartialEq> PartialEq<Bivector<T>> for Bivector<T>
sourceimpl<T: SubAssign> SubAssign<Bivector<T>> for Bivector<T>
impl<T: SubAssign> SubAssign<Bivector<T>> for Bivector<T>
sourcefn sub_assign(&mut self, rhs: Bivector<T>)
fn sub_assign(&mut self, rhs: Bivector<T>)
Performs the
-=
operation. Read moresourceimpl<T: Real> VectorSpace for Bivector<T>
impl<T: Real> VectorSpace for Bivector<T>
type Scalar = T
type Scalar = T
The scalar type of the vector space.
impl<T: Copy> Copy for Bivector<T>
impl<T: Eq> Eq for Bivector<T>
impl<T> StructuralEq for Bivector<T>
impl<T> StructuralPartialEq for Bivector<T>
Auto Trait Implementations
impl<T> RefUnwindSafe for Bivector<T>where
T: RefUnwindSafe,
impl<T> Send for Bivector<T>where
T: Send,
impl<T> Sync for Bivector<T>where
T: Sync,
impl<T> Unpin for Bivector<T>where
T: Unpin,
impl<T> UnwindSafe for Bivector<T>where
T: UnwindSafe,
Blanket Implementations
sourceimpl<T> Bases for Twhere
T: VectorSpace,
impl<T> Bases for Twhere
T: VectorSpace,
sourcefn unit_bases<const I: usize>() -> Selfwhere
Self: Basis<I>,
fn unit_bases<const I: usize>() -> Selfwhere
Self: Basis<I>,
Creates the specified unit basis of the vector space.
sourcefn bases_of<const I: usize>(magnitude: Self::Scalar) -> Selfwhere
Self: Basis<I>,
fn bases_of<const I: usize>(magnitude: Self::Scalar) -> Selfwhere
Self: Basis<I>,
Creates the specified basis of the vector of the specified magnitude.
sourcefn bases<const I: usize>(&self) -> Self::Scalarwhere
Self: Basis<I>,
fn bases<const I: usize>(&self) -> Self::Scalarwhere
Self: Basis<I>,
Queries the specified basis of a vector space.
sourcefn bases_mut<const I: usize>(&mut self) -> &mut Self::Scalarwhere
Self: Basis<I>,
fn bases_mut<const I: usize>(&mut self) -> &mut Self::Scalarwhere
Self: Basis<I>,
Queries the specified basis of a vector space as a mutable reference.
sourcefn with_bases<const I: usize>(self, magnitude: Self::Scalar) -> Selfwhere
Self: Basis<I>,
fn with_bases<const I: usize>(self, magnitude: Self::Scalar) -> Selfwhere
Self: Basis<I>,
Creates a new vector with the specified basis set to a different value.
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more