A396608 · Lexicographically earliest sequence of distinct positive integers whose binary values, when written on a square spiral, one bit per square, high order bits first, contain no pair of 1 bits that are diagonally adjacent.
It is conjectured that the sequence contains all positive integers.
Lexicographically earliest sequence of distinct positive integers whose binary values, when written on a square spiral, one bit per square, high order bits first, contain no pair of 1 bits that are diagonally adjacent.
Ver un ejemplo concreto
The spiral begins:
.
.
0---1---0---0---0---0---0 1
| | |
0 1---0---1---1---1 0 1
| | | | |
0 0 0---0---0 0 0 0
| | | | | | |
0 1 1 1---1 1 1 0
| | | | | |
0 0 0---0---0---0 0 0
| | | |
1 0---1---0---1---1---1 1
| |
0---0---0---0---0---0---0---0
.
a(1) = 1 by definition.
a(2) = 8. As the second number must start with a 1, and as the first number is 1, the 3rd, 4th and 5th squares cannot be 1 else they would be diagonally adjacent to one of the first two 1 bits. The 6th bit can be 1, which is the first bit that can start the third term, so a(2) = 8 = 1000 as it has 0 bits in the 3rd, 4th and 5th squares while allowing a 1 bit in the 6th square.
a(3) = 16. Similar to a(2) = 8, the 7th, 8th, 9th, and 10th square cannot be 1 while the 11th square can be, giving 16 as the earliest term satisfying these conditions.