Abstract
Starting from a positive integer, repeatedly add the integer part of its -th root, where . For the orbit from one we find the first index and entry value at every power threshold. For all positive seeds we give an exact count of the initial values whose orbits meet. Two independent uniform starts up to meet with probability asymptotic to . For cubes we give a formula in the index alone with bounded absolute error. The normalized error has an explicit distribution under logarithmic averaging, while ordinary averages approach different values along different subsequences. For the leading oscillation has a periodic quadratic profile and admits an ordinary limiting distribution. We relate the square-root case to Witty's formula, the 1983 Putnam problem, and the recorded conjecture for the orbit from 19.
Editorial notes
Points the editor recorded on accepting the paper. They are published with the article; the authors were not required to address them before publication.
- In Section 6, add one sentence quantifying how slowly L_N approaches 15/8+1/ln2 (for example, the O(1/log N) effect of early terms), since the tabulated L_N values remain about 0.12 below the prediction at m=11.
- In Section 1 and reference [3], add an archived snapshot (for example, a web-archive URL) of the Berkeley OCF note, because the quoted sentence could not be checked by reviewers and personal pages are not permanent.
- In Section 2 and reference [6], confirm that OEIS A159016 is the square-array entry described, since round-2 reviewers checked A159021 but not A159016.
- In Section 6 under Table 1, state the floating-point precision used to accumulate the sums of Z_n/n and Z_n, so that readers can match the sixth decimal.
1. The square-root problem and the general passage law
Fix an integer . Index the orbit from one and write
For this is Exercise 3.28 of Graham, Knuth and Patashnik [1]. Their solution tracks the excess from one attained square to the next attained square . They credit Carl Witty with an explicit formula for the individual terms. The same orbit is recorded with offset zero as A002984. In A109965 our is the term with index , after an extra initial 1 [2]. The final paragraph of the Berkeley OCF note [3] defines for positive integral and states, “And as it iterates, the "excess" from a perfect decreases.” The note uses for the exponent. Here denotes the exponent and the level. Theorem 1 derives the precise decrement and the reset when the excess reaches zero. Our results use this observation to determine the index of every transition, the components for all seeds, and the scale and shape of the oscillations in the growth law. For , Grau Ribas recorded the leading asymptotic as a conjecture in A113768 [4]. Section 3 gives its short independent proof. All results are proved in the text.
For each put , , and let be if and otherwise. Define
Theorem 1 (first passages). Let be the first with . Then
For one has . In particular the attained -th powers are precisely for integers . The polynomial has degree .
Proof. Every step in has size . Suppose the first value is , . The interval width is . If , step is the first to cross the next threshold and leaves excess . If , step ends one short, and the following step leaves excess . In both cases the excess is less than , so the landing point belongs to the very next block. Initially at . If , then . If , then . Thus the new excess is always . Induction proves the entry and length formulas. Summation gives , since exactly powers of two are strictly below . Summing a degree polynomial of positive leading coefficient gives a polynomial of degree . The first value in a block equals its lower endpoint precisely at a dyadic level.
Corollary 1.1 (recovering a term from its index). For , let be the unique positive integer with . The true level is if , and otherwise. After this single comparison Theorem 1 evaluates directly with . In particular the cube recurrence has a closed form in the index alone, using
Proof. The true level is at most since . For , the binomial formula for gives . Therefore . For the true level is one. The remaining comparison is precisely the first-passage test at . Solving the quadratic inequality for gives the displayed expression.
Square roots and Witty’s formula. Here and . In our indexing Witty’s answer [1] is
To see the equivalence, put . For and , put and . If , then , and is zero or one. Substitution in Theorem 1 gives . The exceptional value gives with and , the third term of that dyadic block. Its value is . For the two indices are immediate. Thus the common dyadic mechanism already accounts for the classical answer.
2. Which starting values eventually meet?
For a positive seed write . Two seeds meet if some forward iterate of one equals some forward iterate of the other. The iterate counts may differ.
Theorem 2 (classification of all seeds). Put and , using a residue between and . The perfect -th powers strictly above in its orbit are precisely for . Two seeds meet exactly when and have the same odd part. For each odd the least member of its component is .
Proof. Steps in the initial block preserve the residue of modulo . The first entry above the next threshold, allowing equality, has excess between and , congruent to . This excess drops by one per subsequent level, so the first exact root above is . From an exact root the next entry excess is , and the next exact root is . The two lists of roots therefore intersect exactly when their odd parts agree. If the orbits meet, their common tail contains an exact power, proving the converse. Finally is strictly increasing and advances by one between consecutive inputs, except for a jump of two at each new root level. The positive integers missing from its image are and for . Every backward chain terminates at a missing integer because . For with the formula gives , while has odd part one. This proves the assertion about least members.
The square-root orbit from 19. The problem of showing that every positive square-root orbit meets a square appeared as Problem B4 of the 1983 Putnam competition [5]. The square-root chains beginning at are tabulated in OEIS A159016 [6]. In the row beginning at 19, Librandi recorded a conjecture specifying all the squares [6]. Here and . By Theorem 2 the squares are exactly for . This also follows by following the orbit to and applying the classical square-to-square argument [1].
Theorem 2.1 (a census of components). Write for the odd label of the seed in Theorem 2, and for the odd part of . Among the integers in , each odd label occurs times. Larger labels do not occur. Consequently the number with label strictly below is zero for , and otherwise equals
Proof. The block has elements. In each run of successive seeds, runs through . Taking odd parts maps this interval bijectively onto because each such odd number has exactly one dyadic multiple in . The final seed shares the residue of the first and has . Summing over levels through gives the polynomial difference and one extra seed at each , .
Corollary 2.2 (random seeds and coalescence). Take independently and uniformly from . As , uniformly for ,
The probability that their orbits eventually meet is
Thus for cubes the leading meeting probability is .
Proof. Put , , and let count the label up to and including . Count complete blocks strictly below and then the initial piece of block . The partial block adds at most seeds per label. Theorem 2.1 and therefore give, for ,
For the complete-block count is zero and the same estimate holds. All larger counts vanish. The logarithms contribute at most when summed, by comparison with the integral of on . Hence , including , and .
Write . The cutoff differs from by at most two integer indices. Summing the estimate for and using gives after normalization. Monotonicity gives a Riemann-sum error uniformly in the endpoint. This proves the distribution formula. By Theorem 2 and independence, the meeting probability equals . Replacing by in the sum of squares costs before normalization. The leading coefficient is therefore
The integral approximation contributes to the probability, and .
3. Leading growth and the higher-root correction
Proposition 3. For each fixed and every positive seed,
Proof. Write . Since and , the mean value theorem gives, for some ,
Averaging the increments gives . This proof uses only the recurrence. For cubes it proves the leading limit in [4].
The following correction and the rest of the paper concern the seed . For write
Theorem 4 (higher roots). Let be the continuous function of period one defined on by
Then, for each fixed ,
The set of subsequential limits of is exactly .
Proof. Write . Comparing the top three powers of in gives the leading coefficients of in descending degree. In detail they satisfy
Thus , since . Put in the -th block. Taking the -st root in the index formula shows that the entry has and the last term has . Here one may use ; the logarithm is included in this bound for . In particular is bounded uniformly. The term formula gives . Expand by the binomial theorem and divide by to obtain
uniformly in a block. The quadratic takes equal values at and , so replacing by its fractional part changes the right side by even at the ends. Consecutive values of in a block differ by . Every phase in is therefore a limit along some sequence of blocks. The quadratic has its maximum at , with rise from either endpoint.
Corollary 4.1 (frequency of the higher-root error). For every fixed , give the indices equal weight. The normalized error in Theorem 4 converges in distribution to , where is uniform on . Its distribution function at is for .
Proof. Over each full block the variable traverses an interval with endpoints and . Since , the derivative there is uniformly. The fraction of the block in any fixed subinterval of the phase therefore tends to the subinterval length. The final incomplete block has terms out of order , and the initial finitely many blocks have vanishing weight. This proves uniformity of the phase for the full sample. Apply Theorem 4 and use . Solving the quadratic inequality gives the stated distribution.
For example, . Its linear term dominates the dyadic term . For cubes is only quadratic. At the next scale its constant term and the dyadic rounding both affect the answer. We now resolve that case.
4. Cube intervals and sharp linear errors
Specialize to , write , and abbreviate , , . Theorem 1 becomes
Set , and . For we have and . Indeed and give .
Theorem 5 (sharp block profile). Uniformly for ,
This strengthens the bound . Equality in the sharper bound occurs at every , , for . Define and . Throughout the block,
The full limiting interval is . On dyadic levels it is . In particular is the optimal asymptotic uniform coefficient in an absolute bound.
Proof. Replace in using the displayed equation for and expand . This gives the identity. For the first parenthesis is at most and , so . Completing the square in the same identity gives
Since is even and strictly below , . This proves the sharp bound. For the indicated odd the stated index is integral and lies between zero and . Here and , giving equality. The exact relation
gives , and . This proves the profile. Every pair is a limiting pair. For take integers nearest to . For use , and for use . Within these blocks choose . Conversely and . The continuous profile therefore attains every limit between its extrema on the square. Setting gives the dyadic interval.
5. An index-only approximation for cubes
Define , , and the period-one function
The values of at agree, so is continuous and Lipschitz across integers as well as between them. Write for the residual left by the ordinary logarithmic expansion.
Theorem 6 (linear term and bounded remainder). On the cube block with parameters from Theorem 5,
Its full set of limits is
On dyadic levels the limiting interval is . Subtracting any constant multiple of leaves errors of order along some subsequence. With the oscillation included, a formula depending only on is
Proof. The exact identity of Theorem 5 gives
We have . The block profile follows by substituting the estimate for and using . The phase pairs fill the square as in Theorem 5. The minimum of on occurs at , and its maximum is one at both endpoints. The quadratic term ranges from to zero. This gives the stated intervals.
For the bounded remainder, replacing by in front of the bracket costs , and replacing by costs after multiplication by , by Lipschitz continuity. Put . The exact relation for and give : the difference is . Thus , giving even when the nearest integer changes. Completing the square gives
The last term tends to zero. Substitution proves the expansion uniformly.
Size of the final remainder. Even the displayed bounded-error formula has a residual that depends on position. Take and with . If , the actual term minus the displayed approximation tends to . In particular it tends to at the block midpoint.
Proof. The nearest integer to is eventually . On the right of , one has . Hence . Also . Subtract the approximation from the exact formula above and use the completed square. The limit is
This gives distinct limits for distinct interior choices of .
6. How often the cube errors occur
The limiting interval in Theorem 6 describes which errors occur. Their frequencies depend on how one samples the indices. Put , and . For define
Theorem 7 (distribution of the cube errors). Choose an index with probability , where . As , the pair converges in distribution to , where are independent uniform random variables on . In particular the logarithmic means of and are respectively and .
For uniform sampling of the index, fix , let , and take . The limiting law has the same formula with uniform and independent of , where is the fractional part and is exponential with rate . In particular
Since , the ordinary empirical distributions of have no single limit.
Proof. In a full block at level , the length is and the index is uniformly. The phase forms an equally spaced grid with mesh and upper endpoint . For any continuous test function of the two phases, averaging over a large block therefore averages its second argument uniformly, with error tending to zero uniformly in the first argument by uniform continuity. The test function may be evaluated at , since this changes by . Logarithmic weights have relative variation within a block, and its total unnormalized mass is .
Under these weights each dyadic range supplies one period of the first phase. For continuous on the Riemann sums give
The last incomplete dyadic range has bounded unnormalized mass. Averaging over the complete ranges proves joint convergence to the two independent uniforms. The uniform profile estimates in Theorems 5 and 6 transfer it to . Both residuals are bounded after normalization. Their means follow from and .
For ordinary weights take . A block has mass with . Thus tends in distribution to a random with density on . The first phase is , so it converges to . To justify the rounding at integers, discard , of asymptotic mass . On the limiting phase has finitely many jumps, which have zero mass. Riemann sums on the remaining intervals converge. The within-block averaging again gives independence from . Since for , this proves the claimed law.
For the mean, reduced modulo one has density on . Integrating on either side of gives . Also . Thus . Substitution gives . The two different limiting means preclude weak convergence because is bounded.
Numerical illustration of Theorem 7. Starting at , we iterated the recurrence using integer cube thresholds. For each with , we computed the two prefix means
Table 1. The common prediction for is to six decimals. The last column gives the prediction for at each cutoff phase.
| 8 | 98,693 | 3.153718 | 3.359780 | 3.320319 | |
| 8 | 49,418 | 3.141867 | 3.366219 | 3.315413 | |
| 11 | 6,294,536 | 3.198872 | 3.328170 | 3.320319 | |
| 11 | 3,147,236 | 3.193224 | 3.325896 | 3.315413 |
For reproducibility, write and . We evaluated
This is the original residual divided by , with the difference rationalized. The numerator is computed in integer arithmetic. Sum , , and from the first term through to recover the table. The logarithmic average retains appreciable weight on the early terms at these cutoffs. The two ordinary means change order between and , illustrating why finite samples alone cannot establish the distinct limits.
References
- [1] R. L. Graham, D. E. Knuth and O. Patashnik. Concrete Mathematics: A Foundation for Computer Science, second edition. Addison-Wesley, 1994. Exercise 3.28, p. 97, and solution crediting Carl Witty, p. 509. Authors’ book page.
- [2] OEIS Foundation. A002984 and A109965. The latter entry points to Exercise 3.28 and explains the extra initial term.
- [3] Integer plus its square root. Berkeley Open Computing Facility, bslin personal notes, last edited 20 September 2022. See the final paragraph immediately following the square-root hint. Original note.
- [4] Jonathan Vos Post. A113768, The On-Line Encyclopedia of Integer Sequences, 2006. Leading asymptotic conjecture contributed by José María Grau Ribas, 13 February 2024.
- [5] L. F. Klosinski, G. L. Alexanderson and A. P. Hillman. The William Lowell Putnam Mathematical Competition. American Mathematical Monthly 91 (1984), 487–495. See 1983 Problem B4 and its solution. Published competition report.
- [6] OEIS Foundation. A159016, square array of the square-root chains, and A159021, the orbit from 19. The latter records Vincenzo Librandi's square conjecture dated 10 April 2009.
AI disclosure
OpenAI’s ChatGPT Codex developed the arguments, implemented the numerical examples, and drafted the paper and revision at Luke Hellum’s request.