Skip to main content

Form

Trait Form 

Source
pub trait Form: Vector {
    // Required method
    fn flat(&self) -> Dual<Self>;

    // Provided methods
    fn dot(&self, b: &Self) -> Self::F { ... }
    fn self_dot(&self) -> Self::F { ... }
    fn check_dot_agrees_with_pairing(a: &Self, b: &Self) -> bool { ... }
    fn check_translation_invariance(a: &Self, b: &Self, c: &Self) -> bool { ... }
}
Expand description

A vector space equipped with a lowering map ♭: V → V*.

This is where geometry enters: flat turns a vector into the covector ⟨v, ·⟩, and dot is the induced form ⟨a, b⟩ = pairing(a, b♭). No invertibility, definiteness, or symmetry is assumed here — a general (even indefinite or degenerate) form is a Form. The refinements add those: Nondegenerate (invertible), Sesquilinear (Hermitian), Bilinear (symmetric), InnerProduct (positive-definite).

Required Methods§

Source

fn flat(&self) -> Dual<Self>

Provided Methods§

Source

fn dot(&self, b: &Self) -> Self::F

Source

fn self_dot(&self) -> Self::F

Source

fn check_dot_agrees_with_pairing(a: &Self, b: &Self) -> bool

Source

fn check_translation_invariance(a: &Self, b: &Self, c: &Self) -> bool

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<F: CField, const N: usize, const D: usize> Form for SlAlgebra<F, N, D>

Source§

impl<R: Field, const N: usize, const M: usize> Form for Coords<R, N, M>

Source§

impl<V: Nondegenerate> Form for Dual<V>