If $M$ is a (real) differentiable manifold, its differentiable structure is completely determined if it is known which mappings $M\to\mathbf{R}$ are smooth.
How much can be said about the differentiable structure of $M$ if it is known which mappings $\mathbf{R}\to M$ are smooth? I suspect that this is not enough to determine the differentiable structure of $M$. If so, can there be a number $k <\operatorname{dim}M$ such that the smooth mappings $\mathbf{R}^k\to M$ completely determine the differentiable structure of $M$?
I think my first question can be rephrased as follows: if $f\colon\mathbf{R}^n\to\mathbf{R}$ has the property that for every smooth $\gamma\colon\mathbf{R}\to\mathbf{R}^n$, the composition $f\circ\gamma\colon\mathbf{R}\to\mathbf{R}$ is smooth, does this imply that $f$ is smooth?
I conjecture that if $f\colon\mathbf{R}^n\to\mathbf{R}$ has the property that for every smooth $\sigma\colon\mathbf{R}^2\to\mathbf{R}^n$, the composition $f\circ\sigma\colon\mathbf{R}^2\to\mathbf{R}$ is smooth, then $f$ is smooth.