OFFSET
1,4
LINKS
Michael De Vlieger, Table of n, a(n) for n = 1..10000
Saeid Azam, Masaya Tomie, and Yoji Yoshii, Classification of pointed reflection spaces, Osaka J. Math. (2021) Vol. 58, 563-589.
Index entries for linear recurrences with constant coefficients, signature (1,1,0,0,-2,0,0,1,1,-1).
FORMULA
a(n) = (1/8)*n*(n-2) + 2*(Sum_{k=3..n/2} p(k,3)) + p((n+2)/2,3) if n is even; a(n) = 2*floor((n-1)/4)*floor((n+1)/4) + 2*(Sum_{k=3..(n-1)/2} p(k,3)) + p((n+1)/2,3) + p((n+3)/2,3) if n is odd, where p(k,3) = A069905(k) is the number of partitions of k into three parts.
From Andrew Howroyd, Oct 29 2020: (Start)
a(n) = a(n-1) + a(n-2) - 2*a(n-5) + a(n-8) + a(n-9) - a(n-10) for n > 10.
G.f.: x^3*(1 + x + x^2 - x^4 - x^5)/((1 - x)^4*(1 + x)^2*(1 + x^2)*(1 + x + x^2)).
(End)
MATHEMATICA
F[n_] := If[EvenQ[n],
n (n - 2)/8 +
2*Sum[Length[IntegerPartitions[k, {3}]], {k, 3, n/2}] +
Length[IntegerPartitions[(n + 2)/2, {3}]],
2*Floor[(n - 1)/4]*Floor[(n + 1)/4] +
2*Sum[Length[IntegerPartitions[k, {3}]], {k, 3, (n - 1)/2}] +
Length[IntegerPartitions[(n + 1)/2, {3}]] +
Length[IntegerPartitions[(n + 3)/2, {3}]]]
(* Second program: *)
LinearRecurrence[{1, 1, 0, 0, -2, 0, 0, 1, 1, -1}, {0, 0, 1, 2, 4, 6, 9, 12, 17, 21}, 55] (* Jean-François Alcover, Nov 13 2020 *)
PROG
(PARI) concat([0, 0], Vec((1 + x + x^2 - x^4 - x^5)/((1 - x)^4*(1 + x)^2*(1 + x^2)*(1 + x + x^2)) + O(x^50))) \\ Andrew Howroyd, Oct 29 2020
CROSSREFS
KEYWORD
nonn,easy
AUTHOR
Masaya Tomie, Oct 16 2020
STATUS
approved