cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A070976 Number of steps to reach 1 in '3x+1' (or Collatz) problem starting with 3^n.

This page as a plain text file.
%I A070976 #28 Dec 25 2016 00:47:04
%S A070976 0,7,19,111,22,96,33,76,75,43,135,134,133,132,144,205,129,190,140,95,
%T A070976 94,261,428,91,258,394,331,255,254,390,389,388,462,461,460,459,458,
%U A070976 457,456,455,454,453,501,500,450,498,497,752,495,494,493,748,491,746,489
%N A070976 Number of steps to reach 1 in '3x+1' (or Collatz) problem starting with 3^n.
%C A070976 For all n, it appears that a(n) <= 37n. For n > 22, it appears that a(n) < 16n. - _T. D. Noe_, Feb 02 2007
%C A070976 This sequence contains some unusually long runs of values that differ by 1. - _Dmitry Kamenetsky_, Dec 09 2016
%H A070976 T. D. Noe, <a href="/A070976/b070976.txt">Table of n, a(n) for n = 0..2000</a>
%F A070976 a(n) = A075487(n+1) = A074472(n) + 1. - _T. D. Noe_, Feb 02 2007
%e A070976 For n=4, 3^4 = 81, and the Collatz sequence (3x + 1 if odd, x/2 if even) goes 81, 244, 122, 61, 184, 92, 46, 23, 70, 35, 106, 53, 160, 80, 40, 20, 10, 5, 16, 8, 4, 2, 1.  This is 22 steps, so a(4) = 22. - _Michael B. Porter_, Dec 15 2016
%t A070976 Table[Length[NestWhileList[If[EvenQ[#],#/2,3#+1]&,3^n,#>1&]]-1, {n,0,60}] (* _Harvey P. Dale_, Oct 13 2011 *)
%o A070976 (PARI) for(n=2,100,s=3^n; t=0; while(s!=1,t++; if(s%2==0,s=s/2,s=3*s+1); if(s==1,print1(t,","); ); ))
%Y A070976 Cf. A279269, A277109. Equals A006577(3^n).
%K A070976 easy,nonn
%O A070976 0,2
%A A070976 _Benoit Cloitre_, May 17 2002