well-definedness of the floor function I'm reading Apostol's analysis book these days. For a nonnegative real number $x$, he defines a subset(say $S$) of nonnegative integers which are less than $x$. We know $S$ is nonempty since $0$ belongs to $S$ and $S$ is bounded above. So $\sup S$ is uniquely determined which we call the floor function value of
$x$. 
The author says it is easy to see that the supremum belongs to $S$
so $x$ is indeed a nonnegative integer. But why is it that? It is not clear to me.
Any help will be appreciated. 
 A: Suppose the supremum $s$ of $S$ is not the maximum. Then, for any $n\in S$, there exists $m\in S$ such that $n<m<s$; since $n+1\le m$, we conclude $n+1\in S$.
As $0\in S$, we have proved by induction that every nonnegative integer belongs to $S$, contradicting the fact that $S$ is bounded.
Addendum: the set $S$ is bounded by construction; however the set of natural numbers is unbounded because of the Archimedean property. In this case, more easily, $S$ cannot contain all natural numbers because by the Archimedean property there is a natural number $k>s$.
A: The integers are not dense (unlike the real numbers) so the limit of a convergent series will be a element in the series. That explains why the supremum is in S and by the definition of S is a nonnegitive integer. 
I believe your last sentence should either say "so $floor(x)$ is indeed a nonnegative integer" or "so the supremum is indeed a nonnegitive integer", because we picked x to be a arbitrary nonnegative real number so it is not necessarily a integer, but $floor(x)=sup(S)$ is.
A: Suppose $s = \sup S$. As $s$ is real there exist an integer $n$ such that $n - 1 < s \le n$, and there exists a real, t, such that $n - 1 < t < s \le n$.  As $s$ is the least upper bound of S, t is not an upper bound so there exists an element of S, call it $m$ such that:
$n - 1 < t < m \le s \le n$.
As $n - 1, m,$ and $n$ are all integers, the only way $n -1 \le m \le n$ is if $m = n$.  Thus $m \le s \le m$.  The $s = m$ and $s$ is an element of S.
