cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-2 of 2 results.

A348025 The numbers visited on a square spiral when stepping to the smallest unvisited number that is not visible from and shares a divisor > 1 with the current number. Start with 1 and 11.

Original entry on oeis.org

1, 11, 55, 15, 21, 3, 9, 27, 30, 2, 6, 14, 16, 10, 4, 8, 12, 18, 20, 32, 34, 28, 22, 24, 26, 36, 33, 39, 42, 38, 40, 46, 44, 48, 45, 5, 25, 65, 13, 91, 7, 35, 49, 105, 51, 17, 153, 57, 19, 114, 50, 52, 54, 56, 66, 68, 62, 58, 29, 87, 84, 60, 63, 69, 23, 161, 77, 99, 93, 31, 124, 70, 72
Offset: 1

Views

Author

Scott R. Shannon, Sep 25 2021

Keywords

Comments

A number is not visible from the current number if, given it has coordinates (x,y) relative to the current number, the greatest common divisor of |x| and |y| is greater than 1. The sequence has a(2) = 11 as that is the smallest number not visible from a(1) = 1.
In the first 10000 terms the longest single step is one at n = 6888 of length sqrt(22556) units between 22203 to 7389. The maximum difference between terms in the same range is from 3469 to 58973 at n = 9709.

Examples

			The square spiral is numbered as follows:
.
  17--16--15--14--13   .
   |               |   .
  18   5---4---3  12   29
   |   |       |   |   |
  19   6   1---2  11   28
   |   |           |   |
  20   7---8---9--10   27
   |                   |
  21--22--23--24--25--26
.
a(3) = 55 as gcd(55,11) = 11 and 55 is unvisited and not visible from 11, being blocked by 29.
a(4) = 15 as gcd(15,55) = 5 and 15 is unvisited and not visible from 55, being blocked by 13, 14 and 30.
a(5) = 21 as gcd(21,15) = 3 and 21 is unvisited and not visible from 15, being blocked by 6.
		

Crossrefs

A348026 The numbers visited on a square spiral when stepping to the smallest unvisited number that does not differ by 1 from the current number, is visible from the current number, and does not share a divisor > 1 with the current number.

Original entry on oeis.org

1, 3, 8, 5, 2, 7, 4, 9, 11, 14, 19, 6, 13, 18, 23, 10, 17, 12, 29, 15, 22, 27, 16, 21, 32, 39, 20, 31, 24, 35, 26, 33, 25, 28, 41, 34, 45, 38, 47, 30, 37, 44, 51, 40, 57, 46, 53, 42, 55, 36, 43, 52, 49, 54, 59, 50, 61, 48, 65, 56, 67, 58, 69, 62, 73, 60, 71, 64, 75, 68, 63, 74, 83, 70, 81, 85
Offset: 1

Views

Author

Scott R. Shannon, Sep 25 2021

Keywords

Comments

A number is visible from the current number if, given that it has coordinates (x,y) relative to the current number, the greatest common divisor of |x| and |y| is 1. The sequence has a(2) = 3 as that is the smallest number visible from a(1) = 1 that does not differ by 1 from a(1).
The majority of steps between terms are diagonals across the current number's nearest corner of the square spiral and thus do not approach the center of the spiral. Occasionally, however, a long diagonal step directly across the center of the spiral is taken. See the linked image.
In the first 20000 terms the longest single step is the one at n = 19534 of length sqrt(38365) units between 19743 at coordinates (-68,-70), to 19460 at coordinates (70,69). This step also yields the maximum difference between terms in the same range.

Examples

			The square spiral is numbered as follows:
.
  17--16--15--14--13   .
   |               |   .
  18   5---4---3  12  29
   |   |       |   |   |
  19   6   1---2  11  28
   |   |           |   |
  20   7---8---9--10  27
   |                   |
  21--22--23--24--25--26
.
a(3) = 8 as gcd(8,3) = 1 and 8 is unvisited, visible from 3, and does not equal 2 or 4.
a(4) = 5 as gcd(5,8) = 1 and 5 is unvisited, visible from 8, and does not equal 7 or 9.
a(5) = 2 as gcd(2,5) = 1 and 2 is unvisited, visible from 5, and does not equal 4 or 6.
		

Crossrefs

Showing 1-2 of 2 results.