login
A087669
The smallest index m such that b(m) is an integer, where b(0)=(2n+1)/n and b(k+1)=b(k)*floor(b(k)) for k>=0.
4
0, 1, 3, 2, 5, 4, 5, 2, 4, 9, 19, 7, 16, 7, 8, 3, 27, 9, 5, 25, 10, 11, 32, 4, 13, 4, 17, 6, 17, 6, 78, 3, 23, 47, 13, 6, 4, 6, 27, 9, 20, 6, 4, 17, 9, 28, 106, 4, 24, 28, 37, 20, 27, 10, 12, 13, 7, 83, 108, 10, 16, 9, 6, 3, 10, 11, 15, 8, 11, 6, 156, 15, 38, 46, 7
OFFSET
1,3
COMMENTS
It is conjectured that an integer is always reached if the initial value is >= 2.
LINKS
J. C. Lagarias and N. J. A. Sloane, Approximate squaring (pdf, ps), Experimental Math., 13 (2004), 113-128.
MAPLE
A087669 := proc(n) local b, stps ; stps := 0 ; b := (2*n+1)/n ; while not type(b, 'integer') do b := b*floor(b) ; stps := stps+1 ; od ; RETURN(stps) ; end: for n from 1 to 100 do print(n, A087669(n)) ; od ; # R. J. Mathar, Feb 12 2007
PROG
(Python)
def A087669(n):
c, x = 0, 2*n+1
a, b = divmod(x, n)
while b != 0:
x *= a
c += 1
a, b = divmod(x, n)
return c # Chai Wah Wu, Mar 01 2021
CROSSREFS
The records and their indices are given by A192230 and A192229.
Cf. A087670 (integer reached), A087666.
Sequence in context: A292776 A061313 A259846 * A053087 A316519 A062327
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, Sep 27 2003
EXTENSIONS
More terms from R. J. Mathar, Feb 12 2007
Terms a(23) onward from Max Alekseyev, Jun 25 2011
STATUS
approved