# Deriving Geodesic Equations from Euler-Lagrange Equations final step

I would like to derive the geodesic equations on a chart on a Riemannian manifold from the Euler-Lagrange equations. What I have so far, is the following computation (basically calculating the things I need in the Euler-Lagrange equation): $$g_{il}\ddot{\gamma}^i + \frac{\partial g_{il}}{\partial x^j}\dot{\gamma}^i\dot{\gamma}^j = \frac{1}{2}\frac{\partial g_{ij}}{\partial x^l}\dot{\gamma}^i \dot{\gamma}^j.$$ Now the book I am following suggest multiplying by $$g^{kl}$$. Doing this, I end up with: $$\ddot{\gamma}^k + g^{kl}\frac{\partial g_{il}}{\partial x^j}\dot{\gamma}^i\dot{\gamma}^j = \frac{1}{2}g^{kl}\frac{\partial g_{ij}}{\partial x^l}\dot{\gamma}^i \dot{\gamma}^j.$$ Now This should be brought into the form $$\ddot{\gamma}^k + \Gamma^k_{ij}\dot{\gamma}^i\dot{\gamma}^j = 0$$ where $$\Gamma^k_{ij} := \frac{1}{2}g^{kl}\left( \frac{\partial g_{jl}}{\partial x^i} + \frac{\partial g_{il}}{\partial x^j} - \frac{\partial g_{ij}}{\partial x^l}\right).$$ My result looks almost the same, however, I am not able to bring it to the required form, I mean, I have $$\ddot{\gamma}^k + \frac{1}{2}g^{kl}\left(2\frac{\partial g_{il}}{\partial x^j} - \frac{\partial g_{ij}}{\partial x^l}\right)\dot{\gamma}^i \dot{\gamma}^j = 0.$$ But then I do not know how to proceed.

Let me use a condesed notation, $$\ddot{\gamma}^k + \frac{1}{2}g^{kl}\left(2\partial_j g_{il} - \partial_l g_{ij}\right)\dot{\gamma}^i \dot{\gamma}^j = 0.$$All you have to note is that the expression in parenthesis is symmetric in the indices $$i$$, $$j$$ beacause is multiplied by $$\dot{\gamma}^i \dot{\gamma}^j$$ so you split $$2\partial_j g_{il}$$ into two term and exchange indices to one.