login
Primes for which only two iterations of 'Prime plus its digit sum equals a prime' are possible.
6

%I #14 Nov 12 2018 18:39:01

%S 11,59,101,149,167,257,293,367,419,479,547,617,727,839,1409,1579,1847,

%T 2039,2129,2617,2657,2837,3449,3517,3539,3607,3719,4217,4637,4877,

%U 5689,5807,5861,6037,6257,6761,7027,7517,8039,8741,8969,9371,9377,10667

%N Primes for which only two iterations of 'Prime plus its digit sum equals a prime' are possible.

%H Lars Blomberg, <a href="/A048524/b048524.txt">Table of n, a(n) for n = 1..10000</a>

%e prime 727 -> 727 + (7+2+7) = prime 743 -> 743 + (7+4+3) = prime 757 -> next iteration yields composite 776.

%t Select[Prime[Range[1400]],Boole[PrimeQ[Rest[NestList[ #+Total[ IntegerDigits[ #]]&,#,3]]]] == {1,1,0}&] (* _Harvey P. Dale_, Oct 31 2018 *)

%Y Cf. A047791, A048519.

%K nonn,base

%O 1,1

%A _Patrick De Geest_, May 15 1999

%E Changed offset by _Lars Blomberg_, Dec 05 2013