login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A119557 a(1)=0,a(2)=0,a(3)=1 then a(n)=abs(a(n-1)-a(n-2))-a(n-3). 1
0, 0, 1, 1, 0, 0, -1, 1, 2, 2, -1, 1, 0, 2, 1, 1, -2, 2, 3, 3, -2, 2, 1, 3, 0, 2, -1, 3, 2, 2, -3, 3, 4, 4, -3, 3, 2, 4, -1, 3, 0, 4, 1, 3, -2, 4, 3, 3, -4, 4, 5, 5, -4, 4, 3, 5, -2, 4, 1, 5, 0, 4, -1, 5, 2, 4, -3, 5, 4, 4, -5, 5, 6, 6, -5, 5, 4, 6, -3, 5, 2, 6, -1, 5, 0, 6, 1, 5, -2, 6, 3, 5, -4, 6, 5, 5, -6, 6, 7, 7 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,9

COMMENTS

See A104156 for an order 2 example.

b(n) = a(2n)-floor(sqrt(n))+1 is an infinite binary word consisting in a sequence of block (0,1) and single 0's where 0's occur when n is of form k^2-1, k>=2 i.e. b(n) begins for n>=1 : (0,1),0,(0,1),(0,1),0,(0,1),(0,1),(0,1),0,(0,1),... and single 0's occur at n=3,8,15,...

REFERENCES

B. Cloitre, On strange predictible recursions, preprint 2006

LINKS

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

FORMULA

abs(a(2n-1)) = A004738(n)-1 where sign(a(2*n-1)) alternates between 2 consecutive zeros.

PROG

(PARI) an=vector(10000); an[1]=0; an[2]=0; an[3]=1; a(n)=if(n<0, 0, an[n]);

for(n=4, 10000, an[n]=abs(a(n-1)-a(n-2))-a(n-3))

an

CROSSREFS

Cf. A104156.

Sequence in context: A112183 A275451 A269317 * A125919 A241079 A061198

Adjacent sequences:  A119554 A119555 A119556 * A119558 A119559 A119560

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 | More pages
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy .

Last modified September 24 22:31 EDT 2017. Contains 292441 sequences.