Assume $ \mathbb{R}^{n}\supseteq\mathcal{U}\overset{f}{\longrightarrow}\mathbb{R}^{m} $ is a $C^r$ function where $m\leq n$. Assume that $ \text{rank}\left[f'|_{p}\right]=m $ for some $p\in \mathcal{U}$. Porve that there exists a diffeomorphism $\psi$ such that $ f\circ\psi\left(x_{1},...,x_{n}\right)=f\left(p\right)+\left(x_{1},...,x_{m}\right) $.
My thoughts:
I want to define the following map:
$ \psi\left(x_{1},...,x_{n}\right)=\left(f_{1}\left(\underline{x}\right)-f_{1}\left(p\right),...,f_{m}\left(\underline{x}\right)-f_{m}\left(p\right),x_{m+1},...,x_{n}\right) $
Jacobian matrix is given by:
$$ \psi'=\begin{pmatrix}\frac{\partial f_{1}}{\partial x_{1}} & \cdots & & \frac{\partial f_{1}}{\partial x_{m}} & \cdots & & \frac{\partial f_{1}}{\partial x_{n}}\\ \vdots & \ddots & & \vdots & \vdots & & \vdots\\ \frac{\partial f_{m}}{\partial x_{1}} & \cdots & & \frac{\partial f_{m}}{\partial x_{m}} & \cdots & & \frac{\partial f_{m}}{\partial x_{n}}\\ 0 & \cdots & & 0 & 1 & \cdots & 0\\ & & & & & \ddots\\ & & & & & & 1 \end{pmatrix} $$
(We know that the rank of $f'$ is $m$ in $p$ and therefor we know that the rank is $m$ in an open set around $p$, we can assume without loss of generality that this open set is $\mathcal{U} $ and otherwise we'll just look at a smaller set contained in $\mathcal{U} $).
Now, if I could prove that $\psi $ is a diffeomorphism then I'd get the existance of an inverse of $\psi$, and since
$ \pi\circ\psi\left(x\right)=f\left(x\right)-f\left(p\right) $
Composing over $\psi^{-1}$ in both sides yields:
$$ \pi\circ\psi\circ\psi^{-1}=\left(f-f\left(p\right)\right)\circ\left(\psi^{-1}\right) $$
$$ \pi=f\circ\psi^{-1}\left(x\right)-f\left(p\right) $$
$$ \pi+f\left(p\right)=f\circ\psi^{-1} $$
Which is what I want.
I'd really appreciate some help about how to formalize this idea. How do I prove that this $\psi $ really is a diffeomorphism? (Basically I just need to show that this matrix is non-singular and than I can use the inverse function theorem).
Also, if there are more important details that I need to mention, I'd be happy to hear. Thanks in advance.