I'm trying to prove the next:
A map $\phi:M\rightarrow N$ is smooth if and only if $g\in\mathfrak{F}(N)\implies g\circ\phi\in\mathfrak{F}(M).$
Here, $\mathfrak{F}(M)$ is the set of all functions $f:M\rightarrow\mathbb{R}$ such that $f$ is smooth. $M,N$ are smooth manifolds.
The first implication follows because the composition of smooth maps is smooth.
My problem is on the other; I'm trying to express $\phi$ as composition of compatible charts such that the composition of one o them with $\phi$ be in $\mathfrak{F}(N)$, but I don't get any useful.
Any kind of help is thanked in advanced.
Suppose $\phi$ is such that, for each $g$ smooth function on $N$, the following composition is smooth: $$ g \circ \phi $$
Let $g$ be a coordinate chart about $\phi(p)\in N$. Mark the projection on the $i$-th coordinate $g_i$. This is a smooth function, so the composition $g_i \circ \phi$ is smooth, for each $i\leq n$.
By definition, there exist a coordinate chart $f$ about $p\in M$ such that the composition $ g_i \circ \phi \circ f^{-1}$ is smooth in $p$, for each $i\leq n$.
The map $ g \circ \phi \circ f^{-1}$ is a map between euclidean spaces, smooth in each component - hence smooth itself, by definition of smooth euclidean maps.
We have established that $g\circ \phi \circ f^{-1}$ is smooth, for coordinate charts $g,f$. Thus $\phi$ is smooth by definition.