OFFSET
0,2
COMMENTS
a(n) = 4^(n+1)*H(2^n)/5 with H(2^n) = n+(6+(-1)^n/4^(n+1))/5 = E(N(2^n)), where X, X(1), X(2),... denote random variables with pdf P(X = 1) = P(X = 4) = 1/5 and P(X = 2) = 3/5, N(x) is the first value of k such that X(1)*X(2)*...*X(k) > x and H(x)= E(N(x)).
LINKS
Colin Barker, Table of n, a(n) for n = 0..1000
Index entries for linear recurrences with constant coefficients, signature (7,-8,-16).
FORMULA
a(n) = (n*4^(n+1) + (6*4^(n+1)+(-1)^n)/5)/5.
From Colin Barker, May 03 2017: (Start)
G.f.: 1 / ((1 + x)*(1 - 4*x)^2).
a(n) = 7*a(n-1) - 8*a(n-2) - 16*a(n-3) for n>2.
(End)
E.g.f.: (80*x*exp(4*x)+24*exp(4*x)+exp(-x))/25. - Robert Israel, May 03 2017
MAPLE
seq((n*4^(n+1) + (6*4^(n+1)+(-1)^n)/5)/5, n=0..50); # Robert Israel, May 03 2017
MATHEMATICA
CoefficientList[Series[1/((1 + x) (1 - 4 x)^2), {x, 0, 23}], x] (* or *)
LinearRecurrence[{7, -8, -16}, {1, 7, 41}, 24] (* Michael De Vlieger, May 03 2017 *)
PROG
(PARI) a(n)= (n*4^(n+1)+(6*4^(n+1)+(-1)^n)/5)/5; \\ Michel Marcus, Oct 16 2014
(PARI) Vec(1 / ((1 + x)*(1 - 4*x)^2) + O(x^30)) \\ Colin Barker, May 03 2017
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Edward Omey, Jun 16 2011
EXTENSIONS
Formula corrected and more terms from Michel Marcus, Oct 16 2014
Edited by M. F. Hasler, Oct 16 2014
STATUS
approved