In all the definitions in this section, $S\subseteq \mathbb R$.
Definition (Upper bound).
A real number $M$ is an upper bound of $S$ if $M\geq x$ for all $x \in S$. Then $S$ is bounded above by $M$. If an upper bound $M$ of $S$ belongs to $S$, then $M$ is the maximum of $S$, denoted by $M=\max S$.
Example.
$S=[0,1]$ is bounded above by the upper bound $1$ and $\max S=1$.
$S=(0,1)$ is bounded above by the upper bound $1$ and $\max S$ does not exist as $1\notin S$.
$S=\{x\in \mathbb Q \;|\; x^2\leq 2 \}$ is bounded above by $\sqrt{2}\notin S$ and $\max S$ does not exist.
Suppose $\max S$ exists and $M=\max S$. Then $M\in \mathbb Q$ and since $\sqrt{2}\notin \mathbb Q$ , $M < \sqrt{2}$. Let $M'=\frac{2+2M}{2+M}$. Since $M\in \mathbb Q$, $M'\in \mathbb Q$. Note that
\[M'^2-2=\frac{2(M^2-2)}{(2+M)^2} < 0\]
which implies $M' < \sqrt{2}$. Thus $M'\in S$. Now $M'-M=\frac{2-M^2}{(2+M)^2} > 0$ which implies $M' > M$. Thus $M'\in S$ and $M' > M=\max S$, a contradiction. For an alternative proof, you can use the density of $\mathbb Q$ in $\mathbb R$.
Definition (Lower bound).
A real number $m$ is a lower bound of $S$ if $m\leq x$ for all $x \in S$. Then $S$ is bounded below by $m$. If a lower bound $m$ of $S$ belongs to $S$, then $m$ is the minimum of $S$, denoted by $m=\min S$.
Example.
$S=[0,1]$ is bounded below by the lower bound $0$ and $\min S=0$.
$S=(0,1)$ is bounded below by the lower bound $0$ and $\min S$ does not exist as $0\notin S$.
$S=\{x\in \mathbb Q \;|\; x^2\leq 2 \}$ is bounded below by $-\sqrt{2}\notin S$ and $\min S$ does not exist.
Definition (Bounded set).
$S$ is bounded if it is bounded above and below. $S$ is unbounded if it is not bounded.
Note that a finite set $S$ is always bounded because it is bounded above and below by $\max S$ and $\min S$ respectively. But an infinite set $S$ may not be bounded and also $\max S$ and $\min S$ may not exist.
Example.
$S=(0,1)$ is an infinite bounded set. Note both $\max S$ and $\min S$ do not exist.
$S=[0,\infty)$ is an unbounded set. Note $\min S=0$ but $\max S$ does not exist.
$S=\{\frac{1}{n} \;|\; n\in \mathbb N \}$ is an infinite bounded set. Note $\max S=1$ but $\min S$ does not exist.
When a set $S\subset \mathbb R$ is bounded above but has no maximum, it is useful to know its smallest upper bound which is called the supremum of $S$.
Definition (Supremum).
If $S$ is a nonempty set bounded above by $M$ and $M\leq M'$ for all upper bounds $M'$ of $S$, then $M$ is the supremum or the least upper bound of $S$, denoted by $M=\sup S$. Equivalently $M=\sup S$ if and only if
(a) $M\geq x$ for all $x\in S$ and
(b) for every $\varepsilon > 0$, there exists $x\in S$ such that $x > M-\varepsilon$.
If $S$ is unbounded above, we define $\sup S=\infty$. Also we define $\sup \varnothing=-\infty$.
Example.
For $S=[0,1]$, $\sup S=\max S=1$.
For $S=(0,1)$, $\max S$ does not exist but $\sup S=1$.
For $S=\{-\frac{1}{n} \;|\; n\in \mathbb N \}$, $\max S$ does not exist but $\sup S=0$.
Since $-\frac{1}{n}<0 \;\forall\; n\in \mathbb N$, $x < 0 \forall\; x\in S$. Let $\varepsilon > 0$. By the Archimedean property, we find a natural number $N$ such that $\frac{1}{N} < \varepsilon$. Then $-\frac{1}{N}>-\varepsilon$. So we found $x=-\frac{1}{N}\in S$ such that $x > 0-\varepsilon$. Thus $\sup S=0$.
For $S=\{x\in \mathbb Q \;|\; x^2\leq 2 \}$, $\max S$ does not exist but $\sup S=\sqrt{2}$.
First note $x\leq \sqrt{2} \;\forall\; x \in S$. Let $\varepsilon > 0$. We find $x\in S$ such that $x>\sqrt{2}-\varepsilon$.
If $\varepsilon\geq 2\sqrt{2}$, then $\sqrt{2}-\varepsilon \leq -\sqrt{2}<0=x$. Otherwise assume $\varepsilon< 2\sqrt{2}$. Since there is a rational number between two real numbers (by the density of $\mathbb Q$ in $\mathbb R$), there exists a rational number $x$ such that $-\sqrt{2} <\sqrt{2}-\varepsilon < x < \sqrt{2}$. So we found $x\in S$ such that $x > \sqrt{2}-\varepsilon$. Thus $\sup S=\sqrt{2}$.
Similar to the concept of supremum of a bounded above set, a bounded below set has the infimum which is its largest lower bound.
Definition (Infimum).
If $S$ is a nonempty set bounded below by $m$ and $m\geq m'$ for all lower bounds $m'$ of $S$, then $m$ is the infimum or the greatest lower bound of $S$, denoted by $m=\inf S$. Equivalently $m=\inf S$ if and only if
(a) $m\leq x$ for all $x\in S$ and
(b) for every $\varepsilon > 0$, there exists $x\in S$ such that $x < m+\varepsilon$.
If $S$ is unbounded below, we define $\inf S=-\infty$. Also we define $\inf \varnothing=\infty$.
Example.
For $S=[0,1]$, $\inf S=\min S=0$.
For $S=(0,1)$, $\min S$ does not exist but $\inf S=0$.
For $S=\{\frac{1}{n} \;|\; n\in \mathbb N \}$, $\min S$ does not exist but $\inf S=0$.
For $S=\{x\in \mathbb Q \;|\; x^2\leq 2 \}$, $\min S$ does not exist but $\inf S=-\sqrt{2}$.
Does every bounded above subset of $\mathbb R$ have a supremum?
Axiom (Completeness property).
Every nonempty bounded above subset of $\mathbb R$ has a supremum (least upper bound) in $\mathbb R$.
The completeness property of $\mathbb R$ is considered as an axiom as it cannot be proved just by the field and order properties of $\mathbb R$. The following is equivalent to the Completeness Axiom:
Theorem.
Every nonempty bounded below subset of $\mathbb R$ has an infimum (greatest lower bound) in $\mathbb R$.
Suppose $S\subseteq \mathbb R$ is nonempty and bounded below. Define $-S=\{-x \;|\; x\in \mathbb R\}$. Since $S$ is bounded below, $-S$ is bounded above. Then by the Completeness Axiom, $\sup(-S)$ exists. The rest follows from the fact that $\inf(S)=-\sup(-S)$ (exercise).
Note that the Archimedean property follows from the completeness property of $\mathbb R$.
Suppose $n\leq \frac{x}{\varepsilon}$ for all $n\in \mathbb N$. Consider the set $S=\{n\in \mathbb N\;|\; n\leq \frac{x}{\varepsilon}\}$. Note that $S=\mathbb N$ and it is bounded above by $\frac{x}{\varepsilon}$. By the completeness property of $\mathbb R$, $\mathbb N$ has a least upper bound, say $M$. Then $M-1$ is not an upper bound of $\mathbb N$ and consequently $M-1 < k$ for some $k\in \mathbb N$. Then $M < k+1$ where $k+1\in \mathbb N$ contradicting that $M$ is an upper bound of $\mathbb N$.
Remark
An ordered field $\mathbb F$ is incomplete if it has a nonempty bounded above subset with no supremum in $\mathbb F$. For example, $\mathbb Q$ is incomplete because $S=\{x\in \mathbb Q \;|\; x^2\leq 2 \}$ does not have a supremum in $\mathbb Q$. It can be shown that $\mathbb R$ is the unique complete ordered field meaning any complete ordered field is isomorphic to $\mathbb R$.