# Inverse Functions: Arctangent and Angle Between Two Lines (Part 24)

Here’s a straightforward application of arctangent that, a generation ago, used to be taught in a typical Precalculus class (or, as it was called back then, analytical geometry).

Find the smallest angle between the lines $y= 3x$ and $y = -x/2$.

This problem is almost equivalent to finding the angle between the vectors $\langle 1,3 \rangle$ and $\langle -2,1 \rangle$. I use the caveat almost because the angle between two vectors could be between $0$ and $\pi$, while the smallest angle between two lines must lie between $0$ and $\pi/2$.

This smallest angle can be found using the formula

$\theta = \displaystyle \tan^{-1} \left( \left| \frac{m_1 - m_2}{1 + m_1 m_2} \right| \right)$,

where $m_1$ and $m_2$ are the slopes of the two lines. In the present case,

$\theta = \tan^{-1} \left( \left| \displaystyle \frac{ 3 - (-1/2) }{1 + (3)(-1/2)} \right| \right)$

$\theta = \tan^{-1} \left( \left| \displaystyle \frac{7/2}{-1/2} \right| \right)$

$\theta = \tan^{-1} 7$

$\theta \approx 81.87^\circ$.

Not surprisingly, we obtain the same answer that we obtained a couple of posts ago using arccosine. The following picture makes clear why $\tan^{-1} 7 = \cos^{-1} \displaystyle \frac{1}{\sqrt{50}}$.

In tomorrow’s post, I’ll explain why the above formula actually works.