Published Updated
python-flint merges a repair that preserves decimal error bounds
python-flint merged the reported constructor repair and regression tests, preserving midpoint uncertainty when tuple radii are added to inexact decimal inputs.
A bound that no longer contains its input
Interval arithmetic represents a number together with a bound on its error. In python-flint, constructing that interval with a tuple-form radius can erase the error introduced while converting an ordinary decimal such as 0.1. The result is marked exact even though it misses the exact value 1/10.
Tasuku Kobayashi submitted python-flint issue #448 on November 9, 2026. python-flint merged repair PR #449 on November 10 and closed the issue. The fix is in development source; a release is pending.
The same radius, a different guarantee
The constructor accepts a tuple (a, b) as the exact value a × 2**b. Thus 0 and (0, 0) are the same additional radius. At 53-bit precision, their results differ:
| Construction | Contains exact 1/10? | Reported error bound |
|---|---|---|
arb("0.1", 0) | Yes | Includes conversion uncertainty |
arb("0.1", (0, 0)) | No | Zero |
In the second row, the stored midpoint differs from 1/10 by exactly 1/180143985094819840, but its radius is zero. A nonzero example also fails: arb("0.1", (1, -2)) does not enclose the complete requested interval 1/10 ± 1/4. Passing the same radius as 0.25 preserves the interval.
The check reconstructs the stored binary midpoint and radius using Python’s exact Fraction arithmetic. It compares them with the exact requested value or interval, without rounding the reference to another arb or relying on displayed decimal digits.
The tuple-zero failure reproduces for seven decimal or rational inputs at five precisions, from 10 to 200 bits: all 35 combinations fail. The integer-zero control preserves the enclosure in every case. python-flint 0.7.1 behaves correctly; 0.8.0, 0.9.0 and main at 67ec567 exhibit the regression. The recorded runs used CPython 3.12.14 on Linux x86_64.
The reported repair is now merged upstream
The affected tuple branch assigned the radius directly, replacing uncertainty already present in an inexact midpoint. The merged repair keeps direct assignment for exact midpoints and uses the existing error-addition path otherwise. This preserves conversion uncertainty while retaining exact tuple radii for representation and pickling.
Merge commit d9d8cce includes regression coverage for decimal midpoints and already-inexactarb values. It matches the repair direction and test cases supplied in the report. The current released versions 0.8.0 and 0.9.0 remain affected; the project lists 0.10.0 as not yet released.
Increasing working precision alone does not solve the tuple-zero case: a non-dyadic value such as 1/10 still needs a rounding-error bound at finite precision. Until a release contains the fix, passing the radius as an arb, for example arb(mid, arb(radius_tuple)), preserves the required uncertainty.
The public upstream report contains the full reproducer, exact reference, outputs, version comparison and workaround. The investigation establishes this constructor regression; it does not measure its frequency in user workloads or establish a SciGround production incident.