# Polinomio de Lagrange

$$f_n(x) = \sum_{i=0}^{n} \ell_{i} f(x_{i})$$

## Polinomio lineal

\begin{equation*} f(x) = \frac{x - x_{1}}{x_{0} - x_{1}} f(x_{0}) + \frac{x - x_{0}}{x_{1} - x_{0}} f(x_{1}) \end{equation*}

$$f'(x) = \frac{1}{x_{0} - x_{1}} f(x_{0}) + \frac{1}{x_{1} - x_{0}} f(x_{1})$$

In [ ]:

\begin{equation*} f(x) = \frac{(x - x_{1})(x - x_{2})}{(x_{0} - x_{1})(x_{0} - x_{2})} f(x_{0}) + \frac{(x - x_{0})(x - x_{2})}{(x_{1} - x_{0})(x_{1} - x_{2})} f(x_{1}) + \frac{(x - x_{0})(x - x_{1})}{(x_{2} - x_{0})(x_{2} - x_{1})} f(x_{2}) \end{equation*}

$$f'(x) = \frac{2 x - (x_{1} - x_{2})}{(x_{0} - x_{1})(x_{0} - x_{2})} f(x_{0}) - \frac{2 x - (x_{0} - x_{2})}{(x_{1} - x_{0})(x_{1} - x_{2})} f(x_{1}) + \frac{2 x - (x_{0} - x_{1})}{(x_{2} - x_{0})(x_{2} - x_{1})} f(x_{2})$$

$$f''(x) = \frac{2}{(x_{0} - x_{1})(x_{0} - x_{2})} f(x_{0}) - \frac{2}{(x_{1} - x_{0})(x_{1} - x_{2})} f(x_{1}) + \frac{2}{(x_{2} - x_{0})(x_{2} - x_{1})} f(x_{2})$$

In [ ]:

## Polinomio cúbico

\begin{equation*} f(x) = \frac{(x - x_{1})(x - x_{2})(x - x_{3})}{(x_{0} - x_{1})(x_{0} - x_{2})(x_{0} - x_{3})} f(x_{0}) + \frac{(x - x_{0})(x - x_{2})(x - x_{3})}{(x_{1} - x_{0})(x_{1} - x_{2})(x_{1} - x_{3})} f(x_{1}) + \frac{(x - x_{0})(x - x_{1})(x - x_{3})}{(x_{2} - x_{0})(x_{2} - x_{1})(x_{2} - x_{3})} f(x_{2}) + \frac{(x - x_{0})(x - x_{1})(x - x_{2})}{(x_{3} - x_{0})(x_{3} - x_{1})(x_{3} - x_{2})} f(x_{3}) \end{equation*}