login
A255668
Number of perfect digital invariants of order n, i.e., numbers equal to the sum of n-th powers of their digits.
3
1, 10, 2, 6, 5, 8, 3, 7, 5, 6, 3, 10, 2, 3, 3, 2, 4, 6, 2, 6, 3, 4, 2, 7, 5, 10, 2, 9, 2, 9, 2, 6, 3, 5, 3, 6, 3, 5, 5, 7, 2, 2, 4, 9, 6, 9, 5, 7, 2, 3, 2, 4, 2, 3, 6, 4, 5, 4, 2, 4, 4, 4, 3, 7, 3, 6, 3, 4, 3, 3, 4, 3, 4, 5, 3, 4, 5, 5, 3, 3, 2, 3, 2, 4, 3, 8, 3, 5, 2, 7, 3
OFFSET
0,2
COMMENTS
Row lengths of the table A252648.
For a number with d digits, the sum of n-th powers cannot exceed d*9^n, but the number is not less than 10^(d-1). Therefore there is only a finite number of possible perfect digital invariants for any n, the largest of which has at most d* digits, where d* = 1+(n*log(9)+log d*)/log(10).
FORMULA
a(n) >= 2 for all n > 0, since 0 and 1 are digital invariants for any power n > 0.
EXAMPLE
a(0)=1 because 1 is the only number equal to the sum of 0th powers of its digits.
a(1)=10 because { 0, 1, ... 9 } are the only numbers equal to the sum of their digits (taken to the power 1).
a(2)=2 because 0 and 1 are the only numbers equal to the sum of the squares of their digits.
a(3)=6 because { 0, 1, 153, 370, 371, 407 } is the set of all numbers equal to the sum of the 3rd powers of their digits, cf. A046197.
For more examples, see the table A252648.
MATHEMATICA
Reap@ For[n = 0, n < 6, n++, Sow@ Length@ Select[Range[0, 10^(n + 1)], Plus @@ (IntegerDigits[#]^n) == # &]] // Flatten // Rest (* Michael De Vlieger, Apr 14 2015 *)
KEYWORD
nonn,base
AUTHOR
M. F. Hasler, Apr 14 2015
EXTENSIONS
a(10)-a(90) from Don Knuth, Sep 09 2015
STATUS
approved