OFFSET
1,1
LINKS
Hugo Pfoertner, Table of n, a(n) for n = 1..1000
FORMULA
a(n) = A054552(prime(n)) if prime(n) != 1 mod 4.
EXAMPLE
37--36--35--34--33--32--31
| |
38 17--16--15--14--13 30 ...
| | | | |
39 18 5---4---3 12 29 54
| | | | | | |
40 19 6 1---2 d=2 d=3 53
| | | | | |
41 20 7---8---9--10 27 52
| | | |
42 21--22--23--24--25--26 51
| |
43--44--45--46--47--48--49-d=5
.
a(1) = 11 is the index of the first occurrence of distance d = 2 = prime(1) from the start of the spiral.
a(2) = 28 is the index of the first occurrence of distance d = 3 = prime(2) from the start of the spiral.
Distances of the form 4*k+1 corresponding to Pythagorean primes A002144 occur earlier than on the East spoke of the square spiral, dependent on the decomposition of p^2 into two squares. prime(3)^2 = 4^2 + 3^2 leads to index a(3) = 50 in the spiral.
CROSSREFS
KEYWORD
nonn
AUTHOR
Hugo Pfoertner, Jul 24 2020
STATUS
approved