Continuous functions and infinum Let $f:\mathbb R \to \mathbb R$ with $f(-2)=4$ and $f(3)=7$. Let $S:=\{x \in [-2,3]\mid f(x)\geq 5\}$. Then $\alpha:=\inf S$ exists. If $f$ is continuous at $\alpha$, show that:
(a) $-2<\alpha<3$
(b) $f(\alpha)=5$
To solve the question, I guess we should use the IVT which states: Let $f$ be continuous on $[a,b]$. If $k$ is any number between $f(a)$ and $f(b)$, then there exists $t \in (a,b)$ such that $f(t)=k$.
Or should we use the max/min theorem?
I'm not exactly sure which one to use and how to apply it here. Could anyone help me out please? Thanks.
 A: Hint: use the greatest-lower-bound property for $S$, say:
If  $E\subset X$, $E$ is not empty, and  $E$ is bounded below, then $\inf{E}\in X$
Take $E=S$, $X=[2,3]$, how $3\in S\implies S\neq \emptyset$, and $2$ is a lower bound of $S$, then $\inf{S}=\alpha\in[2,3]$.
Now for (a) 
(i) If $\alpha=2$, For all $B_\delta(2)$,  there is $x_0\in S$ and $x_0\in B_\delta(2)$ because $2=\inf{S} $, Take  $\epsilon<1$, then by continuity $$|x_0-2|<\delta\implies|f(x_0)-f(2)|=|f(x_0)-4|<1$$
but how $f(x_0)\geq5\implies|f(x_0)-4|\geq 1$ this is a contradiction.
(ii) If $\alpha=3$, how $3=\inf{S} $, by definition of $S$, if $x_0\in[2,3)\implies f(x_0)<5$, take $\epsilon<2$, then by continuity
$$|x_0-3|<\delta\implies|f(x_0)-f(3)|=|f(x_0)-7|<2$$
but how $f(x_0)<5\implies|f(x_0)-7|> 2$ this is a contradiction.
Therefor $2<\alpha<3$
For (b) Use (a), suposse that $f(\alpha)=t\neq5$, then if $t<5$ use (i), if $t>5$ use (ii).
A: The infimum (plural infima) of a subset S of a partially ordered set T is the greatest element of T that is less than or equal to all elements of S.
Thus, the infimum of your subset $S$ of the poset $\mathbb{R}$ (more specifically a chain) is the greatest element $x \in \mathbb{R} : f(x) \geq 5$ that is less than or equal to all elements of $S$. 
Now consider the fact that $\alpha = inf \space S$ may not actually lie in $S$. So then it lies outside, say $x \leq -2$ or $3 \leq x$. This implies that all of the $f(x) : -2 < x < 3$ are less than $5$. But that's impossible by applying the IVT to $f(3)$ and any point to the left of $3$. 
$b)$ follows from $a)$.
A: a) Assume that $\alpha=-2$. Then $f(x)\geq5$ for each $x>-2$. But then $f$ cannot be continuous at $\alpha$, since $f(\alpha)=f(-2)=4$.
Assume that $\alpha=3$. Then $f(x)<5$ for each $x<3$. But then $f$ cannot be continuous at $\alpha$, since $f(\alpha)=f(3)=7$.
b) Since $\alpha$ is the infimum of $S$ we find sequences $(x_n)\subset S$, $(y_n)\subset[-2,3]\backslash S$ converging to $\alpha$. Note that $(a)$ implies that $[-2,3]\backslash S$ is not empty. Since $f$ is continuous at $\alpha$ we have $f(\alpha)=f(\lim_{n\to\infty}x_n)=\lim_{n\to\infty}f(x_n)\geq5\geq\lim_{n\to\infty}f(y_n)=f(\lim_{n\to\infty}y_n)=f(\alpha)$, so $f(\alpha)=5$.
