|
|
A083367
|
|
Numbers k that are equal to the sum of its divisors after the digits of each divisor have been sorted in ascending order.
|
|
0
|
|
|
1, 60, 1959, 149587, 277947, 1449933, 2222863, 2396214, 24918486, 25354845, 48878262, 1673533845, 24753647943
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
COMMENTS
|
|
|
LINKS
|
|
|
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))
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,base,more
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|