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.

Showing 1-10 of 10 results.

A097220 Numbers n such that pi(n) = product of digits of n.

Original entry on oeis.org

16, 17, 63, 73, 364, 437, 545, 573, 963, 6475, 23797, 67458, 2475989, 2475998
Offset: 1

Views

Author

Farideh Firoozbakht, Aug 02 2004

Keywords

Comments

The only numbers with the property that pi(n) = sum of the digits of n, are the three numbers 15, 27 & 39.
When n exceeds approximately 10^44, then pi(n) is consistently greater than the product of digits of n. So no term of this sequence exceeds 10^44. In particular, this sequence is finite. - Jeppe Stig Nielsen, Nov 04 2018
Products of digits of terms are in A002473. Term by term up to some bound (such that the bounds on primes hold), one could check terms t in A002473 on some known bounds. See example below. - David A. Corneth, Nov 06 2018
There are no other terms below 10^17. - Max Alekseyev, Nov 07 2024

Examples

			2475998 is in the sequence because pi(2475998)=2*4*7*5*9*9*8.
1152 is in A002473. As 8643 <= prime(1152) <= 9794. Examples of the 13 numbers with product of digits is 1152 in that interval are: 8944, 9288, 9448, 9484 none of which are terms. - _David A. Corneth_, Nov 06 2018
		

Crossrefs

Programs

  • Magma
    [n: n in [1..10^5] | &*Intseq((n)) eq #PrimesUpTo(n)]; // Vincenzo Librandi, Nov 06 2018
  • Mathematica
    v={}; Do[If[h=IntegerDigits[n]; l=Length[h]; p=Product[h[[k]], {k, l}]; PrimePi[n]==p, v=Append[v, n]; Print[v], If[Mod[n, 1000000]==0, Print[ -n]]], {n, 200000000}]
    Select[Range[2500000],PrimePi[#]==Times@@IntegerDigits[#]&] (* Harvey P. Dale, Dec 04 2012 *)
  • PARI
    isok(n) = primepi(n) == factorback(digits(n)); \\ Michel Marcus, Apr 23 2018
    

Extensions

Keyword fini from Jeppe Stig Nielsen, Nov 04 2018

A099068 Numbers n such that n=P(d_1)*P(d_2)*...*P(d_k)+(P(d_1)+P(d_2)+...+P(d_k)) where d_1 d_2 ... d_k is the decimal expansion of n and P(i) is the i-th prime.

Original entry on oeis.org

23, 119, 428, 918, 1637682, 652827658771
Offset: 1

Views

Author

Farideh Firoozbakht, Oct 29 2004

Keywords

Comments

There is no other term up to 15000000.
a(7) > 10^12. [Donovan Johnson, Mar 26 2010]
There are no other terms < 10^44. - Chai Wah Wu, Aug 12 2017

Examples

			1637682 is in the sequence because 1637682=
P(1)*P(6)*P(3)*P(7)*P(6)*P(8)*P(2)+(P(1)+P(6)+P(3)+P(7)+P(6)+P(8)+P(2)).
		

Crossrefs

Programs

  • Mathematica
    Do[h=IntegerDigits[n];l=Length[h];If[ !MemberQ[h, 0]&&n==Product[Prime[h[[k]]], {k, l}]+Sum[Prime[h[[k]]], {k, l}], Print[n]], {n, 15000000}]

Extensions

Definition corrected by D. S. McNeil, Mar 14 2009
a(6) from Donovan Johnson, Mar 26 2010

A099069 Numbers n such that n = prime(d_1*d_2*...*d_k) - phi(d_1 + d_2 + ... + d_k) where d_1 d_2 ... d_k is the decimal expansion of n.

Original entry on oeis.org

1, 2, 3, 19, 35497
Offset: 1

Views

Author

Farideh Firoozbakht, Oct 29 2004

Keywords

Comments

Sequence is finite since prime(d_1*d_2*...*d_k) <= prime(9^k) <= 9^k(k log 9 + log k + log log 9) < 10^(k-1) for large enough k, i.e., it will have fewer than k digits. In particular, a(n) < 10^69. - Chai Wah Wu, Aug 10 2017

Examples

			35497 is in the sequence because 35497 = prime(3*5*4*9*7) - phi(3 + 5 + 4 + 9 + 7).
		

Crossrefs

Programs

  • Mathematica
    Do[h=IntegerDigits[n];l=Length[h];If[ !MemberQ[h, 0]&&n==Prime[Product[h[[k]], {k, l}]]-EulerPhi[Sum[h[[k]], {k, l}]], Print[n]], {n, 6000000}]

A107120 Numbers m such that pi(m) = prime(d_1*d_2*...*d_k) where d_1 d_2 ... d_k is the decimal expansion of m.

Original entry on oeis.org

162, 242, 291, 371, 461, 515, 2419, 2815, 11874, 64751, 81927, 264961, 276184, 757155, 2537825, 7717729, 9548491, 14738827, 19728438, 19728446, 19728464, 23695527, 77362954, 269776516, 269776523, 269776532, 358399327, 2385883646, 59955748691, 67893872935, 848472784869
Offset: 1

Views

Author

Farideh Firoozbakht, May 13 2005

Keywords

Comments

A107121 is a subsequence of this sequence (see the comments line of A107121).
a(32) > 7*10^14, if it exists. - Giovanni Resta, Jun 01 2020
The sequence is finite as pi(m) >= pi(10^(k-1)) grows faster than prime(9^k) >= prime(d_1*d_2*...*d_k). - Max Alekseyev, Dec 30 2024

Examples

			23695527 is in the sequence because pi(23695527)=prime(2*3*6*9*5*5*2*7).
		

Crossrefs

Programs

  • Mathematica
    Do[h = IntegerDigits[m]; l = Length[h]; If[Min[h] > 0 && PrimePi[m] == Prime[Product[h[[k]], {k, l}]], Print[m]], {m, 52000000}]

Extensions

a(23)-a(28) from Donovan Johnson, Jul 12 2010
a(29)-a(31) from Giovanni Resta, Jun 01 2020

A107121 Numbers m such that m=prime(prime(d_1*d_2*...*d_k)) where d_1 d_2 ... d_k is the decimal expansion of m.

Original entry on oeis.org

461, 264961, 9548491, 14738827
Offset: 1

Views

Author

Farideh Firoozbakht, May 13 2005

Keywords

Comments

If m is in the sequence then pi(m) = prime(d_1*d_2*...*d_k) where d_1 d_2 ... d_k is the decimal expansion of m, so this sequence is a subsequence of A107120.
The sequence is finite as m >= 10^(k-1) grows faster than prime(prime(9^k)) >= prime(prime(d_1*d_2*...*d_k)). If it exists, a(5) > 10^14. - Max Alekseyev, Dec 30 2024

Examples

			14738827 is in the sequence because 14738827=prime(prime(1*4*7*3*8*8*2*7)).
		

Crossrefs

Programs

  • Mathematica
    Do[h= IntegerDigits[Prime[m]];l = Length[h];If[Min[h] > 0 && m == Prime[Product[h[[k]], {k, l}]], Print[Prime [m]]], {m, 20000000}]

A110070 Numbers n such that n=pi(d_1!*d_2!*...*d_k!) where d_1 d_2 ... d_k is the decimal expansion of n.

Original entry on oeis.org

0, 3, 34, 52, 2800414
Offset: 1

Views

Author

Farideh Firoozbakht, Jul 22 2005

Keywords

Comments

No other terms below 10^15. - Max Alekseyev, Jul 21 2024

Examples

			2800414 is in the sequence because 2800414=pi(2!*8!*0!*0!*4!*1!*4!).
		

Crossrefs

A306766 Primes whose index is divisible by the product of its digits.

Original entry on oeis.org

11, 13, 17, 61, 73, 113, 223, 541, 571, 1151, 1213, 1321, 1511, 1811, 2111, 2267, 3221, 3271, 4211, 4621, 5443, 11251, 11813, 12211, 12553, 13163, 17123, 17351, 19211, 21143, 21713, 24137, 28181, 29921, 31511, 32213, 34141, 34361, 41141, 61129, 63211, 71263, 95231
Offset: 1

Views

Author

William C. Laursen, Mar 08 2019

Keywords

Comments

It is unknown whether this sequence is finite or not. For instance, if the index is exactly the product of the digits, A097223, it is known that only three such primes exist.

Examples

			A000040(21)=73 and 7*3 divides 21.
A000040(30)=113 and 1*1*3 divides 30.
		

Crossrefs

A097223 is a subset of this sequence where k=1, k being the above integer found after dividing.
A004022, the prime repunits, is a subsequence, because the product of the digits for all of them is 1, which trivially divides every index that the prime could hold.

Programs

  • Maple
    p:= 2: count:= 0: Res:= NULL:
    for i from 2 while count < 100 do
      p:= nextprime(p);
      pd:= convert(convert(p,base,10),`*`);
      if pd > 0 and i mod pd = 0 then
        count:= count+1; Res:= Res, p
      fi
    od:
    Res; # Robert Israel, Mar 10 2019
  • Mathematica
    seqQ[n_] := PrimeQ[n] && (prod=Times@@IntegerDigits[n])>0 && Divisible[PrimePi[n], prod]; Select[Range[100000], seqQ] (* Amiram Eldar, Mar 11 2019 *)
  • PARI
    isok(n) = isprime(n) && (pd=vecprod(digits(n))) && !(primepi(n) % pd); \\ Michel Marcus, Mar 09 2019

Formula

If a prime is to be in this sequence, its index q must obey A007954(A000040(q))/q = k, where k is an integer.

A107122 Numbers m such that m=prime(prime(prime(d_1*d_2*...*d_k))) where d_1 d_2 ... d_k is the decimal expansion of m.

Original entry on oeis.org

31, 161159, 2935241, 12393851, 25792148743, 8378273888129
Offset: 1

Views

Author

Farideh Firoozbakht, May 13 2005, May 27 2008

Keywords

Comments

a(7) > 7*10^14, if it exists. - Giovanni Resta, Jun 01 2020
The sequence is finite as m > 10^(k-1) grows faster than prime(prime(prime(9^k))) >= prime(prime(prime(d_1*d_2*...*d_k))). - Max Alekseyev, Dec 30 2024

Examples

			12393851 is in the sequence because 12393851 = prime(prime(prime(1*2*3*9*3*8*5*1))).
		

Crossrefs

Programs

  • Mathematica
    Do[h= IntegerDigits[Prime[m]];l = Length[h];If[Min[h] > 0 && m == Prime[Prime[Prime[Product[h[[k]], {k, l}]]], Print[Prime[m]]]], {m, 10000000}]

Extensions

a(6) from Giovanni Resta, Jun 01 2020

A140175 Numbers n such that n=prime((d_1*d_2*...*d_k)*(d_1+d_2+...+d_k)) where d_1d_2...d_k is the decimal expansion of n.

Original entry on oeis.org

4621, 34361, 2881861, 63882851
Offset: 1

Views

Author

Farideh Firoozbakht, Jun 09 2008

Keywords

Examples

			63882851=prime((6*3*8*8*2*8*5*1)*(6+3+8+8+2+8+5+1)).
		

Crossrefs

Cf. A097223.

Programs

  • Mathematica
    fQ[n_] := Block[{id = IntegerDigits@ n}, n == Prime[Plus @@ id Times @@ id]]; k = 1; lst = {}; While[ k < 10^8, If[ fQ@n, AppendTo[lst, k]; Print@ n]; k++ ]; lst (* Robert G. Wilson v *)

A307851 Prime numbers prime(k) with a zeroless decimal representation such that (product of decimal digits of prime(k)) / k is an integer.

Original entry on oeis.org

2, 17, 73, 89, 2475989
Offset: 1

Views

Author

Ctibor O. Zizka, May 01 2019

Keywords

Examples

			For k = 21, prime(21) = 73, product of decimal digits of prime(k) / k = 7 * 3 / 21 = 1 so prime(21) = 73 is in the sequence.
		

Crossrefs

Programs

  • PARI
    lista(nn) = {my(ip=0, d); forprime(p=2, nn, ip++; d = digits(p); if (vecmin(d) && !(frac(vecprod(d)/ip)), print1(p, ", ")););} \\ Michel Marcus, May 02 2019
    
  • Python
    from math import prod
    from sympy import nextprime
    def aupton(terms):
      p, k, t = 2, 1, 0
      while t < terms:
        strp = str(p)
        if '0' not in strp and prod(int(d) for d in strp)%k == 0:
          t += 1; print(p, end=", ")
        p, k = nextprime(p), k+1
    aupton(5) # Michael S. Branicky, Feb 17 2021

Extensions

a(5) from Alois P. Heinz, May 01 2019
Showing 1-10 of 10 results.