The OEIS mourns the passing of Jim Simons and is grateful to the Simons Foundation for its support of research in many branches of science, including the OEIS.
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!)
A275748 Number of Fibonacci numbers in {n, f(n), f(f(n)), ...., 1}, where f is the Collatz function. 0
1, 2, 5, 2, 4, 5, 6, 3, 6, 4, 6, 5, 5, 6, 4, 3, 5, 6, 6, 4, 4, 6, 4, 5, 6, 5, 6, 6, 6, 4, 6, 3, 6, 6, 4, 6, 6, 6, 7, 4, 6, 4, 6, 6, 6, 4, 6, 5, 6, 6, 6, 5, 4, 6, 7, 6, 6, 6, 7, 4, 4, 6, 6, 3, 6, 6, 6, 6, 5, 4, 6, 6, 7, 6, 3, 6, 6, 7, 6, 4, 4, 6, 6, 4, 3, 6, 6, 6, 7, 6, 6, 4, 4, 6, 6, 5, 7, 6, 6, 6 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
Or number of Fibonacci numbers in the trajectory of n under the 3x+1 map (i.e. the number of Fibonacci numbers until the trajectory reaches 1).
LINKS
EXAMPLE
The finite sequence n, f(n), f(f(n)), ...., 1 for n = 9 is: 9, 28, 14, 7, 22, 11, 34, 17, 52, 26, 13, 40, 20, 10, 5, 16, 8, 4, 2, 1 which has six Fibonacci numbers {1, 2, 5, 8, 13, 34}. Hence a(9) = 6.
MATHEMATICA
s = Fibonacci /@ Range@ 20; Table[Length@ Select[Union@ NestWhileList[If[EvenQ@ #, #/2, 3 # + 1] &, n, # != 1 &], MemberQ[s, #] &], {n, 120}] (* Michael De Vlieger, Aug 07 2016 *)
PROG
(PARI) print1(1, ", "); for(n=2, 100, s=n; t=1; while(s!=1, if(issquare(5*s^2+4) ||issquare(5*s^2-4), t++, t=t); if(s%2==0, s=s/2, s=(3*s+1)); if(s==1, print1(t, ", "); ); ))
CROSSREFS
Cf. A006577.
Sequence in context: A187788 A085072 A077200 * A216625 A122581 A151871
KEYWORD
nonn,easy
AUTHOR
Michel Lagneau, Aug 07 2016
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 May 28 18:29 EDT 2024. Contains 372919 sequences. (Running on oeis4.)