OFFSET
0,3
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 0..1000
Eric Weisstein's World of Mathematics, Pentagonal Number
Wikipedia, Pentagonal number
Wikipedia, Platonic Solid
Wolfram MathWorld, Platonic Solid
Index entries for linear recurrences with constant coefficients, signature (1,2,-2,-1,1).
FORMULA
a(n) = n * floor(3n/2) = n * A032766(n).
a(n) = a(n-1) + 2*a(n-2) - 2*a(n-3) - a(n-4) + a(n-5). - Colin Barker, Oct 22 2014
G.f.: -x*(2*x^3+4*x^2+5*x+1) / ((x-1)^3*(x+1)^2). - Colin Barker, Oct 22 2014
a(n) = 3/2 * n^2 + ((-1)^n-1) * n/4. E.g.f.: ((3/2)*x^2+(5/4)*x)*exp(x)-(x/4)*exp(-x). - Robert Israel, Oct 26 2014
EXAMPLE
For n=5, a(n) = 5*floor(15/2) = 5*7 = 35.
MAPLE
seq(n*floor(3*n/2), n=0..100); # Robert Israel, Oct 26 2014
MATHEMATICA
Table[n Floor[3 n/2], {n, 0, 100}] (* Vincenzo Librandi, Oct 22 2014 *)
PROG
(Python)
from math import *
{print(int(n*floor(3*n/2)), end=', ') for n in range(101)}
(PARI) a(n)=3*n\2*n \\ Charles R Greathouse IV, Oct 21 2014
(Magma) [n*Floor(3*n/2): n in [0..60]]; // Vincenzo Librandi, Oct 22 2014
(PARI) concat(0, Vec(-x*(2*x^3+4*x^2+5*x+1)/((x-1)^3*(x+1)^2) + O(x^100))) \\ Colin Barker, Oct 22 2014
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Karl V. Keller, Jr., Oct 21 2014
STATUS
approved