07Jmodulusderivative

toc = Absolute Value Function =

Derivative of Basic Function
Consider the absolute value function: (shown in blue)

math f(x)=\Big| x \Big| =\Bigg\{ \begin{matrix} +x && x\geqslant 0\\ \\ -x && x<0 \end{matrix} math

The absolute value fuction f(x) is not differentiable at the cusp (sharp point) at x = 0.

The derivative of the function is: (shown in red)

math f'(x)=\Bigg\{ \begin{matrix} +1&& x>0\\ \\ -1&& x<0 \end{matrix} math

Note: Open circles at the endpoints (0, 1) and (0, –1)

Note: The domain has changed for the right section from "__>__" in the orginal function to ">" in the derivative function.

Derivative on the Calculator


Using the CAS calculator, the derivative of the absolute value function is given as **signum(//x//)**. Signum(x) is a calculator function and not a part of mathematics.

math \textbf{Signum} \big( g(x) \big) = \Bigg\{ \begin{matrix} +1 && g(x) >0 \\ \\ -1 && g(x) <0 \end{matrix} math

It is **__not__** acceptable to give **signnum** as an answer. Answers should be written as hybrid functions. For example, math \dfrac{d}{dx} \Big( \left| 3x+2 \right| \Big) = 3 \; \text{signum} (3x + 2) math

This should be understood as: math 3 \;\text{signum} \big( 3x+2 \big) = 3 \; \Bigg\{ \begin{matrix} +1 && 3x+2 >0 \\ \\ -1 && 3x+2 <0 \end{matrix} \\. \\ . \qquad \qquad \qquad \qquad = \Bigg\{ \begin{matrix} +3 && x > \frac{-2}{3} \\ \\ -3 && x<\frac{-2}{3} \end{matrix} math

Note: You may enter signnum(x) into the calculator to produce graphs of the derivative of absolute value functions (Copy/Paste from the Main Screen or look it up in the CAT tab of the virtual keyboard) but you are probably better to enter d/dx of the function (see Eg 2 below)

Note: When using a calculator to graph a function and its derivative, use different lines to distinguish between the function and the derivative.

Note: The calculator will not show open/closed circles at endpoints. You must remember to put them in on your graphs. The circles must be significant (not just a dot).

Finding the Derivative
To find the derivative of simple functions, express the function as a hybrid function, then take the derivative of each section. Remember to change any "__>__" to ">" in the domain.

** Example 1 **
Find the derivative of f(x) = |3x + 2|.

__**Solution**__

The cusp occurs where 3x + 2 = 0 math \Longrightarrow \; x = -\frac{2}{3} math

Therefore the function, f(x) = |3x + 2| can be written as:

math f(x)=\Bigg\{ \begin{matrix} +(3x+2) && x\geqslant -\frac{2}{3} \\ \\ -(3x+2) && x< -\frac{2}{3} \end{matrix} math

Hence the derivative is:

math f'(x)=\Bigg\{ \begin{matrix} +3 && x > -\frac{2}{3} \\ \\ -3 && x< -\frac{2}{3} \end{matrix} math

More Complicated Functions
When finding the derivative of a more complicated absolute value function you can either:
 * write the original absolute value function as a hybrid function then differentiate each part seperately (or)
 * Treat it as a composite function and use the chain rule to differentiate.

math \text{For } f(x) = \big| g(x) \big| \text{ then} math

math f'(x)=g'(x)\times \Bigg\{ \begin{matrix} +1 & g(x)>0 \\ -1 & g(x)<0 \end{matrix} math

** Example 2 **
Find the derivative of //f(x) = |x 2 - 1|// and sketch the graphs of //f(x)// and //f'(x)//.

__Solution:__

math f(x)= \big| g(x) \big| \text{ where }g(x)=x^2-1 math

Using the chain rule math f'(x)=g'(x) \times \Bigg\{ \begin{matrix}+1 && g(x)>0 \\ -1 &&g(x)<0 \end{matrix} math

math .\qquad=2x\times \Bigg\{ \begin{matrix} +1 && x^2-1>0 \\ -1 &&x^2-1<0 \end{matrix} math

math .\qquad=2x \times \Bigg \{ \begin{matrix} +1 && x<-1 \textit{ or } x>1 \\ -1 && -1 < x < 1 \end{matrix} math

math .\qquad=\Bigg\{ \begin{matrix} +2x && x<-1 \textit{ or } x>1 \\ -2x && -1 < x < 1 \end{matrix} math

Since the function can __not__ be differentiated at x = –1 and x = 1, the endpoints of the derivative graph are clearly marked with open circles.

Using the CAS calculator to graph the function and its derivative, choose a different line mode to graph the derivative.

As illustrated, the CAS calculator does not include endpoints, but places vertical lines between the sections.

It is **__not__** acceptable to show such vertical lines in your graphs.

** Example 3 **
Find the derivative of //f(x) = |x| 2 - |x|// and sketch the graphs of //f(x)// and //f'(x)//.

__Solution:__

It may be easier to treat //f(x)// as a hybrid function and then differentiate each section. math f(x) = \big| x \big| ^2 - \big| x \big| math

can be written as: math f(x)=\Bigg\{\begin{matrix} x^2-x &&x \geqslant 0\\ x^2+x && x<0 \end{matrix} math

then the derivative is: math f'(x)=\Bigg\{ \begin{matrix} 2x-1 && x>0 \\ 2x+1 && x<0 \end{matrix} math Go to top of page flat

.