NLAlib.ShiftedQR.findRitzChoice_writes
Library · theorem
Exact arithmetic
The actual comparison keeps the first half on a tie and otherwise moves its start. [BanksGarzaVargasSrivastava2021, §4.3]. Shared by the trees of NLAlib.ShiftedQR.scalarDecouple and NLAlib.ShiftedQR.shqrSmallEigRoutine, on their scratch.
NLAlib.ShiftedQR.findRitzChoice_writes {Op Tst : Type} [Ops.Has Ops.IndexOp Op]
[Ops.Has Ops.CmpTst Tst] {M : Ops.Machine ℝ} {I : Ops.Interp Op Tst ℝ} (hL : Ops.IsIndexLit M I)
(hE : Ops.ExactModel id M) (hCmp : Ops.IsCmp id I) {τ : Ops.Tape ℝ} {m : Ops.Mem ℝ} {a h : ℕ}
{r : ℕ × ℕ} {left right : ℝ} (ha : m.store.get r.1 r.2 = some ↑a)
(hl : m.store.get r.1 (r.2 + 3) = some left) (hr : m.store.get r.1 (r.2 + 4) = some right) :
Ops.Writes Ops.Mode.total I τ ShiftedQR.findRitzChoice (Ops.Env.frame [a, h] [r, r])
(Ops.Store.inBlock r.1 r.2 1)
(fun m' ↦ m'.pos = m.pos ∧ m'.store.get r.1 r.2 = some ↑(if right ≤ left then a else a + h)) mImport NLAlib.Eigensolvers.ShiftedQR.FindRitzDecision.