Is $C^{\infty}(\mathbb{R}^{m+n})$ a flat module over $C^{\infty}(\mathbb{R}^{m})$? For $m>0$ we consider the ring $C^{\infty}(\mathbb{R}^{m})$ of smooth functions on $\mathbb{R}^{m}$. For $n>0$ we consider the projection $\mathbb{R}^{m+n}\to \mathbb{R}^{m}$ hence $C^{\infty}(\mathbb{R}^{m+n})$ is naturally a $C^{\infty}(\mathbb{R}^{m})$ module.


My question is: is it true that $C^{\infty}(\mathbb{R}^{m+n})$ is a flat module over $C^{\infty}(\mathbb{R}^{m})$? I'm not sure if we should take the topology on algebra into consideration.


 A: This is just a long comment. Let $X,Y$ be smooth manifolds (here in particular, resp. $\mathbb{R}^n$ and $\mathbb{R}^m$), and let $M$ be a $C^\infty(X)$-module. Then any pair $(m,\phi)\in M\times C^\infty(X\times Y)$ defines  a function $Y\to M$, namely $Y\ni c\mapsto \phi(x,c)m\in M$ (which is well defined as  for all $c\in Y$, $\phi(x,c)\in  C^\infty(X)$). Since this is correspondence is bilinear $M\times C^\infty(X,Y) \to M^Y$, it produces a  morphism of $C^\infty(X)$-modules $$M\otimes C^\infty(X,Y)   \to M^Y.$$  Is this morphism injective? That is, can one see $M\otimes C^\infty(X,Y) $ as a space of $M$-valued functions on $Y$? If the answer is yes, then any  morphism $f:M\to M'$ produces a $f\otimes 1:M\otimes C^\infty(X,Y)\to M'\otimes C^\infty(X,Y)$ which extends to the morphism $M^Y\ni u\mapsto f\circ u\in M'^Y$, which is injective whenever $f$ is injective. Therefore   $ C^\infty(X,Y)$ would be a flat $ C^\infty(X)$-module.
A: PS: The answer below has gaps, and it is likely incorrect.  

Yes, $C^{\infty}(\mathbb{R}^{m+n})$ is a flat $C^{\infty}(\mathbb{R}^{m})$ module. Or, following @Pietro 's comment, with more generality, if $X,Y$ are smooth manifolds, then $C^\infty(X\times Y)$ is a $C^\infty(X)$ flat module. To see this, it is enough to consider $C^\infty(X)$ linear, injective maps $\varphi: K \rightarrow L$, where $K = <r_1,\dots,r_d>_{C^\infty(X)}$ is a finitely generated $C^\infty(X)$ ideal, and $L=C^\infty(X)$ is the ring of scalars.
Notice that in that case, considering that $C^\infty(X)$ is a sub-ring of $C^\infty(X\times Y)$, the tensor operation $.\otimes_{C^\infty(X)} C^\infty(X\times Y) $ applied to an ideal such as $K$ is just the extension of scalars, i.e., in some natural way, 
$$
K\otimes_{C^\infty(X)} C^\infty(X\times Y)  = <r_1,\dots,r_d>_{C^\infty(X\times Y)},
$$
and 
$$L\otimes_{C^\infty(X)} C^\infty(X\times Y)  = C^\infty(X\times Y).$$
Moreover, with these representations, $\bar{\varphi} = \varphi \otimes Id$, the extension of $\varphi$ from $K$ to   $K\otimes C^\infty(X\times Y)$, satisfies:
$$
\bar{\varphi}( \sum_{i=1}^d r_i\ m_i) = \sum_{i=1}^d \varphi(r_i)\ m_i
$$
for any $m_1,\dots, m_d \in C^\infty(X\times Y)$. 
We want to verify that, under the assumption the $\varphi$ is injective, $\bar{\varphi}$ is injective. Now, if for some linear combination $\sum_i r_i \ m_i$ we have $\bar{\varphi}(\sum_i r_im_i) = 0$, then $\sum_i \varphi(r_i)\ m_i = 0$ in $C^\infty(X\times Y)$, and so, for all $y \in Y$,
$$
\sum_i \varphi(r_i)\ m_i(.,y) = 0
$$
in $C^\infty(X)$, but $\varphi$ being $C^\infty(X)$ linear, we get:
$$
 \varphi(  \sum_i r_i\ m_i(.,y) ) = 0.
$$
By injectivity of $\varphi$, $ \sum_i r_i\ m_i(.,y) = 0$
(With @Pietro notation, this is the condition of an element of $M^Y$ having all 0 coordinates applied to the case $M = $ a finitely generated ideal of $C^\infty(X)$)
Since this holds for all $y$, then $\sum_i r_i\ m_i = 0$, which shows injectivity of $\varphi$.
A: Let $X,Y$ be smooth manifolds; let $\Im = <r_1,\dots,r_d>_{C^\infty(X)}$ be a finitely generated ideal of $C^\infty(X)$. Then $\Im \otimes_{C^\infty(X)} C^\infty(X \times Y) = \{ \sum_{i=1}^d r_i \otimes g_i \ | \ g_1,\dots,g_d \in C^\infty(X \times Y)\}$. I claimed elsewhere that the condition $\sum_{i=1}^d r_i \otimes g_i = 0$ in $\Im \otimes C^\infty(X \times Y)$ is equivalent to $\sum_{i=1}^d r_i  g_i = 0$ in  $C^\infty(X \times Y)$. That is not the case. The correct statement is:  
The following conditions are equivalent: 
i) $\sum_{i=1}^d r_i  g_i = 0$ in  $C^\infty(X \times Y)$
ii) $k(\sum_{i=1}^d r_i \otimes g_i) = 0$ for all $k \in \Im$ 
Proof $i) \Rightarrow ii)$ If  $\sum_{i=1}^d r_i  g_i = 0$ and $k \in \Im$ then $0 = k \otimes (\sum_{i=1}^d r_i  g_i ) = \sum_{i=1}^d k \otimes (r_i  g_i) =$
$ \sum_{i=1}^d  r_i \ (k \otimes  g_i) = \sum_{i=1}^d  (r_i k) \otimes  g_i = k (\sum_{i=1}^d  r_i \otimes  g_i) $ 
$ii) \Rightarrow i)$ Take $k = r_j$, and assume $0 = r_j( \sum_{i=1}^d  r_i \otimes   \ g_i) =\sum_{i=1}^d  r_i \otimes  ( r_j \ g_i) $. Fix $a \in Y$, and consider the bilinear map $e : \Im \times C^\infty(X \times Y) \to C^\infty(X)$ defined as $ e(k,g) = k(x)g(x,a)$. If $\bar{e}$ is the corresponding map on $\Im \otimes C^\infty(X \times Y)$, then $0 = \bar{e}( \sum_{i=1}^d  r_i \otimes  ( r_j \ g_i) ) = \sum_{i=1}^d  \bar{e}(r_i \otimes  ( r_j \ g_i)) =$
$ \sum_{i=1}^d  r_i \ r_j \ g_i(.,a) = r_j ( \sum_{i=1}^d  r_i \  g_i(.,a) )$ 
Since this holds for all $j$, at any point $x \in X$ where some $r_j $ does not vanish, $\sum_{i=1}^d  r_i(x) \  g_i(x,a) =0$, and the same holds trivially at any point $x$ where all $r_j$'s vanish.
