Struct HermitianEigenproblem
pub struct HermitianEigenproblem<'a> { /* private fields */ }Description
A finite Hermitian matrix pencil with an explicitly positive-definite metric.
Types retain exact basis identities and physical dimensions. Matrices describe the already constrained space; this owner never removes nullspace coordinates or regularizes a singular metric. The caller retains the constraint lineage. A standard problem supplies an explicit dimensionless identity metric.
Implementations§
§impl HermitianEigenproblem<'_>
impl HermitianEigenproblem<'_>
pub fn excluded_metric_projector(
operator: &ValueLiteral,
metric: &ValueLiteral,
embedding: &ValueLiteral,
tolerance: f64,
) -> Result<ValueLiteral, Diagnostic>
pub fn excluded_metric_projector( operator: &ValueLiteral, metric: &ValueLiteral, embedding: &ValueLiteral, tolerance: f64, ) -> Result<ValueLiteral, Diagnostic>
Dimensionless complementary metric projector
E = I - P (Pᴴ B P)⁻¹ Pᴴ B of an explicitly declared embedding.
The full original metric may be singular or indefinite; its pullback
must be positive definite. E describes directions excluded by P and
has rank full_extent - admitted_extent. It is generally an oblique
projector in coefficient coordinates. This does not assert that A or B
vanishes on those directions, or that they are physical gauge freedoms.
Cholesky triangular solves avoid explicitly forming an inverse.
tolerance checks the B-orthonormality of the lifted coordinate basis.
§impl HermitianEigenproblem<'_>
impl HermitianEigenproblem<'_>
pub fn pullback(
operator: &ValueLiteral,
metric: &ValueLiteral,
embedding: &ValueLiteral,
) -> Result<(ValueLiteral, ValueLiteral), Diagnostic>
pub fn pullback( operator: &ValueLiteral, metric: &ValueLiteral, embedding: &ValueLiteral, ) -> Result<(ValueLiteral, ValueLiteral), Diagnostic>
Pull back complete Hermitian matrices along an explicit map u=Pq.
Returns (Pᴴ A P, Pᴴ B P) in P’s exact source basis. The restricted
metric must have positive finite Cholesky pivots; the original metric
may be singular or indefinite only outside this admitted space. No
coordinates are chosen, deleted, shifted or regularized implicitly.
This does not prove that reduced eigenvectors satisfy the original
equation: lifted candidates still require original-pencil verification.
§impl HermitianEigenproblem<'_>
impl HermitianEigenproblem<'_>
pub fn metric_projector(
&self,
modes: &[ValueLiteral],
tolerance: f64,
) -> Result<ValueLiteral, Diagnostic>
pub fn metric_projector( &self, modes: &[ValueLiteral], tolerance: f64, ) -> Result<ValueLiteral, Diagnostic>
Construct the dimensionless metric projector P=U Uᴴ B of supplied modes.
Checks the exact mode types, nonzero vectors and B-orthonormality, using
||UᴴBU-I||_F <= tolerance. Tolerance is an explicit dimensionless
numerical control in (0,1). A mode permutation, independent phases,
or a unitary rotation within this subspace leaves the projector unchanged.
This does not establish that the subspace is invariant under A; eigenpair
residuals must be verified separately by the owning Plan.
§impl<'a> HermitianEigenproblem<'a>
impl<'a> HermitianEigenproblem<'a>
pub fn check_operator(operator: &ValueLiteral) -> Result<(), Diagnostic>
pub fn check_operator(operator: &ValueLiteral) -> Result<(), Diagnostic>
Check one complete Hermitian endomorphism on its exact finite basis.
This checks the bound coefficients before any evolution scaling or solve. Both triangles and imaginary diagonal parts participate; no tolerance, dimension cap, or discarded triangle weakens this mathematical contract.
§Errors
Rejects non-endomorphism types or any unequal conjugate coefficients.
pub fn new(
operator: &'a ValueLiteral,
metric: &'a ValueLiteral,
) -> Result<HermitianEigenproblem<'a>, Diagnostic>
pub fn new( operator: &'a ValueLiteral, metric: &'a ValueLiteral, ) -> Result<HermitianEigenproblem<'a>, Diagnostic>
Check exact type correspondence, both full Hermitian matrices, and every Cholesky pivot of the metric. No dimension-specific formula or size cap is used. Numerically nonpositive/nonfinite pivots reject explicitly.
pub fn original_eigenpair_defects(
operator: &'a ValueLiteral,
metric: &'a ValueLiteral,
eigenvalue: &ValueLiteral,
mode: &ValueLiteral,
) -> Result<(f64, f64), Diagnostic>
pub fn original_eigenpair_defects( operator: &'a ValueLiteral, metric: &'a ValueLiteral, eigenvalue: &ValueLiteral, mode: &ValueLiteral, ) -> Result<(f64, f64), Diagnostic>
Verify a lifted mode against a complete original Hermitian pencil.
The original metric need not be positive definite outside the admitted space. This evaluates residual and normalization only; it does not admit a singular/indefinite pencil for execution or prove subspace membership.
pub fn original_metric_projector(
operator: &'a ValueLiteral,
metric: &'a ValueLiteral,
modes: &[ValueLiteral],
tolerance: f64,
) -> Result<ValueLiteral, Diagnostic>
pub fn original_metric_projector( operator: &'a ValueLiteral, metric: &'a ValueLiteral, modes: &[ValueLiteral], tolerance: f64, ) -> Result<ValueLiteral, Diagnostic>
Verify B-orthonormal lifted modes and construct their original-space metric projector. Positivity outside their span is not established.
pub const fn operator(&self) -> &ValueLiteral
pub const fn operator(&self) -> &ValueLiteral
Complete typed operator, in row-major component order.
pub const fn metric(&self) -> &ValueLiteral
pub const fn metric(&self) -> &ValueLiteral
Complete typed metric, in row-major component order.
pub const fn dimension(&self) -> usize
pub const fn dimension(&self) -> usize
Number of coordinates of the exact admitted finite space.
pub const fn eigenvalue_type(&self) -> &ValueType
pub const fn eigenvalue_type(&self) -> &ValueType
Real eigenvalue type, including the quotient dimension A/B.
pub const fn mode_type(&self) -> &ValueType
pub const fn mode_type(&self) -> &ValueType
Mode type, including the metric normalization dimension B^-1/2.
pub fn eigenpair_defects(
&self,
eigenvalue: &ValueLiteral,
mode: &ValueLiteral,
) -> Result<(f64, f64), Diagnostic>
pub fn eigenpair_defects( &self, eigenvalue: &ValueLiteral, mode: &ValueLiteral, ) -> Result<(f64, f64), Diagnostic>
Independently measure a typed candidate against the original pencil.
Returns (relative residual, normalization defect) where the residual
is ||Au-lambda Bu|| / (||Au|| + |lambda| ||Bu||) and the defect is
|uᴴBu - 1|. A zero residual with zero denominator has relative residual
zero. Both quantities are dimensionless; no acceptance tolerance is
hidden here. Zero modes, wrong types and nonfinite arithmetic reject.
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for HermitianEigenproblem<'a>
impl<'a> RefUnwindSafe for HermitianEigenproblem<'a>
impl<'a> Send for HermitianEigenproblem<'a>
impl<'a> Sync for HermitianEigenproblem<'a>
impl<'a> Unpin for HermitianEigenproblem<'a>
impl<'a> UnsafeUnpin for HermitianEigenproblem<'a>
impl<'a> UnwindSafe for HermitianEigenproblem<'a>
Blanket Implementations§
Source§impl<T> Any for Twhere
T: 'static + ?Sized,
impl<T> Any for Twhere
T: 'static + ?Sized,
§impl<Src, Scheme> ApproxFrom<Src, Scheme> for Srcwhere
Scheme: ApproxScheme,
impl<Src, Scheme> ApproxFrom<Src, Scheme> for Srcwhere
Scheme: ApproxScheme,
§fn approx_from(src: Src) -> Result<Src, <Src as ApproxFrom<Src, Scheme>>::Err>
fn approx_from(src: Src) -> Result<Src, <Src as ApproxFrom<Src, Scheme>>::Err>
§impl<Dst, Src, Scheme> ApproxInto<Dst, Scheme> for Srcwhere
Dst: ApproxFrom<Src, Scheme>,
Scheme: ApproxScheme,
impl<Dst, Src, Scheme> ApproxInto<Dst, Scheme> for Srcwhere
Dst: ApproxFrom<Src, Scheme>,
Scheme: ApproxScheme,
§type Err = <Dst as ApproxFrom<Src, Scheme>>::Err
type Err = <Dst as ApproxFrom<Src, Scheme>>::Err
§fn approx_into(self) -> Result<Dst, <Src as ApproxInto<Dst, Scheme>>::Err>
fn approx_into(self) -> Result<Dst, <Src as ApproxInto<Dst, Scheme>>::Err>
Source§impl<T> Borrow<T> for Twhere
T: ?Sized,
impl<T> Borrow<T> for Twhere
T: ?Sized,
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,
§impl<T, Dst> ConvAsUtil<Dst> for T
impl<T, Dst> ConvAsUtil<Dst> for T
§fn approx(self) -> Result<Dst, Self::Err>where
Self: Sized + ApproxInto<Dst>,
fn approx(self) -> Result<Dst, Self::Err>where
Self: Sized + ApproxInto<Dst>,
§impl<T> ConvUtil for T
impl<T> ConvUtil for T
§fn approx_as<Dst>(self) -> Result<Dst, Self::Err>where
Self: Sized + ApproxInto<Dst>,
fn approx_as<Dst>(self) -> Result<Dst, Self::Err>where
Self: Sized + ApproxInto<Dst>,
§fn approx_as_by<Dst, Scheme>(self) -> Result<Dst, Self::Err>where
Self: Sized + ApproxInto<Dst, Scheme>,
Scheme: ApproxScheme,
fn approx_as_by<Dst, Scheme>(self) -> Result<Dst, Self::Err>where
Self: Sized + ApproxInto<Dst, Scheme>,
Scheme: ApproxScheme,
§fn into_as<Dst>(self) -> Dstwhere
Self: Sized + Into<Dst>,
fn into_as<Dst>(self) -> Dstwhere
Self: Sized + Into<Dst>,
§fn try_as<Dst>(self) -> Result<Dst, Self::Err>where
Self: Sized + TryInto<Dst>,
fn try_as<Dst>(self) -> Result<Dst, Self::Err>where
Self: Sized + TryInto<Dst>,
§impl<T> DistributionExt for Twhere
T: ?Sized,
impl<T> DistributionExt for Twhere
T: ?Sized,
fn rand<T>(&self, rng: &mut (impl Rng + ?Sized)) -> Twhere
Self: Distribution<T>,
Source§impl<T> From<T> for T
impl<T> From<T> for T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T, U> Into<U> for Twhere
U: From<T>,
impl<T, U> Into<U> for Twhere
U: From<T>,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>where
F: FnOnce(&Self) -> bool,
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>where
F: FnOnce(&Self) -> bool,
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> Same for T
impl<T> Same for T
§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read more§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).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.