Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Find the equation of the line tangent to $f(x) = \tan x$ at $x = \frac{\pi}{4}$.

I'm trying to incorporate the slope point formula using $f'(x) = \sec^2 x$ but I'm nowhere near!

share|cite|improve this question
up vote 2 down vote accepted


We have $$f'\left(\frac\pi4\right)=\frac{y-f\left(\frac\pi4\right)}{x-\frac\pi4}$$

share|cite|improve this answer
Yes this is where I am stuck. $$\sec^2(\pi / 4 ) = \frac{ y-1 } { x- \pi / 4 }$$ But I have 2 unknowns and only one equation! – user3200098 May 10 '14 at 13:56
@user3200098, What are the unknown(s) here. We need to form the equation of a Straight line, right? – lab bhattacharjee May 10 '14 at 13:57
Right, I was just about to edit my answer. Sorry! Thanks...Sometimes I get confused. – user3200098 May 10 '14 at 13:58
Could you give me a hand here?… – user3200098 May 10 '14 at 13:58
@user3200098. It is the same problem. – Claude Leibovici May 10 '14 at 13:59

At $x = \pi/4,\;$ $f(x) =y = \tan(\pi/4) = 1$.

So $(\pi/4, 1)$ is the point of tangency of $f(x)$ and the desired line, which means it is certainly a point on the desired line.

Now, $f'(x) = \sec^2(x)$. At $x = \pi/4$, $$f'(x) = \sec^2(\pi/4) = \frac{1}{\cos^2(\pi/4)} = \left(\sqrt 2\right)^2 = 2$$ So the slope of the tangent line at the given point is $m = 2$.

Now use the point-slope form of an equation of a line, since you have needed point $(\pi/4, 1) = (a, b)$ and the slope $m = 2$:

$$(y - a) = m(x - b)$$

$$\begin{align} y - 1 = 2(x - \pi/4) & \iff y = 2x + (1 - \pi/2) \\ \\ &\iff y= 2x + \frac{2-\pi}{2}\end{align}$$

share|cite|improve this answer

The tangent line is described by the equation: $$y=mx+b.$$ And we know that the slope of a tangent line to the graph of a function $f(x)$ at a point $(x_0, f(x_0))$ is the derivative of $f(x)$ evaluated at $x_0$, that is: $$m=f'(x_0).$$ So let's find it! $$m=\dfrac{\mathrm d}{\mathrm dx}\tan(x)\left|\right._{x={\pi}/{4}}=\sec^2\left(\tfrac{\pi}{4}\right)=2.$$ This tangent line passes through the point $\big(\pi/4, \tan(\pi/4)\big)=(\pi/4,1)$. By the slope-point formula: $$y-y_0=m(x-x_0)\Rightarrow y-1=2(x-\pi/4).$$ Rearranging we get: $$y=2x+\dfrac{2-\pi}2$$ which is our desired equation.

share|cite|improve this answer

Equation of tangent at $x=x_0$ is given by $y-f(x_0)=f'(x_0)(x-x_0)$

Now put $x=\frac{\pi}{4}$

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.