OFFSET
0,2
LINKS
R. H. Hardin, Table of n, a(n) for n=0..500
Index entries for linear recurrences with constant coefficients, signature (2).
FORMULA
a(n) = 113*2^(n-7) for n >= 8. - Brad Clardy, Feb 11 2012
G.f.: (2*x^8+2*x^7+2*x^6+2*x^5-1)/(2*x-1). - Alois P. Heinz, Aug 17 2019
MATHEMATICA
CoefficientList[Series[(2x^8+2x^7+2x^6+2x^5-1)/(2x-1), {x, 0, 50}], x] (* or *) LinearRecurrence[{2}, {1, 2, 4, 8, 16, 30, 58, 114, 226}, 50] (* Harvey P. Dale, Apr 23 2022 *)
PROG
(Empirical) (bc) (z is number of 0's) z=4; for(i=0; i<=500; i++) { if(i<=z)a=2^i else if(i<=2*z)a=2*a-2 else a=2*a; a }
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
R. H. Hardin, Aug 11 2009
STATUS
approved