[Math] continuous function and max/min values

calculus

I would be happy if someone could give me a hand with this practice problem.

Given $f$ is continuous in the interval $[0, \infty)$, and $f(0) = \lim_{x\to\infty}f(x) = 0$, prove or disprove: $f$ attains a maximum and a minimum in the interval $[0, \infty)$.

Now, I approached this by creating a closed interval $[0,n]$, inside which $f$ is continuous. So by Weierstrass's second theorem I know that $f$ gets max/min values inside it. Now, if I'm given that the limit is zero when $x$ goes to $\infty$, I know that for any $\epsilon > 0$ , there exists $n>0$ such that, for any $x>n$, $|f(x)-0| < \epsilon \implies |f(x)| < \epsilon$.

I'm having trouble showing exactly how $f$ gets minimal or maximal values in the interval $[n, \infty)$. Also, I'm having trouble explaining how $f(0) = 0$ helps me define a minimal/maximal value when $x$ goes to $\infty$.

Thanks for any help.

Best Answer

For a maximum: If $f(x)\le0$ for all $x$, there's nothing to show (the maximum value is $f(0)=0$). Otherwise, $f(c)=\alpha>0$ for some $c>0$. Choose $N>c$ so that $f(x)<\alpha/2$ for all $x\ge N$. This can be done since $\lim\limits_{x\rightarrow\infty} f(x)=0$.

Now, $f$ attains a maximum value on $[0,N]$. Show that this in fact is the global maximum value of $f$ (note the maximum value on $[0,N]$ is at least $\alpha$).

Argue in a similar manner to show $f$ attains a minimum value.

Related Question