I just started doing exercises on the Inverse Function Theorem and I think this is probably a pretty simple application of it, but I just wanted to check my reasoning.
The condition that the derivative of $f$ is surjective tells us that at every $p \in U$, the Jacobian matrix has non zero determinant (since the matrix has full rank because of surjectivity). Then by the inverse function theorem $f$ is a local diffeomorphism. Since $f$ is injective, it's restriction to its image is bijective and hence has an inverse, which is locally smooth near any $p \in U$ again by the inverse function theorem, which then proves that $f^{-1}$ is smooth as well, therefore $f$ is a global diffeomorphism onto its image.
Is all of that correct, can anything be improved? Thanks beforehand.