OFFSET
0,2
COMMENTS
Numbers of the form m*(7*m + 2) for m = 0, -1, 1, -2, 2, -3, 3, ... - Bruno Berselli, Feb 26 2018
LINKS
Index entries for linear recurrences with constant coefficients, signature (1,2,-2,-1,1).
FORMULA
a(2*k) = k*(7*k + 2), a(2*k + 1) = 7*k^2 + 12*k + 5.
a(n) = n^2 + n + 3*ceiling(n/2)^2. - Gary Detlefs, Feb 23 2010
G.f.: -x*(5*x^2 + 4*x + 5)/((x - 1)^3*(x + 1)^2). - Colin Barker, Oct 24 2012
Sum_{n>=1} 1/a(n) = 7/4 - cot(2*Pi/7)*Pi/2. - Amiram Eldar, Mar 15 2022
MAPLE
seq(n^2+n+3*ceil(n/2)^2, n=0..48); # Gary Detlefs, Feb 23 2010
MATHEMATICA
f[n_]:=IntegerQ[Sqrt[1+7*n]]; Select[Range[0, 8! ], f[ # ]&] (* Vladimir Joseph Stephan Orlovsky, Feb 19 2010 *)
PROG
(Magma) [n^2+n+3*Ceiling(n/2)^2: n in [0..50]]; // Wesley Ivan Hurt, Jul 07 2014
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Mohamed Bouhamida, Nov 08 2007
EXTENSIONS
More terms from Max Alekseyev, Nov 13 2009
Better definition from Max Alekseyev, Oct 24 2012
STATUS
approved