login
A178561
Primes q from A178548.
2
31, 11, 313, 23, 163, 53, 157, 43, 41, 71, 103, 137, 61, 127, 193, 227, 113, 109, 107, 101, 277, 127, 101, 223, 113, 181, 251, 571, 233, 409, 151, 257, 211, 317, 491, 557, 733, 367, 433, 359, 313, 491, 271, 233, 509, 281, 241, 311, 271, 373, 1163, 613, 571
OFFSET
1,1
COMMENTS
See comments in A178548.
EXAMPLE
From Robert G. Wilson v, Aug 23 2010: (Start)
2*13 + prime(3) = 26 + 5 = 31 = prime(11), digsum(13)=digsum(31)=4
2*2 + prime(4) = 4 + 7 = 11 = prime(5), digsum(2)=digsum(11)=2
2*151 + prime(5) = 302 + 11 = 313 = prime(65), digsum(151)=digsum(313)=7
2*5 + prime(6) = 10 + 13 = 23 = prime(9), digsum(5)=digsum(23)=5, etc.
(End)
MATHEMATICA
f[n_] := Block[{p = 2}, While[q = 2 p + Prime[n + 2]; !PrimeQ@q || Plus @@ IntegerDigits@p != Plus @@ IntegerDigits@q, p = NextPrime@p]; q]; Array[f, 53] (* Robert G. Wilson v, Aug 23 2010 *)
PROG
(PARI) a(n) = {my(p=2, q=prime(n+2)+2*p); while ((!isprime(q) || (sumdigits(p) != sumdigits(q))), p = nextprime(p+1); q = prime(n+2) + 2*p); q; }
vector(70, n, a(n)) \\ G. C. Greubel and Michel Marcus, Feb 26 2019
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Ulrich Krug (leuchtfeuer37(AT)gmx.de), May 29 2010
EXTENSIONS
All comments removed by Robert G. Wilson v, Aug 23 2010
a(37) corrected by G. C. Greubel, Feb 16 2019
STATUS
approved