Record TCL3BivectorHelper

Unit

Declaration

type TCL3BivectorHelper = record helper for TCL3Bivector

Description

Record helper for TCL3Bivector providing geometric operations specific to grade-2 elements of Cl(3,0).

All operations follow the conventions of Clifford algebra over ℝ³:

Overview

Methods

Public function Conjugate: TCL3Bivector;
Public function Dot(const AVector: TCL3Bivector): double; overload;
Public function Dot(const AVector: TCL3Multivector): TCL3Multivector; overload;
Public function Dot(const AVector: TCL3Trivector): TCL3Vector; overload;
Public function Dot(const AVector: TCL3Vector): TCL3Vector; overload;
Public function Dual: TCL3Vector;
Public function ExtractBivector(AComponents: TCL3MultivectorComponents): TCL3Bivector;
Public function Inverse: TCL3Bivector;
Public function Norm: double;
Public function Normalized: TCL3Bivector;
Public function Projection(const AVector: TCL3Bivector): TCL3Bivector; overload;
Public function Projection(const AVector: TCL3Multivector): TCL3Multivector; overload;
Public function Projection(const AVector: TCL3Trivector): TCL3Bivector; overload;
Public function Projection(const AVector: TCL3Vector): TCL3Bivector; overload;
Public function Reciprocal: TCL3Bivector;
Public function Reflection(const AVector: TCL3Bivector): TCL3Bivector; overload;
Public function Reflection(const AVector: TCL3Multivector): TCL3Multivector; overload;
Public function Reflection(const AVector: TCL3Trivector): TCL3Bivector; overload;
Public function Reflection(const AVector: TCL3Vector): TCL3Bivector; overload;
Public function Rejection(const AVector: TCL3Bivector): double; overload;
Public function Rejection(const AVector: TCL3Multivector): TCL3Multivector; overload;
Public function Rejection(const AVector: TCL3Trivector): double; overload;
Public function Rejection(const AVector: TCL3Vector): TCL3Bivector; overload;
Public function Reverse: TCL3Bivector;
Public function Rotation(const AVector1, AVector2: TCL3Bivector): TCL3Bivector; overload;
Public function Rotation(const AVector1, AVector2: TCL3Multivector): TCL3Multivector; overload;
Public function Rotation(const AVector1, AVector2: TCL3Trivector): TCL3Bivector; overload;
Public function Rotation(const AVector1, AVector2: TCL3Vector): TCL3Bivector; overload;
Public function SameValue(const AValue: TCL3Bivector): boolean;
Public function SameValue(const AValue: TCL3Multivector): boolean;
Public function SquaredNorm: double;
Public function ToMultivector: TCL3Multivector;
Public function ToString: string;
Public function ToString(APrecision, ADigits: longint): string;
Public function Wedge(const AVector: TCL3Bivector): double; overload;
Public function Wedge(const AVector: TCL3Multivector): TCL3Multivector; overload;
Public function Wedge(const AVector: TCL3Trivector): double; overload;
Public function Wedge(const AVector: TCL3Vector): TCL3Trivector; overload;

Description

Methods

Public function Conjugate: TCL3Bivector;

Returns the Clifford conjugate of the bivector. The conjugate combines reversion and grade involution. For a bivector (k = 2): B† = -B.

Public function Dot(const AVector: TCL3Bivector): double; overload;

Returns the inner (dot) product of two bivectors. Lowers the grade: grade(2) · grade(2) → grade(0) = scalar. Result: B₁ · B₂ = -(m12₁·m12₂ + m13₁·m13₂ + m23₁·m23₂).

Parameters
AVector
The grade-2 right operand.
Public function Dot(const AVector: TCL3Multivector): TCL3Multivector; overload;

Returns the inner (dot) product of the bivector and a multivector. The result is a full TCL3Multivector due to grade mixing.

Parameters
AVector
The right operand.
Public function Dot(const AVector: TCL3Trivector): TCL3Vector; overload;

Returns the inner (dot) product of the bivector and a trivector. Lowers the grade: grade(2) · grade(3) → grade(1) = vector.

Parameters
AVector
The grade-3 right operand.
Public function Dot(const AVector: TCL3Vector): TCL3Vector; overload;

Returns the inner (dot) product of the bivector and a vector. Lowers the grade: grade(2) · grade(1) → grade(1) = vector.

Parameters
AVector
The grade-1 right operand.
Public function Dual: TCL3Vector;

Returns the dual of the bivector with respect to the pseudoscalar e₁₂₃. The dual maps grade-2 elements to grade-1 (vector) elements: B* = B · e₁₂₃⁻¹. For example: (e₁∧e₂)* = -e₃, (e₁∧e₃)* = e₂, (e₂∧e₃)* = -e₁.

Public function ExtractBivector(AComponents: TCL3MultivectorComponents): TCL3Bivector;

Returns a new bivector containing only the components specified by AComponents. Components not present in AComponents are set to zero. Useful for extracting specific basis blade contributions from a bivector.

Parameters
AComponents
A set of TCL3MultivectorComponent values identifying the components to retain. Valid values are mcm12, mcm13, mcm23.
Public function Inverse: TCL3Bivector;

Returns the inverse of the bivector under the geometric product. For a pure bivector B, the inverse is: B⁻¹ = -B / |B|², since B² ≤ 0 in Cl(3,0).

Public function Norm: double;

Returns the norm of the bivector: |B| = √(m12² + m13² + m23²). Defined as the square root of -B² since B² ≤ 0 for pure bivectors.

Public function Normalized: TCL3Bivector;

Returns the unit bivector in the same orientation. Each component is divided by Norm.

Public function Projection(const AVector: TCL3Bivector): TCL3Bivector; overload;

Returns the projection of the bivector onto another bivector subspace. Defined as: proj(B₁, B₂) = (B₁ · B₂⁻¹) ∧ B₂.

Parameters
AVector
The bivector defining the subspace to project onto.
Public function Projection(const AVector: TCL3Multivector): TCL3Multivector; overload;

Returns the projection of the bivector onto a multivector subspace. Defined as: proj(B, M) = (B · M⁻¹) ∧ M. The result is a full TCL3Multivector due to grade mixing.

Parameters
AVector
The multivector defining the subspace to project onto.
Public function Projection(const AVector: TCL3Trivector): TCL3Bivector; overload;

Returns the projection of the bivector onto a trivector subspace. Defined as: proj(B, T) = (B · T⁻¹) ∧ T. Since the trivector spans all of ℝ³, the projection of any bivector onto it returns the bivector unchanged.

Parameters
AVector
The trivector defining the subspace to project onto.
Public function Projection(const AVector: TCL3Vector): TCL3Bivector; overload;

Returns the projection of the bivector onto a vector subspace. Defined as: proj(B, v) = (B · v⁻¹) ∧ v. The result is the component of B that lies in the plane containing v.

Parameters
AVector
The vector defining the subspace to project onto.
Public function Reciprocal: TCL3Bivector;

Returns the reciprocal of the bivector: B̃ / (B · B̃). Equivalent to Inverse for non-zero bivectors.

Public function Reflection(const AVector: TCL3Bivector): TCL3Bivector; overload;

Returns the reflection of the bivector through another bivector. Defined as: reflect(B₁, B₂) = -B₂ · B₁ · B₂⁻¹.

Parameters
AVector
The bivector defining the reflection element.
Public function Reflection(const AVector: TCL3Multivector): TCL3Multivector; overload;

Returns the reflection of the bivector through a multivector. Defined as: reflect(B, M) = -M · B · M⁻¹. The result is a full TCL3Multivector due to grade mixing.

Parameters
AVector
The multivector defining the reflection element.
Public function Reflection(const AVector: TCL3Trivector): TCL3Bivector; overload;

Returns the reflection of the bivector through a trivector. Defined as: reflect(B, T) = -T · B · T⁻¹. Since the pseudoscalar commutes with all even-grade elements, the reflection through a trivector returns the bivector unchanged.

Parameters
AVector
The trivector defining the reflection element.
Public function Reflection(const AVector: TCL3Vector): TCL3Bivector; overload;

Returns the reflection of the bivector through a vector. Defined as: reflect(B, v) = -v · B · v⁻¹. Reflects the oriented plane of B through the hyperplane orthogonal to v.

Parameters
AVector
The vector defining the reflection hyperplane normal.
Public function Rejection(const AVector: TCL3Bivector): double; overload;

Returns the rejection of the bivector from another bivector subspace. Defined as: rej(B₁, B₂) = B₁ - proj(B₁, B₂). In ℝ³ the rejection of a bivector from a bivector is a scalar.

Parameters
AVector
The bivector defining the subspace to reject from.
Public function Rejection(const AVector: TCL3Multivector): TCL3Multivector; overload;

Returns the rejection of the bivector from a multivector subspace. Defined as: rej(B, M) = B - proj(B, M). The result is a full TCL3Multivector due to grade mixing.

Parameters
AVector
The multivector defining the subspace to reject from.
Public function Rejection(const AVector: TCL3Trivector): double; overload;

Returns the rejection of the bivector from a trivector subspace. Defined as: rej(B, T) = B - proj(B, T). In ℝ³ the rejection of a bivector from a trivector is a scalar.

Parameters
AVector
The trivector defining the subspace to reject from.
Public function Rejection(const AVector: TCL3Vector): TCL3Bivector; overload;

Returns the rejection of the bivector from a vector subspace. Defined as: rej(B, v) = B - proj(B, v). The result is the component of B orthogonal to v.

Parameters
AVector
The vector defining the subspace to reject from.
Public function Reverse: TCL3Bivector;

Returns the reverse of the bivector. The reverse of a grade-k blade changes sign by (-1)ˆ(k·(k-1)/2). For a bivector (k = 2): B̃ = -B.

Public function Rotation(const AVector1, AVector2: TCL3Bivector): TCL3Bivector; overload;

Returns the bivector rotated by the rotor defined by two bivectors. The rotation is applied as: B' = R · B · R⁻¹.

Parameters
AVector1
The first bivector defining the rotor.
AVector2
The second bivector defining the rotor.
Public function Rotation(const AVector1, AVector2: TCL3Multivector): TCL3Multivector; overload;

Returns the bivector rotated by the rotor defined by two multivectors. The rotation is applied as: B' = R · B · R⁻¹. The result is a full TCL3Multivector due to potential grade mixing.

Parameters
AVector1
The first multivector defining the rotor.
AVector2
The second multivector defining the rotor.
Public function Rotation(const AVector1, AVector2: TCL3Trivector): TCL3Bivector; overload;

Returns the bivector rotated by the rotor defined by two trivectors. The rotation is applied as: B' = R · B · R⁻¹.

Parameters
AVector1
The first trivector defining the rotor.
AVector2
The second trivector defining the rotor.
Public function Rotation(const AVector1, AVector2: TCL3Vector): TCL3Bivector; overload;

Returns the bivector rotated by the rotor defined by two vectors. The rotor is constructed as R = AVector2 · AVector1 (normalised to a unit rotor). The rotation is applied as: B' = R · B · R⁻¹.

Parameters
AVector1
The first vector defining the rotation plane.
AVector2
The second vector defining the rotation plane.
Public function SameValue(const AValue: TCL3Bivector): boolean;

Returns True if the two bivectors are numerically equal within the default floating point tolerance.

Parameters
AValue
The bivector to compare against.
Public function SameValue(const AValue: TCL3Multivector): boolean;

Returns True if the bivector is numerically equal to the given multivector within the default floating point tolerance. All non-bivector components of AValue must be negligible.

Parameters
AValue
The multivector to compare against.
Public function SquaredNorm: double;

Returns the squared norm of the bivector: |B|² = m12² + m13² + m23². Avoids the square root computation of Norm.

Public function ToMultivector: TCL3Multivector;

Converts the bivector to a full TCL3Multivector. All components are zero except m12, m13, m23.

Public function ToString: string;

Converts the bivector to its default string representation. The format is m12·e₁₂ + m13·e₁₃ + m23·e₂₃.

Public function ToString(APrecision, ADigits: longint): string;

Converts the bivector to a formatted string with controlled precision. The format is m12·e₁₂ + m13·e₁₃ + m23·e₂₃.

Parameters
APrecision
Number of significant digits.
ADigits
Minimum number of digits in the output.
Public function Wedge(const AVector: TCL3Bivector): double; overload;

Returns the outer (wedge) product of two bivectors. Always zero in ℝ³: grade(2) ∧ grade(2) → grade(4) = 0.

Parameters
AVector
The grade-2 right operand.
Public function Wedge(const AVector: TCL3Multivector): TCL3Multivector; overload;

Returns the outer (wedge) product of the bivector and a multivector. Only the scalar and vector parts of AVector contribute to a non-zero result; higher-grade wedge products vanish in ℝ³.

Parameters
AVector
The right operand.
Public function Wedge(const AVector: TCL3Trivector): double; overload;

Returns the outer (wedge) product of the bivector and a trivector. Always zero in ℝ³: grade(2) ∧ grade(3) → grade(5) = 0.

Parameters
AVector
The grade-3 right operand.
Public function Wedge(const AVector: TCL3Vector): TCL3Trivector; overload;

Returns the outer (wedge) product of the bivector and a vector. Raises the grade: grade(2) ∧ grade(1) → grade(3) = trivector.

Parameters
AVector
The grade-1 right operand.

Generated by PasDoc 1.0.4.