supremum and infimum example can anyone give me a good example of how to find supremum and infimum not lim sup and lim inf. I try to find some good example online but it keep given me lim sup and lim inf. I just need one good example of how to find sup and inf with step by step. like ex: how to find sup and inf of $1- \frac 1n \lt x \lt 2- \frac 1n$ or any thing like it.
thank you
 A: Consider the following example:
$$G=\left\{\dfrac{1}{n}\mid n\in\mathbb{N}\right\}$$
$\inf G=0$ and $\sup G=1$
This is because for $n=1$, we attain the highest value in the set. ( In this case $\sup G=\max G)$. As for calculating the infimum of $G$, there's so specific $n$ this time, but we note that as $n$ gets larger and larger $\frac{1}{n}$ gets smaller and smaller, approaching zero. (In this case $\inf G\neq \min G$)
A: For a given interval I, a supremum is the least upper bound on I. (Infimum is the greatest lower bound). So, if you have a function f over I, you would find the max of f over I to get a supremum, or find the min of f to get an infimum.
Here's a worked out example: $f(x) = \sqrt{x}$ over the interval $(3,5)$ is shown in gray. Since f is increasing, we know that the max is $\sqrt{5}$ (red), so then our supremum is also $\sqrt{5}$. Similarly we know that the min is $\sqrt{3}$ (blue), so then our infimum is also $\sqrt{3}$.

A: Example: 
Given a sequence of real numbers $(x_n)_{n\geq 1}$ that is bounded from above and increasing, then $$y:=\sup \{x_n \mid n\geq 1 \} $$ 
exists (as real number) and is the limit towards which the sequence will converge. (So, in this example, one would find the $\sup$ of the set the same way one would look for the limit of the sequence.) Indeed, as $Y:=\{x_n \mid n\geq 1 \}$ is bounded from above, then $y$ exists (as real number) based on Cantor-Dedekind axiom of upper bound. Let now $\epsilon>0$ arbitrary, but fixed. Then $y-\epsilon$ is not an upper bound for $Y$ as $y$ is the least upper bound of it. So, there must be an $N\geq 1$ such that 
$$ x_N>y-\epsilon.$$
As the sequence is increasing, we get:
$$ y-\epsilon<x_N\leq x_n \leq y<y+\epsilon$$
for all $n\geq N$, from where:
$$|x_n-y|<\epsilon $$
for all $n\geq N$, that is, $(x_n)_{n\geq 1}$ converges to $y$.
Exercise: $$\sup \left\{ \frac{3n-1}{n} \mid n\geq 1\right\} = 3.$$ 
A related fact is that for any set of real numbers bounded from above, $B$,  with $b:=\sup B$ (which must exist due to boundness from above), there must be a sequence $(a_n)_{n\geq 1}\subset B$ that is convergent to $b$. Indeed, for every $n\geq 1$ there is an element $a_n$ in $B$ such that
$$ b-\frac{1}{n} < a_n \leq b,$$
due to the fact that $b$ is the least upper bound of $B$. So:
$$ \left| a_n - b\right| < \frac{1}{n}$$
for all $n\geq 1$, which means $(a_n)_{n\geq 1}$ converges to $b$.
Exercise: $$ \sup(0,1) =1.$$
Note that it is easy to see that $1$ is an upper bound of $(0,1)$, so:
$$ \sup (0,1) \leq 1.$$
We also see that $\left(1-1/n\right)_{n\geq 2}$ is in $(0,1)$ and converges to $1$. As
$$ \{1-1/n \mid n\geq 2 \} \subset  (0,1),$$
then $\sup (0,1)$ is an upper bound of $\{1-1/n \mid n\geq 2 \}$, so:
$$ 1=\sup\{1-1/n \mid n\geq 2 \} \leq  \sup (0,1),$$
where our initial fact guarantees the first equality.
