login
A242622
a(n) = number of numbers with digit sum n, not greater than the n-th repunit (cf. A052222).
4
1, 1, 2, 6, 21, 77, 287, 1079, 4082, 15522, 59271, 227131, 873051, 3364827, 12998867, 50321075, 195162350, 758156366, 2949614789, 11490869489, 44819531180, 175009397380, 684059403670, 2676260628574, 10479320689274, 41065736472890, 161043272100440, 631974335773536
OFFSET
0,3
COMMENTS
a(n) = length of row n in triangle A242614.
LINKS
Jens Kruse Andersen, Table of n, a(n) for n = 0..100
PROG
(Haskell)
a242622 = length . a242614_row
(PARI) \\ c[x, y] = #numbers < 10^x with digit sum y-1.
m=50; c=matrix(m, m+1); for(x=1, m, for(y=1, m+1, c[x, y]=sum(d=0, min(9, y-1), if(x>1, c[x-1, y-d], d==y-1)))); for(n=0, m, print1(1+sum(i=2, n, c[i-1, i+1])", ")); \\ Jens Kruse Andersen, Jul 17 2014
CROSSREFS
Sequence in context: A294825 A101265 A101879 * A279561 A360150 A294048
KEYWORD
nonn,base
AUTHOR
Reinhard Zumkeller, Jul 16 2014
EXTENSIONS
More terms from Jens Kruse Andersen, Jul 17 2014
STATUS
approved