A383810
Primes which satisfy the requirements of A380943 in more than one way.
Original entry on oeis.org
373, 1913, 3733, 6737, 7937, 11353, 13997, 19937, 19997, 23773, 24113, 29347, 31181, 31193, 31907, 34729, 37277, 38237, 41593, 47293, 59929, 71971, 72719, 73823, 74177, 79337, 79613, 82373, 83773, 83911, 88397, 100913, 103997
Offset: 1
373 is a member since 373 is the 74th prime, p=3 and q=73, and the reverse concatenation is 733 which is the 130th prime. In another way, p=37 and q=3 and the reverse concatenation is 337, the 68th prime.
-
f[n_] := Block[{cnt = 0, id = IntegerDigits@ n, k = 1, len, p, q, qp}, len = Length@ id; While[k < len, p = Take[id, k]; q = Take[id, -len + k]; qp = FromDigits[ Join[q, p]]; If[ PrimeQ[FromDigits[p]] && PrimeQ[FromDigits[q]] && PrimeQ[qp] && IntegerLength[qp] == len, cnt++]; k++]; cnt]; Select[ Prime@ Range@ 10000, f@# > 1 &]
A383811
Primes which satisfy the requirements of A380943 in exactly two ways.
Original entry on oeis.org
373, 1913, 3733, 6737, 7937, 11353, 13997, 19997, 23773, 24113, 29347, 31181, 31193, 31907, 34729, 37277, 38237, 41593, 47293, 59929, 71971, 72719, 73823, 74177, 79337, 79613, 82373, 83773, 83911, 88397, 100913, 111773, 111973, 118171, 118273, 118747, 132113, 132137, 139547
Offset: 1
373 is a member since 373 is the 74th prime, p=3 and q=73, and the reverse concatenation is 733 which is the 130th prime. In another way, p=37 and q=3, and the reverse concatenation is 337, the 68th prime.
-
f[n_] := Block[{cnt = 0, id = IntegerDigits@ n, k = 1, len, p, q, qp}, len = Length@ id; While[k < len, p = Take[id, k]; q = Take[id, -len + k]; qp = FromDigits[ Join[q, p]]; If[ PrimeQ[FromDigits[p]] && PrimeQ[FromDigits[q]] && PrimeQ[qp] && IntegerLength[qp] == len, cnt++]; k++]; cnt];Select[ Prime@ Range@ 13000, f@# == 2 &]
A383813
Primes which satisfy the requirements of A380943 in exactly four ways.
Original entry on oeis.org
257931013, 1394821313, 2699357347, 3122419127, 3132143093, 3647381953, 3736320359, 3799933727, 6130099337, 7622281937, 7943701397, 7991407367
Offset: 1
-
f[n_] := Block[{cnt = 0, id = IntegerDigits@ n, k = 1, len, p, q, qp}, len = Length@ id; While[k < len, p = Take[id, k]; q = Take[id, -len + k]; qp = FromDigits[ Join[q, p]]; If[ PrimeQ[FromDigits[p]] && PrimeQ[FromDigits[q]] && PrimeQ[qp] && IntegerLength[qp] == len, cnt++]; k++]; cnt];Select[ Prime@ Range@ 10000000, f@# == 4 &]
Original entry on oeis.org
313, 373, 797, 11311, 13331, 13931, 17971, 19991, 31013, 35353, 36263, 36563, 38783, 71317, 79397, 97379, 98389, 1129211, 1196911, 1611161, 1793971, 1982891, 3106013, 3166613, 3193913, 3236323, 3288823, 3304033, 3319133, 3329233, 3365633, 3417143, 3447443, 3449443, 3515153, 3670763
Offset: 1
The palindromic prime 313 is formed by the concatenation of the primes 31 and 3, which reversed, also form the prime 331. The palindromic prime 13931 is formed by the concatenation of 139 and 31; 31139 is also prime.
-
rev:= proc(n) local L,i;
L:= convert(n,base,10);
add(L[-i]*10^(i-1),i=1..nops(L))
end proc:
tcat:= proc(x,y) y + 10^(ilog10(y)+1)*x end proc:
filter:= proc(z) local i,x,y;
if not isprime(z) then return false fi;
for i from 1 to ilog10(z) do
x:= z mod 10^i;
if x < 10^(i-1) then next fi;
y:= (z-x)/10^i;
if isprime(x) and isprime(y) and isprime(tcat(x,y)) then return true fi;
od;
false
end proc:
N:= 7: # for terms of up to 7 digits
R:= NULL:
for d from 1 to (N-1)/2 do
for x from 10^(d-1) to 10^d-1 do
for y from 0 to 9 do
z:= rev(x) + 10^d * y + 10^(d+1)*x;
if filter(z) then R:= R,z fi
od od od:
R; # Robert Israel, Jun 08 2025
-
f[n_] := Block[{cnt = 0, id = IntegerDigits@ n, k = 1, len, p, q, qp}, len = Length@ id; While[k < len, p = Take[id, k]; q = Take[id, -len + k]; qp = FromDigits[Join[q, p]]; If[ PrimeQ@ FromDigits@ p && PrimeQ@ FromDigits@ q && PrimeQ@ qp && IntegerLength@ qp == len, cnt++]; k++]; cnt]; fQ[n_] := Reverse[idn = IntegerDigits@ n] == idn && f@ n > 0; Select[ Prime@ Range@ 264000, fQ]
A383814
Least number which satisfies the requirements of A380943 in exactly n ways.
Original entry on oeis.org
2, 37, 373, 19937, 257931013, 4199993923
Offset: 0
See the examples in A383810 through A383813.
-
f[n_] := Block[{cnt = 0, id = IntegerDigits@ n, k = 1, len, p, q, qp}, len = Length@ id; While[k < len, p = Take[id, k]; q = Take[id, -len + k]; qp = FromDigits[ Join[q, p]]; If[ PrimeQ[FromDigits[p]] && PrimeQ[FromDigits[q]] && PrimeQ[qp] && IntegerLength[qp] == len, cnt++]; k++]; cnt];a[n_]:=Module[{k=1},While[f[Prime[k]]!=n,k++];Prime[k]];Array[a,4,0]
Showing 1-5 of 5 results.
Comments