cp's OEIS Frontend

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.

Previous Showing 11-16 of 16 results.

A052494 Number of different primes that can be formed by permuting digits of n-th prime.

Original entry on oeis.org

1, 1, 1, 1, 1, 2, 2, 1, 1, 1, 2, 2, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 1, 1, 2, 1, 1, 2, 1, 3, 2, 3, 3, 2, 4, 1, 3, 3, 3, 3, 4, 2, 2, 2, 4, 3, 1, 1, 1, 1, 1, 2, 2, 2, 1, 1, 1, 2, 2, 2, 2, 2, 1, 3, 2, 3, 2, 3, 2, 2, 1, 3, 2, 3, 4, 1, 3, 4, 1, 1, 4, 2, 1, 1, 2, 1, 1, 2, 2, 2, 2, 2, 1, 4, 1, 1, 1, 2, 1, 1, 2, 1, 2, 2, 3
Offset: 2

Views

Author

Enoch Haga, Mar 16 2000

Keywords

Comments

Leading zeros not permitted, so, e.g., prime(27) = 103 but a(27) = 1 even though 13 and 31 are both primes. - Harvey P. Dale, Dec 17 2012

Examples

			a(75)=4 because the digits in 379 may be arranged to form a total of 4 primes: 379, 397, 739 and 937.
		

Crossrefs

Programs

A118553 Number of permutations of digits of n which denote perfect power.

Original entry on oeis.org

1, 1, 0, 0, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0
Offset: 1

Views

Author

Giovanni Teofilatto, May 07 2006

Keywords

Crossrefs

Cf. A039999.

A328515 Number of primes in permutations of digits per permutation class of the positive integers ordered by smallest member of this class excluding leading zeros.

Original entry on oeis.org

0, 0, 1, 1, 0, 1, 0, 1, 0, 0, 0, 1, 0, 2, 1, 0, 1, 2, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 1, 1, 0, 2, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 2, 0, 0, 1, 0, 0, 0, 1, 0, 1, 1, 0, 1, 2, 0, 1, 0, 1, 3, 0, 1, 0, 0, 2, 2, 0, 0, 2, 2, 0, 2, 2, 0, 2, 1, 0, 3, 3, 0, 2, 0, 1, 2, 0, 0, 4, 0, 0, 3, 0, 0
Offset: 0

Views

Author

David A. Corneth, Oct 18 2019

Keywords

Comments

Primitive sequence of A039999.

Examples

			A179239(67) = 103. Its permutations of digits without leading zeros are 103, 130, 301, 310. Of these, only 103 is prime which is one number. So a(67) = 1.
		

Crossrefs

A039998 Primes embedded in prime(n).

Original entry on oeis.org

1, 1, 1, 1, 1, 2, 2, 1, 1, 1, 2, 2, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 1, 1, 2, 2, 3, 4, 2, 3, 2, 3, 3, 2, 4, 1, 3, 3, 3, 3, 4, 2, 2, 2, 4, 3, 1, 1, 1, 1, 1, 2, 2, 2, 1, 1, 1, 2, 2, 2, 2, 2, 3, 3, 2, 3, 2, 3, 2, 2, 1, 3, 2, 3, 4, 1, 3, 4, 2, 1, 4, 2, 1, 1, 2, 1, 1, 2, 2, 2, 2, 2, 1, 4, 1, 2, 2, 2, 1, 1, 2, 1, 2, 2, 3
Offset: 1

Views

Author

Keywords

Comments

a(n) counts permutations of digits of prime(n) which denote primes.

Formula

a(n) = A039999(prime(n)).

A086151 Number of permutations of decimal digits of 2^n which yield a prime.

Original entry on oeis.org

1, 0, 0, 1, 1, 0, 2, 0, 2, 4, 0, 0, 5, 19, 10, 3, 87, 9, 0, 377, 293, 84, 9, 265, 142, 502, 4916, 979, 30453, 38758, 15274, 5270, 10463, 81628, 69189, 91023, 1605954, 378559, 152874, 3447170, 220776, 4350954, 1746163, 51889555, 12949705, 5145813, 202624585, 404342074, 118292490
Offset: 1

Views

Author

Labos Elemer, Aug 04 2003

Keywords

Examples

			n=19: 2^19 = 524288, has 180 permutations, each composite, a(19)=0;
n=13: 2^13 = 8192, the following 5 of the 24 permutations provide primes: {8219, 8291, 1289, 9281, 2819}.
		

Crossrefs

Programs

  • Mathematica
    Table[Count[Table[PrimeQ[tn[Part[Permutations[ IntegerDigits[2^w]], j]]], {j, 1, Length[Permutations[ IntegerDigits[2^w]]]}], True], {w, 1, 20}]
  • PARI
    \\ here b(n) is A039999.
    b(n)={my(D=vecsort(digits(n)), S=0); forperm(D, p, if(isprime(fromdigits(Vec(p))),  S++)); S}
    { for(n=1, 30, print1(b(2^n), ", ")) } \\ Andrew Howroyd, Jan 05 2020
    
  • Python
    from sympy import isprime
    from sympy.utilities.iterables import multiset_permutations as mp
    def a(n): return sum(1 for p in mp(str(2**n)) if isprime(int("".join(p))))
    print([a(n) for n in range(1, 31)]) # Michael S. Branicky, May 25 2023

Formula

a(n) = A039999(A000079(n)).

Extensions

a(27)-a(44) from Andrew Howroyd, Jan 05 2020
a(45)-a(49) from Michael S. Branicky, May 26 2023

A118626 Number of permutations of digits of n which denote a palindromic number.

Original entry on oeis.org

1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 2, 0, 0, 0
Offset: 1

Views

Author

Giovanni Teofilatto, May 09 2006

Keywords

Crossrefs

Previous Showing 11-16 of 16 results.