|
|
A140991
|
|
a(n) = (1/9)*(7*2^n + (-1)^n*(3*n+2)) - (n-1)^2.
|
|
0
|
|
|
0, 1, 3, 1, 5, 7, 27, 61, 153, 331, 719, 1489, 3069, 6223, 12579, 25285, 50753, 101683, 203607, 407449, 815205, 1630711, 3261803, 6523981, 13048425, 26097307, 52195167, 104390881, 208782413, 417565471, 835131699, 1670264149
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,3
|
|
REFERENCES
|
R. L. Graham, D. E. Knuth and O. Patashnik, Concrete Mathematics, Addison-Wesley, Reading, MA, 1990, p. 327.
|
|
LINKS
|
|
|
FORMULA
|
a(n) = 3*a(n-1) - 6*a(n-3) + 3*a(n-4) + 3*a(n-5) - 2*a(n-6).
G.f.: x*(1-8*x^2+8*x^3+7*x^4)/((-1+2*x)*(1+x)^2*(x-1)^3). (End)
|
|
EXAMPLE
|
a(0) = (1/9)*(7*2^0 + (-1)^0*(3*0+2)) - (0-1)^2 = (1/9)*(7*1 + 1*(0+2)) - (-1)^2 = (1/9)*(7+2) - 1 = 1 - 1 = 0.
|
|
PROG
|
(Magma) [ (1/9)*(7*2^n+(-1)^n*(3*n+2))-(n-1)^2: n in [0..100] ]; // Vincenzo Librandi, Dec 19 2010
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|