cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-3 of 3 results.

A329230 The number of steps it takes to reach all n positions around a circle during the grasshopper procedure.

Original entry on oeis.org

1, 2, 3, 4, 10, 9, 7, 8, 23, 17, 16, 21, 20, 27, 29, 16, 58, 25, 28, 30, 40, 43, 88, 50, 40, 55, 87, 50, 62, 59, 70, 32, 81, 72, 67, 91, 84, 73, 71, 125, 107, 113, 69, 88, 148, 116, 135, 113, 158, 95, 137, 114, 182, 123, 174, 166, 112, 146, 215, 173, 126, 171
Offset: 1

Views

Author

Peter Kagey, Nov 08 2019

Keywords

Comments

The grasshopper procedure: n positions are evenly spaced around a circle, a grasshopper hops randomly to any position, after the k-th hop, the grasshopper looks clockwise and counterclockwise k positions. If one of the positions has been visited less often then the other, it hops there; if both positions have been visited an equal number of times, it hops k steps in the clockwise position. (See Mathematics Stack Exchange link for more details.)
In the Mathematics Stack Exchange link, the author conjectures that a(n) = n if and only if n = 3, n = 7, or n = 2^k for some nonnegative k.

Examples

			For n = 5 the a(5) = 10 steps are:
  [0,0,0,0,0] (randomly step to first position)
  [1,0,0,0,0] (length 1 clockwise (right) step)
  [1,1,0,0,0] (length 2 clockwise (right) step)
  [1,1,0,1,0] (length 3 clockwise (right) step)
  [1,2,0,1,0] (length 4 counterclockwise (left) step)
  [1,2,1,1,0] (length 5 clockwise (right) step)
  [1,2,2,1,0] (length 6 clockwise (right) step)
  [1,2,2,2,0] (length 7 clockwise (right) step)
  [2,2,2,2,0] (length 8 clockwise (right) step)
  [2,2,2,3,0] (length 9 counterclockwise (left) step)
  [2,2,2,3,1]
For example, the length 4 counterclockwise step occurs because stepping clockwise would result in landing in a position which has been visited once, and stepping counterclockwise would result in landing in a position which has not been visited before.
		

Crossrefs

A329231 The maximum number of times one reaches a single position during the grasshopper procedure.

Original entry on oeis.org

1, 1, 1, 1, 3, 2, 1, 1, 4, 3, 3, 3, 3, 3, 3, 1, 5, 2, 3, 3, 4, 3, 5, 3, 3, 4, 5, 3, 4, 4, 4, 1, 4, 4, 3, 4, 4, 3, 3, 5, 4, 5, 3, 3, 4, 4, 5, 4, 6, 4, 5, 4, 5, 4, 5, 4, 4, 4, 5, 5, 4, 5, 5, 1, 4, 4, 5, 3, 4, 5, 5, 4, 4, 7, 4, 4, 4, 5, 5, 5, 4, 4, 4, 4, 4, 5, 4
Offset: 1

Views

Author

Peter Kagey, Nov 08 2019

Keywords

Comments

The grasshopper procedure: n positions are evenly spaced around a circle, a grasshopper hops randomly to any position, after the k-th hop, the grasshopper looks clockwise and counterclockwise k positions. If one of the positions has been visited less often then the other, it hops there; if both positions have been visited an equal number of times, it hops k steps in the clockwise position. (See Mathematics Stack Exchange link for more details.)
a(n) >= (A329230(n)-1)/(n-1).
Least values of n such that a(n) = 1, 2, 3, etc are 1, 6, 5, 9, 17, 49, 74, 198, 688, 1745 etc.
Conjecture: a(n) = 1 if and only if n = 3, n = 7, or n = 2^k for some k.
Conjecture: The largest values of n for which a(n) = 2, 3, 4, 5 respectively are n = 18, 68, 381, 1972.
If the second conjecture is true, then 2, 3, 4, and 5 appear 2, 19, 87, and 313 times respectively.
Conjecture: Every integer greater than 1 appears in this sequence a finite number of times.

Crossrefs

A329232 The number of counterclockwise steps during the grasshopper procedure.

Original entry on oeis.org

0, 0, 1, 0, 2, 3, 3, 0, 9, 6, 4, 5, 4, 5, 7, 0, 18, 10, 4, 7, 10, 14, 31, 15, 11, 9, 25, 16, 19, 23, 12, 0, 28, 15, 21, 29, 25, 17, 16, 38, 26, 30, 18, 26, 49, 29, 43, 29, 38, 23, 37, 31, 55, 43, 46, 53, 25, 42, 62, 51, 29, 51, 56, 0, 31, 56, 69, 22, 35, 65
Offset: 1

Views

Author

Peter Kagey, Nov 10 2019

Keywords

Comments

The grasshopper procedure: n positions are evenly spaced around a circle, a grasshopper hops randomly to any position, after the k-th hop, the grasshopper looks clockwise and counterclockwise k positions. If one of the positions has been visited less often then the other, it hops there; if both positions have been visited an equal number of times, it hops k steps in the clockwise position. (See Mathematics Stack Exchange link for more details.)
Conjecture: a(n)=0 if and only if n = 2^k.

Crossrefs

Showing 1-3 of 3 results.