A289354 Number of 9-digit numbers whose sum of digits is n.
1, 9, 45, 165, 495, 1287, 3003, 6435, 12870, 24309, 43741, 75465, 125445, 201675, 314523, 477015, 705012, 1017225, 1435005, 1981845, 2682559, 3562131, 4644255, 5949615, 7493982, 9286233, 11326425, 13604085, 16096905, 18770031, 21576079, 24455955, 27340500, 30152925, 32811945, 35235465, 37344615, 39067875, 40344975, 41130255, 41395240, 41130255, 40344975, 39067875, 37344615, 35235465, 32811945, 30152925, 27340500, 24455955, 21576079, 18770031, 16096905, 13604085, 11326425, 9286233, 7493982, 5949615, 4644255, 3562131, 2682559, 1981845, 1435005, 1017225, 705012, 477015, 314523, 201675, 125445, 75465, 43741, 24309, 12870, 6432, 3003, 1287, 495, 165, 45, 9, 1
Offset: 1
Examples
a(2)=9: 100000001, 100000010, 100000100, 100001000, 100010000, 100100000, 101000000, 11000000, 20000000.
Links
- Miquel Cerda, Table of n, a(n) for n = 1..81
Crossrefs
Programs
-
Mathematica
With[{d = 9}, Rest@ CoefficientList[Series[(x - x^10)/(1 - x) ((1 - x^10)/(1 - x))^(d - 1), {x, 0, 9 d}], x]] (* Michael De Vlieger, Jul 04 2017 *)
Formula
a(n) = a(82 - n). - David A. Corneth, Jul 03 2017
G.f.: (x - x^10)/(1 - x)*((1 - x^10)/(1 - x))^8 - Michael De Vlieger, Jul 04 2017
Comments