1

After coming across the Lagrangian density of the Maxwell equations $$ \mathcal{L} = -\frac{1}{4\mu_0} F_{\mu\nu}F^{\mu\nu}-J_\mu A^\mu = \frac{\varepsilon_0}{2}||\mathbf{E}||^2-\frac{1}{2\mu_0}||\mathbf{B}||^2 -j_\mu A^\mu $$ I was wondering whether there is a corresponding Hamiltonian for Classical Electrodynamics. I have found that for the source-free case ($j_\mu$=0) it is $$\mathcal{H}=\frac{\varepsilon_0}{2}||\mathbf{E}||^2+\frac{1}{2\mu_0}||\mathbf{B}||^2,$$ yet I have only seen it in a couple of places and never including the source terms.

Is there any Hamiltonian that works with sources as well? If not, what could be the reason?

PS: there seems to be a similar question Is there a Hamiltonian for the (classical) electromagnetic field? If so, how can it be derived from the Lagrangian? but no Hamiltonian is given in the answers...

Qmechanic
  • 201,751
  • 1
    As the answer to the linked question suggests...have you tried just performing the Legendre transform yourself? If $J$ is just a background current, this should be straightforward as far as I can recall. – Richard Myers Apr 13 '21 at 22:11

1 Answers1

2

According to these lecture notes, the combination of the following Hamiltonian density and constraint gives rise to the Maxwell equations:

$$\mathcal{H} = \frac{\varepsilon_0}{2}\mathbf{E}^2 + \frac{1}{2\mu_0}\mathbf{B}^2 - j_\mu A^\mu$$ and $$\nabla\cdot\mathbf{E}=\frac{\rho}{\varepsilon_0}$$