The OEIS is supported by the many generous donors to the OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A217974 The ZEBRA Sequence. 0
 26, 5, 2, 18, 1, 24, 1, 0, 13, 6, 24, 6, 0, 12, 11, 24, 11, 0, 6, 12, 24, 12, 0, 5, 18, 24, 18, 0, 7, 19, 24, 19, 0, 11, 17, 24, 17, 0, 8, 13, 24, 13, 0, 9, 16, 24, 16, 0, 4, 15, 24, 15, 0, 12, 20, 24, 20, 0, 3, 12, 24, 12, 0, 17, 21, 24, 21, 0, 5, 7, 24, 7, 0, 16, 19, 24, 19, 0, 9, 8, 24, 8, 0, 10, 15, 24, 15, 0, 2, 14, 24, 14, 0, 13, 22, 24, 22, 0, 1, 11, 24, 11, 0, 21, 23, 24, 23, 0, 10, 3, 24, 3, 0, 13, 14, 24, 14, 0, 10, 11, 24, 11, 0, 4, 14, 24, 14, 0, 7, 20, 24, 20, 0, 7, 17, 24, 17, 0, 13, 17, 24, 17, 0, 4, 11, 24, 11, 0 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,1 COMMENTS If a=1, b=2... Then ZEBRA = 26,5,2,18,1. Let the 1st, 3rd, 5th, etc. terms of the sequence be "Black" numbers, and the 2nd, 4th, 6th, etc. be "White" numbers. Using the first 5 terms as a starting point, to calculate the n-th term, one needs to calculate B(n), the n-th black number using B(n) = B(n-1) - B(n-2). If one runs out of Black numbers to calculate, switch over and calculate White numbers, using the formula W(n) = W(n-1) - W(n-2). There are no negative terms, so if a negative term appears, multiply it by -1. A pattern begins to appear: in every group of 5 after the first 8 terms, the 5th term = 0, the middle term = 24 and the 2nd term = 4th term. LINKS Table of n, a(n) for n=1..148. FORMULA B(n) = |B(n-1) - B(n-2)|, W(n) = |W(n-1) - W(n-2)|. EXAMPLE First 5 terms; 26,5,2,18,1 Black numbers = 26, 2, 1 White numbers = 5, 18 To calculate the 6th term, Use the formula B(n) = B(n-1) - B(n-2) 6th term = 2 - 26 = -24. But there are no negative terms, so 6th term = 24 7th term = 2 - 1 = 1 8th term = 1 - 1 = 0 We can no longer calculate Black numbers, so we switch to calculating White numbers. 9th term = 1st White term - 2nd White term = 5 - 18 = -13 => No negative terms => 9th term = 13 10th term = 18 - 24 = -6 => 6 11th term = 24 - 0 = 24 CROSSREFS Sequence in context: A040662 A082058 A040658 * A040659 A073029 A040657 Adjacent sequences: A217971 A217972 A217973 * A217975 A217976 A217977 KEYWORD nonn AUTHOR Brian J. Tyrrell, Oct 16 2012 STATUS approved

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

Last modified February 27 19:47 EST 2024. Contains 370378 sequences. (Running on oeis4.)