Variational and classical-field repair
A field equation does not follow from an action by a formal command to “vary and discard a total derivative.” It follows from a first variation in which the fields, region, allowed variations, and boundary data have all been declared. This focused review rebuilds that calculation for a scalar field and then transfers it to Maxwell theory, where a singular Legendre map introduces constraints.
The goal is practical: given a local action, you should be able to display its bulk and surface terms, explain what makes the surface term vanish or cancel, and separate an interior Euler–Lagrange equation from boundary data and canonical constraints.
Required background. You should be comfortable differentiating functions of several variables, integrating by parts, and tracking upper and lower indices. If the last step is uncertain, begin with Linear and tensor methods. The formulas below inherit the site’s conventions and normalizations.
From a local action to its first variation
Section titled “From a local action to its first variation”Let be smooth real field components on a spacetime region , and consider a first-derivative local action
A variation is a one-parameter family through admissible configurations. Thus has the same tensor and reality properties as and is tangent to whatever boundary data have been fixed. Before any integration by parts,
Define
One integration by parts gives the decisive decomposition
Here is the outward-directed surface element. If the action also contains a boundary functional, its variation must be added to the second line before stationarity is tested.
Compactly supported vanish near . Stationarity for every such variation therefore implies the interior Euler–Lagrange equations
That argument says nothing about the boundary. On a finite region, the remaining surface variation must vanish for the allowed boundary variations, or be cancelled or reshaped by a boundary functional. This is a differentiability test for the action, not by itself a theorem about existence, uniqueness, or stability of the resulting differential equation Harlow and Wu 2020, §§1 and 2.2.
Use the same four moves every time:
- State the fields, action, region, and data held fixed.
- Vary first; do not impose the field equations.
- Integrate by parts once and retain every surface contribution.
- Classify each resulting condition by its origin and role.
Scalar field: the surface term chooses the problem
Section titled “Scalar field: the surface term chooses the problem”For one real scalar, take
The unintegrated variation and its bulk–boundary split are
Arbitrary compactly supported variations give
Several different boundary problems can share this same bulk equation:
- Fixed field value (Dirichlet). If is fixed on a boundary component, every allowed variation obeys there. The displayed surface term then vanishes without an extra boundary functional.
- Free field value. If is arbitrary at a smooth non-null boundary and no boundary functional is added, stationarity produces the natural condition .
- Fixed normal flux. Holding fixed is not the same as leaving free. A boundary Legendre term changes the residual variation from to on a fixed boundary geometry.
- Robin data. A boundary functional depending on can make a linear combination of and its normal derivative the natural boundary equation. Its sign must be checked by varying the complete action again.
The full comparison of these choices is developed in Boundaries, variations, and well-posed actions. Notice also that fixing a variation on initial and final time caps for the stationary-action derivation is not the same task as supplying Cauchy data on one time slice and proving that the equations evolve it uniquely.
For the diagnostic potential
the equation is
Three quick checks are available. Setting recovers the free Klein–Gordon equation. With the inherited Fourier convention, , so a free plane wave obeys . Finally, in natural units and the kinetic term gives , making every term in the equation have the same engineering dimension. The scalar derivation and its assumptions are treated more fully in The action principle and field equations and Schwartz 2014, §3.2.
Equations, constraints, and boundary conditions
Section titled “Equations, constraints, and boundary conditions”These labels answer different questions; they are not interchangeable.
| Kind of condition | How it is found | What it controls |
|---|---|---|
| Euler–Lagrange equation | Coefficient of an arbitrary interior variation | Which spacetime configurations are on shell |
| Boundary condition | Declared boundary data or coefficient of a free boundary variation | Which boundary traces or fluxes are allowed |
| Primary constraint | Relation among fields and canonical momenta caused by a singular velocity Hessian | Which points belong to the canonical initial-data surface |
Choose a time coordinate and define
If is invertible, the velocities can locally be recovered from the momenta. If it has a null direction, the definitions of the momenta instead imply one or more relations among : primary constraints. A complete constrained-Hamiltonian analysis must then preserve those relations under time evolution, which can generate further constraints Henneaux and Teitelboim 1992, chs. 1–3.
There is an important overlap in terminology. An Euler–Lagrange equation may be an evolution equation after a time split, or it may constrain initial data without solving for a highest time derivative. Maxwell’s Gauss equation is an Euler–Lagrange equation and a canonical constraint. By contrast, the primary relation follows directly from the singular Legendre map. Neither is a boundary condition.
Maxwell theory: variation and the singular Legendre map
Section titled “Maxwell theory: variation and the singular Legendre map”Let
Using the antisymmetry of ,
Variations of compact support give the vacuum Maxwell equations
For a finite region, fixing the appropriate pullback of makes the surface variation vanish; flux-type data require a different boundary test. This boundary choice is independent of the canonical degeneracy below.
Taking as the configuration variables, the canonical momenta are
Therefore
No can be recovered from these definitions, so the velocity Hessian has a null direction and is a primary constraint. The Euler–Lagrange equation is
the source-free Gauss constraint. It contains no second time derivative of ; in the Hamiltonian analysis it arises when the primary constraint is preserved. The spatial equations contain the evolution of the electric field. Meanwhile, a statement such as on a chosen boundary is boundary data. The origins of all three statements are now visibly different.
This calculation diagnoses the constraint structure; it does not finish the Dirac–Bergmann algorithm or count physical polarizations. Continue to Hamiltonian initial data and phase space or Constraints, Dirac brackets, and symplectic reduction when that fuller analysis is needed.
Exercises
Section titled “Exercises”1. A scalar on an interval with Robin walls
Section titled “1. A scalar on an interval with Robin walls”On the time slab , consider
Set at the time caps but allow it to vary freely at and . Derive the bulk equation and both wall equations. Classify each.
Solution
Varying the bulk action before integrating gives
The fixed time-cap variations remove the temporal endpoint term. Integration by parts in both variables gives
The boundary functional contributes
Arbitrary interior variations give the Euler–Lagrange equation
Because the wall variations are free, their two coefficients must vanish:
The opposite signs of the derivatives reflect the opposite outward normals. These are natural Robin boundary equations, not additional bulk Euler–Lagrange equations and not canonical constraints. If the wall values of had instead been fixed, would vanish there and these Robin equations would not follow.
2. Classify the Maxwell conditions
Section titled “2. Classify the Maxwell conditions”Starting from the Maxwell density, compute . Use it to derive the canonical momenta and the field equation. Then classify , , and .
Solution
Since ,
Setting gives
so and . The first relation follows before any equation of motion is imposed and reveals that the Legendre map cannot recover ; it is a primary constraint.
The Euler–Lagrange equation is
It is the Gauss equation in the covariant derivation and a constraint on canonical initial data after a time split. In the full Hamiltonian analysis it is generated by preserving . Finally, restricts the allowed boundary variations; it is boundary data. It neither follows from the velocity Hessian nor replaces the Gauss equation.
3. A total divergence is boundary data, not zero
Section titled “3. A total divergence is boundary data, not zero”Replace a scalar density by . Show what changes in the first variation and explain why the bulk equations agree for compactly supported variations but a finite-region variational problem can change.
Solution
The action changes by a surface functional,
Its variation is
for a fixed boundary geometry. This contribution vanishes for variations of compact support, so the interior Euler–Lagrange equations are unchanged. On a finite region with nonzero boundary variations, however, it changes the surface coefficient and can therefore change the natural boundary equation or the boundary functional needed for fixed data. “Total derivative” means “pure boundary contribution” here, not “identically zero.”
Re-check and return
Section titled “Re-check and return”Repeat the variational part of the classical-field and relativity diagnostic with a potential different from the one above, or use Maxwell theory with a boundary choice you state explicitly. Your work is ready to carry forward when it contains:
- the field content, action, region, and admissible variations;
- the unintegrated first variation;
- a checked bulk–boundary split;
- the interior Euler–Lagrange equations;
- the exact boundary condition or boundary functional that controls every surface term;
- the canonical momenta and velocity-Hessian test; and
- separate labels for primary constraints, any constraint-type field equations, evolution equations, and boundary data.
If every item is explicit and the scalar and Maxwell signs survive a direct recalculation, return to Classical fields, actions, and local dynamics. If the bulk equation is correct but the surface term or Legendre-map argument remains implicit, redo one exercise with changed coefficients before returning. If an integration by parts or index contraction is still blocking the calculation, revisit Field variations and boundary terms or Linear and tensor methods, then repeat the same line rather than restarting the entire route.
References
Section titled “References”- Daniel Harlow and Jie-qiang Wu, “Covariant Phase Space with Boundaries,” Journal of High Energy Physics 2020, no. 10 (2020): 146, doi:10.1007/JHEP10(2020)146, Open PDF.
- Marc Henneaux and Claudio Teitelboim, Quantization of Gauge Systems, Princeton University Press, 1992, publisher page.
- Matthew D. Schwartz, Quantum Field Theory and the Standard Model, Cambridge University Press, 2014, doi:10.1017/9781139540940.