OFFSET
0,3
COMMENTS
A permutation of A061037(n) = -1, -3, 0, 5, 3, 21, 2, 45, 15, 77, 6, ... and of A214297(n) = -1, 0, -3, 2, 3, 6, 5, 12, ... .
Among consequences: b(n) = 4*a(n) + (sequence of period 3:repeat 1, 4, 16) = 1, 0, 4, 9, 16, 36, 25, 64, 100, ... , is a permutation of the squares of the nonnegative integers A000290(n).
And a(n)/b(n) = 0/1, -1/0, -3/4, 2/9, 3/16, 5/36, ... is a permutation of the Balmer series A061037(n)/A061038(n) = -1/0, -3/4, 0/1, 5/36, 3/16, ... .
a(5n) is divisible by 5.
LINKS
Colin Barker, Table of n, a(n) for n = 0..1000
Index entries for linear recurrences with constant coefficients, signature (0,0,3,0,0,-3,0,0,1).
FORMULA
a(n) = 3*a(n-3) - 3*a(n-6) + a(n-9).
a(3*k) + a(3*k+1) + a(3*k+2) = 9*k^2 + 5*k - 4.
G.f.: x*(3*x^7 - 3*x^6 - 14*x^4 - 6*x^3 - 2*x^2 + 3*x + 1)/((x-1)^3*(x^2 +x+1)^3). - Robert Israel, Dec 01 2014
a(n) = -(n^2 + n + floor(n/3)*(27*floor(n/3)^3 - 18*(n+1)*floor(n/3)^2 + (3*n^2 + 21*n - 14)*floor(n/3) - (5*n^2 - n + 5)))/2. - Luce ETIENNE, Mar 13 2017
From Amiram Eldar, Oct 08 2023: (Start)
Sum_{n>=1} 1/a(n) = 1/2.
Sum_{n>=1} (-1)^n/a(n) = Pi/4 + 1 - 2*log(2). (End)
MAPLE
seq(op([k*(k+1), (2*k-1)*(2*k+1), (2*k-1)*(2*k+3)]), k=0..100); # Robert Israel, Dec 01 2014
MATHEMATICA
Table[Sequence @@ {n*(n+1), (2*n-1)*(2*n+1), (2*n-1)*(2*n+3)}, {n, 0, 18}] (* Jean-François Alcover, Dec 16 2014 *)
PROG
(PARI) concat(0, Vec(x*(3*x^7-3*x^6-14*x^4-6*x^3-2*x^2+3*x+1)/((x-1)^3*(x^2+x+1)^3) + O(x^100))) \\ Colin Barker, Dec 02 2014
(Magma) m:=50; R<x>:=PowerSeriesRing(Integers(), m); [0] cat Coefficients(R!(x*(3*x^7-3*x^6-14*x^4-6*x^3-2*x^2+3*x+1)/((x-1)^3*(x^2 +x+1)^3))); // G. C. Greubel, Sep 20 2018
CROSSREFS
KEYWORD
sign,easy
AUTHOR
Paul Curtz, Dec 01 2014
STATUS
approved