# Integration by trig substitution - Why can I draw a right triangle and use that to go back to the original variable?

Suppose we are given an integral of the form $\int f(x) dx$ with $f(x)$ defined on $[a;b]$.

We can then use inverse substitution using a function $g(t)$ defined over an interval $[\alpha;\beta]$ such that $g(\alpha) = a$ and $g(\beta) = b$. Also it makes the substitutation easier if $g(t)$ is one-to-one such that $g(t)^{-1}$ exists.

Then $\int f(x) dx = F(x) = \int f(g(t))g^{'}(t) dt = F(g(t))$. So we have $F(g(t))$ as an anti-derivative of $f(x)$ with respect to the change of variable $x$ to $g(t)$. Since $g(t)$ is continous it has image $g([\alpha;\beta]) = [a;b]$, so we can evaluate $F(g(t))$ for any two points in the original interval $[a;b]$ to get values for $F(x)$ by using appropriate values for $t \in [\alpha;\beta]$, so indeed $F(g(t))$ is an anti-derivative of $F(x)$ with respect to the variable $x = g(t)$.

Now since we are dealing with an indefinite integral we must return the the original variable. We want an integral with $x$ instead of $t$, so we use the identity $x = g(t)$. In other words we are returning the original interval $[a;b]$. Then setting $g(t) = a/2$ yields $t = g^{-1}(a/2)$ so removal of terms involving $g(t)$ and $t$ in our integral $F(g(t))$ are trivial.

Please correct me if I am wrong about any of this.

In the case of trig substitution of the form $x = \sin(\theta)$ substitution back the the original integral involving $x$ is easy when terms are involving $\theta$ are trivial. However terms like $\cot(\theta)$ becomes much more difficult. I understand that using trig identities allow us to express $\cot(\theta)$ in terms of $x$, however I don't see why we can draw a right triangle with $\theta$ as the angle and then just divide two sides to get $\cot(\theta)$ in terms of $x$. Could someone explain why this is possible and right to do ?

Thanks

Below I have attached an image for reference:

In this case we know that $sin(\theta) = x/3$. Why does this imply we can draw a triangle with side $\sqrt{9 - x^2}$ ? I see for any value of $\theta$, $x$ must be in proportion for the identity $sin(\theta) = x/3$ to be true. • – Git Gud Nov 24 '13 at 8:48
• Thanks @Git Gud. Those identities are interesting, and will help me doing trig substitution 'the hard way'. However it will be much easier to draw a triangle to instant get expressions for $\cot, \sec$ etc. However I am missing connection between the drawing and the trigonometic identities - How can I be sure those expressions are true ? – Shuzheng Nov 24 '13 at 9:55
• I proved them properly in my answer, if there's something you don't understand, feel free to ask. I don't know how to do it geometrically nor do I have any interest in it. – Git Gud Nov 24 '13 at 9:57
• I like your derivation of $\cot(x)$ at the bottom of the page. I can then substitute the expressions for $\sin(x)$ to get an expression in terms of the original variable only. How would you go about representing $\cot(x)$ in terms of $\cos(x)$ ? This problem is arising frequently. Just substitute $\sin(x)$ by $\sqrt{1 - cos^2(x)}$ in the expression of $\cot(x)$ in terms of $\sin(x)$ that you've proved ? Also is my understanding of inverse substitution right ? And last, for any trigometric expression like $\cot(x)$ whatever - can I always represent it using only $\sin(x)$ or $\cos(x)$ etc. ? – Shuzheng Nov 24 '13 at 10:09
• I'm sorry for not having been clear. Do you mind copying your comment and pasting it on my answer? I'll then gladly add a derivation of $\cot$ in terms of $\cos$. – Git Gud Nov 24 '13 at 10:18

## 1 Answer

I think I see the core of your question from your last paragraph, your image, and your response in post. The essential answer to your question boils down to the definitions of the trig functions.

The definitions of the trigs are nothing more than definitions, and they are defined over right triangles with $\theta$ being either of the non-right angles. That is to say for example, as you surely know, $\sin\theta=\frac{opposite}{hypoteneuse}$. By geometric principles, given any two sides of any right triangle we can always find the third side by the theorem of Pythagoras.

The technique of trigonometric substitution (like any other substitution) works when we can make a total substitution, and then completely reverse substitute the final result. In the case of succesful trig substitutions, we can always go back and call out the value of any of the trigs including $\cot \theta$. We can draw these because ALL of the trigs are defined over right triangles, and we can always find a third side given two. No one trig is more difficult to find than another over a right triangle with defined side lengths.

When all of the terms of an integral can be completely substituted by the method, the result, assuming you can find it, should always be re-translatable in to the original terms as all of the information required for the back substitution is included in the contents of a right triangle, as a trig of an angle is nothing more than the ratio of two sides of a right triangle.

Given any of the 6 trigs with variable theta, we can always assign measures to two of three sides of a right triangle as that is how the trigs are defined, hence we can always define the third side.

I hope this post is helpful, please let me know if it is less than clear. Trig sub is my favorite technique as far as methods go and so I am happy to have this out with you.

• No problem there. For example, suppose you let $x=3\sin \theta$, and you drew this triangle (this triangle makes sense). On the back substitution, if $\theta$ was a part of the result, then since $\sin \theta =\frac{x}{3}$, $\theta=\sin^{-1}(\frac{x}{3})$. Note I am having trouble reading the math part of what you just posted. – J. W. Perry Nov 24 '13 at 11:07
• In terms of the image I've attached. Suppose we have $\theta$ as a term in the resulting anti-derivative of $\int f(g(\theta))g^{'}(\theta)$ Then setting $g(\theta) = x = b \Rightarrow \theta = g^{-1}(x)$. So we substitute $g^{-1}(x)$ for $\theta$. However in terms of $\cot(\theta)$ I want to be sure that setting $g(\theta) = x = b \Rightarrow \cot(\theta) =$ some expression of $x$. $\cot(\theta) = \frac {hyp} \cos$ I can easily express $\cos$ in terms of $\sin$. But since $\sin(\theta) = \frac x 3$ I can conclude that $hyp = \sqrt{9-x^2}$ ? I guess my problem is the hypotenuse. – Shuzheng Nov 24 '13 at 11:13
• Although I am not reading all of what you just said with flawless clarity, I think the answer is yes. Let me just say this. If you make a successful substitution that results in this triangle you have formed, it is set in stone! You can back substitute from that triangle in any manner that suits you so long as it is mathematically correct. Given any two constant sides of a right triangle the third side is set in stone constant. You may use it at will. Also, yes if $\sin(\theta) = \frac x 3$ then the hypoteneuse is as you say. This is bible. It follows from core principles of right triangles. – J. W. Perry Nov 24 '13 at 11:17
• I just want to be convinced that setting $g(\theta) = x = b \Rightarrow \theta = g^{-1}(x)$ Now I know the the value of $\theta$ for my value of $g(\theta)$ namely $g^{-1}(x)$. So prove that $\cot(g^{-1}(x))$ $= \frac {\sqrt {9 - x^2}} x$. – Shuzheng Nov 24 '13 at 11:21
• Wow the sun is starting to rise. I did not sleep lol (on the east coast of USA) – J. W. Perry Nov 24 '13 at 11:23