NLA-lib Explorer

NLAlib.ShiftedQR.indexNat_writes

Library · theorem

Exact arithmetic

An actual dimension-literal operation stores the natural as an exact real word. The rule for one call of the operation.

NLAlib.ShiftedQR.indexNat_writes {Op Tst : Type} [Ops.Has Ops.IndexOp Op] {M : Ops.Machine ℝ}
  {I : Ops.Interp Op Tst ℝ} (hL : Ops.IsIndexLit M I) (hE : Ops.ExactModel id M) {τ : Ops.Tape ℝ}
  {m : Ops.Mem ℝ} {ρ : Ops.Env} {e : Ops.IExp} {out : Ops.Operand} {n : ℕ} {z : ℕ × ℕ}
  (he : Ops.IExp.eval ρ.idx e = some n) (ho : Ops.Operand.eval ρ out = some z)
  (hz : z.2 < m.store.len z.1) :
  Ops.Writes Ops.Mode.total I τ (Ops.Stmt.call (Ops.Has.inj Ops.IndexOp.lit) [e] [] [out]) ρ
    (Ops.Store.inBlock z.1 z.2 1) (fun m' ↦ m'.pos = m.pos ∧ m'.store.get z.1 z.2 = some ↑n) m

Full source on GitHub

Import NLAlib.Eigensolvers.ShiftedQR.FindRitzRegisters.