# Equation of string as hamiltonian field equations

I am using Hamiltonian field theory for the first time and I struggle with some final steps. The task is to derive the equation of vibrating string using Hamilton's field equations. Here is what I have done so far:

Lagrangian density of vibrating string, denoting as usual $y=y(x,t)$ the displacement, $\rho$ the linear density and $T$ the tension:

$$\mathcal{L} = \frac{1}{2}\rho\left(\partial_t y\right)^2-\frac{1}{2}T\left(\partial_x y\right)^2$$

Conjugate momentum fields are:

$$\pi_{y_t} = \frac{\partial \mathcal{L}}{\partial (\partial_t y)} = \rho \ \partial_t y \ \ , \ \ \pi_{y_x} = \frac{\partial \mathcal{L}}{\partial (\partial_x y)} = T \ \partial_x y$$

therefore:

$$\mathcal{H} = \frac{\pi_{y_t}}{2\rho}+\frac{\pi_{y_x}}{2T}$$

and here I am beginning to lose the ground. The problem are the variational derivatives $\frac{\delta\mathcal{H}}{\delta\mathcal{\pi_i}}$. I should give it a try, so:

$$\frac{\delta\mathcal{H}}{\delta\mathcal{\pi_{y_t}}} = \frac{\partial \mathcal{H}}{\partial \pi_{y_t}} - \frac{\mathrm{d}}{\mathrm{d}t}\frac{\partial \mathcal{H}}{\partial \left(\partial_t \pi_{y_t}\right)} = \frac{\pi_{y_t}}{\rho} - 0$$

Is this correct? How should look the term according to the above quoted wikipedia article (first line below the field equations on wiki)?

• What is $\pi_{y_x}$? Usual Hamiltonian field theory does not associate momenta to the spatial derivatives, that is only done in the covariant approach known as de Donder-Weyl theory. In particular, you should not be taking $\frac{\delta\mathcal{H}}{\delta\pi_{y_x}}$. Nov 23, 2015 at 16:03
• @ACuriousMind: OK, thanks, that's my mistake. So the hamiltonian density should be: $H=π2/ρ+(1/2)T(∂xy)2$? Nov 25, 2015 at 13:04

As pointed out in the comments, you only need to introduce one conjugate momentum density: $\pi = \frac{\partial \mathcal{L}}{\partial \dot{y}} = \rho \dot{y}$ The Hamiltonian density becomes $$\mathcal{H} = \frac{1}{2\rho}\pi^2 + \frac{T}{2}y_x^2$$
The first equation is trivial, i.e. $\pi = \rho \dot{y}$, and the second leads to the equation of motion. Using the definition of the variational derivative, we get \begin{eqnarray} \dot{\pi} = -\frac{\partial \mathcal{H}}{\partial y} + \partial_x \frac{\partial \mathcal{H}}{\partial y_x} \\ = 0 + T y_{xx} \end{eqnarray} So \begin{eqnarray} \rho\ddot{y} = T y_{xx} \end{eqnarray}