NLAlib.SmallEig.decoupleLast_writes_scans
Library · theorem
This statement changed in the recorded rename: 2026-11-schur.
Standard rounding
NLAlib.SmallEig.decoupleLast with its scan history, on a scalar machine with the standard model at 0 \le \boldsymbol{u}, (n + 2)\boldsymbol{u} \le 1/2500, index literals, exact natural literals up to n + 2 and exact comparisons: from NLAlib.SmallEig.DecoupleInput with an upper Hessenberg \mathbf{H} of order n + 2, the shift \lambda and at least eight words, on every tape, it writes only the matrix and the flag and, for some \ell \le m_2, stores the end \widehat{\mathbf{H}}_\ell (upper Hessenberg) of ends \widehat{\mathbf{H}}_k, k \le \ell, of backward-stable chains (relative error 300(n + 2)^2\boldsymbol{u}) of k steps with the shift \lambda whose scans failed for k < \ell, t_L < (1 + \boldsymbol{u})^2\lvert h_k\rvert^2 (t_L = qs[7], h_k the last subdiagonal entry); and the flag 0 with (1 - \boldsymbol{u})^2\lvert h_\ell\rvert^2 \le t_L, or the flag 1 at \ell = m_2 with t_L < (1 + \boldsymbol{u})^2\lvert h_\ell\rvert^2.
Shared by the trees of NLAlib.ShiftedQR.shqrSmallEigRoutine and NLAlib.SmallEig.smallEigRoutine, on their scratch.
NLAlib.SmallEig.decoupleLast_writes_scans {O Q : Type} [Ops.Has Ops.ScalarOp O]
[Ops.Has Ops.IndexOp O] [Ops.Has Ops.CmpTst Q] {M : Ops.Machine ℝ} {I : Ops.Interp O Q ℝ} {u : ℝ}
(hS : Ops.IsScalar M I) (hM : Ops.StdModel u id M) (hu : 0 ≤ u) (hL : Ops.IsIndexLit M I)
(hC : Ops.IsCmp id I) {n m₂ : ℕ} (hNat : Ops.IsExactNatLit id M (n + 2))
(hnu : (↑n + 2) * u ≤ 1 / 2500) {H : Matrix (Fin (n + 2)) (Fin (n + 2)) ℂ} {ζ : ℂ} {qs : List ℝ}
(hqs : 8 ≤ qs.length) (hH : IsUpperHessenberg H) {τ : Ops.Tape ℝ} {μ : Ops.Mem ℝ}
{h lam qw f : ℕ × ℕ} (hin : SmallEig.DecoupleInput H ζ qs h lam qw f μ) {ns w : ℕ} {lg : ℕ × ℕ}
{LL : List (Option (List GivensEntry))} (hlog : HoldsSlottedLog lg ns w LL [] μ.store)
(hj : LL.length + m₂ ≤ ns) (hw : n + 1 ≤ w) (hlgl : μ.Live [lg])
(hlgb : ∀ b ∈ [h, lam, qw, f], b.1 ≠ lg.1) :
Ops.Writes Ops.Mode.total I τ SmallEig.decoupleLast
(Ops.Env.frame [n + 2, m₂, w, LL.length] [h, lam, qw, h, f, lg])
(Ops.Store.inBlock h.1 h.2 (2 * ((n + 2) * (n + 2))) ⊔ Ops.Store.inBlock f.1 f.2 1 ⊔
Ops.Store.inBlock lg.1 lg.2 (ns * (1 + 5 * w)))
(fun μ' ↦
∃ ℓ Hs,
ℓ ≤ m₂ ∧
(∀ k ≤ ℓ,
∃ Rs, IsStableQRChain (300 * (↑n + 2) ^ 2 * u) H (List.replicate k ζ) (Hs k) Rs) ∧
(∀ k < ℓ,
qs.getD 7 0 < (1 + u) ^ 2 * ‖Hs k (Fin.last (n + 1)) (Fin.last n).castSucc‖ ^ 2) ∧
IsUpperHessenberg (Hs ℓ) ∧
HoldsMatrix h (Hs ℓ) μ'.store ∧
(μ'.store.get f.1 f.2 = some 0 ∧
(1 - u) ^ 2 * ‖Hs ℓ (Fin.last (n + 1)) (Fin.last n).castSucc‖ ^ 2 ≤
qs.getD 7 0 ∨
μ'.store.get f.1 f.2 = some 1 ∧
ℓ = m₂ ∧
qs.getD 7 0 <
(1 + u) ^ 2 * ‖Hs ℓ (Fin.last (n + 1)) (Fin.last n).castSucc‖ ^ 2) ∧
∃ Ls,
Ls.length ≤ m₂ ∧
(∀ x ∈ slotEntries w Ls, x.1 + 1 < n + 2) ∧
HoldsSlottedLog lg ns w (LL ++ Ls) [] μ'.store)
μImport NLAlib.Eigensolvers.SmallEig.Decouple.