Let us suppose you have a certain function $f(x)$ and you want to find out in which intervals this function is decreasing, constant or increasing. I know you need to follow these steps:
- Find out $f'(x)$.
- Find out the values for which $f'(x)=0$. In other words, we need to find out the zeroes of $f'(x)$. Let's suppose we find out two values which are $x=a$ and $x=b$, and that $a<b$.
- Now we need to choose a random value $r$ from the interval $(-\infty,a]$ or $(-\infty,a)$ (I don't remember exactly) and calculate $f'(x)$ for $x=r$.
- If $f'(x)<0$ for $x=r$, then $f(x)$ is decreasing in the mentioned interval. If $f'(x)=0$ for $x=r$, then $f(x)$ is constant in that interval. If $f'(x)>0$ for $x=r$, then $f(x)$ is increasing in that interval.
- We need to repeat steps 3 and 4 for the other intervals.
Now, what happens if $f'(x)$ doesn't have any zeroes? What should I do?
Example of a (derivative) function that doesn't have any zeroes: $e^x/x$.
Thanks in advance!
$\endgroup$3 Answers
$\begingroup$For the types of functions that you are probably dealing with, you can simply expand your step 2 to examine points where $f'(x)=0$ or $f'(x)$ is undefined. If this set has only isolated points, then these are the only points where the derivative can change sign. In the example that you give, we have $$f'(x) = \frac{e^x }{x}$$ which is undefined at zero. Thus, it is possible for the derivative to change sign there as well and, in fact, it does. Thus the correct answer is that the function is decreasing on $(-\infty,0)$ and then increasing on $(0,\infty)$. Here's a plot of one possible anti-derivative for this function:
Of possible interest is the fact that the non-differentiability at the origin means that the two "branches" could be shifted different amounts. Thus, another possible anti-derivative is
There is one other point that has been glossed over by all the answers - namely derivatives, while not necessarily continuous, do satisfy the intermediate value property. Thus, if a derivative is defined and non-vanishing on an interval then it cannot change signs on the interval.
$\endgroup$ 0 $\begingroup$There are also other kind of separation points, in the given example it is $x=0$, where the function is not defined.
So, choose arbitrary values $r$ from the intervals $(-\infty,0)$, $(0,1)$ and $(1,+\infty)$ now.
In case we didn't have more separation points --assuming that the given function is continuous (and differentiable) everywhere-- (e.g. for $f(x)=e^x$), we would have only one interval, $(-\infty,+\infty)$, and, as $e^0=1>0$, we could conclude that $f$ is increasing/decreasing throughout $\Bbb R$.
$\endgroup$ 1 $\begingroup$In the example you give, we have
$$\frac{e^x}x\begin{cases}>0&\,\;\;x>0\\{}\\<0&,\;\;x<0\end{cases}$$
So the function of which the above is the derivative is monotone ascending if $\,x>0\;$ and monotone descending when $\,x<0\,$
The above is all you need in general, for a differentiable function, in order to know where it is monotone ascending or descending. you don't need to know where the derivative vanishes.
$\endgroup$