|
|
A115360
|
|
Period 6: repeat [1,-1,1,0,0,0].
|
|
2
|
|
|
1, -1, 1, 0, 0, 0, 1, -1, 1, 0, 0, 0, 1, -1, 1, 0, 0, 0, 1, -1, 1, 0, 0, 0, 1, -1, 1, 0, 0, 0, 1, -1, 1, 0, 0, 0, 1, -1, 1, 0, 0, 0, 1, -1, 1, 0, 0, 0, 1, -1, 1, 0, 0, 0, 1, -1, 1, 0, 0, 0, 1, -1, 1, 0, 0, 0, 1, -1, 1, 0, 0, 0, 1, -1, 1, 0, 0, 0, 1, -1, 1
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
0,1
|
|
COMMENTS
|
Diagonal sums of number triangle A115359.
|
|
LINKS
|
|
|
FORMULA
|
G.f.: 1/(1 + x - x^3 - x^4) = 1/( (1+x)*(1-x)*(1+x+x^2)).
a(n) = -a(n-1) + a(n-3) + a(n-4), n > 3.
a(n) = cos(2*Pi*n/3)/3 - sin(2*Pi*n/3)/sqrt(3) + cos(Pi*n)/2 + 1/6.
a(n) = Sum_{k=0..floor(n/2)} if(n-k=k, 1, 0) OR if(n-k=2k+1, -1, 0).
a(n) = (1/2)*((-1)^n + i^(4-2*(n mod 3))), where i=sqrt(-1). - Bruno Berselli, Oct 31 2012
|
|
MATHEMATICA
|
LinearRecurrence[{-1, 0, 1, 1}, {1, -1, 1, 0}, 100] (* Vincenzo Librandi, Sep 09 2015 *)
|
|
PROG
|
|
|
CROSSREFS
|
|
|
KEYWORD
|
sign,easy
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|