login
A180541
Primes that become a different prime under the mapping 3 <=> 5.
1
3, 5, 131, 137, 151, 157, 337, 347, 547, 557, 839, 859, 1031, 1051, 1367, 1439, 1459, 1567, 1637, 1657, 1931, 1951, 2351, 2531, 2837, 2857, 3011, 3119, 3167, 3209, 3251, 3257, 3301, 3307, 3319, 3391, 3407, 3449, 3457, 3547, 3581, 3631, 3637, 3659, 3701
OFFSET
1,1
LINKS
Index to Primes, Primes that become a different prime under some mapping.
MAPLE
filter:= proc(n) local L, Lp, i, x;
if not isprime(n) then return false fi;
L:= convert(n, base, 10);
Lp:= subs([3=5, 5=3], L);
if L=Lp then return false fi;
isprime(add(Lp[i]*10^(i-1), i=1..nops(Lp)))
end proc:
select(filter, [seq(i, i=3..10000, 2)]); # Robert Israel, Jul 28 2020
MATHEMATICA
fQ[n_] := Block[{id = IntegerDigits@n}, (MemberQ[id, 3] || MemberQ[id, 5]) && PrimeQ[ FromDigits[ id /. {3 -> 5, 5 -> 3}] ]]; Select[ Prime@ Range@ 550, fQ]
CROSSREFS
KEYWORD
base,nonn
AUTHOR
STATUS
approved