# Integration by Substitution (by Example)

Okay, so you know of some basic rules of integration. For example, the integral of sine is minus cosine plus constant. But what about the integral of the double angle of sine? For this, we can use the “reverse of the chain rule,” but that I mean, make a substitution and use the composition of functions. The process is easy after some practice.

Integration by substitution is the counterpart to the chain rule of differentiation. We study this integration technique by working through many examples and by considering its proof. Several exercises are given at the end for further practice.

## Understanding Integration by Substitution

Suppose it is known that in a certain country the life expectancy at birth of a female is changing at the rate of $$g'(t)=\frac{5.45218}{(1+1.09t)^{0.9}}$$ years per year. Here, $t$ is measured in years, with $t=0$ corresponding to the beginning of 1900. Can we find an expression $g(t)$ giving the life expectancy at birth (in years) of a female in that country if the life expectancy at the beginning of 1900 is 50.02 years. If so, for example what is the life expectancy at birth of a female born at the beginning of 2000 in that country?

We use integration to find $g(t)$ as follows, $$g(t)=\int g'(t) \, dt = \int \frac{5.45218}{(1+1.09t)^{0.9}} \, dt$$ by making a change of variables. Let $u=1+0.09 t.$ Then $du=1.09 \, dt$ and so $$g(t) = \frac{1}{1.09} \int \frac{5.45218}{u^{0.9}} \, du \approx 50.02 (1+1.09 t)^{0.1} +C.$$ Since $g(0)=50.02$ we find $C=0$, and then $g(t)=50.02(1+1.09 t)^{0.1}.$ The life expectancy at birth of a female in the year 2000 is $$g(100)=50.02 \left(110^{0.1}\right) \approx 80.04 \text{ years.}$$

We turn our attention to the substitution rule which (as seen below) is basically the reverse of the chain rule. To see this let $f$, $g$, and $u$ be differentiable functions of $x$ such that $$f(x)=g(u)\frac{du}{dx}.$$ Then $$\int f(x) \, dx = \int g(u) \frac{du}{dx} \, dx = \int g(u) \, du =G(u)+C$$ where $G$ is the antiderivative of $g.$ Indeed, if $G$ is an antiderivative of $g$, then $G'(u)=g(u)$ and by the chain rule $$f(x)=\frac{d}{dx}[G(u)]=G'(u)\frac{du}{dx} =g(u) \frac{du}{dx}.$$ Now integrating both sides of this equation we obtain $$\int f(x) \, dx = \int \left[ g(u) \frac{du}{dx} \right] \, dx =\int \left[ \frac{d}{dx} G(u) \right] \, dx = G(u)+C$$ where $C$ is a constant.

## The Integration by Substitution Rule

Theorem. (Substitution Rule) If $u=g(x)$ is a differentiable function whose range is an interval $I$ and $f$ is continuous on $I$, then $$\int f(g(x)) g'(x) \, dx =\int f(u) \, du.$$

Proof. By the chain rule, $F(g(x))$ is an antiderivative of $f(g(x)) g'(x)$ whenever $F$ is an antiderivative of $f$ since $$\frac{d}{dx} F(g(x))=F(g(x)) g'(x) =f(g(x)) g'(x).$$ If we make the substitution $u=g(x)$ then \begin{align} \int f(g(x)) g'(x) \, dx & =\int \frac{d}{dx} F(g(x)) \, dx =F(g(x))+C =F(u) +C \\ & = \int F'(u)\, du = \int f(u) \, du. \end{align}

The idea behind the substitution rule is to choose $u=g(x).$ Then find $du=g'(x) \, dx.$ Next, make the substitution to obtain $$\int f(u) \, du.$$ If it is possible to integrate the last integral involving $u$ only, then the change of variable, using the substitution rule can successful.

Example. Evaluate $\displaystyle \int \frac{\cos \sqrt{\theta} }{\sqrt{\theta} \sin^2\sqrt{\theta}}\, d\theta.$

Solution. Let $u=\sin\sqrt{\theta}.$ Then $du=\cos \sqrt{ \theta } \left(\frac{1}{2\sqrt{\theta}} \right) \, d\theta .$ By substitution \begin{align} \int \frac{\cos \sqrt{\theta} }{\sqrt{\theta} \sin^2\sqrt{\theta}}\, d\theta & =2\int \frac{1}{u^2} du =\frac{-2}{u}+C \\ & =-\frac{2}{\sin \sqrt{\theta}}+C =-2\csc \sqrt{\theta} +C \end{align} where $C$ is a constant.

Example. Evaluate $\displaystyle \int r^4 \left(7-\dfrac{r^5}{10}\right)^3\, dr.$

Solution. Let $u=7-\dfrac{r^5}{10}.$ Then $du= \dfrac{-r^4}{2}\, dr.$ By substitution \begin{align} \int r^4 \left(7-\frac{r^5}{10}\right)^3\, dr & = -2\int \left(7-\frac{r^5}{10}\right)^3\left(-\frac{1}{2}r^4\right) \, dr \\ & =-2\left( \frac{x^4}{4}\right)+C=-\frac{1}{2}\left(7-\frac{r^5}{10}\right)^4+C \end{align} where $C$ is a constant.

Example. Evaluate $\displaystyle \int \sqrt{\frac{x-1}{x^5}}\, dx.$

Solution. Let $u=1-\frac{1}{x}.$ Then $du= \frac{1}{x^2}\, dx.$ By substitution \begin{align} \int \sqrt{\frac{x-1}{x^5}}\, dx & = \int \sqrt{1-\frac{1}{x}} \left(\frac{1}{x^2}\right) \, dx \\ & =\int \sqrt{u} \, du = \frac{u^{3/2}}{3/2}+C =\frac{2}{3}\left(1-\frac{1}{x}\right)^{3/2}+C \end{align}
where $C$ is a constant.

Example. Evaluate $\displaystyle \int e^{\sin^2 \theta} \sin 2\theta\, dx.$

Solution. Let $u=\sin^2\theta.$ Then $du= 2\sin \theta \cos \theta \, d\theta =\sin 2\theta \, d\theta.$ By substitution \begin{align} \int e^{\sin^2 \theta} \sin 2\theta\, dx =\int e^u \, du =e^u+C =e^{\sin^2 \theta}+C \end{align} where $C$ is a constant.

Example. Evaluate $\displaystyle \int \frac{1}{x\sqrt{x^4-1}}\, dx.$

Solution. Let $u=x^2.$ Then $du= 2x \, dx.$ By substitution \begin{align} \int \frac{1}{x\sqrt{x^4-1}}\, dx & =\int \frac{2x}{2x^2\sqrt{x^4-1}} \, dx =\int \frac{1}{2u\sqrt{u^2-1}} \, du \\ & =\frac{1}{2}\int\frac{1}{|u| \sqrt{u^2-1}} \, du =\frac{1}{2}\sec^{-1}u +C =\frac{1}{2}\sec^{-1}x^2 +C \end{align} where $C$ is a constant.

Example. Evaluate $\displaystyle \int \frac{ e^{\cos^{-1}x}}{\sqrt{1-x^2}} \, dx.$

Solution. Let $u=\cos^{-1}x.$ Then $du= -\frac{1}{\sqrt{1-x^2}}\, dx.$ By substitution \begin{align} \int \frac{e^{\cos^{-1}x}}{\sqrt{1-x^2}} \, dx =-\int e^u \, du +C =-e^{\cos^{-1}x}+C \end{align} where $C$ is a constant.

Example. Evaluate $\displaystyle \int \frac{1}{\sin^{-1}y \sqrt{1-y^2}}\, dy.$

Solution. Let $u=\sin^{-1}y .$ Then $du= \frac{1}{\sqrt{1-y^2}}\, dy .$ By substitution \begin{align} \int \frac{1}{\sin^{-1}y \sqrt{1-y^2}}\, dy =\int \frac{1}{u}\,du =\ln |u|+C =\ln |\sin^{-1} y|+C \end{align} where $C$ is a constant.

Example. Evaluate $\displaystyle \int \frac{\sin \sqrt{\theta}}{\sqrt{\theta \cos^3 \sqrt{\theta}}} \, d\theta.$

Solution. Let $u=\cos \sqrt{\theta} .$ Then $du= -\sin \sqrt{\theta} \frac{1}{2\sqrt{\theta}}\, d\theta .$ By substitution \begin{align} \int \frac{\sin \sqrt{\theta}}{\sqrt{\theta \cos^3 \sqrt{\theta}}} \, d\theta & = -\int \frac{-2\sin \sqrt{\theta}}{2\sqrt{\theta}\cos^{3/2}\sqrt{\theta}} \, d\theta \\ & =-2\int \frac{1}{u^{3/2}}\, du =\frac{4}{\sqrt{u}}+C =\frac{4}{\sqrt{\cos \sqrt{\theta}}}+C \end{align} where $C$ is a constant.

Example. Solve the initial value problem: $$y”(x)=4\sec^2 2x \tan 2x, \qquad y'(0)=4, \qquad y(0)=-1.$$

Solution. First we find $$y’=\int 4\sec^2 2x \tan 2x \, dx = \int 2u \, du =u^2+C=\tan^2 2x +C$$ using $u=\tan 2x$ and $du=2\sec^2 2x \, dx$ and where $C$ can be determine using $y'(0)=4.$ We find $C=4$ and so $y’=\tan^2 2x+4.$ Using $\tan^2 x=\sec^2 x-1$, we find \begin{align} y& =\int \left(\tan^2 2x +4\right)\, dx =\int \left(\sec^2 2x +3\right)\, dx \\ & =\int \sec^2 2x \, dx +\int 3\, dx = \frac{1}{2} \tan 2x +3x+C \end{align} where $C$ can be determined by $y(0)=1.$ We find $C=-1$ and therefore $$y(x)=\frac{1}{2}\tan 2x+3x-1$$ as desired.

Example. Evaluate $\displaystyle \int 2 \sin x\cos x \, dx.$

Solution. Since $2\sin x \cos x=\sin 2x$, we use $u=2x.$ Then $du=2dx$ so \begin{align} \int 2\sin x \cos x\, dx & =\int \sin 2x \, dx =\int\frac{1}{2}\sin u \, du \\ & =-\frac{1}{2} \cos u +C =-\frac{1}{2} \cos 2x+C \end{align} where $C$ is a constant. Alternatively, let $v=\sin x.$ Then $dv=\cos x\,dx$ and so $$\int 2\sin x \cos x\, dx =2\int v \, dv =v^2+K =\sin^2x +K$$ where $K$ is a constant. Alternatively, let $w=\cos x.$ Then $dv=-\sin x\,dx$ and so $$\int 2\sin x \cos x\, dx =-2\int w \, dw =-w^2+L =-\cos^2x +L$$ where $L$ is a constant.

Example. The slope at each point $(x,y)$ on the graph of $y=F(x)$ is given by $x (x^2-1)^{1/3}$ and the graph passes through the point $(3,1).$ Find $F.$

Solution. Since $\displaystyle \frac{dy}{dx}=x(x^2-1)^{1/3}$ we find
F(x)=\int x (x^2-1)^{1/3} \, dx =\frac{1}{2} \int u^{1/3} \, du =\frac{1}{2} \cdot \frac{3}{4} (x^2-1)^{1/3} +C Using, $F(3)=\frac{3}{8} (2)^4+C=1$ implies $C=-5$, it follows $$F(x)=\frac{3}{8} (x^2-1)^{4/3}-5$$ as desired.

## An Application to Special Relativity

Example. According to Einstein’s special theory of relativity, the mass of a particle is given by $$m=\frac{m_0}{\sqrt{\displaystyle 1-\frac{v^2}{c^2}}}$$ where $m_0$ is the rest mass of the particle, $v$ is its velocity, and $c$ is the speed of light. Suppose that a particle starts from rest at $t=0$ and moves along a straight line under the action of a constant force $F.$ Then, according to Newton’s second law of motion, the equation of motion is $$F=m_0 \frac{d}{dt} \left(\frac{v}{\sqrt{1-\frac{v^2}{c^2}}}\right).$$ Find the velocity and position functions of the particle. What happens to the velocity of the particle as time goes by?

Solution. From $\displaystyle F=m_0 \dfrac{d}{dt} \left(\dfrac{v}{\sqrt{1-\frac{v^2}{c^2}}}\right)$ we find $$\frac{d}{dt} \left[\frac{v}{\sqrt{1-\frac{v^2}{c^2}}}\right]=\frac{F}{m_0}$$ which implies $$\frac{v}{\sqrt{1-\frac{v^2}{c^2}}}=\int \frac{F}{m_0} \, dt = \frac{F t}{m_0}+k$$ where $k$ is a constant. But $v(0)=0$, so $k=0.$ Therefore, $$\frac{v}{\sqrt{1-\frac{v^2}{c^2}}} = \frac{Ft}{m_0}$$ and after solving for velocity $$v=\frac{c F t}{\sqrt{m_0^2 c^2+F^2 t^2}}.$$ Next we find the position function, $$s=\int v(t) \, dt =\int \frac{c F t}{\sqrt{m_0^2 c^2+F^2 t^2}} \, dt$$ Let $u=m_0^2 c^2+F^2 t^2$ then $du = 2 F^2 t \, dt.$ Then by substitution, $$s=\frac{c F}{2F^2} \int \frac{1}{u^{1/2}} \, du = \frac{c}{F} \left( m_0^2 c^2+F^2 t^2 \right)^{1/2} +C$$ where $C$ is the constant of integration. Then $s(0)=0$ which shows that $$C=-\frac{c^2 m_0}{F},$$ so that $$s(t)=\frac{c}{F}\left( m_0^2 c^2+F^2 t^2 \right)^{1/2} -\frac{c^2 m_0}{F}.$$ Finally, $$\lim_{t\to \infty } v(t)= \lim_{t\to \infty } \frac{c F t}{\sqrt{m_0^2+F^2 t^2}} = \lim_{t\to \infty } \frac{c F}{\sqrt{\frac{m_0^2 c^2}{t^2}+F^2}} =\frac{c F}{F}=c$$ showing that its velocity approaches the speed of light.

## Exercises on Integration by Substitution

Exercise. Evaluate the following integrals.

$(1) \quad \displaystyle \int \frac{\ln x}{x} \, dx$

$(2) \quad \displaystyle \int \sqrt{3x-5} \, dx$

$(3) \quad \displaystyle \int (11-2x)^{-4/5}\, dx$

$(4) \quad \displaystyle \int \csc^2 5x \, dx$

$(5) \quad \displaystyle \int \cot \left[ \ln (x^2+1)\right] \frac{2x}{x^2+1}\, dx$

$(6) \quad \displaystyle \int \frac{6x-9}{(x^2-3x+5)^3}\, dx$

$(7) \quad \displaystyle \int \sin^3 x \cos x\, dx$

$(8) \quad \displaystyle \int \frac{x^2}{x^3+1} \, dx$

$(9) \quad \displaystyle \int \frac{4x}{2x+1} \, dx$

$(10) \quad \displaystyle \int \frac{e^{\sqrt[3]{x}} }{x^{2/3}} \, dx$

$(11) \quad \displaystyle \int x^3(x^2+4)^{1/2} \, dx$

$(12) \quad \displaystyle \int \frac{\ln (x+1)}{x+1} \, dx$

$(13) \quad \displaystyle \int \frac{1}{x^{2/3} (\sqrt[3]{x} +1)} \, dx$

$(14) \quad \displaystyle \int \frac{e^{\sqrt{x}}}{ \sqrt{x} (e^{\sqrt{x}} +1) } \, dx$

Exercise. The slope at each point $(x,y)$ on the graph of $y=F(x)$ is given by $$\dfrac{2x}{1-3x^2}.$$ What is $F(x)$ if the graph passes through $(0,5)$?

Exercise. A particle moves along the $t$-axis in such a way that at time $t$, its velocity is $$v(t)=t^2(t^3-8)^{1/3}.$$ At what time does the particle turn around? If the particle starts at a position which we denote as 1, where does it turn around?

Exercise. A rectangular storage tank has a square base 10 ft on a side. Water is flowing into the tank at the rate modeled by the function $$R(t)=t(3t^2+1)^{-1/2}$$ in units $\text{ft}^3/\text{s}$ at time $t$ seconds. If the tank is empty at time $t=0$, how mush water does it contain 4 sec later? What is the depth of the water at that time?

Exercise. Evaluate the following integrals.

$(1) \quad \displaystyle \int \frac{1}{(x+1)\sqrt{(x+1)^2}-9} \, dx$

$(2) \quad \displaystyle \int \frac{1}{x\left[9+(\ln x)^2 \right] } \, dx$

$(3) \quad \displaystyle \int \frac{\sqrt{a^2-x^2}}{x^4} \, dx$

$(4) \quad \displaystyle \int \left[ (x^2-1)(x+1)\right]^{-2/3} \, dx$

Exercise. Find the indefinite integral for the following then check you answer by differentiation.

$(1) \quad \displaystyle \int \left(3t^2+\frac{t}{2}\right) \, dt$

$(2) \quad \displaystyle \int \left(1-x^2-3x^5\right)dx$

$(3) \quad \displaystyle \int \left(x^{-1/3}\right) \, dx$

$(4) \quad \displaystyle \int \left(\frac{\sqrt{x}}{2}+\frac{2}{\sqrt{x}}\right) \, dx$

$(5) \quad \displaystyle \int 2x\left(1-x^{-3}\right)dx$

$(6) \quad \displaystyle \int \left(\frac{4+\sqrt{t}}{t^3}\right) \, dt$

$(7) \quad \displaystyle \int \left(7 \sin \frac{\theta }{3}\right) \, d\theta$

$(8) \quad \displaystyle \int \left(-\frac{\sec ^2x}{3}\right) \, dx$

$(9) \quad \displaystyle \int \left(e^{3x}+5e^{-x}\right) \, dx$

$(10) \quad \displaystyle \int (1.3)^x \, dx$

$(11) \quad \displaystyle \int \left(\frac{1+\cos 4t}{2}\right) \, dt$

$(12) \quad \displaystyle \int \left(\frac{2}{\sqrt{1-y^2}}-\frac{1}{y^{1/4}}\right) \, dy$

$(13) \quad \displaystyle \int \left(1+\tan ^2\theta \right) \, d\theta$

Exercise. Verify the following formulas by differentiation where $C$ is an arbitrary constant.

$(1) \quad \displaystyle \int (7x-2)^3 \, dx=\frac{(7x-2)^4}{28}+C$

$(2) \quad \displaystyle \int \csc ^2\left(\frac{x-1}{3}\right) \, dx=-3 \cot \left(\frac{x-1}{3}\right)+C$

$(3) \quad \displaystyle \int x e^xdx=x e^x-e^x+C$

Exercise. Determine which of the following formulas are right and which are wrong. Write an explanation for each. Assume $C$ is an arbitrary constant.

$(1) \quad \displaystyle \int \tan \theta \sec ^2\theta d\theta =\frac{\sec ^3\theta }{3}+C$

$(2) \quad \displaystyle \int \tan \theta \sec ^2\theta d\theta =\frac{1}{2}\tan ^2 \theta +C$

$(3) \quad \displaystyle \int \tan \theta \sec ^2\theta d\theta =\frac{1}{2}\sec ^2\theta +C$

$(4) \quad \displaystyle \int \sqrt{2x+1} \, dx=\sqrt{x^2+x+C}.$

$(5) \quad \displaystyle \int \sqrt{2x+1} \, dx=\sqrt{x^2+x}+C.$

$(6) \quad \displaystyle \int \sqrt{2x+1} \, dx=\frac{1}{3}\left(\sqrt{2x+1}\right)^3+C.$

Exercise. Solve the following initial value problems.

$(1) \quad \displaystyle \frac{dy}{dx}=\frac{1}{x^2}+x,$ $x>0;$ $y(2)=1.$

$(2) \quad \displaystyle \frac{dy}{dx}=\frac{1}{2\sqrt{x}},$ $y(4)=0.$

$(3) \quad \displaystyle \frac{d^2r}{dt^2}=\frac{2}{t^3},$ $\frac{dr}{dt}|_{t=1}=1,$ and $r(1)=1.$

$(4) \quad \displaystyle \frac{d^3y}{dx^3}=6,$ $y\text{”}(0)=-8,$ $y'(0)=0,$ and $y(0)=5.$

Exercise. Find a curve $y=f(x)$ with $d^2y/dx^2=6x$ and its graph passes through the point $(0,1)$ and has a horizontal tangent there. How many curves like this are there? How do you know?

Exercise. Given $f(x)=\frac{d}{dx}\left(1-\sqrt{x}\right)$ and $g(x)=\frac{d}{dx}(x+2)$, find each of the following.

$(1) \quad \displaystyle \int f(x) \, dx,$

$(2) \quad \displaystyle \int g(x) \, dx,$

$(3) \quad \displaystyle \int [-f(x)] \, dx,$

$(4) \quad \displaystyle \int [-g(x)] \, dx,$

$(5) \quad \displaystyle \int [f(x)+g(x)] \, dx,$

$(6) \quad \displaystyle \int [f(x)-g(x)]dx.$

David Smith (Dave) has a B.S. and M.S. in Mathematics and has enjoyed teaching precalculus, calculus, linear algebra, and number theory at both the junior college and university levels for over 20 years. David is the founder and CEO of Dave4Math.