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”).

A350281
Square array filled and read by antidiagonals upwards; the first value is 0; if the previous value has already appeared in the table, then the next value is the square of the distance to the nearest earlier position with the same value; otherwise the next value is 0.
1
0, 0, 1, 0, 1, 1, 1, 5, 0, 4, 0, 4, 13, 0, 1, 4, 5, 4, 1, 5, 10, 0, 4, 1, 5, 5, 1, 2, 0, 1, 5, 2, 25, 0, 5, 4, 16, 0, 1, 1, 2, 1, 4, 5, 1, 10, 106, 0, 1, 1, 1, 1, 1, 2, 5, 5, 29, 0, 1, 1, 1, 1, 1, 1, 1, 2, 5, 1, 13, 49, 0, 4, 17, 0, 8, 0, 8, 8, 2, 73, 0, 4, 13, 5, 13, 8, 5, 10, 25, 37, 0
OFFSET
0,8
COMMENTS
This sequence is a two-dimensional variant of Van Eck's sequence (A181391).
When working on a square spiral, we quickly end with all 1's:
1--1--1--1--1--1--1
| |
1 1--1--0-13--2 1
. | | |
. 1 1--0--1 0 1
. | | | | |
1 4 0--0 5 1
| | | |
1 0--2--0--1 1
| |
1--1--1--1--1--1
LINKS
Rémy Sigrist, C++ program
EXAMPLE
Square array begins:
n\k| 0 1 2 3 4 5 6 7 8 9
---+----------------------------------------
0| 0 1 1 4 1 10 2 4 1 5
1| 0 1 0 0 5 1 5 5 2 1
2| 0 5 13 1 5 0 4 1 1 0
3| 1 4 4 5 25 1 1 1 8 10
4| 0 5 1 2 2 1 1 0 5 1
5| 4 4 5 1 1 1 17 8 5 1
6| 0 1 1 1 1 4 13 1 1 29
7| 0 0 0 1 0 5 5 1 25 2
8| 16 106 0 49 13 1 1 2 5 20
9| 10 29 13 4 4 1 8 5 0 2
PROG
(C++) See Links section.
CROSSREFS
Sequence in context: A258754 A175296 A076266 * A354053 A200102 A016581
KEYWORD
nonn,tabl
AUTHOR
Rémy Sigrist, Mar 27 2022
STATUS
approved