login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A143245 Primes in A098957. 1
3, 5, 7, 13, 11, 17, 29, 23, 31, 41, 37, 53, 61, 43, 47, 97, 113, 73, 101, 67, 83, 107, 71, 127, 193, 233, 197, 229, 181, 173, 131, 163, 227, 251, 199, 167, 151, 223, 257, 449, 353, 337, 433, 409, 313, 421, 277, 373, 269, 461, 349, 509, 307, 331, 491, 283, 443 (list; graph; refs; listen; history; text; internal format)
OFFSET

1,1

LINKS

Robert Israel, Table of n, a(n) for n = 1..10000

Eric Weisstein's World of Mathematics, Gray Code

MAPLE

brev:= proc(n) local L;

  L:= convert(n, base, 2);

  add(L[-i]*2^(i-1), i=1..nops(L))

end proc:

select(isprime, [seq(brev(ithprime(i)), i=1..100)]); # Robert Israel, Apr 03 2019

MATHEMATICA

GrayCodeList[k_] := Module[{b = IntegerDigits[k, 2], i}, Do[ If[b[[i - 1]] == 1, b[[i]] = 1 - b[[i]]], {i, Length[b], 2, -1} ]; b ]; a[n_] = GrayCodeList[Prime[n]]; a0 = Table[Sum[a[n][[m + 1]]*2^m, {m, 0, Length[a[n]] - 1}], {n, 1, 200}]; Flatten[Table[If[PrimeQ[a0[[n]]], a0[[n]], {}], {n, 1, 200}]]

PROG

(PARI) forprime(p=2, 1e3, v=binary(p); s=0; forstep(i=#v, 1, -1, s+=s+v[i]); if(isprime(s), print1(s", "))) \\ Charles R Greathouse IV, Nov 07 2011

CROSSREFS

Cf. A098957.

Sequence in context: A161329 A111745 A098957 * A018205 A121047 A152075

Adjacent sequences:  A143242 A143243 A143244 * A143246 A143247 A143248

KEYWORD

nonn,look,base

AUTHOR

Roger L. Bagula and Gary W. Adamson, Oct 21 2008

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
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified October 18 02:23 EDT 2019. Contains 328135 sequences. (Running on oeis4.)