A255375 Number of strings of n decimal digits that contain at least one string of exactly 5 consecutive "0" digits.
0, 0, 0, 0, 0, 1, 18, 261, 3420, 42300, 504000, 5849991, 66599757, 746995383, 8279925399, 90898904070, 989984885400, 10709800740081, 115197460652916, 1232968482968526, 13139617033315116, 139495426762343121, 1475946175849599240, 15569374280153300271
Offset: 0
Links
- Alois P. Heinz, Table of n, a(n) for n = 0..1000
- Index entries for linear recurrences with constant coefficients, signature (20,-100,0,0,0,-9,99,-90).
Crossrefs
Programs
-
Mathematica
LinearRecurrence[{20,-100,0,0,0,-9,99,-90},{0,0,0,0,0,1,18,261},30] (* Harvey P. Dale, Dec 12 2023 *)
Formula
a(0) = a(1) = ... = a(4) = 0, a(5) = 1, a(n) = 9*(10^(n-6) - a(n-6) + sum_{i=5..n-1} a(i)) for n>=6.
G.f.: x^5*(x-1)^2/((10*x-1)*(9*x^7-9*x^6+10*x-1)). - Alois P. Heinz, Feb 26 2015