# Commuting derivative/Integral (not FTC or Leibniz)

## Main Question or Discussion Point

Hi,

I'm concerned with finding the Euler-Lagrange equations for slowly modulated surface gravity waves and, as is custom in this type of physical problem, I would like to consider the averaged Lagrangian defined as

$$\mathcal{L}=\frac{1}{2\pi}\int_0^{2\pi}Ld\theta$$

where $$\theta$$ is defined as $$\theta_x=k$$ and $$\theta_t=-\omega$$ where k and $\omega$ represent wave number and frequency respectively, which can also be functions of space and time. My Lagrangian, which comes from the physics of the problem, is $$L=L(\theta;x,t)$$ and the Euler-Lagrange equation then becomes

$$\frac{\partial L}{\partial \theta}-\frac{\partial }{\partial x }\frac{\partial L}{\partial \theta_x}-\frac{\partial }{\partial t}\frac{\partial L}{\partial \theta_t}=0$$

If I integrate the above equation over $$\theta$$ from 0 to $$2\pi$$ and normalize, I know the first term goes to 0 because L is periodic (which again comes from the physics). So I'm trying to see if I can write the rest of equation in terms of the averaged Lagrangian, $$\mathcal{L}$$. So my question is this, how does the term

$$\frac{1}{2\pi}\int_0^{2\pi}\frac{\partial }{\partial x }\frac{\partial L}{\partial \theta_x} \ d\theta$$

relate to

$$\frac{\partial }{\partial x }\frac{\partial }{\partial \theta_x} \mathcal{L}$$

Thanks!
Nick