What is the difference between $f: \mathbb{S}^{1} \mapsto \mathbb{S}^{1}$ and $f: \mathbb{S}^{1} \mapsto \mathbb{R}$? Does defining in what space the domain of a function lies in apriori determine in what space the range of that function will be?
Let's have an example. Suppose I take $f(x) = x$. I assume that $x \in \mathbb{S}^{1}$. Does this mean automatically that $f(x) \in \mathbb{S}^{1}$, i.e. $f: \mathbb{S}^{1} \mapsto  \mathbb{S}^{1}$ and so $f(x)$ is well-defined?
Or we have no way of determining the domain of $f$ yet and thus we still may assign  $f(x) \in \mathbb{R}$, hence putting $f: \mathbb{S}^{1} \mapsto \mathbb{R}$?  In which case the function is not well-defined (in fact, it will be discontinuous)...
Thanks!
 A: Implicit in the definition of a function is a domain and codomain. That is, two functions $f:A\to B$ and $g:C\to D$ are equal if and only if $A=C$, $B=D$, and $f(x)=g(x)$ for all $x\in A$.
So in the case you're considering, we have a function $f:\Bbb{S}^1\to B$ for some set $B$, and $f(x)=x$ for all $x\in\Bbb{S}^1$. Since by definition of a function we must have $x=f(x)\in B$ for all $B$, you can at least say that $\Bbb{S}^1\subseteq B$, but that's about it. For instance, $B$ could be $\Bbb{S}^1$ itself, or $B$ could be $\Bbb{R}^2$.
I'm not quite sure what you mean by assigning a value $f(x)=x\in\Bbb{R}$. There is certainly no canonical way to assign to each $x$ a value in $\Bbb{R}$. Maybe if you can explain that better I can update my answer to address it.
A: Formally,  a function $f : A\rightarrow B$, is a subset of the cartesian product $A\times B$ (with certain constraints). In that sense, the symbol "$f$" already encodes in it both of the sets $A$ and $B$. I would also note that the codomain $B$ alone can have an have actual implications on question regrding the function; for example, a function $f : A\rightarrow B_1$ can be open, while another function $g : A\rightarrow B_2$ is not open, even if $f(x)=g(x)$ for all $x\in A$.
