lemmaroutine

Finite buffered comparison test for sums

Finite test accepts every s>2us>2u and only s>us>u, with O(d)O(d) digits
fixed-precision comparison for the numerical interface
Lemma·lem:arith-buffered-test·§10.5 Indexed ranks, sums, scales, and structural leaves

Statement (paper)

Let d≥1d\geq1, let ss and uu have known magnitude bound 2κd2^{\kappa d}, and suppose u≥ρ≥2−κdu\geq\rho\geq2^{-\kappa d}. There is a deterministic finite test that accepts every s>2us>2u and accepts only s>us>u. It uses O(d)O(d)-place digit queries after normalization, with intrinsic and suspended local lengths O(d)O(d). Its result is independent of any subsequent numerical output clock.

In plain English

For ss and uu with known magnitude bound 2κd2^{\kappa d} and u≥ρ≥2−κdu\geq\rho\geq2^{-\kappa d}, there is a deterministic finite test that accepts every s>2us>2u and accepts only s>us>u. It uses O(d)O(d)-place digit queries after normalization, has intrinsic and suspended local lengths O(d)O(d), and its outcome does not depend on any later numerical output clock.

Why it's here

This gives a comparison with a factor-two buffer: inputs clearly above 2u2u are accepted, inputs at or below uu are rejected, and the gap in between may go either way. Because uu is bounded below by 2−κd2^{-\kappa d}, finitely many digits suffice to decide, so the test can be used inside the numerical interface at fixed precision without depending on output clocks. It supplies the buffered tests that the uniform numerical interface relies on.
Classified routine:
A standard approximate-comparison argument: since u is bounded below by 2^{-κd} and the factor-two gap is wide, truncating s and u to O(d) binary places and comparing the approximations decides the buffered comparison. The only new part is the bookkeeping of the paper's own length and clock accounting.

Sources

PaperOpen
Section
§10.5 Indexed ranks, sums, scales, and structural leaves
Page
—
Label
lem:arith-buffered-test
Line
sections/arithmetic.tex:698
Leannot aligned

Phase 2 aligns this node to a Lean declaration.