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!)
A353305 The smallest number reached after n when iterating map x -> A353313(x) and starting from x=n, or -1 if no finite cycle is ever reached. 3
0, 1, 5, 1, 1, 5, 2, 14, 5, 1, 5, 20, 1, 5, 25, 5, 16, 5, 2, 5, 20, 7, 5, 23, 5, 25, 5, 1, 28, 16, 5, 2, 5, 11, 5, 20, 1, 11, 5, 5, 23, 20, 14, 20, 25, 5, 25, 5, 16, 28, 16, 5, 16, 5, 2, 5, 16, 5, 11, 5, 20, 5, 20, 7, 11, 5, 5, 5, 16, 23, 20, 23, 5, 5, 20, 25, 20, 5, 5, 25, 5, 1, 5, 5, 28, 16, 20, 16, 20, 16, 5, 5 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,3
LINKS
EXAMPLE
Starting from n=2 and iterating A353313, we obtain the following 104 terms [2, 5, 10, 19, 34, 59, 100, 169, 284, 475, 794, 1325, 2210, 3685, 6144, 2048, 3415, 5694, 1898, 3165, 1055, 1760, 2935, 4894, 8159, 13600, 22669, 37784, 62975, 104960, 174935, 291560, 485935, 809894, 1349825, 2249710, 3749519, 6249200, 10415335, 17358894, 5786298, 1928766, 642922, 1071539, 1785900, 595300, 992169, 330723, 110241, 36747, 12249, 4083, 1361, 2270, 3785, 6310, 10519, 17534, 29225, 48710, 81185, 135310, 225519, 75173, 125290, 208819, 348034, 580059, 193353, 64451, 107420, 179035, 298394, 497325, 165775, 276294, 92098, 153499, 255834, 85278, 28426, 47379, 15793, 26324, 43875, 14625, 4875, 1625, 2710, 4519, 7534, 12559, 20934, 6978, 2326, 3879, 1293, 431, 720, 240, 80, 135, 45, 15] before the iteration returns to 5 again, thus after the initial 2, 5 is the smallest number encountered, therefore a(2) = 5.
PROG
(PARI)
A353313(n) = { my(r=(n%3)); if(!r, n/3, ((5*((n-r)/3)) + r + 3)); };
A353305(n) = { my(visited = Map(), m=0); for(j=1, oo, n = A353313(n); if(!m, m=n, m=min(m, n)); if(mapisdefined(visited, n), return(m), mapput(visited, n, j))); };
CROSSREFS
Cf. A353306 (positions of 1's), A353313.
Sequence in context: A131777 A323388 A260877 * A237888 A286462 A046607
KEYWORD
nonn
AUTHOR
Antti Karttunen, Apr 13 2022
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 August 15 11:39 EDT 2024. Contains 375173 sequences. (Running on oeis4.)