Understanding relation between Quotient Space and $S^1$
The quotient space $Y = X / \sim$ as a set is just the set of equivalence classes of $X$ under $\sim$, so the set $\{ [x]: x \in \mathbb{R} \} $ in your case.
The equivalence class of a number $x$ is just (in your case) the set $\{ x+n : n \in \mathbb{Z} \}$. Now we need a topology. The standard topology that we take on $Y$ is all subsets $O$ of $Y$ (where points in $Y$ are "really" subsets of $X$, the equivalence classes) such that $q^{-1}[O]$ is open in the topology of $X = \mathbb{R}$. Here $q$ is the map that sends $x$ to its class $[x]$ in $Y$, the so-called quotient map. This is called the quotient topology on $Y$, and as you see it assumes you have a topology on $X$ already, and we give $Y$ the largest topology possible to still have $q$ continuous. (The smallest one would always be the indiscrete topology, which is not very interesting, hence the other "natural" choice.)
Now, if we have a function $f$ from $Y$, the quotient space in the quotient topology, to any space $Z$, then $f$ is continuous iff $f \circ q$ is continuous as a function from $X$ to $Z$: one way is clear, as the composition of continuous maps is continuous, and for the other side, if $O$ is open in $Z$, by definition $f^{-1}[O]$ is open in $Y$ iff $q^{-1}[f^{-1}[O]]$ is open in $X$, and this set equals $(f \circ q)^{-1}[O]$ which is open, as by assumption $f \circ q$ is continuous.
Now, consider the map $f$ that sends the class $[x]$ to the point $e^{2\pi ix}$ in $\mathbb{S}^1$, the unit circle. This is well-defined: if $x'$ were another representative of $[x]$, then $x \sim x'$ and thus $x - x'$ is an integer and so $f(x') = f(x)$. It is continuous, as $f \circ q$ is just the regular map sending $x$ to $e^{2\pi ix}$, and this is even differentiable etc. It is clearly surjective and injective because the only way $[x]$ and $[y]$ will have the same value is when $2 \pi ix - 2 \pi i y$ is an integer multiple of $2 \pi i$, which happens iff $x - y$ is an integer. One can also check that $q[X] = q[[0,1]]$ and by continuity of $q$ we have that $Y$ is compact. This makes (with $\mathbb{S}^1$ Hausdorff) the map $f$ a homeomorphism, by standard theorems.
We could also have achieved this as the quotient of $[0,1]$ under the equivalence relation that has exactly one non-trivial class, namely $\{0,1\}$. This is more intuitive, as we then glue together (consider as one point) just the points $0$ and $1$, and this geometrically gives a circle. In your example (which is a nice so-called covering map, and a group homomorphism as well) we glue a lot more points together, but all classes are now similar: just shifted versions of a point by an integer. We sort of wrap the interval $[0,1)$ infinitely many times over itself.
The quotient topology is tricky! ...
There's a number of aspects to consider; all of them basically boil down to:
- Equip the quotient topology: $\pi:(X,\mathcal{S})\to Y$
- Check for quotient map: $\pi:(X,\mathcal{S})\to (Y,\mathcal{T})$
1.) Why do we take the quotient topology?
Given a plain space one wants to give it a topology that is good enough in the sense:
$g\text{ continuous}\iff g\circ\pi\text{ continuous}$
In other words, we don't want to artificially create new continuous maps plus we don't want to accidentally loose continuous maps.
Luckily, this can be guaranteed by imposing the quotient topology!
Given a plain space one wants to give it a topology that is good enough in the sense:
$f\text{ continuous}\iff\pi\circ f\text{ continuous}$
So one would like to maintain continuous maps with our plain space as codomain rather than as domain.
Unfortunately, this cannot be guaranteed in general by specific choice of some topology!
So that is all we can get!
(By the way, this is the same reason for the subspace topology as well as the product topology)
2.) How can we check and compare spaces for quotient topology?
a) Checking for quotient map:
Now, we are given already some topology. Is it the quotient topology?
Obviously, the projection must be necessarily continuous and surjective in order to be a quotient map, that is the given topology is the quotient topology.
However, this is not enough!!! (i.e. $\pi:[0,1)\to\mathbb{S}^1: s\mapsto \mathrm{e}^{2\pi\mathrm{i}s}$)
There's actually a number of lemmata providing sufficient conditions for it to be a quotient map, among them the one on saturated sets or the one on closed sets.
b) Comparing quotient maps:
Assume you are given now two topological spaces together with their own quotient maps and they seem to describe basically the same object, that is they seem to be isomorphic:
$\pi_1:(X,\mathcal{S})\to(Y_1,\mathcal{T}_1)$ and $\pi_2:(X,\mathcal{S})\to(Y_2,\mathcal{T}_2)$
Then, in order to prove that they are basically the same it suffices to check wether they make the same identifications:
$\pi_1(x)=\pi_1(\tilde{x})\iff\pi_2(x)=\pi_2(\tilde{x})$
(That is quite neat since one does not have to check topological properties)
2.)* How can we practically work with these?
There's a central result called the 'closed map lemma' that offers an astonishingly simple way to prove strong statements:
- Quotient map?
- Topological embedding?
- Homeomorphism?
All one has to check is continuity!!! (plus some little things)
In particular, this is quite useful in your case to prove the realization of the unit sphere as a quotient space. (Both of the preceding answers by Henno and by Aaron made use of this!)
Here's a draft how this goes:
$\pi:[0,1]\to[0,1]/\sim:s\mapsto [s]$ and $\epsilon:[0,1]\to\mathbb{S}^1:s\mapsto\mathrm{e}^{2\pi\mathrm{i}s}$
$\epsilon\text{ continuous and surjective}\Rightarrow\epsilon\text{ quotient map}$ ...with $[0,1]\text{ compact}$ and $\mathbb{S}^1\text{ Hausdorff}$
$\pi(s)=\pi(\tilde{s})\text{ iff }\epsilon(s)=\epsilon(\tilde{s})\Rightarrow[0,1]/\sim\cong\mathbb{S}^1$
... There's a lot more to discuss on quotient spaces but that should give you some first insights.
Given a set $S$ and an equivalence relation $\sim$ on $S$, then we can quotient out the set by the equivalence relation to obtain the quotient $S/\sim$, which is the set of all equivalence classes of $S$ under $\sim$.
If $S$ isn't just a set but is actually a topological space, we wish to give a topology to $S/\sim$. There are many ways to do this, but we want one that has as much to do with the topology of $S$ as possible.
The main condition that we want is that the natural quotient map $q:S\to S/\sim$ should be continuous. Any topology on $S/\sim$ that didn't satisfy this property would be too far from $S$. However, even with this condition, there are still lots of choices for the topology. For example, if we gave $S/\sim$ the trivial topology (only the empty set and entire set are open), the map would be continuous, but the topology would be very far from being what we want.
Instead, we take the other extreme approach. If $U\subset S/\sim$, then $U$ is open if and only if $q^{-1}(U)$ is open. Alternatively, the open sets of $S/\sim$ are exactly those of the form $q(V)$ for $V\subset S$ open such that $V$ is the union of equivalence classes.
This gives us the following universal property: If $f:S\to X$ is a continuous map such that $f(x)=f(y)$ whenever if $x\sim y$, then we can uniquely factor the map through $S/\sim$, that is, we can find a unique continuous map $\widetilde{f}:S/\sim \to X$ such that $f=\widetilde{f}\circ q$.
For the example you are looking at, the equivalence relation defines a quotient map to the circle by the map $x\to e^{2\pi i x}$, where we are viewing $S^1$ as the unit circle in the complex plane. What we need to check is that the quotient topology is the normal topology.
The wrapping map is continuous. We just need to make sure that every open set in the quotient topology is open in the usual (subspace) topology. However, we have some extra structure in our situation which makes this easier to check. Namely, $\mathbb{R}$ is a group, and our quotient is the (group theoretic) quotient by the subgroup $\mathbb{Z}$. Given an open set $U\subset \mathbb{R}$, the set $\widetilde{U}=\bigcup_{i\in \mathbb Z} U+i$ is the smallest set that contains $U$ and is the union of equivalence classes. Moreover, because it is the union of open sets, it is open. The image of such sets will be the open sets in the quotient topology.
Because the topology of $\mathbb{R}$ has a basis of intervals, and because passing from an interval $U=(a,b)$ to $\widetilde{U}$ to $q\widetilde{U}$ is the same as wrapping the interval around the circle, and because subsets of this form give a basis for the topology of the circle, we must have that the usual topology is the same as the quotient topology.
Note that this implies that if you quotient a topological group by a subgroup, giving the quotient the quotient topology, the quotient map will actually be an open map (the image of an open set is open). This is not true for general quotient maps.