login
A357263
Numbers k such that the sum of the distinct digits of k is equal to the product of the prime divisors of k.
0
1, 2, 3, 5, 6, 7, 24, 343, 375, 392, 640, 686, 2401, 3375, 4802, 4913, 6400, 13122, 14336, 14641, 30375, 33614, 64000, 468750, 640000, 1703936, 2725888, 2839714, 2883584, 4687500, 5537792, 6298560, 6400000, 7864320, 13668750, 14172488, 19267584, 21807104, 26040609, 28629151
OFFSET
1,2
COMMENTS
64*10^k is a term of the sequence for every positive integer k.
EXAMPLE
375 = 3*5^3. 3+7+5 = 3*5. Thus 375 is a term.
MATHEMATICA
Select[Range[10^6], Plus @@ Union[IntegerDigits[#]] == Times @@ FactorInteger[#][[;; , 1]] &] (* Amiram Eldar, Sep 21 2022 *)
PROG
(PARI) isok(k) = vecsum(Set(digits(k))) == vecprod(factor(k)[, 1]);
(Python)
from math import prod
from sympy import primefactors
def ok(n): return n and sum(map(int, set(str(n)))) == prod(primefactors(n))
print([k for k in range(10**5) if ok(k)]) # Michael S. Branicky, Sep 22 2022
CROSSREFS
Sequence in context: A146747 A077674 A343742 * A067077 A370688 A357132
KEYWORD
nonn,base
AUTHOR
Alexandru Petrescu, Sep 21 2022
EXTENSIONS
More terms from Michel Marcus, Sep 21 2022
STATUS
approved