To be used in future
 Section 4.1: Introduction Up Chapter 4: Charged Particles and Electromagnetic Fields Section 4.3: Gauge transformations and Gauge invariance 

4.2 Hamiltonian

We shall use the correspondence principle to derive the quantum Hamiltonian from the classical one. Unfortunately electrodynamics is most readily formulated in the Lagrangian formalism, where one uses the variables and , rather than and . We shall have to do a little work to end up with a Hamiltonian, which we can then quantise using the correspondence principle.

4.2.1 Lagrangian approach

It is straightforward to write the Lagrangian for a charged particle in an electromagnetic field in terms of the scalar and vector potentials, see Ref. [12], pp. 23 [K]  [K] Note that this book, like many other classics, uses Gaussian rather than SI units; which explains (some of) the different factors (especially powers of ) in the equations here..
We use the definition of the electromagnetic potentials in vacuum as This allows us to write an expression for the Lagrangian for a particle in the e.m. field as Indeed the Lagrangian equation of motion (the generalisation of ) [L]  [L] I.e., we minimise the action . becomes which can be written as which is the standard result you have seen many times before. There are two important algebraic steps in the derivation above that deserve some attention: First of all, the total time derivative in () acts both implicitely on the argument of , since is time dependent, and explictely on the argument . This gives rise to the two last expressions on the left-hand side of Eq. (). Secondly, from the first to the second line of () we have used the standard result ().

4.2.2 Canonical momentum

The important reason to write down the complicated expression () above, is to derive a Hamiltonian, which is formulated in terms of momenta; we follow the standard procedue, and find that the form of the canonical momentum is simple but surprising. From the definition we find The canonical momentum in an electromagnetic field thus includes the vector potential.
The classical Hamiltonian, defined as can be written as This is the form we shall use this course.

4.2.3 Quantum Hamiltonian

The quantum Hamiltonian is constructed by the correspondence principle, substituting operators where we had classical variables. where the electro-magnetic potentials and are simply functions of the coordinate operator, and as always A choice had to be made in writing down (), since and do in general not commute, so the order of multiplication matters. The form used here is called the “minimal coupling substitution”, and is the one commonly used.

4.2.4 Conservation of momentum

There is a problem with Eq. (), which we notice by looking at the commutator of the Hamiltonian in zero electric potential, , with (a component of) the momentum operator. We use Eq. (), and the fact that does not commute with , since the latter depends functionally on , and this is obviously not zero! But it is trivial to show that the momentum-like quantity commutes with and is thus a constant of the motion (conserved). This should not surprise us; e.g., if describes a homogeneous magnetic field we know classically that the particle moves in a spiral about the magnetic field lines. We are just seeing the quantum analogue.
 Section 4.1: Introduction Up Chapter 4: Charged Particles and Electromagnetic Fields Section 4.3: Gauge transformations and Gauge invariance