Realizing smooth curves as geodesics Given a smooth manifold $M$ and any smooth curve $C\subset M$, can we always find a Riemannian metric $g$ on $M$ for which the curve is a geodesic (in the variational sense)? Going further, if not, what is a necessary and sufficient condition for $C$ to be realized as a geodesic in this sense?
 A: Certainly this is not true in general without some additional restrictions: Pick any smooth curve $\gamma: I \to M$ such that, for times $a \neq b$, $\gamma(a) = \gamma(b)$ and $\gamma'(a) = \gamma'(b)$, but the germs of $a$ and $b$ do not agree, and pick any metric $g$. Then, $\gamma$ cannot be a geodesic, as the uniqueness of geodesics guarantee that the germ of $\gamma$ at time $t$ is determined by $\gamma(t)$ and $\gamma'(t)$. (For a more concrete argument, just take $M = \Bbb R^n$ and replace the condition on germs with the condition that $\gamma''(a) \neq \gamma''(b)$.)
On the other hand, a suitable local version of the statement is true:

Suppose $\gamma: I \to M$ is a nonsingular curve. Then, for any time $t_0 \in I$, there is an $\epsilon > 0$ and a metric $g$ on $M$ such that $\bar{\gamma} := \gamma\vert_{(t_0 - \epsilon, t_0 + \epsilon)}$ is a parameterized geodesic of $g$.

Proof (sketch): Extend $\gamma'$ to a smooth, nonvanishing vector field $X$ in some neighborhood of $\gamma(t_0)$, and choose flowbox coordinates $(x^a)$ for $X$ around that point. In particular, $\gamma'(t) = \partial_{x_1} \vert_{\gamma(t)}$ for all $t$ sufficiently close to $t_0$. Then, using a suitable partition of unity, you can construct a metric $g$ on $M$ that is given in flowbox coordinates by $\sum (dx^a)^2$ on some neighborhood $U$ of $\gamma(t_0)$. Then, you can choose $\epsilon > 0$ such that $(t_0 - \epsilon, t_0 + \epsilon)$ is contained inside the connected component of $t_0$ in $\gamma^{-1}(U)$. By construction, $\bar\gamma$ is a parameterized geodesic of 
$\sum (dx^a)^2$ and hence of $g$.
