How do I find, by the definition of a derivative, the derivative of $\tan x$? How do I find, by  the definition of a derivative, the derivative of tanx? $$f'(x)=\lim_{\Delta x \to 0}{f(x+\Delta x)-f(x)\over \Delta x}=\lim_{\Delta x \to 0}{\tan(x+\Delta x)-\tan(x)\over \Delta x}=\lim_{\Delta x \to 0}{{\sin(x+\Delta x)\over \cos(x+\Delta x)}-{\sin(x)\over \cos(x)}\over \Delta x}$$ 
I tried using identities but I always reached something like ${0\over \cos(x+ \Delta x)\cos(x)}$ which is no good... Thanks for any help! 
P.S. I'm only at the beginning of the derivatives subject, so we need to find the derivative of $tanx$ using definition only.
 A: Taking the alternative and equivalent definition of derivative and using a little trigonometry and known limits , we get for $\,\displaystyle{\tan'(y):=\lim_{x\to y}
\frac{\tan x-\tan y}{x-y}}\,$:
$$\frac{\tan x-\tan y}{x-y}=\frac{\tan(x-y)(1+\tan x\tan y)}{x-y}=$$
$$=\frac{\sin(x-y)}{x-y}\frac{1+\tan x\tan y}{\cos(x-y)}\xrightarrow [x\to y]{}1\cdot\frac{1+\tan^2y}{1}=1+\tan^2 y=\frac{1}{\cos^2 y}=\sec^2y$$
A: Using some trigonometry, you can check that
$$\tan(x+\Delta x) = \frac{\tan x + \tan \Delta x}{1-\tan x \tan \Delta x}.$$
Hence,
\begin{align}
\frac{\tan(x+\Delta x) - \tan x}{\Delta x} &=
\dfrac{\dfrac{\tan x + \tan \Delta x}{1-\tan x \tan \Delta x} - \tan x}{\Delta x}\\
&= \dfrac{\dfrac{\tan x + \tan \Delta x}{1-\tan x \tan \Delta x} - \dfrac{\tan x - \tan^2 x\tan \Delta x}{1-\tan x\tan \Delta x}}{\Delta x}\\
&= \frac{\tan \Delta x (1+\tan^2 x)}{\Delta x(1-\tan x\tan \Delta x)}.
\end{align}
I think you can finish it off now. (Remember that $\tan \Delta x = \sin \Delta x/\cos \Delta x$ and that $\tan \Delta x \to 0$ as $\Delta x \to 0$.)
