Show that $\sup\{x\in\mathbb{Q}: x>0,x^2<2\}=\sqrt{2}$. It is problem 1.1 in Kaczor's "Problems in mathematical analysis 1".
I had big problems with this problem. And I even posted a question about the solution to this problem. But did not get answer. So here I write down my solution.
This set is nonempty and bounded from above. Although it is not stated precisly the supremum must be found in real numbers. So this set has the supremum.
Let $s=\sup\{x\in\mathbb{Q}: x>0,x^2<2\}$.
If so then for ANY $\epsilon>0$ we must have $$(s-\epsilon)^2<2$$ and $$(s+\epsilon)^2>2.$$
For the first inequality $$s^2-2s\epsilon<s^2-2s\epsilon +\epsilon^2<2$$ and we get $$s^2\leq 2$$ because if $s^2>2$ then we can take $\epsilon=\frac{1}{2s}$ (contradiction).
For the second inequality $$s^2+2s\epsilon +\epsilon^2>2$$ and we get $$s^2\geq 2$$ because in other case we can take $\epsilon=s$ (contradiction).
Is it correct? If not then where is a problem? I worry about two things. First, are my strict inequalities in step 3 correct? Second, if this set consists of rational numbers can I take ANY $\epsilon$ or I must consider only rational numbers (in step 3)?
EDIT: I did not write down it but my assumption for $\epsilon$ is $s\geq \epsilon >0.$
In general, if $A \subseteq \Bbb{R}$ and $s \in \Bbb{R}$, the basic approach to proving $s = \sup A$ (the least upper bound of $A$), is to prove the following:
If $A$ is a downwards closed subset of $\Bbb{Q}_{>0}$, (i.e., if $A \subseteq \Bbb{Q_{>0}}$, and $\forall a \in A, x \in \Bbb{Q_{>0}}(x \le a \implies x \in A)$), then conditions 2 and 3 are equivalent to saying that, for any positive $\varepsilon$, $s - \varepsilon \le a$ for some $a \in A$ and $s + \varepsilon \not\in A$. This is the fact that you are using in your approach. I think you would do better to follow the basic approach I suggested above, because otherwise you have some extra justification to do.
In your example, steps 1 and 2 are straightforward using the fact that $a < b$ iff $a^2 < b^2$ for $a, b > 0$. 3 isn't difficult, but how to go about it depends on what you are expected to know already (but amounts to showing that if $x^2 < 2$, then there is $a \in \Bbb{Q}$ such that $x^2 < a^2 < 2$).