login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Lower twin primes whose sum of digits is a lower twin prime.
1

%I #13 Aug 23 2022 18:16:30

%S 3,5,29,41,137,179,191,197,227,269,281,311,461,641,809,821,827,881,

%T 1019,1031,1091,1277,1301,1451,1619,1721,1871,2027,2081,2087,2111,

%U 2267,2339,2591,2711,2801,2999,3167,3251,3257,3329,3527,3581,3671,3851,4001,4049,4157,4229,4241,4337,4421,4481

%N Lower twin primes whose sum of digits is a lower twin prime.

%C Members k of A001359 such that A007953(k) is in A001359.

%H Robert Israel, <a href="/A356147/b356147.txt">Table of n, a(n) for n = 1..10000</a>

%e a(3) = 29 is a term because 29, 29 + 2 = 31, 2 + 9 = 11 and 2 + 9 + 2 = 13 are primes.

%p filter:= proc(n) local s;

%p if not(isprime(n) and isprime(n+2)) then return false fi;

%p s:= convert(convert(n,base,10),`+`);

%p isprime(s) and isprime(s+2)

%p end:

%p select(filter, [3, seq(i,i=5..5000,6)]);

%t Select[Prime[Range[600]], AllTrue[{# + 2, (d = Plus @@ IntegerDigits[#]), d + 2}, PrimeQ] &] (* _Amiram Eldar_, Jul 28 2022 *)

%Y Cf. A001359, A007953.

%Y Subsequence of A046704.

%K nonn,base

%O 1,1

%A _J. M. Bergot_ and _Robert Israel_, Jul 27 2022