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.

A068186 a(n) is the largest number whose product of decimal digits equals n^n.

Original entry on oeis.org

22, 333, 22222222, 55555, 333333222222, 7777777, 222222222222222222222222, 333333333333333333, 55555555552222222222, 0, 333333333333222222222222222222222222, 0, 7777777777777722222222222222
Offset: 2

Views

Author

Labos Elemer, Feb 19 2002

Keywords

Comments

No digit=1 is permitted to avoid infinite number of solutions; a(n)=0 if A067734(n^n)=0.

Examples

			n=10, 10^10=10000000000, a(5)=55555555552222222222.
		

Crossrefs

Programs

  • Python
    from sympy import factorint
    def A068186(n):
        if n == 1:
            return 1
        pf = factorint(n)
        ps = sorted(pf.keys(),reverse=True)
        if ps[0] > 7:
            return 0
        s = ''
        for p in ps:
            s += str(p)*(n*pf[p])
        return int(s) # Chai Wah Wu, Aug 12 2017

Formula

a(n) is obtained as prime factors of n^n concatenated in order of magnitude and with repetitions; a(n)=0 if n has p > 7 prime factors.

Extensions

a(12) corrected by Chai Wah Wu, Aug 12 2017