# Smooth function onto a regular submanifold

Let $M^m, N^n$ be smooth manifolds and $f:M\to N$ a continuous map such that $f(M)\subset S$, where $S$ is a regular submanifold of $N$ with codimension $k$. Prove that $f$ is smooth with respect to the submanifold atlas of $S \Leftrightarrow f$ is smooth with respect to the atlas of $N$.

Here is what I've thought so far:

Take $p\in M$ and a chart $(U, \phi)$ at $p$. Since $S\subset M$ is a regular submanifold, there is an adapted chart $(V, \psi)$ at $f(p)\in N$ such that $\psi(V\cap S)=\psi(V)\cap (\mathbb{R}^k\times\{0\}^{n-k})$. In particular, we have a chart $(V\cap S, \tilde{\psi})$ at $f(p)\in S$ , where $\tilde{\psi}(q):=(\psi^1(q),...,\psi^k(q))$.

Now, in some neighbourhood of $\phi(p)\in \mathbb{R}^n$ we have:

\begin{cases} \psi\circ f\circ\phi^{-1}(x_1, ..., x_n)=(y_1, ..., y_k, 0, ...,0) \\ \tilde{\psi}\circ f\circ\phi^{-1}(x_1, ..., x_n)=(y_1, ..., y_k) \end{cases}

Of course, $\psi\circ f\circ\phi^{-1}$ is smooth $\Leftrightarrow \tilde{\psi}\circ f\circ\phi^{-1}$ is smooth.

But that is still not enough, since $\psi$ is only an adapted chart, and I'm supposed to prove this for an arbitrary $\psi$. Besides, I can't see how the continuity of $f$ plays a role here. I'm stuck. Any sugestions? Thanks!

The adapted charts give an atlas for $S$ which is compatible with the usual one, so it's enough to check if for adapted charts as you've done. Continuity came into the picture when you said "in some neighbourhood of $\phi(p)$" -- this neighborhood would have to be $f^{-1}(V) \cap U$, and to know this is open you are using the continuity of $f$. But this doesn't need to be assumed, as either of the hypotheses (smooth as a map into $S$ or into $N$) imply the continuity (note that, since $S$ is embedded, it has the subspace topology, and hence continuous as a map into $S$ or $N$ are the same thing).