login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Numbers m such that 7^m reversed is prime.
5

%I #11 Jul 21 2022 01:55:05

%S 1,12,24,225,392,819,1201,1645,1775

%N Numbers m such that 7^m reversed is prime.

%t Do[ If[ PrimeQ[ ToExpression[ StringReverse[ ToString[7^n] ] ] ], Print[n] ], {n, 1, 2500} ]

%o (Python)

%o from sympy import isprime

%o k, m, A058994_list = 1, 7, []

%o while k <= 10**3:

%o if isprime(int(str(m)[::-1])):

%o A058994_list.append(k)

%o k += 1

%o m *= 7 # _Chai Wah Wu_, Mar 09 2021

%o (PARI) isok(m) = isprime(fromdigits(Vecrev(digits(7^m)))) \\ _Mohammed Yaseen_, Jul 20 2022

%Y Cf. A059208, A071584.

%Y Numbers m such that k^m reversed is prime: A057708 (k=2), A350441 (k=4), A058993 (k=5), this sequence (k=7), A350442 (k=8), A058995 (k=13).

%K nonn,base,more

%O 1,2

%A _Robert G. Wilson v_, Jan 17 2001