Exact widening of posit words #
Appending zero bits preserves the decoded value, including zero and NaR, whenever the
destination is at least as wide as the source. For finite inputs, rounding the exact source
value at the destination therefore produces precisely that extended word.
The proof iterates the decoder's one-bit precision identity; neither the storage backend nor particular widths enter the argument.
References #
- Posit Standard (2022), §6.1.
theorem
FloatLib.Floats.Formats.Posit.Model.nonnegativeRatAt_widen
(source target : Format)
(hwidth : source.bits ≤ target.bits)
{code : ℕ}
(hcode : code < source.signMaskNat)
:
Any number of appended zero bits preserves a nonnegative finite decoded value.