OFFSET
1,2
LINKS
G. E. Andrews, Further Problems on Partitions, Amer. Math. Monthly 94 (1987), no. 5, 437-439.
Index entries for linear recurrences with constant coefficients, signature (1,0,1,-1,0,-1,1,0,1,-1,0,-1,1,0,1,-1,0,-1,1,0,1,-1).
FORMULA
From Colin Barker, Dec 01 2019: (Start)
G.f.: x*(1 + x)*(1 + x^2 + x^4 - x^5 + x^6 + x^8 + x^12 + x^14 - x^15 + x^16 + x^18 + x^20) / ((1 - x)^2*(1 + x^2)*(1 + x + x^2)*(1 - x^2 + x^4)*(1 + x^4)*(1 - x^4 + x^8)).
a(n) = a(n-1) + a(n-3) - a(n-4) - a(n-6) + a(n-7) + a(n-9) - a(n-10) - a(n-12) + a(n-13) + a(n-15) - a(n-16) - a(n-18) + a(n-19) + a(n-21) - a(n-22) for n>22.
(End)
MATHEMATICA
okQ[n_] := OddQ[n] || AnyTrue[{2, 8, 12, 14, 18, 20, 24, 30}, Mod[n, 32] == #&];
Select[Range[100], okQ] (* Jean-François Alcover, Mar 09 2023 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, Nov 29 2019
STATUS
approved