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!)
A182145 XOR(d1,d2), where d1 and d2 are the difference between consecutive primes given in binary. 1

%I #18 Aug 03 2014 14:01:27

%S 3,0,6,6,6,6,6,2,4,4,2,6,6,2,0,4,4,2,6,4,2,2,14,12,6,6,6,6,10,10,2,4,

%T 8,8,4,0,2,2,0,4,8,8,6,6,14,0,8,6,6,2,4,8,12,0,0,4,4,2,6,8,4,10,6,6,

%U 10,8,12,8,6,2,14,14,0,2,2,14,12,12,2,8,8,8

%N XOR(d1,d2), where d1 and d2 are the difference between consecutive primes given in binary.

%C Conjecture: among values less than 60 the most frequent value is 30 (based on frequencies for n < 2126795281, i.e. primes less than 50176000000).

%H T. D. Noe, <a href="/A182145/b182145.txt">Table of n, a(n) for n = 1..10000</a>

%H Eric Weisstein's World of Mathematics, <a href="http://mathworld.wolfram.com/XOR.html">XOR</a>

%H Wikipedia, <a href="http://en.wikipedia.org/wiki/Bitwise_operation#XOR">Bitwise operation XOR</a>

%F a(n) = (primes(n+2)-primes(n+1)) XOR (primes(n+1)-primes(n)) , where XOR is the bitwise exclusive-OR operator

%e (5-3)xor(3-2)=3, (7-5)xor(5-3)=0, (11-7)xor(7-5)=6.

%t nn = 100; d = Differences[Prime[Range[nn+2]]]; Table[BitXor[d[[n]], d[[n+1]]], {n, nn}] (* _T. D. Noe_, Apr 16 2012 *)

%o (Haskell)

%o import Data.Bits (xor)

%o a182145 n = a182145_list !! (n-1)

%o a182145_list = zipWith xor a001223_list $ tail a001223_list :: [Integer]

%o -- _Reinhard Zumkeller_, Apr 23 2012

%Y Cf. A000040, A001223.

%K nonn,base

%O 1,1

%A Alex Ratushnyak, Apr 14 2012

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 April 18 11:02 EDT 2024. Contains 371779 sequences. (Running on oeis4.)