TITLE: Nonlinear functions from $\mathbb{R}^n$ to $\mathbb{R}^n$ that preserve or grow the angle between any two vectors?
QUESTION [5 upvotes]: Do there exist differentiable almost-everywhere functions on $\mathbb{R}^n \rightarrow \mathbb{R}^n$ such that $\frac{|\langle x, y \rangle|}{|x||y|} \geq \frac{|\langle f(x), f(y) \rangle|}{|f(x)||f(y)|}$? How does one go about constructing one?

REPLY [5 votes]: I claim that those maps are precisely those that preserves lines through the origin, followed by an orthogonal movement.
For $n=1$, the condition is void (except that we demand $0\mapsto 0$ perhaps?) and hence the claim holds.
Your inequality demands that image vectors are "at least as orthogonal" as the input vectors. In particular, such a map preserves orthogonality. 
Thus for any $v\ne0$ with $f(v)\ne 0$, it induces a map with the same properties from $v^\perp$ to $f(v)^\perp$, i.e., $\Bbb R^{n-1}\to\Bbb R$.
If $e_1,\ldots, e_n$ is the standard basis of $\Bbb R^n$, then $f(e_1),\ldots, f(e_n)$ is an orthogonal base of $\Bbb R^n$ and by performing an orthogonal movement, we may assume $f(e_i)=c_ie_i$ with $c_i>0$.
We may assume that $f|_{e_n^\perp}$ is of the claimed form. 
For $v\in\Bbb R^n$ write $c=ae_n+w$ with $w\in e_n^\perp$. Assume $c\ne0$. Then $v^\perp$ intersects $e_n^\perp$ in an $\Bbb R^{n-2}$ left invariant under$f$, hence $f(v)$ is confined to the perpendicular space of that, which is a $2$-plane. Thus it remains to show the claim for $n=2$.
Indeed, $v=ae_1+be_2$ with non-zero $a,b$ can map at most to $a'e_1+b'e_2$ with $a':b'=\pm a:b$. IN case of negative sign, add a reflection at one of the axes. Then for all other vectors $w$ in the plane, the angle condition relative to $e_1$, $e_2$, $v$ determine that  $f(w)$ is on the same line as $w$.