I am having trouble while solving in the Problem 3.1 of the QFT book by Schwartz.
Problem
Find the generalization of the Euler-Lagrange equations for general higher-order Lagrangians of the form $\mathcal{L}[\phi, \partial_\mu \phi, \partial_\mu \partial_\nu \phi, \ldots]$.
I have tried to solve this problem. But got stuck. I will be glad if anyone can help me solving this. The steps which I done so far is given below.
Let, the action is \begin{equation}\label{S} S=\int d^4x\,{\cal L} \,, \end{equation} where ${\cal L}$ denotes a Lagrangian density which may depend on $\phi$ and up to its $N$-th order space-time derivatives. In other words, we have \begin{equation}\label{L} {\cal L}={\cal L}(\phi,\partial_{\mu_1}\phi, \partial_{\mu_1}\partial_{\mu_2}\phi,\dots,\partial_{\mu_1}\partial_{\mu_2}\dots\partial_{\mu_N}\phi) \,. \end{equation}
The classical dynamics of the system is determined by demanding the action $S$ to remain stationary under arbitrary variations of $\phi$ and its derivatives, vanishing at the integration boundary.
\begin{align} & \delta S\\ = & \delta \left(\int d^4x ~\mathcal{L}(\phi,\partial_{\mu_1}\phi, \partial_{\mu_1}\partial_{\mu_2}\phi,\dots,\partial_{\mu_1}\partial_{\mu_2}\dots\partial_{\mu_N}\phi)\right)\\ = & \int d^4 x~ \delta \mathcal{L}(\phi,\partial_{\mu_1}\phi, \partial_{\mu_1}\partial_{\mu_2}\phi,\dots,\partial_{\mu_1}\partial_{\mu_2}\dots\partial_{\mu_N}\phi)\\ = & \int d^4 x~ \left(\frac{\partial{\cal L}}{\partial\phi} \delta\phi + \frac{\partial{\cal L}}{\partial(\partial_{\mu_1}\phi)} \delta(\partial_{\mu_1}\phi) + \frac{\partial{\cal L}}{\partial(\partial_{\mu_1}\partial_{\mu_2}\phi)} \delta(\partial_{\mu_1}\partial_{\mu_2}\phi) + \dots + \frac{\partial{\cal L}}{\partial(\partial_{\mu_1}\partial_{\mu_2}\dots\partial_{\mu_N}\phi)} \delta(\partial_{\mu_1}\partial_{\mu_2}\dots\partial_{\mu_N}\phi)\right) \label{eqn: action2} \end{align} Define, \begin{equation} \partial_{\mu_{(n)}}\phi \equiv \partial_{\mu_1}\partial_{\mu_2}\dots\partial_{\mu_n}\phi \end{equation} where $\partial_{\mu_{(0)}}$ denotes no derivative at all, that is, $\partial_{\mu_{(0)}}\phi\equiv\phi$.
Therefore, \begin{align} \delta S = & \int d^4x~ \sum_{n=0}^{N}\frac{\partial{\mathcal{L}}}{\partial(\partial_{\mu_{(n)}}\phi)} \delta(\partial_{\mu_{(n)}}\phi)\\ = & \int d^4x~ \sum_{n=0}^{N}\frac{\partial{\mathcal{L}}}{\partial(\partial_{\mu_{(n)}}\phi)} \partial_{\mu_{(n)}} (\delta \phi)\\ \end{align}