NLA-lib Explorer

NLAlib.Ops.StdModel.abs_add_sub_le

Library · theorem

Standard rounding

One rounded addition of two approximate sums: if a, b approximate S₁, S₂ up to e relative to T₁, T₂, their rounded sum approximates S₁ + S₂ up to (1 + u) (1 + e) - 1 relative to T₁ + T₂.

NLAlib.Ops.StdModel.abs_add_sub_le {K : Type} {u : ℝ} {dec : K → ℝ} {M : Ops.Machine K}
  (hM : Ops.StdModel u dec M) (hu : 0 ≤ u) {a b : K} {S₁ S₂ T₁ T₂ e : ℝ}
  (h1 : |dec a - S₁| ≤ e * T₁) (h2 : |dec b - S₂| ≤ e * T₂) (hS₁ : |S₁| ≤ T₁) (hS₂ : |S₂| ≤ T₂) :
  |dec (M.add a b) - (S₁ + S₂)| ≤ ((1 + u) * (1 + e) - 1) * (T₁ + T₂)

Full source on GitHub

Import NLAlib.Ops.Blas.Sum.