[Math] rigorous notation for functions

functionsnotation

I have seen many ways to denote a function: $f(x)=x^2, y=x^2, f: x\mapsto x^2$ and so on. What is exact notation for functions? Please include lethal doses of rigor, set theory, and of course notational exactness.

Note: I am very familiar with functions in general. I just know that a lot of mathematical literature abuses notation when it comes to functions.

Best Answer

$$f:E\to F,\quad x\mapsto f(x)$$

For example, the function $f:\mathbb R\to\mathbb R$, $x\mapsto x^2$, is not the function $g:\mathbb R_+\to\mathbb R$, $x\mapsto x^2$, but the functions $h:\{-1,0,1\}\to\mathbb R$, $x\mapsto x^2$ and $k:\{-1,0,1\}\to\mathbb R$, $x\mapsto |x|$ are equal.