NLA-lib Explorer

Float.Model.UnpackedFloat.abs_toReal_mul_sub_le

Library · theorem

A finite unpacked product of canonical operands has relative allowance 2^{-p} and absolute allowance 2^{e_{\min}}/2, where p is the precision and e_{\min} the smallest significand exponent. The format has at least two exponent bits; packing is separate.

Float.Model.UnpackedFloat.abs_toReal_mul_sub_le {spec : Float.Model.Format}
  [Fact (2 ≤ spec.exponentBits)] (x y : Float.Model.UnpackedFloat)
  (hx : Float.Model.UnpackedFloat.IsCanonical spec x)
  (hy : Float.Model.UnpackedFloat.IsCanonical spec y)
  (h : (Float.Model.UnpackedFloat.mul spec x y).IsFinite) :
  |(Float.Model.UnpackedFloat.mul spec x y).toReal - x.toReal * y.toReal| ≤
    spec.unitRoundoff * |x.toReal * y.toReal| + spec.underflowBound

Full source on GitHub

Import NLAlib.ForMathlib.Data.Float.Operations.