1. ## Polynomial

Question: If $x_{1}, ... , x_{n}$ are distinct numbers, find a polynomial $f_{i}$ of degree $n-1$ which is $1$ at $x_{i}$ and 0 at $x_{j}$ for $j \ne i$. Hint: the product of all $(x-x_{i})$ for $j \ne i$ is zero at $x_{j}$ if $j \ne i$. .

Confusion: The part of the question that I don't understand is the 'which is $1$ at $x_{i}$ and 0 at $x_{j}$ for $j \ne i$.' What are $x_{i}$ and $x_{j}$? Does it mean that for any two numbers we choose from the sequence $x_{1}, ..., x_{n}$, we get $f_{i}$ as 0, for one, and 1, for the other? And how would you go about finding this polynomial?

2. The polynomial is...

$\displaystyle P(x)= \frac{\prod_{i=1, i\ne j}^{n} (x-x_{i})} {\prod_{i=1, i\ne j}^{n} (x_{j}-x_{i})}$

Kind regards

$\chi$ $\sigma$

3. Originally Posted by chisigma
The polynomial is...

$\displaystyle P(x)= \frac{\prod_{i=1, i\ne j}^{n} (x-x_{i})} {\prod_{i=1, i\ne j}^{n} (x_{j}-x_{i})}$

Kind regards

$\chi$ $\sigma$
Can you do a bit of explanation, please, if you don't mind? For example, it's not apparent to me that it's of degree $n-1$.

4. Originally Posted by Hardwork
The part of the question that I don't understand is the 'which is $1$ at $x_{i}$ and 0 at $x_{j}$ for $j \ne i$.' What are $x_{i}$ and $x_{j}$?
The problem asks to find, for every $i=1,\dots,n$, a polynomial $f_i$ with the given property, which is a total of $n$ polynomials.

For example, it's not apparent to me that it's of degree $n - 1$.
In the denominator, you have a product of numbers. In the numerator, you have a product of $n-1$ expressions of the form $x-c$ for various constants $c$.

This is similar to the interpolation polynomial in the Lagrange form (the link uses notation $\ell_j$ instead of $f_j$).