0, 0, 1, 1, 4, 3, 8, 2, 2, 5, 7, 4, 5, 8, 16, 3, 7, 14, 12, 23, 16, 12, 25, 31, 13, 6, 11, 28, 11, 17, 9, 9, 22, 34, 6, 15, 13, 29, 23, 22, 29, 45, 26, 19, 51, 14, 24, 39, 28, 39, 18, 37, 57, 17, 38, 41, 15, 68, 32, 24, 66, 42, 10, 50, 27, 10, 53, 72, 25, 26
Offset: 0
A300002
Lexicographically earliest sequence of positive integers such that no k+2 points fall on any polynomial of degree k.
Original entry on oeis.org
1, 2, 4, 3, 6, 5, 9, 16, 14, 20, 7, 15, 8, 12, 18, 31, 26, 27, 40, 30, 49, 38, 19, 10, 23, 53, 11, 32, 21, 25, 13, 47, 83
Offset: 1
a(1) = 1.
a(2) != 1 or else (1, 1) and (2, 1) fall on y = 1. (Similarly all terms must be distinct.)
a(2) = 2.
a(3) != 1 or else (1, 1) and (3, 1) fall on y = 1.
a(3) != 2 or else (2, 2) and (3, 2) fall on y = 2.
a(3) != 3 or else (1, 1), (2, 2) and (3, 3) fall on y = x.
a(3) = 4.
a(4) != 1 or else (1, 1) and (4, 1) fall on y = 1.
a(4) != 2 or else (2, 2) and (4, 2) fall on y = 2.
a(4) = 3
-
A = {{1, 1}, {2, 2}};
n = 3;
While[n < 50,
c = Sort[Select[Select[InterpolatingPolynomial[#, n] & /@ Subsets[A, {1, n - 1}], # > 0 & ] , IntegerQ]];
B = Differences[c];
If[Max[B] == 1,
d = Max[c] + 1,
d = Part[c, First[Position[B, Select[B, # > 1 &][[1]]]][[1]]] + 1];
A = Append[A, {n, d}];
Print[{n, d}]
n++;
] (* Luca Petrone, Apr 18 2017 *)
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)).
Original entry on oeis.org
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
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.
See
A334044 for a similar sequence.
-
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])) ", "))
A255708
No three points (i,a(i)), (j,a(j)), (k,a(k)) are collinear, for n = 0,1,2,... the value of a(n) is chosen to be m or -m (in this order) for the smallest m>=0 satisfying the condition.
Original entry on oeis.org
0, 0, 1, 1, -1, -1, 4, 2, 2, -3, -5, -2, -7, -2, 5, 3, 3, -5, -4, -4, 6, 5, -6, -3, -10, 11, -6, 4, 18, 11, 19, 7, 12, 12, 6, -13, 19, 7, -10, -7, -9, -14, 13, 23, -28, -8, -14, 9, 8, -22, -9, -8, 23, -11, 15, 22, 13, 8, -21, -13, -26, 9, -12, -12, -11, 40, 21
Offset: 0
-
a:= proc(n) option remember; local i, j, k, t, ok;
for t from 0 do for k in [t, -t] do ok:=true;
for j from n-1 to 1 by -1 while ok do
for i from j-1 to 0 by -1 while ok do
ok:= (n-j)*(a(j)-a(i))<>(j-i)*(k-a(j))
od od; if ok then return k fi
od od
end:
seq(a(n), n=0..60);
A255709
No three points (i,a(i)), (j,a(j)), (k,a(k)) are collinear and all values distinct, for n = 0,1,2,... the value of a(n) is chosen to be m or -m (in this order) for the smallest m>=0 satisfying the condition.
Original entry on oeis.org
0, 1, -1, 2, 3, -2, -5, -3, 4, -6, 6, -7, -4, 5, 12, 16, 7, 8, -10, -8, 9, 19, 14, -12, -14, -9, 21, 10, -11, -15, 17, 15, -19, 13, -22, -13, -16, -24, 11, 18, 22, -18, 25, 23, -17, 24, 40, -21, -38, 20, -29, 36, -30, -20, 32, -34, 26, 43, -23, 37, -26, 33
Offset: 0
-
b:= proc() true end:
a:= proc(n) option remember; local i, j, k, t, ok;
for t from 0 do for k in [t, -t] do ok:=b(k);
for j from n-1 to 1 by -1 while ok do
for i from j-1 to 0 by -1 while ok do
ok:= (n-j)*(a(j)-a(i))<>(j-i)*(k-a(j))
od od; if ok then b(k):=false; return k fi
od od
end:
seq(a(n), n=0..60);
A300670
Table read by antidiagonals: the n-th row is the lexicographically earliest sequence such that no k + 2 points of ((1, a(1)), (2, a(2)), ...) lie on a polynomial of degree k for k < n.
Original entry on oeis.org
1, 2, 1, 3, 2, 1, 4, 4, 2, 1, 5, 3, 4, 2, 1, 6, 6, 3, 4, 2, 1, 7, 5, 6, 3, 4, 2, 1, 8, 9, 5, 6, 3, 4, 2, 1, 9, 12, 9, 5, 6, 3, 4, 2, 1, 10, 7, 12, 9, 5, 6, 3, 4, 2, 1, 11, 14, 19, 12, 9, 5, 6, 3, 4, 2, 1, 12, 13, 17, 19, 16, 9, 5, 6, 3, 4, 2, 1, 13, 8, 7, 17
Offset: 1
Table begins
1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, ...
1, 2, 4, 3, 6, 5, 9, 12, 7, 14, 13, 8, 23, 17, 18, 22, ...
1, 2, 4, 3, 6, 5, 9, 12, 19, 17, 7, 8, 15, 20, 18, 22, ...
1, 2, 4, 3, 6, 5, 9, 12, 19, 17, 8, 10, 31, 7, 11, 22, ...
1, 2, 4, 3, 6, 5, 9, 16, 14, 20, 7, 15, 8, 12, 18, 31, ...
1, 2, 4, 3, 6, 5, 9, 16, 14, 20, 7, 15, 8, 12, 18, 31, ...
...
In the first row, no two points lie on a 0-degree polynomial (i.e., all terms are distinct).
In the second row, no two terms are the same and no three points (1, a(1)), (2, a(2)), ... lie on the same line.
In the third row, no two terms are the same; no three points (1, a(1)), (2, a(2)), ... lie on the same line; and no four points lie on the same parabola.
Comments