TorchLean API

FloatLib.Floats.Formats.IEEE754.Native.Integer.Constructors

Arbitrary integer constructors #

Lean exposes the definitions of Float.ofNat, Float.ofInt, and their binary32 counterparts on top of its logical floating-point models. The arbitrary-integer casts use these constructors, whose scientific-literal path has a small-input fast path. The proofs here cover both branches before applying the shared integer conversion specification.

Moving exact trailing binary zeros into the exponent does not change model rounding.

A scientific literal with decimal exponent zero is the shared natural-number constructor.