OFFSET
1,2
COMMENTS
No more terms through 10^8. - Ryan Propper, Sep 09 2005
a(13) > 10^10. - Donovan Johnson, Aug 28 2013
a(14) > 10^11. - Giovanni Resta, Aug 30 2013
EXAMPLE
a(3) = 1959 because the divisors of 1959 are [1, 3, 653, 1959] and 1+3+356+1599 = 1959.
MATHEMATICA
Do[l = IntegerDigits /@ Divisors[n]; l = Map[Sort[ # ]&, l]; k = Plus @@ Map[FromDigits[ # ]&, l]; If[k == n, Print[n]], {n, 1, 10^8}] (* Ryan Propper, Sep 09 2005 *)
Select[Range[24*10^5], Total[FromDigits[Sort[IntegerDigits[#]]]&/@Divisors[#]] == #&] (* The program generates the first 8 terms of the sequence. *) (* Harvey P. Dale, Dec 28 2022 *)
PROG
(PARI) is(n) = sumdiv(n, d, fromdigits(vecsort(digits(d))))==n \\ David A. Corneth, Dec 28 2022
(Python)
from sympy import divisors
def sa(n): return int("".join(sorted(str(n))))
def ok(n): return n == sum(sa(d) for d in divisors(n, generator=True))
print([k for k in range(1, 3*10**5) if ok(k)]) # Michael S. Branicky, Dec 28 2022
CROSSREFS
KEYWORD
nonn,base,more
AUTHOR
Jason Earls, Jun 11 2003
EXTENSIONS
More terms from Ryan Propper, Sep 09 2005
a(12) from Donovan Johnson, Aug 28 2013
a(13) from Giovanni Resta, Aug 30 2013
STATUS
approved