OFFSET
0,4
COMMENTS
This sequence is very similar (actually equal, for 1 <= n <= 9) to A277635, which was the original motivation for considering the family A277830 - A277838 and A277849. The main difference is that A277635 is based on A007908 (where 123456789 is followed by 12345678910) while this family is based on A014824, starts as the latter at offset 0, and therefore has a strongly different growth for n > 9.
LINKS
David A. Corneth, Table of n, a(n) for n = 0..998
FORMULA
EXAMPLE
For n=2 there is only one digit '7' in the sequence 0, 1, 2, ..., 12.
For n=3 there are 11 + 10 = 21 more digits '7' in { 17, 27, ..., 67, 70, ..., 79, 87, 97, 107, 117 }, where 77 accounts for two '7's.
PROG
(PARI) print1(c=N=0); for(n=1, 8, print1(", "c+=sum(k=N+1, N=N*10+n, #select(d->d==7, digits(k)))))
(PARI) A277837(n, m=7)=if(n>16, error("n>16 not yet implemented"), n>m, A277837(n, m+1)+(m+2)*10^(n-m-1), (9*n-11)*(10^n+1)\729+2-(m>n)) \\ Edited by M. F. Hasler, Dec 29 2020
CROSSREFS
KEYWORD
nonn,base
AUTHOR
M. F. Hasler, Nov 01 2016
EXTENSIONS
More terms from Lars Blomberg, Nov 05 2016
Removed incorrect b-file. - David A. Corneth, Dec 31 2020
STATUS
approved