login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

Lexicographically earliest sequence of positive integers on a square spiral such that the difference between all orthogonally adjacent pairs of numbers is distinct.
1

%I #11 Aug 09 2022 06:47:27

%S 0,0,1,3,7,12,1,7,15,1,10,23,0,17,35,54,0,27,48,72,0,26,55,83,31,0,34,

%T 69,106,39,1,41,83,126,1,45,91,140,77,128,2,57,1,61,119,183,1,93,158,

%U 1,74,143,218,0,115,192,0,79,160,244,2,87,174,1,89,185,1,166,6,101,198,296,0,101,203,1

%N Lexicographically earliest sequence of positive integers on a square spiral such that the difference between all orthogonally adjacent pairs of numbers is distinct.

%C For larger n the sequences typically consists of a repeating pattern of three values - the first one is small, less than 5, a second larger value, and then a third even larger value, typically around double the previous value. However this pattern is occasionally broken by a fourth or fifth larger value which shifts the position of the subsequent repeating block of three values. This leads to the overall spiral pattern showing a uniform pattern of numbers crossed by random zig-zag lines of values not following the three-value pattern. See the linked color image.

%H Scott R. Shannon, <a href="/A355314/a355314.png">Image of the first 500000 terms</a>. The values are scaled across the spectrum from red to violet, with the value ranges increasing towards the violet end to give more color weighting to the larger numbers.

%e The spiral begins:

%e .

%e .

%e 91--45---1--126-83--41---1 :

%e | | :

%e 140 0--54--35--17---0 39 115

%e | | | | |

%e 77 27 7---3---1 23 106 0

%e | | | | | | |

%e 128 48 12 0---0 10 69 218

%e | | | | | |

%e 2 72 1---7--15---1 34 143

%e | | | |

%e 57 0--26--55--83--31---0 74

%e | |

%e 1--61--119-183--1--93--158--1

%e .

%e .

%e a(8) = 15 as when a(8) is placed, at coordinate (1,-1) relative to the starting square, its two orthogonally adjacent squares are a(1) = 0 and a(7) = 7. The ten previously occurring differences between all orthogonally adjacent pairs up to a(7) are 0, 1, 2, 3, 4, 5, 6, 7, 11, 12. The lowest unused difference is 8 thus a(8) = 15 can be chosen as it results in differences with its two orthogonal neighbors of 15 - 7 = 8 and 15 = 0 = 15, neither of which has previously occurred.

%Y Cf. A307834, A275609, A274640, A355270.

%K nonn

%O 0,4

%A _Scott R. Shannon_, Jun 28 2022