# Scalar field lagrangian in curved spacetime

I am studying inflation theory for a scalar field $\phi$ in curved spacetime. I want to obtain Euler-Lagrange equations for the action:

$$I\left[\phi\right] = \int \left[\frac{1}{2}g^{\mu\nu}\partial_\mu\phi\partial_\nu\phi + V\left(\phi\right) \right]\sqrt{-g} d^4x$$

Euler-Lagrange equations for a scalar field is given by

$$\partial_\mu \frac{\partial L}{\partial\left(\partial_\mu\phi\right)} - \frac{\partial L}{\partial \phi} = 0$$

$$\partial_\mu \frac{\partial L}{\partial\left(\partial_\mu\phi\right)} = \frac{1}{2}\partial_\mu\left(\sqrt{-g}g^{\mu\nu}\partial_\nu\phi \right)$$

$$\frac{\partial L}{\partial \phi} = \frac{\partial \left[\sqrt{-g}V\left(\phi\right)\right]}{\partial \phi}$$

But according to the book the resulting equation is

$$\frac{1}{\sqrt{-g}}\partial_\mu\left(\sqrt{-g}g^{\mu\nu}\partial_\nu\phi\right) = \frac{\partial V\left(\phi\right)}{\partial \phi}$$

What am I doing wrong?

-
First, You forgot a $2$ factor, because the kinetic term is quadratic in first derivatives of $\phi$, and secondly, $\sqrt{-g}$ does not depend on $\phi$. –  Trimok Aug 21 '13 at 9:18
Hawking's 'Large Scale structure of space-time' has a good section on actions in curved space-time if you're interested in learning how the euler-lagrange equations are derived. –  dj_mummy Aug 21 '13 at 10:27