# Definition of the Lagrangian for a relativistic point particle in curved space

I have read that the Lagrangian in GR is defined as $L=\frac{\mathrm{d}s}{\mathrm{d}u}$, where $\mathrm{d}s = g_{ab}\mathrm{d}x^a\mathrm{d}x^b$ is the line element with the metric tensor $g_ab$ and $u$ is an affine parameter, like the proper time $\tau$. How can you "motivate" the definition of $L$?

In the curved space of GR, the straight line path between two points is generalized to the 'shortest' path between two points in spacetime. So we want $$\int \mathrm{d}s$$ to be extremized. Or, in terms of a parameter $u$, we want $$\int \frac{\mathrm{d}s}{\mathrm{d}u}\mathrm{d}u$$ to be extremized. This means we want $$\int L\,\mathrm{d}u$$ to be extremized, but this is just the Lagrangian problem in another guise.