A334043 a(1) = 0, and for any n > 1, a(n) is the number of points of the set { (k, a(k)), k = 1..n-2 } that are visible from the point (n-1, a(n-1)).
0, 0, 1, 2, 2, 3, 5, 4, 5, 7, 8, 8, 10, 8, 9, 12, 11, 13, 16, 14, 15, 16, 14, 17, 20, 20, 17, 21, 25, 23, 26, 28, 27, 25, 29, 25, 31, 27, 34, 34, 28, 39, 35, 36, 41, 36, 40, 41, 41, 42, 45, 35, 49, 45, 47, 46, 49, 47, 49, 47, 54, 54, 52, 56, 54, 54, 58, 56, 59
Offset: 1
Keywords
Examples
For n = 5: - we consider the following points: . . . X / (4,2) . . X . / (3,1) X X . . (1,0) (2,0) - (1,0) and (3,1) are visible from (4,2) - whereas (2,0) is not visible from (4,2), - hence a(5) = 2.
Links
- Rémy Sigrist, Table of n, a(n) for n = 1..10000
Programs
-
PARI
g(z) = z/gcd(real(z), imag(z)) for (n=1, #a=vector(69), print1 (a[n] = #Set(apply(k -> g((k+a[k]*I)-(n-1+a[n-1]*I)), [1..n-2])) ", "))
Comments