OFFSET

1,1

COMMENTS

Apparently if the squares of the digits of a prime sum to a prime, it is more likely that the digits themselves also sum to a prime. In the first 10,000 primes there are 1558 primes p such that the squares of the digits of p sum to a prime. Of these, only 360 are such that the sums of the digits are not prime. Interestingly, all of these primes have a digit sum of 25 or 35. Essentially this sequence is the terms of A052034 (primes whose digits squared sum to a prime) that do not also appear in A046704 (primes whose digits sum to a prime).

LINKS

Vincenzo Librandi, Table of n, a(n) for n = 1..1000

EXAMPLE

a(1)=997 because 9+9+7 = 25 which is not prime, but 9^2+9^2+7^2 = 211 which is prime.

MATHEMATICA

ssdQ[n_]:=Module[{idn=IntegerDigits[n]}, !PrimeQ[Total[idn]]&&PrimeQ[ Total[ idn^2]]]; Select[Prime[Range[2100]], ssdQ] (* Harvey P. Dale, Jun 28 2011 *)

CROSSREFS

KEYWORD

base,nonn

AUTHOR

Chuck Seggelin (barkeep(AT)plastereddragon.com), Jan 03 2004

STATUS

approved