OFFSET
0,2
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 0..10000
Index entries for linear recurrences with constant coefficients, signature (1, 2, -2, -1, 1).
FORMULA
a(n) = a(n-1) +2*a(n-2) -2*a(n-3) -a(n-4) +a(n-5).
a(n) = 48+2*a(n-2)-a(n-4). - Ant King, Aug 16 2011
G.f.: (1+4*x+28*x^2+8*x^3+7*x^4)/((1+x)^2*(1-x)^3). - R. J. Mathar, Jul 25 2009
a(n) = (3*(-1)^n+12*n+1)*((-1)^n+4*n+1)/8. - Ant King, Aug 16 2011
Sum_{n>=0} 1/a(n) = Pi/4 + 3*log(3)/2 + sqrt(3)*log(2-sqrt(3))/2. - Amiram Eldar, Jan 13 2024
MAPLE
A014632:=n->(3*(-1)^n+12*n+1)*((-1)^n+4*n+1)/8: seq(A014632(n), n=0..100); # Wesley Ivan Hurt, Apr 28 2017
MATHEMATICA
Select[Table[n (3 n - 1)/2, {n, 100}], OddQ] (* Harvey P. Dale, Feb 03 2011 *)
PROG
(Magma) [1/8*(11+3*(-1)^(n+1)-12*(n+1))*(3+(-1)^(n+1)-4*(n+1)): n in [0..40]]; // Vincenzo Librandi, Aug 17 2011
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
EXTENSIONS
More terms from Patrick De Geest
STATUS
approved