NLA-lib Explorer

Float.Model.UnpackedFloat.isNearestFloat_toReal_normalize

Library · theorem

normalize returns a nearest float of the exact value M · 2^e.

Float.Model.UnpackedFloat.isNearestFloat_toReal_normalize {spec : Float.Model.Format} (M e : ℤ)
  (zs : Float.Model.UnpackedFloat.Sign) (he : spec.minExponent ≤ e) :
  Float.Model.BinaryRounding.IsNearestFloat spec.mantissaBits spec.minExponent (↑M * 2 ^ e)
    (Float.Model.UnpackedFloat.normalize spec M e zs).toReal

Full source on GitHub

Import NLAlib.ForMathlib.Data.Float.Operations.