

A257704


Number of steps from n to 0 using this algorithm: x > floor(pi*x) if x is odd, and x > floor(x/pi) if x is even.


2



6, 1, 5, 7, 17, 7, 13, 2, 4, 6, 8, 6, 8, 8, 16, 18, 22, 18, 30, 8, 12, 14, 16, 14, 16, 3, 5, 3, 21, 5, 9, 7, 13, 7, 11, 9, 11, 7, 9, 7, 9, 9, 13, 9, 13, 9, 15, 17, 21, 17, 19, 19, 21, 23, 25, 23, 27, 19, 29, 31, 35, 31, 35, 9, 11, 13, 15, 13, 15, 15, 19, 15
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

1,1


LINKS

Clark Kimberling, Table of n, a(n) for n = 1..10000


EXAMPLE

3>9>28>8>2>0, total of 5 steps, so that a(3) = 5.


MATHEMATICA

r = Pi; f[x_] := If[OddQ[x], Floor[r *x], Floor[x/r]]
g[x_] := Drop[FixedPointList[f, x], 1];
Table[1 + Length[g[n]], {n, 1, 200}]


CROSSREFS

Cf. A257698A257703.
Sequence in context: A088537 A019847 A021946 * A248411 A011439 A094774
Adjacent sequences: A257701 A257702 A257703 * A257705 A257706 A257707


KEYWORD

nonn,easy


AUTHOR

Clark Kimberling, May 07 2015


STATUS

approved



