# How do you find the equation of the tangent and normal line to the curve y=tanx at x=-pi/4?

Nov 5, 2016

Tangent: $y = 2 x + \frac{\pi}{2} - 1$
Normal: $y = - \frac{1}{2} x - \frac{\pi}{8} - 1$

#### Explanation:

The gradient tangent to a curve at any particular point is given by the derivative.

If $y = \tan x$ then $\frac{\mathrm{dy}}{\mathrm{dx}} = {\sec}^{2} x$

When $x = - \frac{\pi}{4}$
$\implies y = \tan \left(- \frac{\pi}{4}\right) = - 1$
$\implies \frac{\mathrm{dy}}{\mathrm{dx}} = {\sec}^{2} \left(- \frac{\pi}{4}\right) = 2$

So the tangent passes through $\left(- \frac{\pi}{4} , - 1\right)$ and has gradient ${m}_{T} = 2$

Using $y - {y}_{1} = m \left(x - {x}_{1}\right)$ the equation of the tangent is:

$y - \left(- 1\right) = \left(2\right) \left(x - \left(- \frac{\pi}{4}\right)\right)$
$\therefore y + 1 = 2 x + \frac{\pi}{2}$
$\therefore y = 2 x + \frac{\pi}{2} - 1$

The normal is perpendicular to the tangent, so the product of their gradients is -1 hence normal passes through $\left(- \frac{\pi}{4} , - 1\right)$ and has gradient ${m}_{N} = - \frac{1}{2}$

so the equation of the normal is:

$y - \left(- 1\right) = - \frac{1}{2} \left(x - \left(- \frac{\pi}{4}\right)\right)$
$\therefore y + 1 = - \frac{1}{2} x - \frac{\pi}{2}$
$\therefore y = - \frac{1}{2} x - \frac{\pi}{8} - 1$ 