This site is supported by donations to The OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A076182 a(n) = A006666(n) mod 2. 2

%I

%S 0,1,1,0,0,0,1,1,1,1,0,1,1,0,0,0,1,0,0,0,0,1,1,0,0,0,0,1,1,1,1,1,0,0,

%T 0,1,1,1,1,1,1,1,0,0,0,0,0,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0,0,1,1,1,1,

%U 1,1,1,0,1,0,1,0,0,0,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,0,1,0,0,0,0,0,0,0,0

%N a(n) = A006666(n) mod 2.

%H Antti Karttunen, <a href="/A076182/b076182.txt">Table of n, a(n) for n = 1..10000</a>

%H <a href="/index/3#3x1">Index entries for sequences related to 3x+1 (or Collatz) problem</a>

%H <a href="/index/Ch#char_fns">Index entries for characteristic functions</a>

%F a(n) = A006513(n) - 1.

%F Apparently also the antiparity of A064433. - _Ralf Stephan_, Nov 16 2004

%o (PARI) a(n)=if(n<0,0,s=n; c=0; while(s>1,s=(s%2)*(3*s+1)/2+(1-s%2)*s/2; c++); c)%2

%o (Scheme)

%o (define (A076182 n) (modulo (A006666 n) 2))

%o (definec (A006666 n) (if (= 1 n) 0 (+ 1 (A006666 (A014682 n))))) ;; With memoization-macro definec

%o (define (A014682 n) (if (even? n) (/ n 2) (/ (+ n n n 1) 2)))

%o ;; _Antti Karttunen_, Aug 13 2017

%Y Cf. A014682, A006513, A006666, A076092.

%K nonn

%O 1,1

%A _Benoit Cloitre_, Nov 01 2002

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

Last modified February 17 19:37 EST 2019. Contains 320223 sequences. (Running on oeis4.)