cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

A225659 Primes p where p + sumOfDigits(p) +- 3 is prime.

This page as a plain text file.
%I A225659 #26 Apr 28 2021 01:31:16
%S A225659 2,3,5,7,23,29,41,43,47,61,67,83,89,131,137,139,157,173,179,191,197,
%T A225659 223,227,229,241,263,269,283,311,313,317,337,353,359,373,379,397,401,
%U A225659 409,421,443,449,463,467,487,557
%N A225659 Primes p where p + sumOfDigits(p) +- 3 is prime.
%C A225659 a(n) = A068690(n), A030144(n), A069556(n), A091727(n), A156756(n) if n<14.
%H A225659 Andrew Howroyd, <a href="/A225659/b225659.txt">Table of n, a(n) for n = 1..394</a>
%e A225659 If p = 409, then 409 + sod(409) +- 3 = 409+13 - 3 = 419, which is prime.
%e A225659 If p =  23, then  23 + sod(23)  +- 3 = 23+5   + 3 = 31,  which is prime.
%t A225659 Select[Prime[Range[102]],Or@@PrimeQ[#+Total[IntegerDigits[#]]+{3,-3}] &] (* _Jayanta Basu_, May 23 2013 *)
%o A225659 (PARI)
%o A225659 ok(p)= {my(s=vecsum(digits(p)));isprime(p) && (isprime(p+s-3) || isprime(p+s+3))}
%o A225659 select(ok,[1..1000]) \\ _Andrew Howroyd_, Feb 22 2018
%Y A225659 Cf. A000040, A007605, A068690, A030144, A069556, A091727, A156756.
%K A225659 nonn,easy,base,dumb
%O A225659 1,1
%A A225659 _John-Å. W. Olsen_, May 11 2013