OFFSET
0,2
COMMENTS
a(n) is the number of strings of n+1 decimal digits having an odd number of 0's. For 2 digits these are for example the 18 strings 01, 02, 03, ..., 09, 10, 20, 30, ..., 90. - Geoffrey Critzer, Jan 24 2011
LINKS
G. C. Greubel, Table of n, a(n) for n = 0..990
Index entries for linear recurrences with constant coefficients, signature (18,-80).
FORMULA
From R. J. Mathar, Sep 18 2008: (Start)
a(n) = 5*10^n - 4*8^n = A081203(n+1).
Binomial transform of A081035. (End)
From Geoffrey Critzer, Jan 24 2011: (Start)
a(n) = 8*a(n-1) + 10^(n-1).
E.g.f.: exp(9*x)*sinh(x) (with offset 1). (End)
A060531(n) = a(n) - 9*a(n-1). - R. J. Mathar_, Jan 27 2011
From Vincenzo Librandi, Feb 09 2011: (Start)
a(n) = 10*a(n-1) + 8^n, a(0)=1.
a(n) = 18*a(n-1) - 80*a(n-2), a(0)=1, a(1)=18. (End)
E.g.f.: exp(9*x)*( cosh(x) + 9*sinh(x) ). - G. C. Greubel, Nov 14 2024
MATHEMATICA
Rest@With[{m=30}, CoefficientList[Series[Exp[9 x] Sinh[x], {x, 0, m}], x]*Range[0, m]!]
Table[2^n*(5^(n+1)-4^(n+1)), {n, 0, 40}] (* Vladimir Joseph Stephan Orlovsky, Feb 09 2011 *)
LinearRecurrence[{18, -80}, {1, 18}, 30] (* Harvey P. Dale, Aug 26 2019 *)
PROG
(PARI) Vec(1/((1-8*x)*(1-10*x))+O(x^99)) \\ Charles R Greathouse IV, Sep 24 2012
(Magma) [2^n*(5^(n+1)-4^(n+1)): n in [0..40]]; // G. C. Greubel, Nov 14 2024
(SageMath)
A016186=BinaryRecurrenceSequence(18, -80, 1, 18)
print([A016186(n) for n in range(41)]) # G. C. Greubel, Nov 14 2024
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
EXTENSIONS
More terms added by G. C. Greubel, Nov 14 2024
STATUS
approved