How to prove the existence of maximum and minimum of this set?

61 Views Asked by At

In Analysis I by Herbert Amann, Chap IV, Sec 2, Remarks 2.2 (b), there is a proposition as follows:

Let $f$ be continuous on $[a,b](\subseteq\mathbb{R})$ and differentiable on $(a,b)$. Then $$\max_{x\in[a,b]}f(x)=f(a)\vee f(b)\vee \max\{f(x);x\in(a,b),f'(x)=0\}$$ that is, $f$ attains its maximum either at an end point of $[a,b]$ or at a critical point in $(a,b)$. Similarly $$\min_{x\in[a,b]}f(x)=f(a)\wedge f(b)\wedge \min\{f(x);x\in(a,b),f'(x)=0\}$$

Now for simplicity, let $E:=\{f(x);x\in(a,b),f'(x)=0\}$. Of course, because of the compactness of $[a,b]$ and the completeness of $\mathbb{R}$, $\sup E$ and $\inf E$ are well defined, but how could I know the set $E$ has well defined maximum and minimum? What if the set $E$ has actually infinite number of elements?

For example, let $f:[0,1]\rightarrow \mathbb{R}, x\mapsto x^2\sin\frac{1}{x}(for\ x\neq 0, f(0)=0)$. Clearly $f$ is continuous on $[0,1]$ and differentiable on $(0,1)$, but has infinite critical points. (This is just a specific example to explain why I consider this problem, I'm trying to figure out whether the existence of maximum and minimum is true for a general function that satisfies the condition of continuity and differentiability.)