pub struct Multivector<T: Float, S: Signature> { /* private fields */ }Expand description
A multivector in a Clifford algebra with signature S and scalar type T.
A multivector is a linear combination of basis blades. It is the most general element of a geometric algebra, capable of representing scalars, vectors, bivectors, and arbitrary combinations thereof.
§Type Parameters
T: The scalar type (e.g.,f32,f64). Must implementFloat.S: The metric signature (e.g.,Euclidean3). Defines how basis vectors square and thus the algebra’s geometry.
§Storage
Coefficients are stored in a dense array indexed by blade index.
The blade index is a bitmask where bit i indicates the presence of
basis vector eᵢ. See Blade for details.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean2;
// Create basis vectors
let e1: Multivector<f64, Euclidean2> = Multivector::basis_vector(0);
let e2: Multivector<f64, Euclidean2> = Multivector::basis_vector(1);
// Geometric product: e₁e₂ = e₁₂ (a bivector)
let e12 = &e1 * &e2;
// e₁₂ squares to -1 in Euclidean space!
let e12_squared = &e12 * &e12;
assert!((e12_squared.scalar_part() - (-1.0)).abs() < 1e-10);Implementations§
Source§impl<T: Float, S: Signature> Multivector<T, S>
impl<T: Float, S: Signature> Multivector<T, S>
Sourcepub fn zero() -> Self
pub fn zero() -> Self
Creates the zero multivector (additive identity).
All coefficients are zero. This is the identity element for addition:
M + 0 = M for any multivector M.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let zero: Multivector<f64, Euclidean3> = Multivector::zero();
assert!(zero.is_zero(1e-10));Sourcepub fn one() -> Self
pub fn one() -> Self
Creates the unit scalar (multiplicative identity).
This is the scalar 1, which is the identity for the geometric product:
M * 1 = 1 * M = M for any multivector M.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let one: Multivector<f64, Euclidean3> = Multivector::one();
assert!((one.scalar_part() - 1.0).abs() < 1e-10);Sourcepub fn scalar(value: T) -> Self
pub fn scalar(value: T) -> Self
Creates a scalar multivector (grade 0 only).
A scalar is a multivector with only the grade-0 component nonzero.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let five: Multivector<f64, Euclidean3> = Multivector::scalar(5.0);
assert!((five.scalar_part() - 5.0).abs() < 1e-10);Sourcepub fn from_blade(blade: Blade) -> Self
pub fn from_blade(blade: Blade) -> Self
Creates a multivector with a single basis blade.
The coefficient of the specified blade is set to 1, all others to 0.
§Arguments
blade- The basis blade to create
§Example
use clifford::algebra::Multivector;
use clifford::basis::Blade;
use clifford::signature::Euclidean3;
// Create the bivector e₁₂
let e12_blade = Blade::from_index(0b011);
let e12: Multivector<f64, Euclidean3> = Multivector::from_blade(e12_blade);
assert!((e12.get(e12_blade) - 1.0).abs() < 1e-10);Sourcepub fn basis_vector(i: usize) -> Self
pub fn basis_vector(i: usize) -> Self
Creates a basis vector multivector (grade 1).
Basis vector eᵢ is the fundamental directional unit along axis i.
§Arguments
i- Index of the basis vector (0-indexed)
§Panics
Panics if i >= S::DIM.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
let e2: Multivector<f64, Euclidean3> = Multivector::basis_vector(1);
// Vectors square to their metric value (1 for Euclidean)
let e1_sq = &e1 * &e1;
assert!((e1_sq.scalar_part() - 1.0).abs() < 1e-10);Sourcepub fn vector(components: &[T]) -> Self
pub fn vector(components: &[T]) -> Self
Creates a vector multivector from components.
The components are the coefficients of the basis vectors e₁, e₂, etc.
§Arguments
components- Slice of coefficients for each basis vector
§Panics
Panics if components.len() > S::DIM.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
// Create vector v = 3e₁ + 4e₂ + 0e₃
let v: Multivector<f64, Euclidean3> = Multivector::vector(&[3.0, 4.0, 0.0]);
// |v|² = 3² + 4² = 25
let v_sq = &v * &v;
assert!((v_sq.scalar_part() - 25.0).abs() < 1e-10);Sourcepub fn from_coeffs(coeffs: &[T]) -> Self
pub fn from_coeffs(coeffs: &[T]) -> Self
Creates a multivector from a full array of coefficients.
§Arguments
coeffs- Coefficients for all basis blades (only firstS::NumBlades::USIZEare used)
Source§impl<T: Float, S: Signature> Multivector<T, S>
impl<T: Float, S: Signature> Multivector<T, S>
Sourcepub fn get(&self, blade: Blade) -> T
pub fn get(&self, blade: Blade) -> T
Returns the coefficient of the given basis blade.
§Example
use clifford::algebra::Multivector;
use clifford::basis::Blade;
use clifford::signature::Euclidean3;
let v: Multivector<f64, Euclidean3> = Multivector::vector(&[3.0, 4.0, 5.0]);
assert!((v.get(Blade::basis_vector(0)) - 3.0).abs() < 1e-10);
assert!((v.get(Blade::basis_vector(1)) - 4.0).abs() < 1e-10);Sourcepub fn set(&mut self, blade: Blade, value: T)
pub fn set(&mut self, blade: Blade, value: T)
Sets the coefficient of the given basis blade.
§Example
use clifford::algebra::Multivector;
use clifford::basis::Blade;
use clifford::signature::Euclidean3;
let mut mv: Multivector<f64, Euclidean3> = Multivector::zero();
mv.set(Blade::basis_vector(0), 5.0);
assert!((mv.get(Blade::basis_vector(0)) - 5.0).abs() < 1e-10);Sourcepub fn scalar_part(&self) -> T
pub fn scalar_part(&self) -> T
Returns the scalar part (grade 0 coefficient).
This is the coefficient of the unit scalar blade.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let mv: Multivector<f64, Euclidean3> = Multivector::scalar(42.0);
assert!((mv.scalar_part() - 42.0).abs() < 1e-10);Sourcepub fn is_zero(&self, epsilon: T) -> bool
pub fn is_zero(&self, epsilon: T) -> bool
Checks if this multivector is approximately zero.
Returns true if all coefficients have absolute value less than epsilon.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let zero: Multivector<f64, Euclidean3> = Multivector::zero();
assert!(zero.is_zero(1e-10));
let v: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
assert!(!v.is_zero(1e-10));Source§impl<T: Float, S: Signature> Multivector<T, S>
impl<T: Float, S: Signature> Multivector<T, S>
Sourcepub fn reverse(&self) -> Self
pub fn reverse(&self) -> Self
Returns the reverse of this multivector.
The reverse operation reverses the order of basis vectors in each blade.
For a blade of grade k, the sign change is (-1)^(k(k-1)/2):
| Grade | Sign | Example |
|---|---|---|
| 0 | +1 | 1̃ = 1 |
| 1 | +1 | ẽ₁ = e₁ |
| 2 | -1 | ẽ₁₂ = e₂₁ = -e₁₂ |
| 3 | -1 | ẽ₁₂₃ = e₃₂₁ = -e₁₂₃ |
| 4 | +1 | … |
The reverse is important for computing norms and inverses:
|M|² = ⟨M M̃⟩₀ (scalar part of M times its reverse)
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
let e2: Multivector<f64, Euclidean3> = Multivector::basis_vector(1);
let e12 = &e1 * &e2;
// Reverse of a bivector negates it
let e12_rev = e12.reverse();
assert!((&e12 + &e12_rev).is_zero(1e-10));Sourcepub fn involute(&self) -> Self
pub fn involute(&self) -> Self
Returns the grade involution of this multivector.
Grade involution negates all odd-grade components.
For a blade of grade k, the sign is (-1)^k:
| Grade | Sign |
|---|---|
| 0 (scalar) | +1 |
| 1 (vector) | -1 |
| 2 (bivector) | +1 |
| 3 (trivector) | -1 |
This operation is also called the “main involution” or “grade automorphism”.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let v: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
// Involute of a vector negates it
let v_inv = v.involute();
assert!((&v + &v_inv).is_zero(1e-10));Sourcepub fn conjugate(&self) -> Self
pub fn conjugate(&self) -> Self
Returns the Clifford conjugate of this multivector.
The Clifford conjugate is the composition of reverse and grade involution.
For a blade of grade k, the sign is (-1)^(k(k+1)/2):
| Grade | Sign |
|---|---|
| 0 | +1 |
| 1 | -1 |
| 2 | -1 |
| 3 | +1 |
| 4 | +1 |
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let v: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
let v_conj = v.conjugate();
// Conjugate of a vector negates it
assert!((&v + &v_conj).is_zero(1e-10));Source§impl<T: Float, S: Signature> Multivector<T, S>
impl<T: Float, S: Signature> Multivector<T, S>
Sourcepub fn norm_squared(&self) -> T
pub fn norm_squared(&self) -> T
Returns the squared norm of this multivector.
The squared norm is the scalar part of M * M̃ (M times its reverse).
For vectors in Euclidean space, this equals the sum of squared components.
Note: The squared norm can be negative in non-Euclidean signatures!
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let v: Multivector<f64, Euclidean3> = Multivector::vector(&[3.0, 4.0, 0.0]);
assert!((v.norm_squared() - 25.0).abs() < 1e-10); // 3² + 4² = 25Sourcepub fn norm(&self) -> T
pub fn norm(&self) -> T
Returns the norm of this multivector.
The norm is sqrt(|norm_squared|). We take the absolute value because
the squared norm can be negative in non-Euclidean signatures.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let v: Multivector<f64, Euclidean3> = Multivector::vector(&[3.0, 4.0, 0.0]);
assert!((v.norm() - 5.0).abs() < 1e-10); // sqrt(25) = 5Sourcepub fn normalize(&self) -> Option<Self>
pub fn normalize(&self) -> Option<Self>
Returns the normalized multivector (unit norm), or None if norm is zero.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let v: Multivector<f64, Euclidean3> = Multivector::vector(&[3.0, 4.0, 0.0]);
let v_hat = v.normalize().unwrap();
assert!((v_hat.norm() - 1.0).abs() < 1e-10);Sourcepub fn inverse(&self) -> Option<Self>
pub fn inverse(&self) -> Option<Self>
Returns the multiplicative inverse, or None if not invertible.
For a multivector M with non-zero squared norm:
M⁻¹ = M̃ / |M|²
This satisfies M * M⁻¹ = M⁻¹ * M = 1.
Note: Not all multivectors are invertible! The inverse exists only when the squared norm is non-zero.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let v: Multivector<f64, Euclidean3> = Multivector::vector(&[1.0, 0.0, 0.0]);
let v_inv = v.inverse().unwrap();
// v * v⁻¹ = 1
let product = &v * &v_inv;
assert!((product.scalar_part() - 1.0).abs() < 1e-10);
assert!((&product - &Multivector::one()).is_zero(1e-10));Source§impl<T: Float, S: Signature> Multivector<T, S>
impl<T: Float, S: Signature> Multivector<T, S>
Sourcepub fn grade_select(&self, k: usize) -> Self
pub fn grade_select(&self, k: usize) -> Self
Extracts the grade-k part of this multivector: ⟨M⟩ₖ.
Returns a multivector containing only the components of the specified grade, with all other grades set to zero.
§Arguments
k- The grade to extract (0 = scalar, 1 = vector, 2 = bivector, etc.)
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
// Create a multivector with scalar and vector parts
let mut mv: Multivector<f64, Euclidean3> = Multivector::scalar(5.0);
mv = &mv + &Multivector::vector(&[1.0, 2.0, 3.0]);
// Extract just the scalar part
let scalar = mv.grade_select(0);
assert!((scalar.scalar_part() - 5.0).abs() < 1e-10);
// Extract just the vector part
let vector = mv.grade_select(1);
assert!(vector.grade_select(0).is_zero(1e-10));Sourcepub fn even(&self) -> Self
pub fn even(&self) -> Self
Extracts the even part of this multivector (grades 0, 2, 4, …).
The even subalgebra is closed under the geometric product and contains important elements like rotors (in 3D, the even subalgebra is isomorphic to quaternions).
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
use approx::relative_eq;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
let e2: Multivector<f64, Euclidean3> = Multivector::basis_vector(1);
// A rotor is an even multivector: scalar + bivector
let rotor = &Multivector::scalar(0.5_f64.sqrt()) + &(&e1 * &e2) * 0.5_f64.sqrt();
let even = rotor.even();
assert!(relative_eq!(even, rotor, epsilon = 1e-10, max_relative = 1e-10));Sourcepub fn odd(&self) -> Self
pub fn odd(&self) -> Self
Extracts the odd part of this multivector (grades 1, 3, 5, …).
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
use approx::relative_eq;
let v: Multivector<f64, Euclidean3> = Multivector::vector(&[1.0, 2.0, 3.0]);
let odd = v.odd();
assert!(relative_eq!(odd, v, epsilon = 1e-10, max_relative = 1e-10)); // Vectors are oddSourcepub fn grade(&self, epsilon: T) -> Option<usize>
pub fn grade(&self, epsilon: T) -> Option<usize>
Returns the grade of this multivector if it is homogeneous (all non-zero
components have the same grade), or None if it contains multiple grades.
§Arguments
epsilon- Tolerance for considering a coefficient as zero
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let v: Multivector<f64, Euclidean3> = Multivector::vector(&[1.0, 2.0, 3.0]);
assert_eq!(v.grade(1e-10), Some(1)); // Pure vector
let mixed = &v + &Multivector::scalar(1.0);
assert_eq!(mixed.grade(1e-10), None); // Mixed gradesSourcepub fn pseudoscalar() -> Self
pub fn pseudoscalar() -> Self
Returns the unit pseudoscalar I = e₁e₂...eₙ.
The pseudoscalar is the highest-grade basis blade, representing the oriented unit volume element. In n dimensions, it has grade n.
§Properties
- In Euclidean 2D:
I² = -1(behaves like imaginary unit) - In Euclidean 3D:
I² = -1 - In Euclidean 4D:
I² = +1
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let ps: Multivector<f64, Euclidean3> = Multivector::pseudoscalar();
assert_eq!(ps.grade(1e-10), Some(3)); // Trivector in 3D
// I² = -1 in Euclidean 3D
let ps_sq = &ps * &ps;
assert!((ps_sq.scalar_part() - (-1.0)).abs() < 1e-10);Source§impl<T: Float, S: Signature> Multivector<T, S>
impl<T: Float, S: Signature> Multivector<T, S>
Sourcepub fn exterior(&self, other: &Self) -> Self
pub fn exterior(&self, other: &Self) -> Self
Computes the exterior (wedge) product: a ∧ b.
The exterior product extracts the grade-raising part of the geometric product. For a grade-k blade A and grade-j blade B, the result has grade k + j.
§Properties
- Anticommutative for vectors:
a ∧ b = -(b ∧ a) - Associative:
(a ∧ b) ∧ c = a ∧ (b ∧ c) - Grade-raising:
grade(A ∧ B) = grade(A) + grade(B)
§Geometric Interpretation
The wedge product of two vectors creates a bivector representing the oriented parallelogram spanned by those vectors. More generally, it creates higher-grade blades representing oriented subspaces.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
use approx::relative_eq;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
let e2: Multivector<f64, Euclidean3> = Multivector::basis_vector(1);
// e₁ ∧ e₂ = e₁₂ (bivector)
let e12 = e1.exterior(&e2);
assert_eq!(e12.grade(1e-10), Some(2));
// Anticommutativity: e₂ ∧ e₁ = -e₁₂
let e21 = e2.exterior(&e1);
assert!(relative_eq!(e21, -&e12, epsilon = 1e-10, max_relative = 1e-10));Sourcepub fn left_contract(&self, other: &Self) -> Self
pub fn left_contract(&self, other: &Self) -> Self
Computes the left contraction: A ⌋ B.
The left contraction extracts the grade-lowering part of the geometric product. For a grade-k blade A and grade-j blade B where k ≤ j, the result has grade j - k.
§Mathematical Definition
A ⌋ B is the part of AB with grade grade(B) - grade(A).
If grade(A) > grade(B), the result is zero.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
let e2: Multivector<f64, Euclidean3> = Multivector::basis_vector(1);
let e12 = e1.exterior(&e2);
// Vector left-contracted with bivector gives vector
let result = e1.left_contract(&e12);
assert_eq!(result.grade(1e-10), Some(1));Sourcepub fn right_contract(&self, other: &Self) -> Self
pub fn right_contract(&self, other: &Self) -> Self
Computes the right contraction: A ⌊ B.
The right contraction is the “mirror” of the left contraction. For a grade-k blade A and grade-j blade B where j ≤ k, the result has grade k - j.
§Mathematical Definition
A ⌊ B is the part of AB with grade grade(A) - grade(B).
If grade(B) > grade(A), the result is zero.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
let e2: Multivector<f64, Euclidean3> = Multivector::basis_vector(1);
let e12 = e1.exterior(&e2);
// Bivector right-contracted with vector gives vector
let result = e12.right_contract(&e1);
assert_eq!(result.grade(1e-10), Some(1));Sourcepub fn inner(&self, other: &Self) -> Self
pub fn inner(&self, other: &Self) -> Self
Computes the inner product: a · b.
For vectors, this is the standard dot product, returning a scalar. More generally, this is implemented as the left contraction.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let a: Multivector<f64, Euclidean3> = Multivector::vector(&[1.0, 2.0, 3.0]);
let b: Multivector<f64, Euclidean3> = Multivector::vector(&[4.0, 5.0, 6.0]);
// a · b = 1*4 + 2*5 + 3*6 = 32
let dot = a.inner(&b);
assert!((dot.scalar_part() - 32.0).abs() < 1e-10);Sourcepub fn dual(&self) -> Self
pub fn dual(&self) -> Self
Computes the Hodge dual: A* = A ⌋ I⁻¹.
The dual maps a grade-k blade to a grade-(n-k) blade, where n is the dimension. It represents the orthogonal complement of a subspace.
§Properties
dual(dual(A)) = ±A(sign depends on dimension and signature)- Maps vectors to pseudovectors, bivectors to vectors (in 3D), etc.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
// In 3D, dual of a vector is a bivector
let e1_dual = e1.dual();
assert_eq!(e1_dual.grade(1e-10), Some(2));Sourcepub fn undual(&self) -> Self
pub fn undual(&self) -> Self
Computes the undual (inverse of dual): A⁻* = A ⌋ I.
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
use approx::relative_eq;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
let roundtrip = e1.dual().undual();
assert!(relative_eq!(roundtrip, e1, epsilon = 1e-10, max_relative = 1e-10));Sourcepub fn complement(&self) -> Self
pub fn complement(&self) -> Self
Computes the complement of a multivector.
The complement maps a grade-k blade to a grade-(n-k) blade by XOR with
the pseudoscalar index. The sign is determined by the number of
transpositions needed to put blade ∧ complement(blade) into canonical
order.
This is used in RGA for the regressive product:
a ∨ b = complement(complement(a) ∧ complement(b))
§Properties
grade(complement(a)) = n - grade(a)where n is the dimensioncomplement(complement(a)) = ±a- Different from Hodge dual (which uses contraction)
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
// Complement of e1 in 3D gives a bivector (e23)
let e1_comp = e1.complement();
assert_eq!(e1_comp.grade(1e-10), Some(2));Sourcepub fn right_complement(&self) -> Self
👎Deprecated since 0.3.0: use complement instead
pub fn right_complement(&self) -> Self
complement insteadDeprecated: Use complement instead.
The right complement maps a grade-k blade to a grade-(n-k) blade. This is used in RGA for the regressive product.
Sourcepub fn left_complement(&self) -> Self
👎Deprecated since 0.3.0: use complement instead
pub fn left_complement(&self) -> Self
complement insteadDeprecated: Use complement instead.
The left complement maps a grade-k blade to a grade-(n-k) blade. This is used in RGA for computing the “undual” in the regressive product.
Sourcepub fn regressive(&self, other: &Self) -> Self
pub fn regressive(&self, other: &Self) -> Self
Computes the regressive (vee) product: a ∨ b = complement(complement(a) ∧ complement(b)).
The regressive product is the dual of the outer product. While the outer product represents the “join” (span) of subspaces, the regressive product represents the “meet” (intersection).
§Formula
Using complement notation:
a ∨ b = complement(complement(a) ∧ complement(b))
§Properties
- Grade-lowering (opposite of wedge)
- Associative
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
let e2: Multivector<f64, Euclidean3> = Multivector::basis_vector(1);
let e12 = e1.exterior(&e2);
let e23 = e2.exterior(&Multivector::basis_vector(2));
// Meet of two planes sharing e2 should give e2 direction
let meet = e12.regressive(&e23);
assert_eq!(meet.grade(1e-10), Some(1));Sourcepub fn antiwedge(&self, other: &Self) -> Self
pub fn antiwedge(&self, other: &Self) -> Self
Computes the antiwedge (exterior antiproduct): a ∨ b.
This is an alias for regressive. The antiwedge is
the dual of the wedge product, representing the “meet” (intersection)
of subspaces rather than the “join” (span).
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let e12: Multivector<f64, Euclidean3> =
Multivector::basis_vector(0).exterior(&Multivector::basis_vector(1));
let e23: Multivector<f64, Euclidean3> =
Multivector::basis_vector(1).exterior(&Multivector::basis_vector(2));
// Antiwedge of two planes gives their intersection (a line)
let intersection = e12.antiwedge(&e23);Sourcepub fn bulk_dual(&self) -> Self
pub fn bulk_dual(&self) -> Self
Computes the bulk dual (★): a★ = ã ⊙ 𝟙.
The bulk dual is computed as reverse(a) * pseudoscalar. It maps a blade
to its orthogonal complement using the metric (bulk) structure.
§Properties
grade(a★) = n - grade(a)where n is the dimension(a★)★ = ±a(up to sign, involutory)
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
// In 3D, bulk dual of a vector is a bivector
let e1_bulk_dual = e1.bulk_dual();
assert_eq!(e1_bulk_dual.grade(1e-10), Some(2));Sourcepub fn left_bulk_dual(&self) -> Self
pub fn left_bulk_dual(&self) -> Self
Computes the left bulk dual (★): ★a = 𝟙 ⊙ ã.
The left bulk dual is computed as pseudoscalar * reverse(a). This is
the “undual” operation for the bulk dual, used in computing the antiproduct.
§Properties
grade(★a) = n - grade(a)where n is the dimension★(a★) = ±a(recovers original up to sign)
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
// In 3D, left bulk dual of a vector is a bivector
let e1_left_dual = e1.left_bulk_dual();
assert_eq!(e1_left_dual.grade(1e-10), Some(2));Sourcepub fn weight_dual(&self) -> Self
pub fn weight_dual(&self) -> Self
Computes the weight dual (☆): a☆ = ã ⊛ 1.
The weight dual is computed as reverse(a) ⊛ scalar where ⊛ is the
geometric antiproduct. It maps a blade to its orthogonal complement
using the anti-metric (weight) structure.
§Properties
grade(a☆) = n - grade(a)where n is the dimension- Uses the antiproduct with the scalar (grade-0 element)
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
// In 3D, weight dual of a vector is a bivector
let e1_weight_dual = e1.weight_dual();
assert_eq!(e1_weight_dual.grade(1e-10), Some(2));Sourcepub fn bulk_contraction(&self, other: &Self) -> Self
pub fn bulk_contraction(&self, other: &Self) -> Self
Computes the bulk contraction: a ∨ b★.
The bulk contraction is the antiwedge of a with the bulk dual of b.
This is one of the four interior products in Rigid Geometric Algebra.
§Properties
- Grade-lowering operation
- Measures how much
b“projects onto” the complement ofa
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
let e2: Multivector<f64, Euclidean3> = Multivector::basis_vector(1);
let result = e1.bulk_contraction(&e2);Sourcepub fn weight_contraction(&self, other: &Self) -> Self
pub fn weight_contraction(&self, other: &Self) -> Self
Computes the weight contraction: a ∨ b☆.
The weight contraction is the antiwedge of a with the weight dual of b.
This is one of the four interior products in Rigid Geometric Algebra.
§Properties
- Grade-lowering operation
- Uses the anti-metric structure
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
let e2: Multivector<f64, Euclidean3> = Multivector::basis_vector(1);
let result = e1.weight_contraction(&e2);Sourcepub fn bulk_expansion(&self, other: &Self) -> Self
pub fn bulk_expansion(&self, other: &Self) -> Self
Computes the bulk expansion: a ∧ b★.
The bulk expansion is the wedge of a with the bulk dual of b.
This is one of the four interior products in Rigid Geometric Algebra.
§Properties
- Can be grade-raising or grade-lowering depending on inputs
- Measures the “exterior” relationship using bulk structure
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
let e2: Multivector<f64, Euclidean3> = Multivector::basis_vector(1);
let result = e1.bulk_expansion(&e2);Sourcepub fn weight_expansion(&self, other: &Self) -> Self
pub fn weight_expansion(&self, other: &Self) -> Self
Computes the weight expansion: a ∧ b☆.
The weight expansion is the wedge of a with the weight dual of b.
This is one of the four interior products in Rigid Geometric Algebra.
§Properties
- Can be grade-raising or grade-lowering depending on inputs
- Uses the anti-metric structure
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
let e2: Multivector<f64, Euclidean3> = Multivector::basis_vector(1);
let result = e1.weight_expansion(&e2);Sourcepub fn antiproduct(&self, other: &Self) -> Self
pub fn antiproduct(&self, other: &Self) -> Self
Computes the geometric antiproduct: a ⊛ b = undual(dual(a) × dual(b)).
The geometric antiproduct is the dual of the geometric product. In PGA (Projective Geometric Algebra), the antiproduct is essential for correct motor transformations because it properly handles the degenerate direction.
§Properties
dual(a × b) = dual(a) ⊛ dual(b)(duality relationship)- Used for PGA sandwich transformations:
M ⊛ x ⊛ rev(M)
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
let e2: Multivector<f64, Euclidean3> = Multivector::basis_vector(1);
// Antiproduct of vectors
let result = e1.antiproduct(&e2);Sourcepub fn antisandwich(&self, x: &Self) -> Self
pub fn antisandwich(&self, x: &Self) -> Self
Computes the antisandwich product: R ⊛ x ⊛ R̃.
The antisandwich uses the geometric antiproduct instead of the geometric product. In PGA, this is the correct transformation for motors because it handles translations properly (which the regular sandwich cannot due to the degenerate metric e₀² = 0).
§Properties
- Preserves grade of the argument
- Correctly transforms points under translation in PGA
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
// Create a rotor (identity in this case)
let rotor: Multivector<f64, Euclidean3> = Multivector::scalar(1.0);
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
// Compute the antisandwich transformation
let _result = rotor.antisandwich(&e1);§Note
For PGA (Projective Geometric Algebra), use the specialized types in
clifford::specialized::projective::dim3 which have optimized antisandwich
implementations that handle the degenerate metric correctly.
Sourcepub fn sandwich(&self, x: &Self) -> Self
pub fn sandwich(&self, x: &Self) -> Self
Computes the sandwich product: R x R̃.
The sandwich product is the fundamental operation for transformations in geometric algebra:
- Reflections:
n x nwhere n is a unit vector (reflects across plane normal to n) - Rotations:
R x R̃where R is a rotor
§Properties
- Preserves grade of the argument
- Preserves norm in Euclidean space
- Composition:
R₂(R₁ x R₁̃)R₂̃ = (R₂R₁) x (R₂R₁)̃
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
// Reflect a vector across the yz-plane (normal = e₁)
let n: Multivector<f64, Euclidean3> = Multivector::basis_vector(0); // e₁
let v: Multivector<f64, Euclidean3> = Multivector::vector(&[1.0, 2.0, 3.0]);
let reflected = n.sandwich(&v);
// x component flips sign, y and z stay same
assert!((reflected.norm() - v.norm()).abs() < 1e-10);Sourcepub fn project(&self, other: &Self) -> Self
pub fn project(&self, other: &Self) -> Self
Computes the projection of self onto other: other ∨ (self ∧ other☆).
The projection finds the part of self that lies “on” or “inside” other.
Uses the weight dual (☆) of the target geometry.
§Geometric Interpretation
In PGA (Projective Geometric Algebra):
- Projecting a point onto a line gives the closest point on the line
- Projecting a point onto a plane gives the closest point on the plane
- Projecting a line onto a plane gives the line’s intersection with the plane
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let a: Multivector<f64, Euclidean3> = Multivector::basis_vector(0); // e₁
let b: Multivector<f64, Euclidean3> = Multivector::basis_vector(1); // e₂
let _proj = a.project(&b);Sourcepub fn antiproject(&self, other: &Self) -> Self
pub fn antiproject(&self, other: &Self) -> Self
Computes the antiprojection of self onto other: other ∧ (self ∨ other☆).
The antiprojection finds geometry that passes through self and is
perpendicular to other. Uses the weight dual (☆) of the target geometry.
§Geometric Interpretation
In PGA (Projective Geometric Algebra):
- Antiprojecting a point onto a line gives the plane through the point perpendicular to the line
- Antiprojecting a point onto a plane gives the line through the point perpendicular to the plane
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
let a: Multivector<f64, Euclidean3> = Multivector::basis_vector(0); // e₁
let b: Multivector<f64, Euclidean3> = Multivector::basis_vector(1); // e₂
let _antiproj = a.antiproject(&b);Trait Implementations§
Source§impl<T: Float, S: Signature> AbsDiffEq for Multivector<T, S>
impl<T: Float, S: Signature> AbsDiffEq for Multivector<T, S>
Source§fn default_epsilon() -> Self::Epsilon
fn default_epsilon() -> Self::Epsilon
Source§fn abs_diff_eq(&self, other: &Self, epsilon: Self::Epsilon) -> bool
fn abs_diff_eq(&self, other: &Self, epsilon: Self::Epsilon) -> bool
Source§fn abs_diff_ne(&self, other: &Rhs, epsilon: Self::Epsilon) -> bool
fn abs_diff_ne(&self, other: &Rhs, epsilon: Self::Epsilon) -> bool
AbsDiffEq::abs_diff_eq.Source§impl<T: Float, S: Signature> Add<&Multivector<T, S>> for Multivector<T, S>
impl<T: Float, S: Signature> Add<&Multivector<T, S>> for Multivector<T, S>
Source§impl<T: Float, S: Signature> Add<Multivector<T, S>> for &Multivector<T, S>
impl<T: Float, S: Signature> Add<Multivector<T, S>> for &Multivector<T, S>
Source§type Output = Multivector<T, S>
type Output = Multivector<T, S>
+ operator.Source§impl<T: Float, S: Signature> AddAssign<&Multivector<T, S>> for Multivector<T, S>
impl<T: Float, S: Signature> AddAssign<&Multivector<T, S>> for Multivector<T, S>
Source§fn add_assign(&mut self, rhs: &Self)
fn add_assign(&mut self, rhs: &Self)
+= operation. Read moreSource§impl<T: Float, S: Signature> AddAssign for Multivector<T, S>
impl<T: Float, S: Signature> AddAssign for Multivector<T, S>
Source§fn add_assign(&mut self, rhs: Self)
fn add_assign(&mut self, rhs: Self)
+= operation. Read moreSource§impl<T, S> Arbitrary for Multivector<T, S>
impl<T, S> Arbitrary for Multivector<T, S>
Source§type Parameters = ()
type Parameters = ()
arbitrary_with accepts for configuration
of the generated Strategy. Parameters must implement Default.Source§type Strategy = BoxedStrategy<Multivector<T, S>>
type Strategy = BoxedStrategy<Multivector<T, S>>
Strategy used to generate values of type Self.Source§fn arbitrary_with(_: Self::Parameters) -> Self::Strategy
fn arbitrary_with(_: Self::Parameters) -> Self::Strategy
Source§impl AsRef<Multivector<f64, Euclidean3>> for NonZeroVectorE3
impl AsRef<Multivector<f64, Euclidean3>> for NonZeroVectorE3
Source§fn as_ref(&self) -> &Multivector<f64, Euclidean3>
fn as_ref(&self) -> &Multivector<f64, Euclidean3>
Source§impl AsRef<Multivector<f64, Euclidean3>> for UnitVectorE3
impl AsRef<Multivector<f64, Euclidean3>> for UnitVectorE3
Source§fn as_ref(&self) -> &Multivector<f64, Euclidean3>
fn as_ref(&self) -> &Multivector<f64, Euclidean3>
Source§impl AsRef<Multivector<f64, Euclidean3>> for VectorE3
impl AsRef<Multivector<f64, Euclidean3>> for VectorE3
Source§fn as_ref(&self) -> &Multivector<f64, Euclidean3>
fn as_ref(&self) -> &Multivector<f64, Euclidean3>
Source§impl<T: Float, S: Signature> BitXor<&Multivector<T, S>> for Multivector<T, S>
impl<T: Float, S: Signature> BitXor<&Multivector<T, S>> for Multivector<T, S>
Source§type Output = Multivector<T, S>
type Output = Multivector<T, S>
^ operator.Source§impl<T: Float, S: Signature> BitXor<Multivector<T, S>> for &Multivector<T, S>
impl<T: Float, S: Signature> BitXor<Multivector<T, S>> for &Multivector<T, S>
Source§type Output = Multivector<T, S>
type Output = Multivector<T, S>
^ operator.Source§impl<T: Float, S: Signature> BitXor for &Multivector<T, S>
Wedge (exterior) product via ^ operator.
impl<T: Float, S: Signature> BitXor for &Multivector<T, S>
Wedge (exterior) product via ^ operator.
The ^ operator provides ergonomic syntax for the wedge product:
a ^ b is equivalent to a.exterior(&b).
§Example
use clifford::algebra::Multivector;
use clifford::signature::Euclidean3;
use approx::relative_eq;
let e1: Multivector<f64, Euclidean3> = Multivector::basis_vector(0);
let e2: Multivector<f64, Euclidean3> = Multivector::basis_vector(1);
// e₁ ^ e₂ = e₁₂ (bivector)
let e12 = &e1 ^ &e2;
assert_eq!(e12.grade(1e-10), Some(2));
// Anticommutativity: e₂ ^ e₁ = -e₁₂
let e21 = &e2 ^ &e1;
assert!(relative_eq!(e21, -&e12, epsilon = 1e-10, max_relative = 1e-10));Source§impl<T: Clone + Float, S: Clone + Signature> Clone for Multivector<T, S>
impl<T: Clone + Float, S: Clone + Signature> Clone for Multivector<T, S>
Source§fn clone(&self) -> Multivector<T, S>
fn clone(&self) -> Multivector<T, S>
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl<'de, T, S: Signature> Deserialize<'de> for Multivector<T, S>where
T: Deserialize<'de> + Float,
impl<'de, T, S: Signature> Deserialize<'de> for Multivector<T, S>where
T: Deserialize<'de> + Float,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl<T: Float> From<Bivector<T>> for Multivector<T, Euclidean2>
impl<T: Float> From<Bivector<T>> for Multivector<T, Euclidean2>
Source§impl<T: Float> From<Bivector<T>> for Multivector<T, Euclidean3>
impl<T: Float> From<Bivector<T>> for Multivector<T, Euclidean3>
Source§impl<T: Float> From<Circle<T>> for Multivector<T, Conformal3>
impl<T: Float> From<Circle<T>> for Multivector<T, Conformal3>
Source§impl<T: Float> From<Dipole<T>> for Multivector<T, Conformal3>
impl<T: Float> From<Dipole<T>> for Multivector<T, Conformal3>
Source§impl<T: Float> From<DualQuaternion<T>> for Multivector<T, Cl0_2_1>
impl<T: Float> From<DualQuaternion<T>> for Multivector<T, Cl0_2_1>
Source§fn from(value: DualQuaternion<T>) -> Self
fn from(value: DualQuaternion<T>) -> Self
Source§impl<T: Float> From<FlatPoint<T>> for Multivector<T, Conformal3>
impl<T: Float> From<FlatPoint<T>> for Multivector<T, Conformal3>
Source§impl<T: Float> From<Flector<T>> for Multivector<T, Projective2>
impl<T: Float> From<Flector<T>> for Multivector<T, Projective2>
Source§impl<T: Float> From<Flector<T>> for Multivector<T, Projective3>
impl<T: Float> From<Flector<T>> for Multivector<T, Projective3>
Source§impl<T: Float> From<Hyperbolic<T>> for Multivector<T, Cl1_0_0>
impl<T: Float> From<Hyperbolic<T>> for Multivector<T, Cl1_0_0>
Source§fn from(value: Hyperbolic<T>) -> Self
fn from(value: Hyperbolic<T>) -> Self
Source§impl<T: Float> From<Line<T>> for Multivector<T, Conformal3>
impl<T: Float> From<Line<T>> for Multivector<T, Conformal3>
Source§impl<T: Float> From<Line<T>> for Multivector<T, Euclidean3>
impl<T: Float> From<Line<T>> for Multivector<T, Euclidean3>
Source§impl<T: Float> From<Line<T>> for Multivector<T, Projective2>
impl<T: Float> From<Line<T>> for Multivector<T, Projective2>
Source§impl<T: Float> From<Line<T>> for Multivector<T, Projective3>
impl<T: Float> From<Line<T>> for Multivector<T, Projective3>
Source§impl<T: Float> From<Motor<T>> for Multivector<T, Conformal3>
impl<T: Float> From<Motor<T>> for Multivector<T, Conformal3>
Source§impl<T: Float> From<Motor<T>> for Multivector<T, Projective2>
impl<T: Float> From<Motor<T>> for Multivector<T, Projective2>
Source§impl<T: Float> From<Motor<T>> for Multivector<T, Projective3>
impl<T: Float> From<Motor<T>> for Multivector<T, Projective3>
Source§impl<T: Float> From<Multivector<T, Cl0_0_1>> for Dual<T>
impl<T: Float> From<Multivector<T, Cl0_0_1>> for Dual<T>
Source§fn from(mv: Multivector<T, Cl0_0_1>) -> Self
fn from(mv: Multivector<T, Cl0_0_1>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl0_0_1>> for DualUnit<T>
impl<T: Float> From<Multivector<T, Cl0_0_1>> for DualUnit<T>
Source§fn from(mv: Multivector<T, Cl0_0_1>) -> Self
fn from(mv: Multivector<T, Cl0_0_1>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl0_0_1>> for Scalar<T>
impl<T: Float> From<Multivector<T, Cl0_0_1>> for Scalar<T>
Source§fn from(mv: Multivector<T, Cl0_0_1>) -> Self
fn from(mv: Multivector<T, Cl0_0_1>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl0_1_0>> for Complex<T>
impl<T: Float> From<Multivector<T, Cl0_1_0>> for Complex<T>
Source§fn from(mv: Multivector<T, Cl0_1_0>) -> Self
fn from(mv: Multivector<T, Cl0_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl0_1_0>> for ImagUnit<T>
impl<T: Float> From<Multivector<T, Cl0_1_0>> for ImagUnit<T>
Source§fn from(mv: Multivector<T, Cl0_1_0>) -> Self
fn from(mv: Multivector<T, Cl0_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl0_1_0>> for Scalar<T>
impl<T: Float> From<Multivector<T, Cl0_1_0>> for Scalar<T>
Source§fn from(mv: Multivector<T, Cl0_1_0>) -> Self
fn from(mv: Multivector<T, Cl0_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl0_2_0>> for Bivector<T>
impl<T: Float> From<Multivector<T, Cl0_2_0>> for Bivector<T>
Source§fn from(mv: Multivector<T, Cl0_2_0>) -> Self
fn from(mv: Multivector<T, Cl0_2_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl0_2_0>> for Imaginary<T>
impl<T: Float> From<Multivector<T, Cl0_2_0>> for Imaginary<T>
Source§fn from(mv: Multivector<T, Cl0_2_0>) -> Self
fn from(mv: Multivector<T, Cl0_2_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl0_2_0>> for Quaternion<T>
impl<T: Float> From<Multivector<T, Cl0_2_0>> for Quaternion<T>
Source§fn from(mv: Multivector<T, Cl0_2_0>) -> Self
fn from(mv: Multivector<T, Cl0_2_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl0_2_0>> for Scalar<T>
impl<T: Float> From<Multivector<T, Cl0_2_0>> for Scalar<T>
Source§fn from(mv: Multivector<T, Cl0_2_0>) -> Self
fn from(mv: Multivector<T, Cl0_2_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl0_2_1>> for Bivector<T>
impl<T: Float> From<Multivector<T, Cl0_2_1>> for Bivector<T>
Source§fn from(mv: Multivector<T, Cl0_2_1>) -> Self
fn from(mv: Multivector<T, Cl0_2_1>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl0_2_1>> for DualQuaternion<T>
impl<T: Float> From<Multivector<T, Cl0_2_1>> for DualQuaternion<T>
Source§fn from(mv: Multivector<T, Cl0_2_1>) -> Self
fn from(mv: Multivector<T, Cl0_2_1>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl0_2_1>> for Scalar<T>
impl<T: Float> From<Multivector<T, Cl0_2_1>> for Scalar<T>
Source§fn from(mv: Multivector<T, Cl0_2_1>) -> Self
fn from(mv: Multivector<T, Cl0_2_1>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl0_2_1>> for Trivector<T>
impl<T: Float> From<Multivector<T, Cl0_2_1>> for Trivector<T>
Source§fn from(mv: Multivector<T, Cl0_2_1>) -> Self
fn from(mv: Multivector<T, Cl0_2_1>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl0_2_1>> for Vector<T>
impl<T: Float> From<Multivector<T, Cl0_2_1>> for Vector<T>
Source§fn from(mv: Multivector<T, Cl0_2_1>) -> Self
fn from(mv: Multivector<T, Cl0_2_1>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl1_0_0>> for HypUnit<T>
impl<T: Float> From<Multivector<T, Cl1_0_0>> for HypUnit<T>
Source§fn from(mv: Multivector<T, Cl1_0_0>) -> Self
fn from(mv: Multivector<T, Cl1_0_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl1_0_0>> for Hyperbolic<T>
impl<T: Float> From<Multivector<T, Cl1_0_0>> for Hyperbolic<T>
Source§fn from(mv: Multivector<T, Cl1_0_0>) -> Self
fn from(mv: Multivector<T, Cl1_0_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl1_0_0>> for Scalar<T>
impl<T: Float> From<Multivector<T, Cl1_0_0>> for Scalar<T>
Source§fn from(mv: Multivector<T, Cl1_0_0>) -> Self
fn from(mv: Multivector<T, Cl1_0_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl1_1_0>> for Bivector<T>
impl<T: Float> From<Multivector<T, Cl1_1_0>> for Bivector<T>
Source§fn from(mv: Multivector<T, Cl1_1_0>) -> Self
fn from(mv: Multivector<T, Cl1_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl1_1_0>> for Eventor<T>
impl<T: Float> From<Multivector<T, Cl1_1_0>> for Eventor<T>
Source§fn from(mv: Multivector<T, Cl1_1_0>) -> Self
fn from(mv: Multivector<T, Cl1_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl1_1_0>> for Scalar<T>
impl<T: Float> From<Multivector<T, Cl1_1_0>> for Scalar<T>
Source§fn from(mv: Multivector<T, Cl1_1_0>) -> Self
fn from(mv: Multivector<T, Cl1_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl1_1_0>> for Spacetime<T>
impl<T: Float> From<Multivector<T, Cl1_1_0>> for Spacetime<T>
Source§fn from(mv: Multivector<T, Cl1_1_0>) -> Self
fn from(mv: Multivector<T, Cl1_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl1_1_0>> for Vector<T>
impl<T: Float> From<Multivector<T, Cl1_1_0>> for Vector<T>
Source§fn from(mv: Multivector<T, Cl1_1_0>) -> Self
fn from(mv: Multivector<T, Cl1_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl2_1_0>> for Line<T>
impl<T: Float> From<Multivector<T, Cl2_1_0>> for Line<T>
Source§fn from(mv: Multivector<T, Cl2_1_0>) -> Self
fn from(mv: Multivector<T, Cl2_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl2_1_0>> for Point<T>
impl<T: Float> From<Multivector<T, Cl2_1_0>> for Point<T>
Source§fn from(mv: Multivector<T, Cl2_1_0>) -> Self
fn from(mv: Multivector<T, Cl2_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl2_1_0>> for Pseudoscalar<T>
impl<T: Float> From<Multivector<T, Cl2_1_0>> for Pseudoscalar<T>
Source§fn from(mv: Multivector<T, Cl2_1_0>) -> Self
fn from(mv: Multivector<T, Cl2_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl2_1_0>> for Rotor<T>
impl<T: Float> From<Multivector<T, Cl2_1_0>> for Rotor<T>
Source§fn from(mv: Multivector<T, Cl2_1_0>) -> Self
fn from(mv: Multivector<T, Cl2_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl2_1_0>> for Scalar<T>
impl<T: Float> From<Multivector<T, Cl2_1_0>> for Scalar<T>
Source§fn from(mv: Multivector<T, Cl2_1_0>) -> Self
fn from(mv: Multivector<T, Cl2_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl3_1_0>> for Bivector<T>
impl<T: Float> From<Multivector<T, Cl3_1_0>> for Bivector<T>
Source§fn from(mv: Multivector<T, Cl3_1_0>) -> Self
fn from(mv: Multivector<T, Cl3_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl3_1_0>> for Circle<T>
impl<T: Float> From<Multivector<T, Cl3_1_0>> for Circle<T>
Source§fn from(mv: Multivector<T, Cl3_1_0>) -> Self
fn from(mv: Multivector<T, Cl3_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl3_1_0>> for Eventor<T>
impl<T: Float> From<Multivector<T, Cl3_1_0>> for Eventor<T>
Source§fn from(mv: Multivector<T, Cl3_1_0>) -> Self
fn from(mv: Multivector<T, Cl3_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl3_1_0>> for FlatPoint<T>
impl<T: Float> From<Multivector<T, Cl3_1_0>> for FlatPoint<T>
Source§fn from(mv: Multivector<T, Cl3_1_0>) -> Self
fn from(mv: Multivector<T, Cl3_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl3_1_0>> for Line<T>
impl<T: Float> From<Multivector<T, Cl3_1_0>> for Line<T>
Source§fn from(mv: Multivector<T, Cl3_1_0>) -> Self
fn from(mv: Multivector<T, Cl3_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl3_1_0>> for Motor<T>
impl<T: Float> From<Multivector<T, Cl3_1_0>> for Motor<T>
Source§fn from(mv: Multivector<T, Cl3_1_0>) -> Self
fn from(mv: Multivector<T, Cl3_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl3_1_0>> for PointPair<T>
impl<T: Float> From<Multivector<T, Cl3_1_0>> for PointPair<T>
Source§fn from(mv: Multivector<T, Cl3_1_0>) -> Self
fn from(mv: Multivector<T, Cl3_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl3_1_0>> for Pseudoscalar<T>
impl<T: Float> From<Multivector<T, Cl3_1_0>> for Pseudoscalar<T>
Source§fn from(mv: Multivector<T, Cl3_1_0>) -> Self
fn from(mv: Multivector<T, Cl3_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl3_1_0>> for Pseudoscalar<T>
impl<T: Float> From<Multivector<T, Cl3_1_0>> for Pseudoscalar<T>
Source§fn from(mv: Multivector<T, Cl3_1_0>) -> Self
fn from(mv: Multivector<T, Cl3_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl3_1_0>> for RoundPoint<T>
impl<T: Float> From<Multivector<T, Cl3_1_0>> for RoundPoint<T>
Source§fn from(mv: Multivector<T, Cl3_1_0>) -> Self
fn from(mv: Multivector<T, Cl3_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl3_1_0>> for Scalar<T>
impl<T: Float> From<Multivector<T, Cl3_1_0>> for Scalar<T>
Source§fn from(mv: Multivector<T, Cl3_1_0>) -> Self
fn from(mv: Multivector<T, Cl3_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl3_1_0>> for Scalar<T>
impl<T: Float> From<Multivector<T, Cl3_1_0>> for Scalar<T>
Source§fn from(mv: Multivector<T, Cl3_1_0>) -> Self
fn from(mv: Multivector<T, Cl3_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl3_1_0>> for Trivector<T>
impl<T: Float> From<Multivector<T, Cl3_1_0>> for Trivector<T>
Source§fn from(mv: Multivector<T, Cl3_1_0>) -> Self
fn from(mv: Multivector<T, Cl3_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Cl3_1_0>> for Vector<T>
impl<T: Float> From<Multivector<T, Cl3_1_0>> for Vector<T>
Source§fn from(mv: Multivector<T, Cl3_1_0>) -> Self
fn from(mv: Multivector<T, Cl3_1_0>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Conformal3>> for Circle<T>
impl<T: Float> From<Multivector<T, Conformal3>> for Circle<T>
Source§fn from(mv: Multivector<T, Conformal3>) -> Self
fn from(mv: Multivector<T, Conformal3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Conformal3>> for Dipole<T>
impl<T: Float> From<Multivector<T, Conformal3>> for Dipole<T>
Source§fn from(mv: Multivector<T, Conformal3>) -> Self
fn from(mv: Multivector<T, Conformal3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Conformal3>> for FlatPoint<T>
impl<T: Float> From<Multivector<T, Conformal3>> for FlatPoint<T>
Source§fn from(mv: Multivector<T, Conformal3>) -> Self
fn from(mv: Multivector<T, Conformal3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Conformal3>> for Line<T>
impl<T: Float> From<Multivector<T, Conformal3>> for Line<T>
Source§fn from(mv: Multivector<T, Conformal3>) -> Self
fn from(mv: Multivector<T, Conformal3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Conformal3>> for Motor<T>
impl<T: Float> From<Multivector<T, Conformal3>> for Motor<T>
Source§fn from(mv: Multivector<T, Conformal3>) -> Self
fn from(mv: Multivector<T, Conformal3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Conformal3>> for Plane<T>
impl<T: Float> From<Multivector<T, Conformal3>> for Plane<T>
Source§fn from(mv: Multivector<T, Conformal3>) -> Self
fn from(mv: Multivector<T, Conformal3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Conformal3>> for Pseudoscalar<T>
impl<T: Float> From<Multivector<T, Conformal3>> for Pseudoscalar<T>
Source§fn from(mv: Multivector<T, Conformal3>) -> Self
fn from(mv: Multivector<T, Conformal3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Conformal3>> for RoundPoint<T>
impl<T: Float> From<Multivector<T, Conformal3>> for RoundPoint<T>
Source§fn from(mv: Multivector<T, Conformal3>) -> Self
fn from(mv: Multivector<T, Conformal3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Conformal3>> for Scalar<T>
impl<T: Float> From<Multivector<T, Conformal3>> for Scalar<T>
Source§fn from(mv: Multivector<T, Conformal3>) -> Self
fn from(mv: Multivector<T, Conformal3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Conformal3>> for Sphere<T>
impl<T: Float> From<Multivector<T, Conformal3>> for Sphere<T>
Source§fn from(mv: Multivector<T, Conformal3>) -> Self
fn from(mv: Multivector<T, Conformal3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Euclidean2>> for Bivector<T>
impl<T: Float> From<Multivector<T, Euclidean2>> for Bivector<T>
Source§fn from(mv: Multivector<T, Euclidean2>) -> Self
fn from(mv: Multivector<T, Euclidean2>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Euclidean2>> for Rotor<T>
impl<T: Float> From<Multivector<T, Euclidean2>> for Rotor<T>
Source§fn from(mv: Multivector<T, Euclidean2>) -> Self
fn from(mv: Multivector<T, Euclidean2>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Euclidean2>> for Scalar<T>
impl<T: Float> From<Multivector<T, Euclidean2>> for Scalar<T>
Source§fn from(mv: Multivector<T, Euclidean2>) -> Self
fn from(mv: Multivector<T, Euclidean2>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Euclidean2>> for Vector<T>
impl<T: Float> From<Multivector<T, Euclidean2>> for Vector<T>
Source§fn from(mv: Multivector<T, Euclidean2>) -> Self
fn from(mv: Multivector<T, Euclidean2>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Euclidean3>> for Bivector<T>
impl<T: Float> From<Multivector<T, Euclidean3>> for Bivector<T>
Source§fn from(mv: Multivector<T, Euclidean3>) -> Self
fn from(mv: Multivector<T, Euclidean3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Euclidean3>> for Line<T>
impl<T: Float> From<Multivector<T, Euclidean3>> for Line<T>
Source§fn from(mv: Multivector<T, Euclidean3>) -> Self
fn from(mv: Multivector<T, Euclidean3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Euclidean3>> for Point<T>
impl<T: Float> From<Multivector<T, Euclidean3>> for Point<T>
Source§fn from(mv: Multivector<T, Euclidean3>) -> Self
fn from(mv: Multivector<T, Euclidean3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Euclidean3>> for Pseudoscalar<T>
impl<T: Float> From<Multivector<T, Euclidean3>> for Pseudoscalar<T>
Source§fn from(mv: Multivector<T, Euclidean3>) -> Self
fn from(mv: Multivector<T, Euclidean3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Euclidean3>> for Rotor<T>
impl<T: Float> From<Multivector<T, Euclidean3>> for Rotor<T>
Source§fn from(mv: Multivector<T, Euclidean3>) -> Self
fn from(mv: Multivector<T, Euclidean3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Euclidean3>> for Rotor<T>
impl<T: Float> From<Multivector<T, Euclidean3>> for Rotor<T>
Source§fn from(mv: Multivector<T, Euclidean3>) -> Self
fn from(mv: Multivector<T, Euclidean3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Euclidean3>> for Scalar<T>
impl<T: Float> From<Multivector<T, Euclidean3>> for Scalar<T>
Source§fn from(mv: Multivector<T, Euclidean3>) -> Self
fn from(mv: Multivector<T, Euclidean3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Euclidean3>> for Scalar<T>
impl<T: Float> From<Multivector<T, Euclidean3>> for Scalar<T>
Source§fn from(mv: Multivector<T, Euclidean3>) -> Self
fn from(mv: Multivector<T, Euclidean3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Euclidean3>> for Trivector<T>
impl<T: Float> From<Multivector<T, Euclidean3>> for Trivector<T>
Source§fn from(mv: Multivector<T, Euclidean3>) -> Self
fn from(mv: Multivector<T, Euclidean3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Euclidean3>> for Vector<T>
impl<T: Float> From<Multivector<T, Euclidean3>> for Vector<T>
Source§fn from(mv: Multivector<T, Euclidean3>) -> Self
fn from(mv: Multivector<T, Euclidean3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Projective2>> for Flector<T>
impl<T: Float> From<Multivector<T, Projective2>> for Flector<T>
Source§fn from(mv: Multivector<T, Projective2>) -> Self
fn from(mv: Multivector<T, Projective2>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Projective2>> for Line<T>
impl<T: Float> From<Multivector<T, Projective2>> for Line<T>
Source§fn from(mv: Multivector<T, Projective2>) -> Self
fn from(mv: Multivector<T, Projective2>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Projective2>> for Motor<T>
impl<T: Float> From<Multivector<T, Projective2>> for Motor<T>
Source§fn from(mv: Multivector<T, Projective2>) -> Self
fn from(mv: Multivector<T, Projective2>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Projective2>> for Point<T>
impl<T: Float> From<Multivector<T, Projective2>> for Point<T>
Source§fn from(mv: Multivector<T, Projective2>) -> Self
fn from(mv: Multivector<T, Projective2>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Projective2>> for Scalar<T>
impl<T: Float> From<Multivector<T, Projective2>> for Scalar<T>
Source§fn from(mv: Multivector<T, Projective2>) -> Self
fn from(mv: Multivector<T, Projective2>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Projective2>> for Trivector<T>
impl<T: Float> From<Multivector<T, Projective2>> for Trivector<T>
Source§fn from(mv: Multivector<T, Projective2>) -> Self
fn from(mv: Multivector<T, Projective2>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Projective3>> for Flector<T>
impl<T: Float> From<Multivector<T, Projective3>> for Flector<T>
Source§fn from(mv: Multivector<T, Projective3>) -> Self
fn from(mv: Multivector<T, Projective3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Projective3>> for Line<T>
impl<T: Float> From<Multivector<T, Projective3>> for Line<T>
Source§fn from(mv: Multivector<T, Projective3>) -> Self
fn from(mv: Multivector<T, Projective3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Projective3>> for Motor<T>
impl<T: Float> From<Multivector<T, Projective3>> for Motor<T>
Source§fn from(mv: Multivector<T, Projective3>) -> Self
fn from(mv: Multivector<T, Projective3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Projective3>> for Plane<T>
impl<T: Float> From<Multivector<T, Projective3>> for Plane<T>
Source§fn from(mv: Multivector<T, Projective3>) -> Self
fn from(mv: Multivector<T, Projective3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Projective3>> for Point<T>
impl<T: Float> From<Multivector<T, Projective3>> for Point<T>
Source§fn from(mv: Multivector<T, Projective3>) -> Self
fn from(mv: Multivector<T, Projective3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Projective3>> for Quadvector<T>
impl<T: Float> From<Multivector<T, Projective3>> for Quadvector<T>
Source§fn from(mv: Multivector<T, Projective3>) -> Self
fn from(mv: Multivector<T, Projective3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl<T: Float> From<Multivector<T, Projective3>> for Scalar<T>
impl<T: Float> From<Multivector<T, Projective3>> for Scalar<T>
Source§fn from(mv: Multivector<T, Projective3>) -> Self
fn from(mv: Multivector<T, Projective3>) -> Self
Extracts this type from a multivector.
Note: This is a lossy projection that only extracts the relevant grades. Other components of the multivector are discarded.
Source§impl From<NonZeroVectorE3> for Multivector<f64, Euclidean3>
impl From<NonZeroVectorE3> for Multivector<f64, Euclidean3>
Source§fn from(v: NonZeroVectorE3) -> Self
fn from(v: NonZeroVectorE3) -> Self
Source§impl<T: Float> From<Plane<T>> for Multivector<T, Conformal3>
impl<T: Float> From<Plane<T>> for Multivector<T, Conformal3>
Source§impl<T: Float> From<Plane<T>> for Multivector<T, Projective3>
impl<T: Float> From<Plane<T>> for Multivector<T, Projective3>
Source§impl<T: Float> From<Point<T>> for Multivector<T, Euclidean3>
impl<T: Float> From<Point<T>> for Multivector<T, Euclidean3>
Source§impl<T: Float> From<Point<T>> for Multivector<T, Projective2>
impl<T: Float> From<Point<T>> for Multivector<T, Projective2>
Source§impl<T: Float> From<Point<T>> for Multivector<T, Projective3>
impl<T: Float> From<Point<T>> for Multivector<T, Projective3>
Source§impl<T: Float> From<Pseudoscalar<T>> for Multivector<T, Cl2_1_0>
impl<T: Float> From<Pseudoscalar<T>> for Multivector<T, Cl2_1_0>
Source§fn from(value: Pseudoscalar<T>) -> Self
fn from(value: Pseudoscalar<T>) -> Self
Source§impl<T: Float> From<Pseudoscalar<T>> for Multivector<T, Cl3_1_0>
impl<T: Float> From<Pseudoscalar<T>> for Multivector<T, Cl3_1_0>
Source§fn from(value: Pseudoscalar<T>) -> Self
fn from(value: Pseudoscalar<T>) -> Self
Source§impl<T: Float> From<Pseudoscalar<T>> for Multivector<T, Cl3_1_0>
impl<T: Float> From<Pseudoscalar<T>> for Multivector<T, Cl3_1_0>
Source§fn from(value: Pseudoscalar<T>) -> Self
fn from(value: Pseudoscalar<T>) -> Self
Source§impl<T: Float> From<Pseudoscalar<T>> for Multivector<T, Conformal3>
impl<T: Float> From<Pseudoscalar<T>> for Multivector<T, Conformal3>
Source§fn from(value: Pseudoscalar<T>) -> Self
fn from(value: Pseudoscalar<T>) -> Self
Source§impl<T: Float> From<Pseudoscalar<T>> for Multivector<T, Euclidean3>
impl<T: Float> From<Pseudoscalar<T>> for Multivector<T, Euclidean3>
Source§fn from(value: Pseudoscalar<T>) -> Self
fn from(value: Pseudoscalar<T>) -> Self
Source§impl<T: Float> From<Quadvector<T>> for Multivector<T, Projective3>
impl<T: Float> From<Quadvector<T>> for Multivector<T, Projective3>
Source§fn from(value: Quadvector<T>) -> Self
fn from(value: Quadvector<T>) -> Self
Source§impl<T: Float> From<Quaternion<T>> for Multivector<T, Cl0_2_0>
impl<T: Float> From<Quaternion<T>> for Multivector<T, Cl0_2_0>
Source§fn from(value: Quaternion<T>) -> Self
fn from(value: Quaternion<T>) -> Self
Source§impl<T: Float> From<Rotor<T>> for Multivector<T, Euclidean2>
impl<T: Float> From<Rotor<T>> for Multivector<T, Euclidean2>
Source§impl<T: Float> From<Rotor<T>> for Multivector<T, Euclidean3>
impl<T: Float> From<Rotor<T>> for Multivector<T, Euclidean3>
Source§impl<T: Float> From<Rotor<T>> for Multivector<T, Euclidean3>
impl<T: Float> From<Rotor<T>> for Multivector<T, Euclidean3>
Source§impl<T: Float> From<RoundPoint<T>> for Multivector<T, Cl3_1_0>
impl<T: Float> From<RoundPoint<T>> for Multivector<T, Cl3_1_0>
Source§fn from(value: RoundPoint<T>) -> Self
fn from(value: RoundPoint<T>) -> Self
Source§impl<T: Float> From<RoundPoint<T>> for Multivector<T, Conformal3>
impl<T: Float> From<RoundPoint<T>> for Multivector<T, Conformal3>
Source§fn from(value: RoundPoint<T>) -> Self
fn from(value: RoundPoint<T>) -> Self
Source§impl<T: Float> From<Scalar<T>> for Multivector<T, Conformal3>
impl<T: Float> From<Scalar<T>> for Multivector<T, Conformal3>
Source§impl<T: Float> From<Scalar<T>> for Multivector<T, Euclidean2>
impl<T: Float> From<Scalar<T>> for Multivector<T, Euclidean2>
Source§impl<T: Float> From<Scalar<T>> for Multivector<T, Euclidean3>
impl<T: Float> From<Scalar<T>> for Multivector<T, Euclidean3>
Source§impl<T: Float> From<Scalar<T>> for Multivector<T, Euclidean3>
impl<T: Float> From<Scalar<T>> for Multivector<T, Euclidean3>
Source§impl<T: Float> From<Scalar<T>> for Multivector<T, Projective2>
impl<T: Float> From<Scalar<T>> for Multivector<T, Projective2>
Source§impl<T: Float> From<Scalar<T>> for Multivector<T, Projective3>
impl<T: Float> From<Scalar<T>> for Multivector<T, Projective3>
Source§impl<T: Float> From<Sphere<T>> for Multivector<T, Conformal3>
impl<T: Float> From<Sphere<T>> for Multivector<T, Conformal3>
Source§impl<T: Float> From<Trivector<T>> for Multivector<T, Euclidean3>
impl<T: Float> From<Trivector<T>> for Multivector<T, Euclidean3>
Source§impl<T: Float> From<Trivector<T>> for Multivector<T, Projective2>
impl<T: Float> From<Trivector<T>> for Multivector<T, Projective2>
Source§impl From<UnitVectorE3> for Multivector<f64, Euclidean3>
impl From<UnitVectorE3> for Multivector<f64, Euclidean3>
Source§fn from(v: UnitVectorE3) -> Self
fn from(v: UnitVectorE3) -> Self
Source§impl<T: Float> From<Vector<T>> for Multivector<T, Euclidean2>
impl<T: Float> From<Vector<T>> for Multivector<T, Euclidean2>
Source§impl<T: Float> From<Vector<T>> for Multivector<T, Euclidean3>
impl<T: Float> From<Vector<T>> for Multivector<T, Euclidean3>
Source§impl From<VectorE3> for Multivector<f64, Euclidean3>
impl From<VectorE3> for Multivector<f64, Euclidean3>
Source§impl<T: Float, S: Signature> Mul<&Multivector<T, S>> for Multivector<T, S>
impl<T: Float, S: Signature> Mul<&Multivector<T, S>> for Multivector<T, S>
Source§impl<T: Float, S: Signature> Mul<Multivector<T, S>> for &Multivector<T, S>
impl<T: Float, S: Signature> Mul<Multivector<T, S>> for &Multivector<T, S>
Source§type Output = Multivector<T, S>
type Output = Multivector<T, S>
* operator.Source§impl<T: Float, S: Signature> Mul for &Multivector<T, S>
impl<T: Float, S: Signature> Mul for &Multivector<T, S>
Source§fn mul(self, rhs: Self) -> Self::Output
fn mul(self, rhs: Self) -> Self::Output
Computes the geometric product of two multivectors.
The geometric product is the fundamental operation in geometric algebra. It is computed by distributing over all pairs of basis blades and using the blade multiplication rules defined by the metric signature.
§Complexity
O(4^n) where n is the dimension of the algebra.
Source§type Output = Multivector<T, S>
type Output = Multivector<T, S>
* operator.Source§impl<T: Float, S: Signature> MulAssign<T> for Multivector<T, S>
impl<T: Float, S: Signature> MulAssign<T> for Multivector<T, S>
Source§fn mul_assign(&mut self, scalar: T)
fn mul_assign(&mut self, scalar: T)
*= operation. Read moreSource§impl<T: Float, S: Signature> RelativeEq for Multivector<T, S>
impl<T: Float, S: Signature> RelativeEq for Multivector<T, S>
Source§fn default_max_relative() -> Self::Epsilon
fn default_max_relative() -> Self::Epsilon
Source§fn relative_eq(
&self,
other: &Self,
epsilon: Self::Epsilon,
max_relative: Self::Epsilon,
) -> bool
fn relative_eq( &self, other: &Self, epsilon: Self::Epsilon, max_relative: Self::Epsilon, ) -> bool
Source§fn relative_ne(
&self,
other: &Rhs,
epsilon: Self::Epsilon,
max_relative: Self::Epsilon,
) -> bool
fn relative_ne( &self, other: &Rhs, epsilon: Self::Epsilon, max_relative: Self::Epsilon, ) -> bool
RelativeEq::relative_eq.Source§impl<T, S: Signature> Serialize for Multivector<T, S>
impl<T, S: Signature> Serialize for Multivector<T, S>
Source§impl<T: Float, S: Signature> Sub<&Multivector<T, S>> for Multivector<T, S>
impl<T: Float, S: Signature> Sub<&Multivector<T, S>> for Multivector<T, S>
Source§impl<T: Float, S: Signature> Sub<Multivector<T, S>> for &Multivector<T, S>
impl<T: Float, S: Signature> Sub<Multivector<T, S>> for &Multivector<T, S>
Source§type Output = Multivector<T, S>
type Output = Multivector<T, S>
- operator.Source§impl<T: Float, S: Signature> SubAssign<&Multivector<T, S>> for Multivector<T, S>
impl<T: Float, S: Signature> SubAssign<&Multivector<T, S>> for Multivector<T, S>
Source§fn sub_assign(&mut self, rhs: &Self)
fn sub_assign(&mut self, rhs: &Self)
-= operation. Read moreSource§impl<T: Float, S: Signature> SubAssign for Multivector<T, S>
impl<T: Float, S: Signature> SubAssign for Multivector<T, S>
Source§fn sub_assign(&mut self, rhs: Self)
fn sub_assign(&mut self, rhs: Self)
-= operation. Read moreSource§impl<T: Float, S: Signature> UlpsEq for Multivector<T, S>
impl<T: Float, S: Signature> UlpsEq for Multivector<T, S>
impl<T: Float, S: Signature> Copy for Multivector<T, S>
Auto Trait Implementations§
impl<T, S> Freeze for Multivector<T, S>
impl<T, S> RefUnwindSafe for Multivector<T, S>
impl<T, S> Send for Multivector<T, S>
impl<T, S> Sync for Multivector<T, S>
impl<T, S> Unpin for Multivector<T, S>
impl<T, S> UnwindSafe for Multivector<T, S>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.