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!)
A143329 Primes in A143292. 1

%I #31 Jan 02 2023 12:30:47

%S 3,2,7,11,19,61,47,109,73,223,211,251,239,167,151,157,137,439,421,419,

%T 499,463,331,787,827,971,991,1009,947,911,641,647,659,701,757,613,569,

%U 521,1549,1663,1747,1789,1697,1667,1933,1951,1877,1291,1367,1531,1447,1451

%N Primes in A143292.

%C Primes that are Gray codes of other "source" primes, ordered along increasing source primes, i.e., in the order of appearance in A143292.

%H Charles R Greathouse IV, <a href="/A143329/b143329.txt">Table of n, a(n) for n = 1..10000</a>

%H Kevin Ryde, <a href="http://list.seqfan.eu/oldermail/seqfan/2012-April/009426.html">A143329 gray code primes sample values</a>, SeqFan Mailing list Apr 19 2012

%t GrayCode[n_] := BitXor[n, Floor[n/2]]; Select[ GrayCode@ Prime@ Range@ 275, PrimeQ] (* _Robert G. Wilson v_, Mar 11 2015 *)

%o (Magma)

%o I2B:=func<i | [b eq 1: b in IntegerToSequence(i, 2)]>;

%o B2I:=func<s | SequenceToInteger([b select 1 else 0: b in s], 2)>;

%o [g: n in [1..999] | IsPrime(g) where g is B2I(Xor(I2B(i), I2B(i div 2)cat[false])) where i is NthPrime(n)]; // _Jason Kimberley_, Apr 19 2012

%o (PARI) forprime(p=2,3e6,if(isprime(t=bitxor(p,p>>1)),print1(t", "))) \\ _Charles R Greathouse IV_, Apr 19 2012

%K nonn,easy

%O 1,1

%A _Roger L. Bagula_ and _Gary W. Adamson_, Oct 21 2008

%E _Jason Kimberley_ corrected all terms after a(38) at the suggestion of Kevin Ryde, Apr 19 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 23 05:37 EDT 2024. Contains 371906 sequences. (Running on oeis4.)