OFFSET
0,2
COMMENTS
Taken modulo 3 yields 1,0,2,0,2,0,2,0,2,...; a(n) is congruent to 0 or 2 (mod 3) for n > 0.
LINKS
FORMULA
a(n) = 3*floor((n + 1)/2) + 2*((n+1) mod 2) - 0^n.
a(n) = Sum_{k=0..n} Sum_{j=0..n} binomial(floor((n + k + j)/3), k)*binomial(k, floor((n + k + j)/3)).
G.f.: 1 - x*(-3 - 2*x + 2*x^2)/((1 + x)*(x - 1)^2). - R. J. Mathar, Oct 25 2011
E.g.f.: ((4 + 3*x)*cosh(x) + 3*(1 + x)*sinh(x) - 2)/2. - Stefano Spezia, Feb 20 2023
MATHEMATICA
Join[{1, 3}, LinearRecurrence[{1, 1, -1}, {5, 6, 8}, 100]] (* Vladimir Joseph Stephan Orlovsky, Jan 31 2012 *)
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Paul Barry, Nov 13 2005
STATUS
approved