login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A073047 Least k such that x(k)=0 where x(1)=n and x(k)=k*floor(x(k-1)/k). 4
2, 3, 3, 4, 4, 5, 5, 5, 5, 6, 6, 7, 7, 7, 7, 7, 7, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 16, 16 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,1
COMMENTS
Length of n-th run of consecutive identical terms is given by A028913 - Ralf Stephan.
LINKS
FORMULA
Presumably a(n) = sqrt(Pi*n)+O(1).
EXAMPLE
If x(1)=4, x(2)= 2*floor(4/2)=4, x(3)=3*floor(4/3)=3; x(4)=4*floor(3/4)=0 hence a(4)=4.
MAPLE
f:= proc(n, k) option remember;
if n = 0 then return k-1 fi;
procname(k*floor(n/k), k+1)
end proc:
map(f, [$1..100], 1); # Robert Israel, Jul 25 2019
MATHEMATICA
a[n_] := Module[{x}, x[1] = n; x[k_] := x[k] = k Floor[x[k-1]/k]; For[k = 1, True, k++, If[x[k] == 0, Return[k]]]];
Array[a, 100] (* Jean-François Alcover, Jun 07 2020 *)
PROG
(PARI) a(n)=if(n<0, 0, s=n; c=1; while(s-s%c>0, s=s-s%c; c++); c)
CROSSREFS
Sequence in context: A341053 A126236 A198194 * A038567 A185195 A192512
KEYWORD
easy,nonn
AUTHOR
Benoit Cloitre, Aug 31 2002; revised May 03 2003
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 23 03:30 EDT 2024. Contains 371906 sequences. (Running on oeis4.)