How to show that $1$ is the $\sup$ of this set? Consider $A=\left\{\left|\dfrac{x^2-2}{x^2+2}\right|:\:x\in \mathbb{Q}\right\}$
Show that $$\sup(A) = 1,\qquad  \inf(A)=0$$  
So far I just succeeded to show that $A$ is bounded between $0$ and $1$ but I find it very difficult to deal with showing that they are infimum and supremum respectively.   
I go to the definition of these two and do like this:
Let $\epsilon >0$. I know, for showing that $1$ is supremum for example, that there is some $a\in A$ that $$1-\epsilon <a$$
So I know that I must find a $a$ that depends on $\epsilon$. How to get rid of the absolute value?  
 A: You just need to find some $x$ such that 
$$
1 - \left|\dfrac{x^2 - 2}{x^2 + 2}\right| < \epsilon,
$$
and so it is perfectly reasonable to only consider $x$ such that $x^2 > 2$ (intuitively, you should already see that we want to choose large $x$ in order to satisfy the inequality), i.e. $x$ such that you can drop the absolute values. Then you just need $x$ so that
$$
\dfrac{x^2 + 2 - (x^2 - 2)}{x^2 + 2} = \dfrac{4}{x^2 + 2} < \epsilon.
$$
A: Another approach avoiding $\varepsilon$'s but using some "advanced" techniques:
Note that $x=0$ gives you $\left|\frac{x^2-2}{x^2+2}\right|=1$, so $1\in A$ and hence $\sup(A)=\max(A)=1$. Since $\mathbb Q$ is dense in $\mathbb R$, there is a sequence $(x_n)\subset\mathbb Q$ converging to $\sqrt{2}$. We then have
\begin{align*}
\lim_{n\to\infty}\left|\frac{x_n^2-2}{x_n^2+2}\right|=0,
\end{align*}
which shows that $\inf(A)=0$.
A: Write ${x^2-2\over x^2+2} = 1-{4 \over x^2+2}$.
It is clear that $\lim_{n \to \infty} (1-{4 \over n^2+2}) = 1$.
Let $q_1 = 1, q_{n+1} = {q_n^2+2 \over 2 q_n}$. Then $q_n \in \mathbb{Q}$ and
$q_n \to \sqrt{2}$.
Then we have $\lim_{n \to \infty} (1-{4 \over q_n^2+2}) = 0$.
