Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
I guess the problem is that your $L$ is not even $C^1$ where $\dot q = 0$. We usually require the Lagrangian to be $\dot q$-convex, i.e., $L_{\dot q\dot q}$ exists everywhere and is nonzero. If you allow time dependence, this problem goes away: $L = \mathrm{e}^t\dot q^2$ is smooth and convex.
You might want to have a look at mathoverflow.net/questions/379946/…. In particular, the equation $\ddot q + \dot q = 0$ does not have a Lagrangian that is independent of time, but it is the E-L equation of the functional $\int \mathrm{e}^t {\dot q}^2\, \mathrm{d}t$.
@DeaneYang: No. What H&C-V do is use the fact that a surface of non-zero constant mean curvature has a parallel surface of constant Gauss curvature: If a surface $X:M^2\to \mathbb{R}^3$ has constant mean curvature $H\not=0$ with oriented normal $\nu$, then $X+1/(2H) \nu:M^2\to \mathbb{R}^3$ has constant Gauss curvature $K=4H^2$. You can make surfaces of nonzero constant mean curvature by dipping a wire loop in a soap solution and blowing on the minimal surface to 'inflate' it. For most wire loops, the parallel surfaces of constant Gauss curvature made this way will not be spherical.
Then you should have a look at the discussion in Hilbert and Cohn-Vossen Geometry and the Imagination ($\S32$, Property 10), "...the spherical surface can be bent [i.e., isometrically deformed] as soon as any arbitrarily small portion is removed; it is in fact, sufficient even to slit the sphere open along an arbitrarily small segment of a great circle." The two paragraphs following the cited one give an explicit 'physical' construction of such deformations using the connection with surfaces of constant mean curvature. In particular, a hemisphere is easily deformable.
Consider the example of the $2$-sphere with its standard area form as symplectic struture. Now let $F = (f_1):S^2\to\mathbb{R}$ be any non-constant smooth function. I assume that meets your criterion as an integrable system, and the image of $F$ is an interval in $\mathbb{R}$. However, in general the flow of the Hamiltonian vector field on $S^2$ that corresponds to $f_1$ will not be periodic. You need that flow to be periodic or it won't come from a circle action. It's easy to construct higher dimensional examples by taking products.
@NickL: Yes, that's true. The example I gave is known as the "Klein correspondence", but the compact version replaces $\mathrm{Sp}(4,\mathbb{R})$ with its maximal compact $M=\mathrm{U}(2)$ and then divides by two different circle subgroups of the diagonal matrices. In fact, there are countably many distinct such circle subgroups of $\mathrm{U}(2)$ that give non-homeomorphic quotients. The examples I gave are just two of them. Dividing $\mathrm{SU}(3)$ by its different circle subgroups gives the $7$-dimensional Aloff-Wallach examples, some of which are homemorphic but not diffeomorphic.
@AliTaghavi: In the complete, simply connected, negative curvature case, the squared distance function is smooth, yes. However, if the surface is completely but not simply-connected, the cut locus will not be empty.
Unfortunately, even the squared distance function is not generally smooth on a compact manifold (look at the sphere), it's just smooth away from the cut locus.
If you only require that there be a non-empty $S\subset X$ on which $f$ is injective, then $n$ points in general position suffice. For example, two distinct points in the Euclidean plane will give you an injection on either half-plane bounding the line joining the points. If you want $S = X$, then, generally, you will need more than $n{+}1$ points, but perhaps no more than $2n{+}1$ points. By the way, you might want to let $f_i$ be the square of the distance to $x_i$ so that it will be smooth on a neighborhood of $x_i$.