This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A173580 #30 Jun 12 2025 12:58:52 %S A173580 2,11,41,101,181,211,241,281,401,421,811,821,881,1021,1181,1201,1481, %T A173580 1801,1811,2011,2081,2111,2141,2221,2281,2411,2441,2801,4001,4021, %U A173580 4111,4201,4211,4241,4421,4441,4481,4801,8011,8081,8101,8111,8221,8821,10111 %N A173580 Primes where each digit is 0, 1, 2, 4, or 8. %H A173580 Jason Bard, <a href="/A173580/b173580.txt">Table of n, a(n) for n = 1..10000</a> %p A173580 with(numtheory): for n from 2 to 10000 do: l:=evalf(floor(ilog10(n))+1): n0:=n:indic:=0:for m from 1 to l do:q:=n0:u:=irem(q,10):v:=iquo(q,10): n0:=v : if u=3 or u= 5 or u= 6 or u=7 or u=9 then indic :=1 :else fi :od :if indic = 0 and type(n,prime) = true then print(n):else fi:od: %t A173580 Join[{2}, Select[Map[FromDigits, Tuples[{0, 1, 2, 4, 8}, 3]]*10 + 1, PrimeQ]] (* _Paolo Xausa_, Jun 12 2025 *) %o A173580 (Python) %o A173580 from sympy import isprime %o A173580 from itertools import count, islice, product %o A173580 def agen(): # generator of terms %o A173580 yield 2 %o A173580 yield from (t for digits in count(2) for f in "1248" for mid in product("01248", repeat=digits-2) if isprime(t:=int(f + "".join(mid) + "1"))) %o A173580 print(list(islice(agen(), 45))) # _Michael S. Branicky_, Jun 11 2025 %Y A173580 See A066593. %Y A173580 Cf. A066591, A066592. %K A173580 nonn,base %O A173580 1,1 %A A173580 _Michel Lagneau_, Feb 22 2010