OFFSET
1,1
COMMENTS
EXAMPLE
1518 = 2*3*11*23 is a tetraprime. Its reversal 8151 = 3*11*13*19 is another tetraprime. Thus, 1518 is in this sequence.
MATHEMATICA
Select[Range[10000], Transpose[ FactorInteger[FromDigits[Reverse[IntegerDigits[#]]]]][[2]] == {1, 1, 1, 1} && IntegerDigits[#] != Reverse[IntegerDigits[#]] && Transpose[FactorInteger[#]][[2]] == {1, 1, 1, 1} &]
PROG
(Python)
from sympy import factorint
def tetra(n): return list(factorint(n).values()) == [1, 1, 1, 1]
def ok(n):
if not tetra(n): return False
revn = int(str(n)[::-1])
return n != revn and tetra(revn)
print([k for k in range(9000) if ok(k)]) # Michael S. Branicky, Aug 27 2022
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Tanya Khovanova, Aug 26 2022
STATUS
approved