#[non_exhaustive]pub struct EigshOptions {
pub eigenpairs: usize,
pub target: SpectrumTarget,
pub krylov_dimension: Option<usize>,
pub tolerance: f64,
pub max_iterations: usize,
pub seed: u64,
}Expand description
Controls target selection, search-space size, and convergence for eigsh.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.eigenpairs: usizeNumber of requested eigenpairs; must be smaller than the dimension.
target: SpectrumTargetRegion of the real Hermitian spectrum to target.
krylov_dimension: Option<usize>Optional Lanczos or restart window dimension.
tolerance: f64Required residual norm for convergence.
max_iterations: usizeMaximum Lanczos or restart iteration budget.
seed: u64Deterministic seed for the initial vector.
Implementations§
Source§impl EigshOptions
impl EigshOptions
Sourcepub fn new(eigenpairs: usize, target: SpectrumTarget) -> Self
pub fn new(eigenpairs: usize, target: SpectrumTarget) -> Self
Construct solver controls for an arbitrary spectral target.
Sourcepub fn smallest_algebraic(eigenpairs: usize) -> Self
pub fn smallest_algebraic(eigenpairs: usize) -> Self
Construct default controls for the algebraically lowest eigenpairs.
Sourcepub fn near_shift(eigenpairs: usize, shift: f64) -> Self
pub fn near_shift(eigenpairs: usize, shift: f64) -> Self
Construct default controls for eigenpairs nearest a real shift.
Sourcepub fn with_krylov_dimension(self, dimension: usize) -> Self
pub fn with_krylov_dimension(self, dimension: usize) -> Self
Set the optional Lanczos or restart window dimension.
Sourcepub fn with_tolerance(self, tolerance: f64) -> Self
pub fn with_tolerance(self, tolerance: f64) -> Self
Set the required residual norm.
Sourcepub fn with_max_iterations(self, max_iterations: usize) -> Self
pub fn with_max_iterations(self, max_iterations: usize) -> Self
Set the maximum Lanczos or restart iteration budget.
Trait Implementations§
Source§impl Clone for EigshOptions
impl Clone for EigshOptions
Source§fn clone(&self) -> EigshOptions
fn clone(&self) -> EigshOptions
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for EigshOptions
impl Debug for EigshOptions
Source§impl PartialEq for EigshOptions
impl PartialEq for EigshOptions
Source§fn eq(&self, other: &EigshOptions) -> bool
fn eq(&self, other: &EigshOptions) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for EigshOptions
Auto Trait Implementations§
impl Freeze for EigshOptions
impl RefUnwindSafe for EigshOptions
impl Send for EigshOptions
impl Sync for EigshOptions
impl Unpin for EigshOptions
impl UnsafeUnpin for EigshOptions
impl UnwindSafe for EigshOptions
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§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>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
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
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.