OFFSET
1,1
COMMENTS
a(n) = n*(n+1) if n is odd and n*(n+2) if n is even. - Wesley Ivan Hurt, Nov 19 2013
From Rolf Knobel, Dec 27 2023: (Start)
The first term of the continued fraction also divides k since it is half the last term of the periodic part. Except for a(1), the period is 2 (see A013642). -
REFERENCES
H. Davenport, The Higher Arithmetic. Cambridge Univ. Press, 7th edition, 1999, Table 1.
Kenneth H. Rosen, Elementary Number Theory and Its Applications, Addison-Wesley, 1984, page 426 (but beware of errors!).
LINKS
Harvey P. Dale, Table of n, a(n) for n = 1..1000
Index entries for linear recurrences with constant coefficients, signature (1,2,-2,-1,1).
FORMULA
a(2n) = 2*(n+1)*(2n), a(2n+1) = 2*(n+1)*(2n+1). - Frank Ellermann, Feb 22 2002
G.f.: (-2-6*x)/((x+1)^2*(x-1)^3). - Maksym Voznyy (voznyy(AT)mail.ru), Aug 10 2009
a(n) = n * (n + 1 + (1+(-1)^n)/2). - Wesley Ivan Hurt, Nov 19 2013
MAPLE
MATHEMATICA
Table[n(n+1+(1+(-1)^n)/2), {n, 100}] (* Wesley Ivan Hurt, Nov 19 2013 *)
Table[If[OddQ[n], n(n+1), n(n+2)], {n, 50}] (* Harvey P. Dale, May 15 2021 *)
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
EXTENSIONS
More terms from David W. Wilson
Name clarified by Rolf Knobel, Dec 27 2023
STATUS
approved