This site is supported by donations to The OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A100672 Second least-significant bit in the binary expansion of the n-th prime. 6
 1, 1, 0, 1, 1, 0, 0, 1, 1, 0, 1, 0, 0, 1, 1, 0, 1, 0, 1, 1, 0, 1, 1, 0, 0, 0, 1, 1, 0, 0, 1, 1, 0, 1, 0, 1, 0, 1, 1, 0, 1, 0, 1, 0, 0, 1, 1, 1, 1, 0, 0, 1, 0, 1, 0, 1, 0, 1, 0, 0, 1, 0, 1, 1, 0, 0, 1, 0, 1, 0, 0, 1, 1, 0, 1, 1, 0, 0, 0, 0, 1, 0, 1, 0, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0, 1, 0, 1, 0, 1 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,1 COMMENTS a(n)=1 iff prime(n) is a member of A045326 (equivalently for n>1, iff prime(n)-3 is divisible by 4). LINKS Eric Weisstein's World of Mathematics, Fermat's 4n Plus 1 Theorem. Eric Weisstein's World of Mathematics, Gaussian Prime. FORMULA a(n) = 1-A098033(n), n>1. - Steven G. Johnson (stevenj(AT)math.mit.edu), Sep 18 2008 a(n) = ((ithprime(n)-2) mod 4) mod 3 (Conjectured). - Gary Detlefs, Dec 06 2011 EXAMPLE a(2)=1 because Prime[2]=11_2 (in binary; decimal = 3_10) and its 2^1 bit is 1. a(3)=0 because Prime[3]=101_2 (in binary; decimal = 5_10) and its 2^1 bit is 0. MAPLE A100672 := proc(n)         if n = 1 then                 1 ;         else                 ((ithprime(n) mod 4)-1)/2;         end if; end proc: # R. J. Mathar, Oct 06 2011 seq(((ithprime(n)-2) mod 4) mod 3, n= 1 ..300); # Gary Detlefs, Dec 06 2011 MATHEMATICA Table[Reverse[RealDigits[Prime[k], 2][[1]]][[2]], {k, 1, 128}] PROG (PARI) for(k=1, 105, print1( bittest(prime(k), 1), ", ")) \\ Washington Bomfim, Jan 18 2011 CROSSREFS Cf. A045326, A002144, A002145. Sequence in context: A123594 A145006 A080813 * A079559 A175480 A229062 Adjacent sequences:  A100669 A100670 A100671 * A100673 A100674 A100675 KEYWORD base,nonn,easy AUTHOR Joseph Biberstine (jrbibers(AT)indiana.edu), Dec 06 2004 STATUS approved

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