login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A050288 Pandigital primes. 31

%I #31 Apr 09 2024 10:14:38

%S 10123457689,10123465789,10123465897,10123485679,10123485769,

%T 10123496857,10123547869,10123548679,10123568947,10123578649,

%U 10123586947,10123598467,10123654789,10123684759,10123685749,10123694857,10123746859,10123784569,10123846597,10123849657,10123854679

%N Pandigital primes.

%C Digits may appear multiple times; density n/log n (almost all primes are pandigital).

%C Note that actually a(n) is much larger than n*log(n) (see Formula section). Even for n = 10000, a(n) = 111571*n*log(n). - _Zak Seidov_, Jul 27 2014

%H Charles R Greathouse IV, <a href="/A050288/b050288.txt">Table of n, a(n) for n = 1..10000</a>.

%H Eric Weisstein's World of Mathematics, "<a href="http://mathworld.wolfram.com/PandigitalNumber.html">Pandigital Number</a>".

%F a(n) ~ n log n. - _Charles R Greathouse IV_, Sep 14 2012

%F Intersection of A171102 and A000040. - _Charles R Greathouse IV_, May 04 2013

%t ta={{0}};Do[u=Union[IntegerDigits[n]]; If[Equal[u, {0, 1, 2, 3, 4, 5, 6, 7, 8, 9}]&&PrimeQ[n], ta=Append[ta, n]], {n, 10123456789, 20000000000}];ta (* _Labos Elemer_ *)

%o (PARI) is(n)=isprime(n) && #vecsort(digits(n),,8)>9 \\ _Charles R Greathouse IV_, May 04 2013

%o (Python)

%o from sympy import isprime

%o from itertools import count, islice, product

%o def agen(): # generator of terms

%o for d in count(11):

%o for f in "123456789":

%o for m in product("0123456789", repeat=d-2):

%o for e in "1379":

%o t = f + "".join(m) + e

%o if len(set(t)) == 10 and isprime(it:=int(t)):

%o yield it

%o print(list(islice(agen(), 20))) # _Michael S. Branicky_, Apr 09 2024

%Y Cf. A050278.

%K nonn,base

%O 1,1

%A _Eric W. Weisstein_

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified May 5 10:46 EDT 2024. Contains 372275 sequences. (Running on oeis4.)