OFFSET
1,1
COMMENTS
Equivalently the number immediately above n in a counterclockwise square spiral of the positive integers with the first step to the right.
This is a permutation of the positive integers. A334751 is the inverse permutation.
LINKS
EXAMPLE
For n = 1, a(1) = 4 because 4 is immediately below 1 in the clockwise square spiral with first step to the right:
21--22--23--24--25--26
| |
20 7---8---9---10 27
| | | |
19 6 1---2 11 28
| | | | |
18 5---4---3 12 29
| | |
17--16--15--14--13 30
|
36--35--34--33--32--31
CROSSREFS
KEYWORD
nonn
AUTHOR
Peter Kagey, May 10 2020
STATUS
approved