login
A396837
Lexicographically earliest sequence of distinct nonnegative integers whose binary values, when written on a square spiral, one bit per square, high order bits first, contain no pair of 0 bits that are a knight's move apart.
0
0, 1, 2, 3, 5, 7, 6, 15, 14, 12, 4, 29, 8, 9, 13, 10, 31, 11, 59, 30, 62, 63, 126, 21, 119, 127, 17, 22, 19, 25, 26, 23, 27, 16, 43, 238, 125, 124, 53, 55, 118, 255, 61, 254, 111, 123, 250, 42, 38, 51, 253, 24, 46, 236, 20, 28, 506, 47, 93, 45, 52, 40, 239
OFFSET
0,3
COMMENTS
Although the terms equal to powers of 2 are delayed relative to similar size terms, e.g. a(2214) = 128, it is conjectured that the sequence contains all nonnegative integers.
LINKS
Scott R. Shannon, Image of the first 5000 terms on the square spiral. Zoom in to see the details. The 1 bits are black while the 0 bits are light gray. The bits that comprise each term are connected by a red line.
EXAMPLE
The spiral begins:
.
.
0---1---1---0---1---1---1 1
| | |
0 1---1---0---1---1 0 1
| | | | |
0 1 1---0---1 1 0 1
| | | | | | |
1 1 1 0---1 1 1 1
| | | | | |
0 1 1---0---1---1 0 1
| | | |
0 1---1---0---1---1---0 0
| |
1---1---1---0---1---1---0---1
.
a(0) = 0 by definition.
a(2) = 2 = 10_2 as the 4th square, which contains the 0 bit of 10_2, is not a knight's move away from the 1st square, the only other square containing a 0 bit.
a(4) = 5 = 101_2 as the 8th square, which contains the central 0 bit of 101_2, is not a knight's move away from the 1st or 4th squares, the other squares containing a 0 bit. Note that a(4) cannot equal 4 = 100_2 as that would place a 0 bit on the 9th square which is a knight's move away from the 4th square.
CROSSREFS
Cf. A396836 (start at 1), A007088, A396603, A396604, A396607, A396608.
Sequence in context: A353955 A318954 A296375 * A381013 A306923 A366856
KEYWORD
nonn,base,new
AUTHOR
Scott R. Shannon, Jun 07 2026
STATUS
approved