OFFSET
1,2
LINKS
Nathaniel Johnston, Table of n, a(n) for n = 1..500
FORMULA
Binomial transform of A143098: (1, 2, -1, 2, 2, -1, 2, 2, -1, 2, 2, ...).
From R. J. Mathar, Jul 31 2008: (Start)
G.f.: (3x^3 - 2x^2 - x + 1)*x/((x^2-x+1)*(2x-1)*(x-1)).
a(n) = -1 + 2^(n-1) + A057079(n-1). (End)
EXAMPLE
a(4) = 6 = (1, 3, 3, 1) dot (1, 2, -1, 2) = (1 + 6 - 3 + 2).
MAPLE
A143098 := proc(n) if(n=1)then return 1: elif(n mod 3 = 0)then return -1: else return 2: fi: end: A143100 := proc(n) return add(binomial(n-1, k-1)*A143098(k), k=1..n): end: seq(A143100(n), n=1..34); # Nathaniel Johnston, Apr 30 2011
CROSSREFS
KEYWORD
nonn
AUTHOR
Gary W. Adamson, Jul 24 2008
STATUS
approved