The Definition of a Derivative

Read this section to understand the definition of a derivative. Work through practice problems 1-8.

Fortunately, we will soon have some quick and easy ways to calculate most derivatives, but first we will have to use the definition to determine the derivatives of a few basic functions. In Section 2.2 we will use those results and some properties of derivatives to calculate derivatives of combinations of the basic functions. Let's begin by using the graphs and then the definition to find a few derivatives. 

Example 1: Graph y = f(x) = 5 and estimate the slope of the tangent line at each point on the graph. Then use the definition of the derivative to calculate the exact slope of the tangent line at each point. Your graphic estimate and the exact result from the definition should agree. 

Solution: The graph of y = f(x) = 5 is a horizontal line (Fig. 3) which has slope 0 so we should expect that its tangent line will also have slope 0.


Using the definition: Since  f(x) = 5, then \mathrm{f}(\mathrm{x}+\mathrm{h})=5, so

\mathrm{D}(\mathrm{f}(\mathrm{x})) \equiv \lim\limits_{h \rightarrow 0} \frac{f(x+h)-f(x)}{h}=\lim\limits_{h \rightarrow 0} \frac{5-5}{h}=\lim\limits_{h \rightarrow 0} \frac{0}{h} =0

Using similar steps, it is easy to show that the derivative of any constant function is 0

Theorem: If f(x) = k, then f '(x) = 0

Practice 1: Graph y = f(x) = 7x and estimate the slope of the tangent line at each point on the graph. Then use the definition of the derivative to calculate the exact slope of the tangent line at each point. 

Example 2: Determine the derivative of y = f(x) = 5x^3 graphically and using the definition. Find the equation of the line tangent to y = 5x^3 at the point (1,5)

Solution: It appears that the graph of y = f(x) = 5x3 (Fig. 4) is increasing so the slopes of the tangent lines are positive except perhaps at x = 0 where the graph seems to flatten out. 


Using the definition: Since f(x)=5 x^{3} then f(x+h)=5(x+h)^{3}=5\left(x^{3}+3 x^{2} h+3 x h^{2}+h^{3}\right) so

\begin{aligned}&=\lim\limits_{h \rightarrow 0} \frac{15 x^{2} h+15 x h^{2}+5 h^{3}}{h} \\&=\lim\limits_{h \rightarrow 0} \frac{h\left(15 x^{2}+15 x h+5 h^{2}\right)}{h}\end{aligned}  divide by \mathrm{h}

=\lim\limits_{h \rightarrow 0}\left(15 x^{2}+15 x h+5 h^{2}\right)=15 \mathrm{x}^{2}+0+0=15 \mathrm{x}^{2}

so \mathrm{D}\left(\mathbf{5 x}^{3}\right)=15 \mathrm{x}^{2} which is positive except when \mathrm{x}=0, and then 15 \mathrm{x}^{2}=0

\mathrm{f}^{\prime}(\mathrm{x})=15 \mathrm{x}^{2} is the slope of the line tangent to the graph of \mathrm{f} at the point (\mathrm{x}, \mathrm{f}(\mathrm{x})). At the point (1,5), the slope of the tangent line is \mathrm{f}^{\prime}(1)=15(1)^{2}=15. From the point-slope formula, the equation of the tangent line to \mathrm{f} is \mathrm{y}-5=15(\mathrm{x}-1) or \mathrm{y}=15 \mathrm{x}-10

Practice 2: Use the definition to show that the derivative of \mathrm{y}=\mathrm{x}^{3} is \frac{\mathrm{dy}}{\mathrm{dx}}=3 \mathrm{x}^{2}. Find the equation of the line tangent to the graph of \mathrm{y}=\mathrm{x}^{3} at the point (2,8).

If f has a derivative at x, we say that f is differentiable at x. If we have a point on the graph of a differentiable function and a slope (the derivative evaluated at the point), it is easy to write the equation of the tangent line. 

Tangent Line Formula 

If f is differentiable at a then the equation of the tangent line to f at the point (a ,f(a) ) is y = f(a) + f '(a)(x – a)

Proof: The tangent line goes through the point (a ,f(a) ) with slope f'(a) so, using the point-slope formula, y-f(a)=f^{\prime}(a)(x-a) or y=f(a)+f^{\prime}(a)(x-a).

Practice 3: The derivatives \mathbf{D}(\mathrm{x})=1, \mathbf{D}\left(\mathrm{x}^{2}\right)=2 \mathrm{x}, \mathbf{D}\left(\mathrm{x}^{3}\right)=3 \mathrm{x}^{2} exhibit the start of a pattern. Without using the definition of the derivative, what do you think the following derivatives will be? \mathbf{D}\left(\mathrm{x}^{4}\right), \mathrm{D}\left(\mathrm{x}^{5}\right), \mathbf{D}\left(\mathrm{x}^{43}\right. ), \mathbf{D}(\sqrt{\mathrm{x}})=\mathbf{D}\left(\mathrm{x}^{1 / 2}\right) and \mathbf{D}\left(\mathrm{x}^{\pi}\right)

(Just make an intelligent "guess" based on the pattern of the previous examples. ) 

Before going on to the "pattern" for the derivatives of powers of x and the general properties of derivatives, let's try the derivatives of two functions which are not powers of x: sin(x) and | x |.

Theorem: \quad \mathrm{D}(\sin (\mathrm{x}))=\cos (\mathrm{x})

The graph of \mathrm{y}=\mathrm{f}(\mathrm{x})=\sin (\mathrm{x}) is well-known (Fig. 5). The graph has horizontal tangent lines \left(\right. slope =0) when x=\pm \frac{\pi}{2} and x=\pm \frac{3 \pi}{2} and so on. If 0 < x < \frac{\pi}{2}, then the slopes of the tangent lines to the graph of y=\sin (x) are positive. Similarly, if \frac{\pi}{2} < x  < \frac{3 \pi}{2}, then the slopes of the tangent lines are negative. Finally, since the graph of \mathrm{y}=\sin (\mathrm{x}) is periodic, we expect that the derivative of \mathrm{y}=\sin (\mathrm{x}) will also be periodic.


Proof of the theorem: Since \mathrm{f}(\mathrm{x})=\sin (\mathrm{x}), \mathrm{f}(\mathrm{x}+\mathrm{h})=\sin (\mathrm{x}+\mathrm{h})=\sin (\mathrm{x}) \cos (\mathrm{h})+\cos (\mathrm{x}) \sin (\mathrm{h}) so

\begin{aligned}&\mathbf{f}^{\prime}(\mathrm{x}) \equiv \lim _{h \rightarrow 0} \frac{f(x+h)-f(x)}{h} \\&=\lim\limits_{h \rightarrow 0} \frac{\{\sin (x) \cos (h)+\cos (x) \sin (h)\}-\{\sin (x)\}}{h}\end{aligned}

this limit looks formidable, but if we just collect the terms containing \sin (\mathrm{x}) and then those containing \cos (\mathrm{x}) we get

=\lim\limits_{h \rightarrow 0}\left\{\sin (x) \cdot \frac{\cos (h)-1}{h}+\cos (x) \cdot \frac{\sin (h)}{h}\right\}

now calculate the limits separately

=\left\{\lim\limits_{h \rightarrow 0} \sin (x)\right\} \cdot\left\{\lim _{h \rightarrow 0} \frac{\cos (h)-1}{h}\right\}+\left\{\lim\limits_{h \rightarrow 0} \cos (x)\right\} \cdot\left\{\lim\limits_{h \rightarrow 0} \frac{\sin (h)}{h}\right\}

the first and third limits do not depend on \mathrm{h}, and we calculated the second and fourth limits in Section1.2

=\sin (x) \cdot(0)+\cos (x) \cdot(1)=\cos (x)

So \mathrm{D}(\sin (\mathrm{x}))=\cos (\mathrm{x}), and the various properties we expected of the derivative of \mathrm{y}=\sin (\mathrm{x}) by examining its graph are true of \cos (\mathrm{x})

Practice 4: Use the definition to show that \mathrm{D}(\cos (\mathrm{x}))=-\sin (\mathrm{x}). (This is similar to the situation for \mathrm{f}(\mathrm{x})=\sin (\mathrm{x}). You will need the formula \cos (x+h)=\cos (x) \cdot \cos (h)-\sin (x) \cdot \sin (h). Then collect all the terms containing \cos (x) and all the terms with \sin (x). At that point you should recognize and be able to evaluate the limits.)

Example 3: For \mathrm{y}=|\mathrm{x}| find \mathrm{dy} / \mathrm{dx}.

Solution: The graph of y=f(x)=|x| (Fig. 6) is a "V" with its vertex at the origin. When x>0, the graph is just y=|x|=x which is a line with slope +1 so we should expect the derivative of |x| to be +1. When \mathrm{x} < 0, the graph is \mathrm{y} = |\mathrm{x}| = -\mathrm{x} \quad which is a line with slope -1, so we expect the derivative of |\mathrm{x}| to be -1. When \mathrm{x} = 0, the graph has a corner, and we should expect the derivative of |x| to be undefined at x=0.


Using the definition: It is easiest to consider 3 cases in the definition of |x|: x > 0, x < 0 and x = 0

If x>0, then, for small values of h, x+h>0 so Df (x) \equiv \lim\limits_{h \rightarrow 0} \frac{|x+h|-|x|}{h}=\lim\limits_{h \rightarrow 0} \frac{h}{h}=1

If x, then, for small values of h, we also know that x+h < 0 so \operatorname{Df}(x)=\lim\limits_{h \rightarrow 0} \frac{-h}{h}=-1. When x=0, the situation is a bit more complicated and

\mathbf{D} \mathrm{f}(\mathrm{x}) \equiv \lim _{h \rightarrow 0} \frac{f(x+h)-f(x)}{h}=\lim\limits_{h \rightarrow 0} \frac{|0+h|-|0|}{h}=\lim _{h \rightarrow 0} \frac{|h|}{h} \quad which is undefined

since \lim\limits_{h \rightarrow 0^{+}} \frac{|h|}{h}=+1 and \lim\limits_{h \rightarrow 0^{-}} \frac{|h|}{h}=-1 \text {. }  \mathbf{D}(|x|)= \begin{cases}+1 & \text { if } x > 0 \\ \text { undefined } & \text { if } x=0 \\ -1 & \text { if } x < 0\end{cases}

Practice 5: Graph \mathrm{y}=|\mathrm{x}-2| and \mathrm{y}=|2 \mathrm{x}| and use the graphs to determine \mathbf{D}(|\mathrm{x}-2|) and \mathbf{D}(|2 \mathrm{x}|).