In the stretched string example, we saw that the system is described by a Lagrangian density, \(\mathcal{L}\), and the generalized coordinates are replaced by a field, \(\eta(x,t)\) that depends on both position and time. The equations of motion are those that completely specify the description of the field in space and time. We also saw that the integral of the Lagrangian density over space gives the Lagrangian (hence the name Lagrangian density). In general, the Lagrangian density depends on:
\begin{align}
\mathcal{L}=\mathcal{L}(\eta,\frac{d\eta}{dt},t,\frac{d\eta}{dx},x)
\tag{9.12}\end{align}
where the first three variables are similar to those that determine the Lagrangian, \(L(q,\dot q, t)\), and the last two variables \(\frac{d\eta}{dx},x\) are related to the fact that \(\eta\) is a field. Again, we stress the point that the field plays the role of the generalized coordinate and that it depends on position in space and time. When we apply a variation to the “coordinate” \(\eta\), we do not vary \(x\) and \(t\).
Before proceeding, we tidy up the notation slightly by introducing \(\eta'=\frac{d\eta}{dx}\) and \(\dot\eta=\frac{d\eta}{dt}\), so that the Lagrangian density is written as:
\begin{align}
\mathcal{L}=\mathcal{L}(\eta,\dot\eta,\eta',x,t)
\tag{9.13}\end{align}
The action integral is given by:
\begin{align}
S=\int_{t_a}^{t_b} \int_{x_1}^{x_2}\mathcal{L}\,dx\,dt
\tag{9.14}\end{align}
and we want to find the condition under which \(S\) is stationary (Hamilton’s variational principle). We proceed in a similar fashion as we did in Chapter ?. Let us introduce a small parameter, \(\epsilon\) and the varied field, \(\bar\eta\):
\begin{align}
\bar\eta(x,t)&=\eta(x,t)+\epsilon\phi(x,t)\\
\delta \eta \equiv&\bar\eta(x,t)-\eta(x,t) = \epsilon \phi(x,t)
\tag{9.15}\end{align}
where \(\phi\) is a continuous and differentiable function over the intervals in \(x\) and \(t\) where the unvaried field, \(\eta(x,t)\), is continuous and differentiable. Note that \(\phi(x,t)\) is identically zero at the end points of the integral, since the variation vanishes there.
The variation of the action integral is thus:
\begin{align}
\delta S=\int_{t_a}^{t_b} \int_{x_1}^{x_2}\delta\mathcal{L}\,dx\,dt
\tag{9.16}\end{align}
The variation of the Lagrangian density is:
\begin{align}
\delta\mathcal{L}&=\mathcal{L}(\eta+\delta\eta,\dot\eta+\delta\dot\eta,\eta'+\delta\eta',x,t)-\mathcal{L}(\eta,\dot\eta,\eta',x,t)\end{align}
As usual, we expand the first term using a Taylor series near the unvaried Lagrangian density:
\begin{align}
\lagd(\eta+\delta\eta,\dot\eta+\delta\dot\eta,\eta'+\delta\eta',x,t)=\lagd(\eta,\dot\eta,\eta',x,t)+\die{\lagd}{\eta}\delta\eta+\die{\lagd}{\dot\eta}\delta\dot\eta+\die{\lagd}{\eta'}\delta\eta'+\dots
\tag{9.18}\end{align}
and neglect terms that are second order in the variations. This gives us the variational integral:
\begin{align}
\delta S=\int_{t_a}^{t_b} \int_{x_1}^{x_2} \left(\die{\lagd}{\eta}\delta\eta+\die{\lagd}{\dot\eta}\delta\dot\eta+\die{\lagd}{\eta'}\delta\eta' \right)\,dx\,dt
\tag{9.19}\end{align}
Because variation and differentiation commute, we have the following:
\begin{align}
\delta \eta &=\epsilon \phi\\
\delta \dot\eta &=\epsilon\dot\phi\\
\delta \eta' &=\epsilon \phi'
\tag{9.20}\end{align}
So that the variational integral becomes:
\begin{align}
\delta S=\epsilon\int_{t_a}^{t_b} \int_{x_1}^{x_2} \left(\die{\lagd}{\eta}\phi+\die{\lagd}{\dot\eta}\dot\phi+\die{\lagd}{\eta'}\phi' \right)\,dx\,dt
\tag{9.21}\end{align}
and we require that the rate of change of \(\delta S\) with respect to \(\epsilon\) vanish (since \(S\) must be stationary):
\begin{align}
\frac{d\delta S}{d\epsilon}=\frac{\delta S}{\epsilon}=0
\tag{9.22}\end{align}
Now consider the third term in the integrand, which we integrate by parts over \(x\):
\begin{align}
\int_{t_a}^{t_b} \int_{x_1}^{x_2}\die{\lagd}{\eta'}\phi' \,dx\,dt&=\int_{t_a}^{t_b}\left[\phi\die{\lagd}{\eta'}\right]_{x_1}^{x_2}\,dt-\int_{t_a}^{t_b} \int_{x_1}^{x_2}\phi\frac{d}{dx}\die{\lagd}{\eta'}\,dx\,dt\\
&=\int_{t_a}^{t_b} \int_{x_1}^{x_2}\phi\frac{d}{dx}\die{\lagd}{\eta'}\,dx\,dt
\tag{9.23}\end{align}
however, the first term is zero since \(\phi\) is identically zero at \(x_1\) and \(x_2\). Similarly, we integrate the second term by parts over \(t\), where \(\phi\) is identically zero at \(t_a\) and \(t_b\):
\begin{align}
\int_{t_a}^{t_b} \int_{x_1}^{x_2}\die{\lagd}{\dot\eta}\dot\phi \,dx\,dt&=\int_{x_1}^{x_2}\left[\phi\die{\lagd}{\dot\eta}\right]_{t_a}^{t_b}\,dt-\int_{t_a}^{t_b} \int_{x_1}^{x_2}\phi\frac{d}{dt}\die{\lagd}{\dot\eta} \,dx\,dt\\
&=\int_{t_a}^{t_b} \int_{x_1}^{x_2}\phi\frac{d}{dt}\die{\lagd}{\dot\eta} \,dx\,dt
\tag{9.24}\end{align}
The variation integral thus becomes:
\begin{align}
\frac{\delta S}{\epsilon}=\int_{t_a}^{t_b} \int_{x_1}^{x_2} \phi \left(\die{\lagd}{\eta}-\frac{d}{dt}\die{\lagd}{\dot\eta}- \frac{d}{dx}\die{\lagd}{\eta'} \right)\,dx\,dt
\tag{9.25}\end{align}
Since this must equal zero for any choice of \(\phi\), the term in parenthesis must be zero over the entire region of integration. We obtain the Euler-Lagrange equation for a one dimensional field:
\begin{align}
\therefore \frac{d}{dt}\die{\lagd}{\dot\eta}+\frac{d}{dx}\die{\lagd}{\eta'}-\die{\lagd}{\eta}=0
\tag{9.26}\end{align}
In the case that the Lagrangian density depends on multiple one-dimension fields, it is straightforward to show that one obtains a Euler-Lagrange equation for each field (recall, the fields are similar to generalized coordinates).
Example 9-1
Show that the Euler-Lagrange for a one-dimensional field gives the wave equation for the Lagrangian density of a stretched string, \(\lagd=\frac{1}{2}\left[\mu\left(\frac{d\eta}{dt}\right)^2-Y\left(\frac{d\eta}{dx}\right)^2\right]\)
The Euler-Lagrange equation is:
\begin{align*}
\frac{d}{dt}\die{\lagd}{\dot\eta}+\frac{d}{dx}\die{\lagd}{\eta'}-\die{\lagd}{\eta}=0
\end{align*}
with
\begin{align*}
\frac{d}{dt}\die{\lagd}{\dot\eta}&=\frac{d}{dt}\mu\frac{d\eta}{dt}=\mu\ddot\eta\\
\frac{d}{dx}\die{\lagd}{\eta'}&=-\frac{d}{dx}Y\frac{d\eta}{dx}=-Y\eta''\\
\die{\lagd}{\eta}&=0
\end{align*}
Thus, we get the wave equation:
\begin{align*}
\mu\ddot\eta-Y\eta''=0
\end{align*}