0

$\int_0^2 e^x \cos (x) \sin (x) dx$,

What is the convergence order of the numerical formula?

I am confusing the question.

Do I have to use Trapezoidal rule or simpson rule or approximation rule?

If so then how to use approximation and finding order of convergence?

Help me

MAS
  • 10,638
  • @425481 I'm not sure what you are asking... Do you want to compute the integral exactly or numerically? The question about the convergence order only makes sense in the case of numerical integration, but of course the convergence order will depend on the quadrature rule to be used. – PierreCarre Apr 09 '19 at 09:35
  • numerically integration – MAS Apr 09 '19 at 09:39
  • Which numerical method? Different methods will yield different orders of convergence. – PierreCarre Apr 09 '19 at 09:46

2 Answers2

2

If you want to use a numerical method like the trapezoidal rule, based on a decomposition $0=x_0, x_1, \cdots, x_n=2$ of equally space points (spacing $h$), you just need to compute

$$ \frac h2 \left(f(x_0) + f(x_n) + 2 \sum_{i=1}^{n-1} f(x_i) \right), $$

where $f(x)=\sin x \cos x e^x$. Regarding the order of convergence, you have that the absolute error is given by

$$ \left|\frac{(b-a) h^2}{12} f''(\xi)\right|, \quad \xi \in [0,2] $$

so, if the second derivative of $f$ is bounded (which is the case) the error will behave like $h^2$.

PierreCarre
  • 20,974
  • 1
  • 18
  • 34
0

You can do this integral by doing integration by parts twice with $\cos x \sin x = \frac{1}{2}\sin 2x$. This will help you check your answer.

fGDu94
  • 3,916