login
Primes p such that 11*p is the concatenation of an emirp and its reverse.
1

%I #11 Jul 02 2021 01:48:33

%S 283,647,727,9791,10301,14341,16361,18181,28283,30703,63737,67577,

%T 69197,69997,88289,89399,939391,997991,1003001,1145411,1163611,

%U 1201021,1337431,1363631,1452541,2745373,2809073,2881783,2961593,3001003,3064703,3257623,3284833,3381743,3425243,3473753,3503053

%N Primes p such that 11*p is the concatenation of an emirp and its reverse.

%C The concatenation of a number (not divisible by 10) and its reverse is always a multiple of 11.

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

%e a(3) = 727 is a term because 727 is a prime and 11*727 = 7997 is the concatenation of the emirp 79 and its reverse 97.

%p rev:= proc(n) local L,i;

%p L:= convert(n,base,10);

%p add(L[-i]*10^(i-1),i=1..nops(L))

%p end proc:

%p f:= proc(n) local r,nr;

%p if not isprime(n) then return NULL fi;

%p r:= rev(n);

%p if r = n or not isprime(r) then return NULL fi;

%p nr:= (n*10^(1+ilog10(r))+r)/11;

%p if isprime(nr) then return nr fi;

%p end proc:

%p map(f, [seq(i,i=3..100000,2)]);

%t cat[n_] := FromDigits@Join[(d = IntegerDigits[n]), Reverse[d]]; Select[(cat /@ Select[Range[5000], ! PalindromeQ[#] && PrimeQ[#] && PrimeQ[IntegerReverse[#]] &])/11, PrimeQ] (* _Amiram Eldar_, Jun 29 2021 *)

%Y Cf. A006567.

%K nonn,base

%O 1,1

%A _J. M. Bergot_ and _Robert Israel_, Jun 29 2021