login
A154275
Primes p=prime(k) such that abs(sum of digits of p - sum of digits of k) is prime.
1
5, 7, 11, 13, 19, 31, 37, 43, 47, 61, 67, 73, 89, 103, 107, 113, 137, 151, 157, 167, 173, 193, 211, 223, 227, 233, 239, 269, 271, 277, 281, 311, 353, 373, 379, 401, 409, 419, 421, 431, 433, 439, 443, 449, 467, 487, 503, 509, 571, 599, 601, 631, 641, 647, 653
OFFSET
1,1
LINKS
EXAMPLE
Prime(36)=151 and abs(1+5+1-(3+6)) = abs(7-9) = 2 (a prime), so 151 is in the sequence.
Prime(37)=157 and abs(1+5+7-(3+7)) = abs(13-10) = 3 (a prime), so 157 is in the sequence.
MAPLE
A007953 := proc(n) add(i, i=convert(n, base, 10)) ; end: A007605 := proc(n) A007953(ithprime(n)) ; end: A090431 := proc(n) A007953(n)-A007605(n) ; end: for n from 1 to 200 do q := abs(A090431(n)) ; if isprime(q) then p := ithprime(n) ; printf("%a, ", p) ; fi; od: # R. J. Mathar, Jan 07 2009
MATHEMATICA
Transpose[Select[Table[{n, Prime[n]}, {n, 200}], PrimeQ[Abs[Total[ IntegerDigits[ #[[2]]]] -Total[IntegerDigits[#[[1]]]]]]&]][[2]] (* Harvey P. Dale, Jan 27 2013 *)
CROSSREFS
Cf. A000040.
Sequence in context: A343448 A045438 A176579 * A339347 A167460 A045439
KEYWORD
nonn,base,less
AUTHOR
EXTENSIONS
103, 113 etc. inserted by R. J. Mathar, Jan 07 2009
Name edited by Jon E. Schoenfield, Jan 06 2019
STATUS
approved