close
login
A101781
Lower bound b of twin primes pairs such that b's digital reverse is also prime.
1
3, 5, 11, 17, 71, 101, 107, 149, 179, 191, 311, 347, 1031, 1061, 1091, 1151, 1229, 1301, 1487, 1619, 1949, 3251, 3257, 3299, 3359, 3371, 3389, 3467, 3527, 3767, 3821, 3851, 3917, 3929, 7349, 7457, 7547, 7589, 7757, 7949, 9011, 9041, 9341, 9437, 9857, 10007
OFFSET
1,1
LINKS
EXAMPLE
17 is the lower bound of twin prime pair (17,19) and its digital reverse, 71, is prime.
MATHEMATICA
Select[Transpose[Select[Partition[Prime[Range[1500]], 2, 1], Last[#]- First[#] == 2&]][[1]], PrimeQ[FromDigits[Reverse[IntegerDigits[#]]]]&] (* Harvey P. Dale, Jun 26 2013 *)
Select[Partition[Prime[Range[1500]], 2, 1], #[[2]]-#[[1]]==2&&PrimeQ[IntegerReverse[#[[1]]]]&][[;; , 1]] (* Harvey P. Dale, Sep 01 2025 *)
PROG
(PARI) twinl(n) = /* The n-th lower twin prime */ { local(c, x); c=0; x=1; while(c<n, if(isprime(prime(x)+2), c++); x++; ); return(prime(x-1)) }
rev(str) = /* Get the reverse of the input string */ { local(tmp, s, j); tmp = Vec(Str(str)); s=""; forstep(j=length(tmp), 1, -1, s=concat(s, tmp[j])); return(s) }
twlrpr(n) = { for(x=1, n, y=twinl(x); z=eval(rev(y)); if(isprime(z), print1(y", ")) ) }
CROSSREFS
Sequence in context: A284306 A283399 A216181 * A101783 A078883 A355901
KEYWORD
nonn,base
AUTHOR
Cino Hilliard, Jan 26 2005
EXTENSIONS
Definition clarified by Harvey P. Dale, Sep 01 2025
STATUS
approved