1. Trignonometric substitutions.
When using Maple to aid you in performing integrals which require trigonometric substitutions, you may have work a bit harder to get the result in the form that you want. Let us suppose that we wish to compute the integral
.
From the form of the denominator, it seems very natural to make the substitution
. Maple can help us simplify the integrand as follows.
First, define the function you want to integrate in Maple.
> f:=x->(x^2-2)/(x^2+1);
Next, defi
ne
as a functio
n of
.
> x:=theta->tan(theta);
Then calculate the derivative of
x
with respect to
.
> dx:=D(x)(theta);
Finally, calculate the integrand.
> f(x(theta))*dx;
This integral is very easy to do, once you realize that
, so the integrand is simply
, and thus we have
=
=
=
.
Let us verify this with Maple. Since we defined x as a function, we have to reset it to a variable first.
> x:='x';
> int(f(x),x);
Sometimes, Maple can only help us a little. For example, to do the integral
, we could proceed as follows:
> f:=x->sqrt(1-x^2)/x^4;
> x:=theta->sin(theta);
> dx:=D(x)(theta);
> f(x(theta))*dx;
Now, we know that in the range for which our substitution is valid, when
, we have
, so that we have
. Thus the integrand above can be simplified to
. But we want to convert this into something that even we recognize how to integrate immediately. If you stare at the expression long enough, you might recognize that we can simplify the integrand to
, and this integral is easy enough to do by hand. We obtain that
=
.
Let us verify the result with Maple
> x:='x';int(f(x),x);
Submission:
For the integrals below, use the method above to find the integral. Verify your answer by calculating the indefinite integral directly in Maple.
1)
.
2)
Submission worksheet:
>
2. Converting integrals involving sines and cosines to rational integrals.
The substitution
can be used to convert rational expressions involving sines and cosines to rational expressions, which can then be integrated by using partial fraction decompositions. The basic formulas that are necessary to do this conversion are as follows.
1)
2)
3)
.
Let us consider the integral
. The integrand is
> integrand:=cos(x)/(sin(x)*cos(x)+sin(x));
We can perform all the substitutions given by the rules 1-3 above at once.
> subs(sin(x)=2*z/(1+z^2),cos(x)=(1-z^2)/(1+z^2),dx=2/(1+z^2),integrand*dx);
The result doesn't look too simple, but let us simplify it.
> simplify(%);
This expression is just
, which we can integrate by hand to obtain
. Then all we have to do to finish the problem is substitute
in the answer to obtain
.
Let us verify this answer in Maple.
> int(cos(x)/(sin(x)*cos(x)+sin(x)),x);
Submission:
Use the method above to calculate the following integrals.
1)
.
2)
.
Submission worksheet:
>
>
>