login
The OEIS Foundation is supported by donations from users of the OEIS and by a grant from the Simons Foundation.

 

Logo

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 56th year, we are closing in on 350,000 sequences, and we’ve crossed 9,700 citations (which often say “discovered thanks to the OEIS”).

Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A119558 a(1)=0,a(2)=0,a(3)=1 then a(n)=abs(a(n-1)-a(n-2))+(-1)^n*a(n-3). 1
0, 0, 1, 1, 0, 2, 1, 1, -2, 4, 5, -1, 2, 8, 7, 3, -4, 14, 15, -3, 4, 22, 21, 5, -6, 32, 33, -5, 6, 44, 43, 7, -8, 58, 59, -7, 8, 74, 73, 9, -10, 92, 93, -9, 10, 112, 111, 11, -12, 134, 135, -11, 12, 158, 157, 13, -14, 184, 185, -13, 14, 212, 211, 15, -16, 242, 243, -15, 16, 274, 273, 17, -18, 308, 309, -17, 18, 344 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,6

COMMENTS

See A104156 for an order 2 example.

REFERENCES

B. Cloitre, On strange predictible recursions, preprint 2006

LINKS

Table of n, a(n) for n=0..77.

FORMULA

for n>=1 a(4n)=(-1)^n*(2*floor(n/2)-1), a(4*n+1)=(-1)^(n+1)*2*floor(n/2), a(4*n+2)=n^2-n+2, a(4*n+3)=n^2-n+2+(-1)^n

CROSSREFS

Sequence in context: A108746 A333270 A333272 * A333450 A210112 A024735

Adjacent sequences:  A119555 A119556 A119557 * A119559 A119560 A119561

KEYWORD

sign

AUTHOR

Benoit Cloitre, May 30 2006

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified December 7 12:17 EST 2021. Contains 349581 sequences. (Running on oeis4.)