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-4 of 4 results.

A377307 Minimum number of consecutive pieces that must be added to the pattern given by the binary representation of n to produce a winning position in Gordon Hamilton's Jumping Frogs game, or -1 if there is no such position.

Original entry on oeis.org

1, 2, 3, 1, 4, 8, 3, 1, 5, 2, 10, 3, 4, 2, 1, 1, 6, 3, 8, 2, 6, 12, 6, 3, 5, 2, 1, 2, 4, 2, 1, 1, 7, 4, 3, 3, 9, 13, 10, 2, 7, 11, 12, 6, 7, 2, 3, 3, 6, 3, 3, 2, 4, 8, 1, 2, 5, 2, 2, 1, 1, 2, 1, 1, 8, 5, 4, 3, 10, 14, 3, 3, 8, 12, 13, 7, 8, 3, 5, 2, 8, 11, 10, 6
Offset: 0

Views

Author

Glen Whitney, Oct 23 2024

Keywords

Comments

For the rules of the Jumping Frogs game, see A377232.
Given the result that any block of consecutive single frogs is a winning position, the "interesting" positions are those that have an empty place, or gap, in them. The value a(n) measures "how difficult" the n-th such position is, as follows: Starting from a nonnegative integer n, interpret its binary representation as a Jumping Frogs position consisting of empty and/or singly-filled places. Add one more empty place (one more 0) at the end, to ensure that there is at least one gap. The value a(n) is then the minimum positive number of additional singly-filled places that must be added thereafter to create a winning position, or -1 if no winning position can be so constructed.
Equivalently, a(n) is the least k such that n*2^{k+1} + 2^k - 1 is a term of A377232, should such a k exist, and -1 otherwise.
Gordon Hamilton conjectures in his reference below that a(n) is positive for all n.

Examples

			Consider n=5, with binary representation 101. We append another 0, to get 1010, and then consider the Jumping Frogs positions 10101, 101011, 1010111, etc. Of these, the first one that is solvable turns out to be 101011111111, with eight ones. Therefore, a(5) = 8. (Here is the solution for this case, specified by the place number where each jump starts and its direction, R or L; the places are numbered right-to-left from 0: 5R, 3L, 4L, 7L, 11R, 6R, 1L, 2R, 0L and all ten frogs end up in place 9, the one flanked by zeros in the binary representation.)
		

References

  • Gordon Hamilton, The Infinite Pickle, Our Street Books, 2024, p. 106.

Crossrefs

Cf. A377232, winning binary jumping frogs positions.

A378004 Number of winning positions of Gordon Hamilton's Jumping Frogs game with n single frogs, up to left-right symmetry.

Original entry on oeis.org

1, 1, 2, 5, 12, 39, 123, 412, 1431, 4831, 17363, 60697, 219777, 781260, 2858031, 10329091, 38103069, 138996792
Offset: 1

Views

Author

Glen Whitney, Nov 13 2024

Keywords

Comments

For the rules of the Jumping Frogs game, see A377232.
Counts the number of distinct winning positions of the game with exactly n frogs, each in a different place. Positions are considered the same if one can be obtained from the other by reversing it left-to-right.
Equivalently, a(n) is the number of unordered pairs {k, A030101(k)} with k odd such that the binary weight A000120(k) = n, and k occurs in A377232.
Since a stack of k frogs moves exactly k spaces in the Jumping Frogs game, the sum of the lengths of all moves starting from a position with n single frogs is at most A000217(n-1), the (n-1)st triangular number. Hence if it is a winning position, the length of the position (excluding unoccupied places to the left of the first occupied one, and unoccupied places to the right of the last occupied one) is at most one more than this triangular number. Therefore a(n) is finite for all n.

Examples

			For four frogs, we can win:
  1111 -> 0211 -> 0013 -> 0004
  11101 -> 02101 -> 03001 -> 00004
  11011 -> 02011 -> 02020 -> 04000
  111001 -> 201001 -> 003001 -> 000004
  1101001 -> 0201001 -> 0003001 -> 0000004
Any other position with four frogs in different places is either a left-right reversal of one of these, or no sequence of moves will result in all frogs in the same place. Hence a(4)=5.
Equivalently, one can start with four frogs in a single place and make a tree of all possible reverse moves, and then count leaves in which all frogs are in different places:
                       _____________4____
                      /             |    \
                 ___3001___        202    13
                /   |  |   \      /   \    |
          201001 12001 2101 1021 1102 112 121
         /   |     |         |    |
  1101001 111001 11101      1111 11011
Again we see that a(4) = 5. (Note that nodes whose labels or reversed labels have already occurred earlier in a row are omitted from this tree.)
		

References

Crossrefs

Extensions

a(16)-a(18) from Jinyuan Wang, Nov 25 2024

A377308 All winning positions of Gordon Hamilton's Jumping Frogs game, encoded as even numbers by their prime-factorization exponents.

Original entry on oeis.org

2, 4, 6, 8, 12, 16, 18, 20, 24, 30, 32, 42, 48, 50, 54, 56, 60, 64, 70, 84, 90, 96, 100, 120, 126, 128, 140, 150, 162, 176, 192, 198, 200, 210, 240, 252, 256, 260, 264, 270, 280, 294, 300, 330, 350, 384, 390, 392, 400, 416, 420, 462, 480, 486, 490, 500
Offset: 1

Views

Author

Glen Whitney, Oct 23 2024

Keywords

Comments

For the rules of the Jumping Frogs game, see A377232.
Enumerate the primes in order, p_1 = 2, p_2 = 3, etc. Factor any natural number k > 1 as p_1^{x_1}p_2^{x_2}...p_i^{x_i}, where i is as small as possible and each x_j is nonnegative. Then when k is even and x_1, x_2, ..., x_i is a winning position for Jumping Frogs, k occurs as a term. We consider only even numbers to keep the positions distinct; leading zeros can never be used or affect the outcome of Jumping Frogs.
An even number k is a term if and only if A137502(k) is a term. - Pontus von Brömssen, Oct 24 2024

Examples

			Consider k = 28. It can be written as 2^2 * 3^0 * 5^0 * 7^1. The jumping frogs position 2, 0, 0, 1 has no legal moves (no occupied place adjacent to the 1 entry and no occupied place 2 places away from the 2 entry). Therefore it is not a winning position, and 28 is not a term.
Conversely, k = 20 can be written as 2^2 * 3^0 * 5^1. The jumping frogs position 2, 0, 1 can be won in a single move to 0, 0, 3 (all frogs in one place). Hence k is a term, namely a(8).
		

References

Crossrefs

Cf. A137502, A377232 (binary winning positions).

A378235 Number of winning positions of Gordon Hamilton's Jumping Frogs game with single frogs, where the distance between the leftmost frog and the rightmost frog is equal to n.

Original entry on oeis.org

1, 1, 1, 3, 4, 7, 13, 23, 40, 74, 148, 263, 493, 934, 1719, 3192, 6035, 11280, 21252, 40367, 75796
Offset: 0

Views

Author

Pontus von Brömssen, Nov 20 2024

Keywords

Comments

For the rules of the Jumping Frogs game, see A377232.
A winning position and its reversal are both counted.
a(n) is the number of terms x of A377232 in the interval 2^n <= x < 2^(n+1).

Examples

			For n = 0, the only winning position is 1, so a(0) = 1.
For n = 1, the only winning position is 11, so a(1) = 1.
For n = 2, the only winning position is 111, so a(2) = 1.
For n = 3, there are a(3) = 3 winning positions: 1011, 1101, 1111.
For n = 4, there are a(4) = 4 winning positions: 10111, 11011, 11101, 11111.
For n = 5, there are a(5) = 7 winning positions: 100111, 101111, 110111, 111001, 111011, 111101, 111111.
		

Crossrefs

Showing 1-4 of 4 results.