# Hamiltonian field theory

In theoretical physics, Hamiltonian field theory is the field-theoretic analogue to classical Hamiltonian mechanics. It is a formalism in classical field theory alongside Lagrangian field theory. It also has applications in quantum field theory.

## Definition

The Hamiltonian for a system of discrete particles is a function of their generalized coordinates and conjugate momenta, and possibly, time. For continua and fields, Hamiltonian mechanics is unsuitable but can be extended by considering a large number of point masses, and taking the continuous limit, that is, infinitely many particles forming a continuum or field. Since each point mass has one or more degrees of freedom, the field formulation has infinitely many degrees of freedom.

### One scalar field

The Hamiltonian density is the continuous analogue for fields; it is a function of the fields, the conjugate "momentum" fields, and possibly the space and time coordinates themselves. For one scalar field φ(x, t), the Hamiltonian density is defined from the Lagrangian density by
    ${\mathcal {H}}(\phi ,\pi ,\mathbf {x} ,t)={\dot {\phi }}\pi -{\mathcal {L}}(\phi ,\nabla \phi ,\partial \phi /\partial t,\mathbf {x} ,t)\,.$
with ∇ the "del" or "nabla" operator, x is the position vector of some point in space, and t is time. The Lagrangian density is a function of the fields in the system, their space and time derivatives, and possibly the space and time coordinates themselves. It is the field analogue to the Lagrangian function for a system of discrete particles described by generalized coordinates.
As in Hamiltonian mechanics where every generalized coordinate has a corresponding generalized momentum, the field φ(x, t) has a conjugate momentum field π(x, t), defined as the partial derivative of the Lagrangian density with respect to the time derivative of the field,
    $\pi ={\frac {\partial {\mathcal {L}}}{\partial {\dot {\phi }}}}\,,\quad {\dot {\phi }}\equiv {\frac {\partial \phi }{\partial t}}\,,$
in which the overdot denotes a partial time derivative ∂/∂t, not a total time derivative d/dt.

### Many scalar fields

For many fields φ$_i$(x, t) and their conjugates π$_i$(x, t) the Hamiltonian density is a function of them all:
    ${\mathcal {H}}(\phi _{1},\phi _{2},\ldots ,\pi _{1},\pi _{2},\ldots ,\mathbf {x} ,t)=\sum _{i}{\dot {\phi _{i}}}\pi _{i}-{\mathcal {L}}(\phi _{1},\phi _{2},\ldots \nabla \phi _{1},\nabla \phi _{2},\ldots ,\partial \phi _{1}/\partial t,\partial \phi _{2}/\partial t,\ldots ,\mathbf {x} ,t)\,.$
where each conjugate field is defined with respect to its field,
    $\pi _{i}(\mathbf {x} ,t)={\frac {\partial {\mathcal {L}}}{\partial {\dot {\phi }}_{i}}}\,.$
In general, for any number of fields, the volume integral of the Hamiltonian density gives the Hamiltonian, in three spatial dimensions:
    $H=\int {\mathcal {H}}\ d^{3}x\,.$
The Hamiltonian density is the Hamiltonian per unit spatial volume. The corresponding dimension is [energy][length]$^{−3}$, in SI units Joules per metre cubed, J m$^{−3}$.

### Tensor and spinor fields

The above equations and definitions can be extended to vector fields and more generally tensor fields and spinor fields. In physics, tensor fields describe bosons and spinor fields describe fermions.

## Equations of motion

The equations of motion for the fields are similar to the Hamiltonian equations for discrete particles. For any number of fields:
${\dot {\phi }}_{i}=+{\frac {\delta {H}}{\delta \pi _{i}}}\,,\quad {\dot {\pi }}_{i}=-{\frac {\delta {H}}{\delta \phi _{i}}}\,,$
where again the overdots are partial time derivatives, the variational derivative with respect to the fields
    ${\frac {\delta H}{\delta \phi _{i}}}={\frac {\partial {\mathcal {H}}}{\partial \phi _{i}}}-\nabla \cdot {\frac {\partial {\mathcal {H}}}{\partial (\nabla \phi _{i})}}\,,$
with · the dot product, must be used instead of simply partial derivatives.

## Phase space

The fields φ$_i$ and conjugates π$_i$ form an infinite dimensional phase space, because fields have an infinite number of degrees of freedom.

## Poisson bracket

For two functions which depend on the fields φ$_i$ and π$_i$, their spatial derivatives, and the space and time coordinates,
    $A=\int d^{3}x{\mathcal {A}}\left(\phi _{1},\phi _{2},\ldots ,\pi _{1},\pi _{2},\ldots ,\nabla \phi _{1},\nabla \phi _{2},\ldots ,\nabla \pi _{1},\nabla \pi _{2},\ldots ,\mathbf {x} ,t\right)\,,$
    $B=\int d^{3}x{\mathcal {B}}\left(\phi _{1},\phi _{2},\ldots ,\pi _{1},\pi _{2},\ldots ,\nabla \phi _{1},\nabla \phi _{2},\ldots ,\nabla \pi _{1},\nabla \pi _{2},\ldots ,\mathbf {x} ,t\right)\,,$
and the fields are zero on the boundary of the volume the integrals are taken over, the field theoretic Poisson bracket is defined as (not to be confused with the anticommutator from quantum mechanics).
    $\{A,B\}_{\phi ,\pi }=\int d^{3}x\sum _{i}\left({\frac {\delta {\mathcal {A}}}{\delta \phi _{i}}}{\frac {\delta {\mathcal {B}}}{\delta \pi _{i}}}-{\frac {\delta {\mathcal {B}}}{\delta \phi _{i}}}{\frac {\delta {\mathcal {A}}}{\delta \pi _{i}}}\right)\,,$
where $\delta {\mathcal {F}}/\delta f$ is the variational derivative
    ${\frac {\delta {\mathcal {F}}}{\delta f}}={\frac {\partial {\mathcal {F}}}{\partial f}}-\sum _{i}\nabla _{i}{\frac {\partial {\mathcal {F}}}{\partial (\nabla _{i}f)}}\,.$
Under the same conditions of vanishing fields on the surface, the following result holds for the time evolution of A (similarly for B):
    ${\frac {dA}{dt}}=\{A,H\}+{\frac {\partial A}{\partial t}}$
which can be found from the total time derivative of A, integration by parts, and using the above Poisson bracket.

## Explicit time-independence

The following results are true if the Lagrangian and Hamiltonian densities are explicitly time-independent (they can still have implicit time-dependence via the fields and their derivatives),

### Kinetic and potential energy densities

The Hamiltonian density is the total energy density, the sum of the kinetic energy density (${\mathcal {T}}$) and the potential energy density (${\mathcal {V}}$),
    ${\mathcal {H}}={\mathcal {T}}+{\mathcal {V}}\,.$

### Continuity equation

Taking the partial time derivative of the definition of the Hamiltonian density above, and using the chain rule for implicit differentiation and the definition of the conjugate momentum field, gives the continuity equation:
    ${\frac {\partial {\mathcal {H}}}{\partial t}}+\nabla \cdot \mathbf {S} =0$
in which the Hamiltonian density can be interpreted as the energy density, and
    $\mathbf {S} ={\frac {\partial {\mathcal {L}}}{\partial (\nabla \phi )}}{\frac {\partial \phi }{\partial t}}$
the energy flux, or flow of energy per unit time per unit surface area.

## Relativistic field theory

Covariant Hamiltonian field theory is the relativistic formulation of Hamiltonian field theory.
Hamiltonian field theory usually means the symplectic Hamiltonian formalism when applied to classical field theory, that takes the form of the instantaneous Hamiltonian formalism on an infinite-dimensional phase space, and where canonical coordinates are field functions at some instant of time. This Hamiltonian formalism is applied to quantization of fields, e.g., in quantum gauge theory. In Covariant Hamiltonian field theory, canonical momenta p$^μ$$_i$ corresponds to derivatives of fields with respect to all world coordinates x$^μ$. Covariant Hamilton equations are equivalent to the Euler–Lagrange equations in the case of hyperregular Lagrangians. Covariant Hamiltonian field theory is developed in the Hamilton–De Donder, polysymplectic, multisymplectic and k-symplectic variants. A phase space of covariant Hamiltonian field theory is a finite-dimensional polysymplectic or multisymplectic manifold.
Hamiltonian non-autonomous mechanics is formulated as covariant Hamiltonian field theory on fiber bundles over the time axis, i.e. the real line $\mathbb {R}$.