Property 2 says that two points uniquely determine a line.
Polynomial Interpolation
Property 2 says that two points uniquely determine a degree 1 polynomial (a line), three points uniquely
determine a degree 2 polynomial, four points uniquely determine a degree 3 polynomial, .
.. Given
d
+
1
pairs
(
x
1
,
y
1
)
,...,
(
x
d
+
1
,
y
d
+
1
)
, how do we determine a polynomial
p
(
x
) =
a
d
x
d
+
...
+
a
1
x
+
a
0
such that
p
(
x
i
)=
y
i
for
i
=
1 to
d
+
1. We will give two different efficient algorithms for reconstructing the coefficients
a
0
,...,
a
d
and therefore the polynomial
p
(
x
)
.
In the first method, we write a system of
d
+
1 linear equations in
d
+
1 variables: the coefficients of the
polynomial
a
0
,...,
a
d
. The
i

th
equation is:
a
d
x
d
i
+
a
d

1
x
d

1
i
+
...
+
a
0
=
y
i
.
Since
x
i
and
y
i
are constants, this is a linear equation in the
d
+
1 unknowns
a
0
,...,
a
d
. Now solving these
equations gives the coefficients of the polynomial
p
(
x
)
. For example, given the 3 pairs
(

1
,
2
)
,
(
0
,
1
)
, and
(
2
,
5
)
, we will construct the degree 2 polynomial
p
(
x
)
which goes through these points. The first equation
says
a
2
(

1
)
2
+
a
1
(

1
)+
a
0
=
2. Simplifying, we get
a
2

a
1
+
a
0
=
2. Applying the same technique to the
second and third equations, we get the following system of equations:
a
2

a
1
+
a
0
=
2
a
0
=
1
4
a
2
+
2
a
1
+
a
0
=
5
Substituting for
a
0
and multiplying the first equation by 2 we get:
2
a
2

2
a
1
=
2
4
a
2
+
2
a
1
=
4
Then, adding down we find that 6
a
2
=
6, so
a
2
=
1, and plugging back in we find that