MHB 206.8.7.47 int sin(10x) cos(5x) dx Simpsons rule

  • Thread starter Thread starter karush
  • Start date Start date
  • Tags Tags
    Dx
karush
Gold Member
MHB
Messages
3,240
Reaction score
5
206.8.7.47
$\text{use Simpsons rule} \\
\text{n=8} $

$$\displaystyle
\int_{0}^{3\pi/5} \sin\left({10x}\right)\cos\left({5x}\right)\,dx
\approx \frac{4}{15}=0.2667$$
$$\displaystyle
n=8\therefore \varDelta{x} =\frac{3\pi}{40} \\
S_{47}=\frac{\pi}{40}\left[
y_0+4y_1+2y_2 +4y_3+2y_4+4y_5 +2y_6+4y_7+y_8
\right]\approx -0.0183$$
 
Last edited:
Physics news on Phys.org
karush said:
206.8.7.47
$\text{use Simpsons rule} \\
\text{n=8} $

$$\displaystyle
\int_{0}^{3\pi/5} \sin\left({10x}\right)\cos\left({5x}\right)\,dx
\approx \frac{4}{15}=0.2667$$
$$\displaystyle
n=8\therefore \varDelta{x} =\frac{3\pi}{40} \\
S_{47}=\frac{\pi}{40}\left[
y_0+4y_1+2y_2 +4y_3+2y_4+2y_5 +4y_6+2y_7+y_8
\right]\approx -0.0183$$
$\text{how would this be derived in }
\displaystyle \sum_{k=1}^{8}$

Why use Simpson's Rule when you can evaluate this exactly?

$\displaystyle \begin{align*} \int_0^{\frac{3\,\pi}{5}}{ \sin{ (10\,x)} \cos{ (5\,x)} \,\mathrm{d}x } &= \int_0^{\frac{3\,\pi}{5}}{ 2\sin{(5\,x)}\cos{(5\,x)}\cos{(5\,x)}\,\mathrm{d}x } \\ &= -\frac{2}{5}\int_0^{\frac{3\,\pi}{5}}{ -5\sin{(5\,x)}\cos^2{(5\,x)}\,\mathrm{d}x } \end{align*}$

Let $\displaystyle \begin{align*} u = \cos{(5\,x)} \implies \mathrm{d}u = -5\sin{(5\,x)} \end{align*}$ noting that $\displaystyle \begin{align*} u(0) = 1 \end{align*}$ and $\displaystyle \begin{align*} u\left( \frac{3\,\pi}{5} \right) = -1 \end{align*}$ giving

$\displaystyle \begin{align*} -\frac{2}{5} \int_0^{\frac{3\,\pi}{5}}{ -5\sin{(5\,x)}\cos^2{(5\,x)}\,\mathrm{d}x } &= -\frac{2}{5} \int_1^{-1}{ u^2\,\mathrm{d}u } \\ &= \frac{2}{5} \int_{-1}^1{ u^2\,\mathrm{d}u } \\ &= \frac{2}{5} \left[ \frac{u^3}{3} \right] _{-1}^1 \\ &= \frac{2}{5} \left( \frac{1}{3} + \frac{1}{3} \right) \\ &= \frac{4}{15} \end{align*}$
 
true, but homework was on Simpson's Rule

I have no earthly idea who would ever use it??

big pain😰
 
karush said:
true, but homework was on Simpson's Rule

I have no earthly idea who would ever use it??

big pain😰

Approximate integral methods are typically applied to integrals that don't have an elementary anti-derivative, and they are now done using software with a large number of intervals, or to a designated degree of accuracy.

You want:

$$S_{8}=\frac{\pi}{40}\left(y_0+4y_1+2y_2+4y_3+2y_4+4y_5+2y_6+4y_7+y_8\right)$$

In sigma notation, that would be:

$$S_8=\frac{\pi}{40}\sum_{k=0}^{3}\left(y_{2k}+4y_{2k+1}+y_{2k+2}\right)$$
 
And when you are learning a numerical method, it is not uncommon to be given examples that can be done using other, simpler, methods so that you can check your results. The
 

Similar threads

Back
Top