How to calculate extrema for a given function $f(x)$

70 Views Asked by At

Assume that $f(x)$ is a function which is infinite many times differentiable and also continuous for every derivative. The function graph is in general not known.

How is it possible to detect extremas?

Till now i thought $f'(x)=0$ and $f''(x)\neq 0$ just works, but then i saw the following function:

\begin{cases} 0 & x= 0 \\ \exp\left(-\frac{1}{x^2}\right)&x\neq 0 \end{cases}

For this function it seems to be more tricky to calculate the extrema at $x=0$. Probably there are more functions which are even more "complex".

This brings me to my question: What is a general way calculate the extrema of a given function $f(x)$ for which it is only known that it is infinite many times differentiable and that it is continuous?

Thank you

1

There are 1 best solutions below

4
On BEST ANSWER

Fermat's test still works for extrema of your function, you just have to calculate the derivative properly. You have probably noticed that for $x\ne 0$ the derivative is always nonzero. However, computing the derivative at 0 using the difference quotient we find $$ f'(0)=\lim_{x\rightarrow 0}\frac{e^{-1/x^2}}{x}=0 $$ Which tells you that this is the only extremum candidate for the smooth function. The first derivative test is what I would then use to conclude that it is a minimum.

Edit: To avoid any potential ambiguity, for a critical point $x_0$, the first derivative test requires examining the sign $f'(x_0-\epsilon)$ and $f'(x_0+\epsilon)$. $f'(x_0-\epsilon)< 0$ and $f'(x_0+\epsilon)> 0$ yields that $x_0$ is a minimum. Vice versa for a local maximum.

In this case, $$ f'(x)=\frac{2}{x^3}e^{-1/x^2} $$ Which is less than 0 for $x<0$ and greater than 0 for $x>0$, allowing our conclusion.