Skip to main content

Engine

Struct Engine 

Source
struct Engine<T: Real> {
    m: usize,
    n: usize,
    ncv: usize,
    p: Vec<T>,
    u: Vec<T>,
    b: DenseBlock<T>,
    beta_last: T,
    nl: usize,
    sigma_est: T,
    rng: Rng,
    stats: SvdStats,
}
Expand description

The state of Algorithm B.

Fields§

§m: usize§n: usize§ncv: usize§p: Vec<T>

P, n × (ncv + 1).

§u: Vec<T>

U, m × ncv.

§b: DenseBlock<T>

B, ncv × ncv.

§beta_last: T

β_ncv.

§nl: usize

Locked count n_L.

§sigma_est: T

σ̃_est.

§rng: Rng§stats: SvdStats

Implementations§

Source§

impl<T: Real> Engine<T>

Source

fn expand_from<O: AdjointOperator<T> + ?Sized>( &mut self, op: &mut O, from: usize, eta: T, ) -> Result<(), StatlaError>

Steps B2–B3 for j = from, …, ncv − 1 (0-based).

Source

fn active_block(&self) -> DenseBlock<T>

The active block B[nl.., nl..].

Source

fn ritz(&self, coef: &DenseBlock<T>, c: usize, left: bool) -> Vec<T>

The active Ritz vector U_act X e_c (left) or P_act Y e_c.

Source

fn arrowhead_shape(&self, kp: usize) -> bool

(G3), debug builds, right after a restart to k′ = kp: the locked and kept rows are zero off the diagonal except the spike column kp (and the locked rows are zero there too), nothing beyond kp.

Source

fn orthogonality(&self, j: usize) -> f64

(G1), debug builds: orthonormality of P_{j+1} and U_j.

Auto Trait Implementations§

§

impl<T> Freeze for Engine<T>
where T: Freeze,

§

impl<T> RefUnwindSafe for Engine<T>
where T: RefUnwindSafe,

§

impl<T> Send for Engine<T>
where T: Send,

§

impl<T> Sync for Engine<T>
where T: Sync,

§

impl<T> Unpin for Engine<T>
where T: Unpin,

§

impl<T> UnsafeUnpin for Engine<T>
where T: UnsafeUnpin,

§

impl<T> UnwindSafe for Engine<T>
where T: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.