## Regla de Simpson 3/8

Interpolando cuatro puntos $(x_{0}, f(x_{0}))$, $(x_{1}, f(x_{1}))$, $(x_{2}, f(x_{2}))$ y $(x_{3}, f(x_{3}))$, mediante un polinomio de Lagrange

\begin{equation*} f(x) = \begin{bmatrix} \cfrac{(x - x_{1})(x - x_{2})(x - x_{3})}{(x_{0} - x_{1})(x_{0} - x_{2})(x_{0} - x_{3})} \\ \cfrac{(x - x_{0})(x - x_{2})(x - x_{3})}{(x_{1} - x_{0})(x_{1} - x_{2})(x_{1} - x_{3})} \\ \cfrac{(x - x_{0})(x - x_{1})(x - x_{3})}{(x_{2} - x_{0})(x_{2} - x_{1})(x_{2} - x_{3})} \\ \cfrac{(x - x_{0})(x - x_{1})(x - x_{2})}{(x_{3} - x_{0})(x_{3} - x_{1})(x_{3} - x_{2})} \end{bmatrix}^{T} \begin{bmatrix} f(x_{0}) \\ f(x_{1}) \\ f(x_{2}) \\ f(x_{3}) \end{bmatrix} \end{equation*}

Integrando

\begin{equation*} \int_{x_{0}}^{x_{3}} f(x) \ dx = \begin{bmatrix} -\cfrac{(x_{0} - x_{3})(3 x_{0}^{2} - 4 x_{0} x_{1} - 4 x_{0} x_{2} + 2 x_{0} x_{3} + 6 x_{1} x_{2} - 2 x_{1} x_{3} - 2 x_{2} x_{3} + x_{3}^{2})}{12 (x_{0} - x_{1})(x_{0} - x_{2})} \\ -\cfrac{(x_{0} - x_{3})^{3} (x_{0} - 2 x_{2} + x_{3})}{12 (x_{0} - x_{1})(x_{1} - x_{2})(x_{1} - x_{3})} \\ \cfrac{(x_{0} - x_{3})^{3} (x_{0} - 2 x_{1} + x_{3})}{12 (x_{0} - x_{2})(x_{1} - x_{2})(x_{2} - x_{3})} \\ -\cfrac{(x_{0} - x_{3})[3 x_{3}^{2} + x_{3} (2 x_{0} - 4 x_{1} - 4 x_{2}) + x_{0}^{2} - 2 x_{0} (x_{1} + x_{2}) + 6 x_{1} x_{2}]}{12 (x_{1} - x_{3})(x_{2} - x_{3})} \end{bmatrix}^{T} \begin{bmatrix} f(x_{0}) \\ f(x_{1}) \\ f(x_{2}) \\ f(x_{3}) \end{bmatrix} \end{equation*}


In [ ]: