# Equality of the Hilbert Hamiltonian and the canonical Hamiltonian for gauge
theories in a static spacetime

H. Arthur Weldon<EMAIL_ADDRESS>Department of Physics and Astronomy West
Virginia University,Morgantown, West Virginia, 26506-6315, USA

###### Abstract

The Hilbert energy-momentum tensor for gauge-fixed non-Abelian gauge theories,
defined by the variational derivative of the action with respect to the space-
time metric, is a tensor under general coordinate transformations, symmetric
in its indices, and BRST invariant. The canonical energy-momentum tensor has
none of these properties but the canonical Hamiltonian does correctly generate
the time dependence of the fields. It is shown that the Hilbert Hamiltonian
$\int d^{3}x\,\sqrt{g}\;T^{0}_{\;\;0}$ is equal to the canonical Hamiltonian
for a general gauge theory coupled to spin 1/2 and spin 0 matter fields
(including an $R\phi^{2}$ term) in a static background metric
($\partial_{0}g_{\mu\nu}=0$ and $g_{0j}=0$). The equality depends on on the
Gauss’s law constraint but not on the dynamical Euler-Lagrange equations.

##  I Introduction

The Hilbert energy-momentum tensor Hilbert  in an arbitrary background metric
is determined from the Lagrangian density for matter and radiation by

${\delta\over\delta g^{\mu\nu}(x)}\int d^{4}z\;{\cal L}={\sqrt{g}\over
2}T_{\mu\nu}(x)$ (1)

where $g\equiv-{\rm det}(g_{\alpha\beta})>0$. ${\cal L}$ transforms as a
scalar density under general coordinate transformations (i.e. ${\cal
L}/\sqrt{g}$ is a coordinate scalar) and is gauge invariant except for a
gauge-fixing term. $T_{\mu\nu}$ transforms as a tensor under general
coordinate transformations, is symmetric in $\mu\nu$, and is BRST invariant
Becchi ; Tyutin . It is the source of the gravitational field in the Einstein
field equations. The covariant divergence of the mixed tensor is

$(T^{\mu}_{\;\;\nu})_{;\mu}={1\over\sqrt{g}}\partial_{\mu}(\sqrt{g}\,T^{\mu}_{\;\;\nu})-{1\over
2}(\partial_{\nu}g_{\alpha\beta})T^{\alpha\beta}.$ (2)

If the fields that appear in ${\cal L}$ are required to satisfy the field
equations then $(T^{\mu}_{\;\;\nu})_{;\mu}=0$ (see Sec 94 of Landau  or Sec
12.3 of Weinberg1 ); but it is not a true conservation law because of the
second term in (2).

The so-called canonical energy-momentum tensor that results from Noether’s
first theorem Noether  applied to the invariance of ${\cal L}$ under global
spacetime translations is

$\sqrt{g}\;\Theta^{\mu}_{\;\;\nu}=\sum_{s}{\partial{\cal
L}\over\partial(\partial_{\mu}\chi_{s})}\partial_{\nu}\chi_{s}-\delta^{\mu}_{\;\nu}{\cal
L}$ (3)

where $\chi_{s}$ runs over all the fields: gauge bosons, ghosts, spin 1/2
fermions, and scalar bosons. Though $\Theta^{\mu}_{\;\;\nu}$ is not a
coordinate tensor it will be referred to as the canonical energy-momentum
tensor because when $g_{\alpha\beta}(x)$ is replaced by the Minkowski metric
$(\eta_{\alpha\beta})={\rm diag}(1,-1,-1,-1)$ the resulting quantity is a
Lorentz tensor.

For fields obeying Fermi statistics the ordering in (3) is not accurate. The
ghost fields $\eta_{a}$ and $\overline{\eta}_{a}$ are independent as are the
spin 1/2 fields $\psi$ and $\psi^{\dagger}$; the correct statement of the
first term in (3) is

${\partial{\cal
L}\over\partial(\partial_{\mu}\eta_{a})}\partial_{\nu}\eta_{a}+(\partial_{\nu}\overline{\eta}_{a}){\partial{\cal
L}\over\partial(\partial_{\mu}\overline{\eta}_{a})}$ (4)

for ghosts and

${\partial{\cal
L}\over\partial(\partial_{\mu}\psi)}\partial_{\nu}\psi+(\partial_{\nu}\psi^{\dagger}){\partial{\cal
L}\over\partial(\partial(\partial_{\mu}\psi^{\dagger})}$ (5)

for spin 1/2 fermions. This is rather cumbersome to repeatedly make explicit
and so the simpler form (3) will often be used.

####  $\Theta^{\mu}_{\;\;\nu}$ improvements in Minkowski spacetime:

The differences between $T^{\mu}_{\;\;\nu}$ and $\Theta^{\mu}_{\;\;\nu}$ when
$g_{\alpha\beta}(x)$ is replaced by the Minkowski metric was resolved for
electrodynamics by Belinfante and Rosenfeld Belinfante ; Rosenfeld . In modern
approaches Weinberg2 ; Munoz ; Saravi ; Pons ; Blaschke ; Ilin ; Freese  an
improved $\Theta^{\mu}_{\;\;\nu}$ is obtained by using both global translation
invariance and global Lorentz invariance or with Noether’s second theorem
using local translation invariance. This plus the field equations lead to an
improved Lorentz tensor that agrees with the Hilbert tensor in Minkowski
spacetime:

$T^{\mu\nu}=\Theta^{\mu\nu}+\partial_{\alpha}\Lambda^{\alpha\mu\nu},$ (6)

where the super-potential satisfies
$\Lambda^{\alpha\mu\nu}=-\Lambda^{\mu\alpha\nu}$. Two results follow from the
antisymmetry:

$\displaystyle T^{0\nu}$ $\displaystyle=$
$\displaystyle\Theta^{0\nu}\\!+\\!\partial_{j}\Lambda^{j0\nu}$ (7)
$\displaystyle\partial_{\mu}(T^{\mu\nu})$ $\displaystyle=$
$\displaystyle\partial_{\mu}(\Theta^{\mu\nu}).$ (8)

The first shows that

$\int d^{3}x\,T^{0\nu}=\int d^{3}x\;\Theta^{0\nu};$ (9)

the second shows that the integrals (9) are time-independent. Both require
imposing the field equations.

An interesting generalization is presented in Ref. Ilin . If ${\cal L}$
contains second derivatives or higher of the fields then
$\Lambda^{\alpha\mu\nu}$ is not antisymmetric in the first two indices;
nevertheless $\Lambda^{00\nu}$ is a spatial divergence which adds another term
to (7) so that (9) is still valid; and
$\partial_{\mu}\partial_{\alpha}\Lambda^{\alpha\mu\nu}=0$ so (8) holds which
makes (9) time independent.

#### Derivations of $T_{\mu\nu}$ for an arbitrary metric:

The Hilbert energy-momentum tensor can be derived in a more geometrical manner
using the spacetime diffeomorphism group Gotay  or fibre bundles Forger .
Though it is natural to expect that a canonical energy-momentum tensor
satisfying the requirements of gauge invariance, $\mu\nu$ symmetry, and
covariant conservation would necessarily be equal to the Hilbert tensor, Baker
treats an example of spin 2 fields, the linearized Gauss-Bonnet gravity model,
in which this is not true.

#### Static metric with field equations:

A static metric satisfies both $\partial_{0}g_{\alpha\beta}=0$ and $g_{0j}=0$.
The Schwarzschild and Reissner-Nordström metrics are of this type and the
geometry shares many features of Minkowski spacetime Sanchez ; Fulling ;
Derezinski . The vanishing of $g_{0j}$ means that Lagrangian terms like
$\sqrt{g}\,g^{\mu\nu}(\partial_{\mu}\phi)(\partial_{\nu}\phi)$, and analogous
terms for gauge bosons and spin 1/2 fermions, do not violate time-reversal
invariance; the field equations allow separation of variables (time vs three-
space); and the propagators are invariant under global time translation. If
the field equations are satisfied and the metric is static then
$\partial_{\mu}(\sqrt{g}\,\Theta^{\mu}_{\;\;0})=0$; thus the canonical
Hamiltonian is time-independent

${d\over dt}\int d^{3}x\sqrt{g}\,\Theta^{0}_{\;\;0}=0.$ (10)

Under the same conditions (static metric plus field equations) the Hilbert
tensor satisfies $\partial_{\mu}(\sqrt{g}\,T^{\mu}_{\;\;0})=0$ Landau ;
Weinberg1  and the Hilbert Hamiltonian is time-independent

${d\over dt}\int d^{3}x\sqrt{g}\,T^{0}_{\;\;0}=0.$ (11)

It is plausible, but not guaranteed, that the two Hamiltonians are equal; more
importantly, the argument gives no information about what happens when the
field equations are not satisfied, as is the case in the functional integral
formulation of field theory.

#### Outline:

This paper investigates what happens when the metric is static and only the
non-Abelian Gauss’s law is imposed but none of the other field equations. It
is assumed throughout that the field decrease at spatial infinity is
sufficiently rapid as to allow spatial integration by parts with no boundary
terms.

Section II introduces the Lagrangian density ${\cal L}$ for a general non-
Abelian gauge theory containing five parts: gauge bosons, gauge fixing,
ghosts, spin 1/2 fermions, and scalar bosons:

${\cal L}=\sum_{n=1}^{5}{\cal L}^{n}.$ (12)

The spin 1/2 fermions and the scalar bosons are in arbitrary representations
of the gauge group. The scalar bosons have Yukawa couplings to fermions and a
coupling $\xi R\phi_{i}^{2}$ to the Ricci scalar curvature. The variational
derivative of each action $\int d^{4}x\,{\cal L}^{n}$ gives the Hilbert
energy-momentum tensor $T_{\mu\nu}^{n}$, which is then evaluated for a static
metric. The value of $\sqrt{g}\,g^{00}T_{00}^{n}+{\cal L}^{n}$ is computed for
a static metric.

Section III employs Gauss’s law to obtain

$\int d^{3}x\sum_{n=1}^{5}\sqrt{g}\,g^{00}T_{00}^{n}=\int
d^{3}x\Big{[}\sum_{s}\Pi_{s}\partial_{0}\chi_{s}-\sum_{n=1}^{5}{\cal
L}^{n}\Big{]},$ (13)

which shows the equality of the Hilbert and the canonical Hamiltonians:

$\int d^{3}x\sqrt{g}\,g^{00}T_{00}=\int d^{3}x\sqrt{g}\,g^{00}\Theta_{00}.$
(14)

The dynamical Euler-Lagrange equations are not used. The integrals (14) could
be called proto-Hamiltonians since they are time-dependent.

At this point the equality of the two Hamiltonians could be a special feature
of non-Abelian gauge theories, particularly since the curvature appeared only
in the term $\xi R\phi_{i}^{2}$. To see if the Hamiltonian equality is more
general a term of the form

$\sqrt{g}\,R^{\mu\nu}(\partial_{\mu}\phi)(\partial_{\nu}\phi)$ (15)

is investigated. Explicit calculation shows that the Hilbert energy density
and the canonical energy density are very different but the Hamiltonians are
equal. This rather tedious calculation is contained in Appendix D.

Section IV derives the Hamiltonian equality (14) in a general manner in which
the details of the Lagrangian density are not specified except that it has
only first derivatives of the fields. The result is

$\partial_{\mu}(\sqrt{g}\,T^{\mu}_{\;\;0})=\partial_{\mu}(\sqrt{g}\,\Theta^{\mu}_{\;\;0})-\partial_{j}N^{j},$
(16)

using Gauss’s law but not the dynamical field equations. The spatial integral
is

${d\over dt}\int d^{3}x\sqrt{g}\,T^{0}_{\;\;0}={d\over dt}\int
d^{3}x\sqrt{g}\,\Theta^{0}_{\;\;0}.$ (17)

Since the fields have arbitrary time dependence the integrals must be equal,
which confirms (14) in the more general case.

##  II Explicit results for the Hilbert energy-momentum tensor

This section will compute $T_{\mu\nu}^{n}$ for $n=1,\dots 5$ for a general
time-dependent metric and then catalogue for a static metric the combination
$\sqrt{g}\,g^{00}T_{00}^{n}+{\cal L}^{n}$ for gauge bosons, ghosts, and spin
1/2 fermions ($n=1,3,4$) and the integrated form $\int
d^{3}x[\sqrt{g}\,g^{00}T_{00}^{n}+{\cal L}^{n}]$ for the gauge-fixing term and
scalar bosons ($n=2,5$).

###  II.1 Gauge bosons

#### Gauge bosons in a general metric:

The covariant field strength tensor

$F^{a}_{\mu\nu}=\partial_{\mu}A_{\nu}^{a}-\partial_{\nu}A_{\mu}^{a}-ef^{abc}A_{\mu}^{b}A_{\nu}^{c}$
(18)

is independent of the metric tensor. ($e$ will be used for the gauge coupling
since $g$ is reserved for the absolute value of the determinant of the
metric.). To make the metric dependence explicit ${\cal L}^{1}$ is written in
terms of the covariant field strengths

${\cal L}^{1}=-{\sqrt{g}\over
4}F_{\mu\alpha}^{a}F_{\nu\beta}^{a}g^{\mu\nu}g^{\alpha\beta}.$ (19)

The variational derivative of the action gives

$T_{\mu\nu}^{1}=-F_{\mu\alpha}^{a}F_{\nu\beta}^{a}g^{\alpha\beta}+{g_{\mu\nu}\over
4}F_{\kappa\alpha}^{a}F_{\lambda\beta}^{a}g^{\kappa\lambda}g^{\alpha\beta}.$
(20)

#### Gauge bosons with a static metric:

In this case

$g^{00}T_{00}^{1}=-{1\over 2}F^{0j}_{a}F^{a}_{0j}+{1\over
4}F_{jk}^{a}F_{a}^{jk},$ (21)

and therefore

$\sqrt{g}\,g^{00}\,T_{00}^{1}+{\cal L}^{1}=-\sqrt{g}\,F^{0j}_{a}F_{0j}^{a}.$
(22)

###  II.2 Gauge-fixing

#### Gauge-fixing with general metric:

The Lagrange density

$\displaystyle{\cal L}^{2}$ $\displaystyle=$ $\displaystyle{\lambda\over
2}\sqrt{g}\,[(A^{\mu}_{a})_{;\mu}]^{2}$ (23)
$\displaystyle(A^{\mu}_{a})_{;\mu}$ $\displaystyle=$
$\displaystyle{1\over\sqrt{g}}\partial_{\mu}(\sqrt{g}\,g^{\mu\nu}A_{\nu}^{a})$
(24)

results in BRST invariance Becchi ; Tyutin . Variation of the action with
respect to the metric gives for the energy-momentum tensor

$T_{\mu\nu}^{2}=\lambda\Big{[}-A_{\mu}^{a}\partial_{\nu}W_{a}-A_{\nu}^{a}\partial_{\mu}W_{a}+g_{\mu\nu}[{1\over
2}(W^{a})^{2}+A_{a}^{\beta}\partial_{\beta}W_{a}]\Big{]}.$ (25)

where for conciseness

$W_{a}\equiv(A^{\alpha}_{a})_{;\alpha}={1\over\sqrt{g}}\partial_{\alpha}[\sqrt{g}\,g^{\alpha\beta}A_{\beta}^{a}].$
(26)

#### Gauge-fixing with a static metric:

Equation (25) with $\mu=\nu=0$ leads to

$\displaystyle\hskip-28.45274pt\sqrt{g}g^{00}\,T_{00}^{2}+{\cal L}^{2}$ (27)
$\displaystyle=\lambda\sqrt{g}\,[-2A^{0}_{a}\;\partial_{0}W_{a}+(W_{a})^{2}+A^{\beta}_{a}\,\partial_{\beta}W_{a}].$

In the term $(W_{a})^{2}$ if one factor of $W_{a}$ is expressed in terms of
derivatives then a spatial integration by parts produces

$\displaystyle\hskip-14.22636pt\int d^{3}x[\sqrt{g}g^{00}\,T_{00}^{2}+{\cal
L}^{2}]$ (28) $\displaystyle=\lambda\int
d^{3}x\sqrt{g}\,[(\partial_{0}A^{0}_{a})W_{a}-A^{0}_{a}\,\partial_{0}W_{a}].$

###  II.3 Ghost fields

#### Ghosts with general time-dependent metric:

The Lagrangian density for the ghost fields is

${\cal
L}^{3}=\sqrt{g}\,g^{\mu\nu}(\partial_{\mu}\overline{\eta}_{a})(D_{\nu}\eta)_{a}$
(29)

where $\overline{\eta}_{a}$ and $\eta_{a}$ obey Fermi statistics, transform in
the adjoint representation, are not conjugates of each other, and

$(D_{\nu}\eta)_{a}=\partial_{\nu}\eta_{a}-ef_{abc}A^{b}_{\nu}\eta_{c}.$ (30)

Varying the action with respect to the metric gives

$\displaystyle T_{\mu\nu}^{3}$ $\displaystyle=$
$\displaystyle(\partial_{\mu}\overline{\eta}_{a})(D_{\nu}\eta)_{a}+(\partial_{\nu}\overline{\eta}_{a})(D_{\mu}\eta)_{a}$
(31) $\displaystyle-
g_{\mu\nu}\,g^{\alpha\beta}(\partial_{\alpha}\overline{\eta}_{a})(D_{\beta}\eta)_{a}.$

#### Ghosts with static metric:

Equation (31) becomes

$g^{00}\,T_{00}^{3}=g^{00}(\partial_{0}\overline{\eta}_{a})(D_{0}\eta)_{a}-g^{jk}(\partial_{j}\overline{\eta}_{a})(D_{k}\eta)_{a}$
(32)

which leads to

$\sqrt{g}\,g^{00}\,T_{00}^{3}+{\cal
L}^{3}=2\sqrt{g}\,g^{00}(\partial_{0}\overline{\eta}_{a})(D_{0}\eta)_{a}.$
(33)

###  II.4 Spin $1/2$ fermions

#### Fermions with general metric:

The Lagrangian density for fermions

$\displaystyle{\cal L}^{4}$ $\displaystyle=$
$\displaystyle\sqrt{g}\Big{\\{}{i\over
2}\psi^{\dagger}h\gamma^{\mu}\nabla_{\mu}\psi-{i\over
2}(\nabla_{\mu}\psi)^{\dagger}h\gamma^{\mu}\psi$ (34) $\displaystyle-$
$\displaystyle\psi^{\dagger}h(m_{f}+Y_{i}\phi_{i})\psi\Big{\\}}$

requires some explanation. First, $m_{f}$ is a Hermitian mass matrix; $Y_{i}$
are Hermitian Yukawa couplings to the real scalar fields that are discussed in
Sec. II.5. The spacetime dependent Dirac matrices satisfy

$\displaystyle\big{\\{}\gamma^{\mu},\gamma^{\nu}\\}=2g^{\mu\nu}I$
$\displaystyle(\gamma^{\mu})^{\dagger}=h\gamma^{\mu}h^{-1}$ (35)

where $h^{\dagger}=h$ is the spin metric AW1 . The spacetime independent Dirac
matrices satisfy

$\big{\\{}\gamma^{(\alpha)},\gamma^{(\beta)}\big{\\}}=2\eta^{\alpha\beta}I.$
(36)

The spacetime dependence of the $\gamma^{\mu}$ is carried by vierbeins,
$\gamma^{\mu}=e^{\mu}_{(\alpha)}\gamma^{(\alpha)}$ where
$\eta^{\alpha\beta}e^{\mu}_{(\alpha)}e^{\nu}_{(\beta)}=g^{\mu\nu}$ and
$g_{\mu\nu}e^{\mu}_{(\alpha)}e^{\nu}_{(\beta)}=\eta_{\alpha\beta}$. The spin
metric $h=\gamma^{(0)}$ is not a function of spacetime nor is the matrix
$\gamma^{5}$:

$\gamma^{5}=-i\sqrt{g}\,\epsilon_{\alpha\beta\mu\nu}\gamma^{\alpha}\gamma^{\beta}\gamma^{\mu}\gamma^{\nu}/4!\,.$
(37)

Consequently $\nabla_{\mu}\gamma^{5}=0$ and no additional effort is required
if $\psi_{L}$ and $\psi_{R}$ are in different representations of the gauge
group.

The covariant derivative of the fermion field is

$\nabla_{\mu}\psi=\partial_{\mu}\psi+\Gamma_{\mu}\psi-ieA_{\mu}^{a}T^{a}\psi$
(38)

where the spin connection is

$\Gamma_{\mu}={1\over
8}e^{(\alpha)}_{\rho}\Big{(}\partial_{\mu}e^{\rho}_{(\beta)}+\Gamma^{\rho}_{\mu\lambda}e^{\lambda}_{(\beta)}\Big{)}\big{[}\gamma_{(\alpha)},\gamma^{(\beta)}\big{]}.$
(39)

The detailed calculation of $T_{\mu\nu}^{4}$ is presented in Appendix B with
the result

$\displaystyle T_{\mu\nu}^{4}$ $\displaystyle=$ $\displaystyle{i\over
4}\Big{(}\psi^{\dagger}h\gamma_{\mu}\nabla_{\nu}\psi+\psi^{\dagger}h\gamma_{\nu}\nabla_{\mu}\psi\Big{)}$
$\displaystyle-$ $\displaystyle{i\over
4}\Big{(}(\nabla_{\nu}\psi)^{\dagger}h\gamma_{\mu}\psi+(\nabla_{\mu}\psi)^{\dagger}h\gamma_{\nu}\psi\Big{)}$
$\displaystyle-$ $\displaystyle g_{\mu\nu}\,{\cal L}^{4}/\sqrt{g}\,.$

#### Fermions with static metric:

For a static metric (II.4) immediately gives

$\sqrt{g}\,g^{00}\,T_{00}^{4}+{\cal L}^{4}=\sqrt{g}{i\over
2}\Big{[}\psi^{\dagger}h\gamma^{0}\nabla_{0}\psi-(\nabla_{0}\psi)^{\dagger}h\gamma^{0}\psi\Big{]}.$
(41)

For the static metric $e_{0}^{(0)}=\sqrt{g_{00}}$ and $e_{0}^{(j)}=0$; the
spin connection $\Gamma_{0}$ simplifies to

$\Gamma_{0}={1\over 8}(\partial_{j}g_{00})[\gamma^{0},\gamma^{j}].$ (42)

This satisfies $(\Gamma_{0})^{\dagger}=-h\Gamma_{0}h^{-1}$. The combination
that appears in (41) is

$h\gamma^{0}\Gamma_{0}-\Gamma_{0}^{\dagger}h\gamma^{0}=h\\{\gamma^{0},\Gamma_{0}\\}=0.$
(43)

Thus $\nabla_{0}\psi$ in (41) can be replaced by

$D_{0}\psi=\partial_{0}\psi-ieA_{0}^{a}T^{a}\psi$ (44)

so that

$\sqrt{g}\,g^{00}\,T_{00}^{4}+{\cal L}^{4}=\sqrt{g}{i\over
2}\Big{[}\psi^{\dagger}h\gamma^{0}D_{0}\psi-(D_{0}\psi)^{\dagger}h\gamma^{0}\psi\Big{]}$
(45)

###  II.5 Scalar bosons

#### Scalars with general metric:

For a set of real scalar fields $\phi_{i}$ the Lagrangian density is

${\cal L}^{5}=\sqrt{g}\Big{[}{g^{\mu\nu}\over
2}(D_{\mu}\phi)_{i}(D_{\nu}\phi)_{i}-U(\phi)-{1\over 2}\xi
R\phi_{i}^{2}\Big{]},$ (46)

where the gauge covariant derivative is

$(D_{\mu}\phi)_{i}=\partial_{\mu}\phi_{i}-ieA_{\mu}^{a}(t^{a})_{ij}\phi_{j}$
(47)

with $t^{a}$ imaginary and antisymmetric, $U(\phi)$ is a polynomial in the
fields invariant under local gauge transformations, $R$ is the Ricci scalar,
and $\xi$ is an arbitrary parameter.

The presence of the Ricci scalar $R$ causes some complications in varying the
action with respect to the metric tensor. It is convenient to separate the
calculation into two parts:

$\delta\int d^{4}x\,{\cal L}^{5}={1\over 2}\int
d^{4}x\sqrt{g}\,\big{[}\,T_{\mu\nu}^{5A}\delta g^{\mu\nu}-\xi(\delta
R)\phi_{i}^{2}\big{]},$ (48)

where $T^{5A}_{\mu\nu}$ results from varying everything except $R$:

$\displaystyle T_{\mu\nu}^{5A}$ $\displaystyle=$
$\displaystyle(D_{\mu}\phi)_{i}(D_{\nu}\phi)_{i}$
$\displaystyle\hskip-28.45274pt-g_{\mu\nu}\Big{[}{1\over
2}g^{\alpha\beta}(D_{\alpha}\phi)_{i}(D_{\beta}\phi)_{i}-U(\phi)-{1\over 2}\xi
R\phi_{i}^{2}\Big{]}.$

The variation of $R$ required in (48) is available in Sec 10.9 of Weinberg1 :

$\delta R=R_{\mu\nu}\delta g^{\mu\nu}-(\delta
g^{\mu\nu})_{;\mu;\nu}+g_{\mu\nu}(\delta g^{\mu\nu})^{;\rho}_{\;\;;\rho}.$
(50)

The result of the variation is

$-{1\over 2}\xi\int d^{4}x\sqrt{g}\,(\delta R)\phi_{i}^{2}={1\over 2}\int
d^{4}x\sqrt{g}\,T_{\mu\nu}^{5B}\,\delta g^{\mu\nu},$ (51)

where

$T_{\mu\nu}^{5B}=\xi\Big{[}-R_{\mu\nu}\phi_{i}^{2}+(\phi_{i}^{2})_{;\mu;\nu}-g_{\mu\nu}(\phi_{i}^{2})^{;\rho}_{\;\;;\rho}\Big{]}.$
(52)

In summary

${\delta\over\delta g^{\mu\nu}}\int d^{4}x\,{\cal L}^{5}={1\over
2}\sqrt{g}\Big{[}T_{\mu\nu}^{5A}+T_{\mu\nu}^{5B}\Big{]}$ (53)

#### Comment:

$T_{\mu\nu}^{5B}$ has the property that its covariant divergence is

$(g^{\mu\lambda}T^{5B}_{\lambda\nu})_{;\mu}=-{1\over
2}\xi(\partial_{\nu}R)\phi_{i}^{2}$ (54)

with no derivatives of the fields.

#### Scalars with static metric:

Eq. (II.5) with $\mu=\nu=0$ and a static metric gives

$\sqrt{g}\,g^{00}\,T_{00}^{5A}+{\cal
L}^{5}=\sqrt{g}\,g^{00}\,(D_{0}\phi)_{i}(D_{0}\phi)_{i}.$ (55)

For a static metric (54) is a true conservation law,
$\partial_{\mu}[\sqrt{g}\,g^{00}T^{5B}_{00}]=0$ and so

${d\over dt}\int d^{3}x\sqrt{g}\,g^{00}\,T_{00}^{5B}=0.$ (56)

Since the spatial integral is constant and the fields have arbitrary spacetime
dependence, it is natural to expect that the integral is zero. Appendix C
confirms this:

$\int d^{3}x\sqrt{g}\,g^{00}T_{00}^{5B}=0.$ (57)

This and (55) may be summarized as

$\displaystyle\int d^{3}x[\sqrt{g}\,g^{00}\,(T_{00}^{5A}+T_{00}^{5B})+{\cal
L}^{5}]$ (58) $\displaystyle\hskip 56.9055pt=\int
d^{3}x\sqrt{g}\,g^{00}\,(D_{0}\phi)_{i}(D_{0}\phi)_{i}.$

Comment: $T_{\mu\nu}^{1},T_{\mu\nu}^{3},T_{\mu\nu}^{4},T_{\mu\nu}^{5}$ all
agree with Table 1 of Forger , which does not include gauge fixing.

##  III Equality of $\int d^{3}x\,\sqrt{g}\,g^{00}\,T_{00}$ and the canonical
Hamiltonian

The results of the previous five subsections will now be combined. All
equations assume a static metric but allow arbitrary spacetime dependence of
the fields.

###  III.1 Assembly of the results

The spatial integral of (22), (33), and (45) when added to the integrated
results (28) and (58) give

$\int d^{3}x[\sqrt{g}\,g^{00}\,T_{00}+{\cal L}]=\int
d^{3}x\sqrt{g}\,[\Omega_{1}+\Omega_{2}],$ (59)

where $\Omega_{1}$ comes from the gauge boson ${\cal L}^{1}$ and $\Omega_{2}$
from the gauge fixing, ghosts, spin 1/2 fermions, and scalars:

$\displaystyle\Omega_{1}$ $\displaystyle=$
$\displaystyle-F^{0j}_{a}F^{a}_{0j}$ $\displaystyle\Omega_{2}$
$\displaystyle=$ $\displaystyle
g^{00}\big{[}\lambda(\partial_{0}A_{0}^{a})W_{a}\\!-\\!\lambda
A_{0}^{a}(\partial_{0}W_{a})+2(\partial_{0}\overline{\eta}_{a})(D_{0}\eta)_{a}$
$\displaystyle+$ $\displaystyle{i\over
2}\big{(}\psi^{\dagger}h\gamma_{0}D_{0}\psi-(D_{0}\psi)^{\dagger}h\gamma_{0}\psi\big{)}$
$\displaystyle+$ $\displaystyle(D_{0}\phi)_{i}(D_{0}\phi)_{i}\big{]}$

A more explicit expression of $\Omega_{1}$ is

$\sqrt{g}\,\Omega_{1}=\sqrt{g}[-F^{0j}_{a}\partial_{0}A_{j}^{a}+F^{0j}_{a}(D_{j}A_{0})^{a}].$
(61)

The spatial integral, after an integration by parts, is

$\int d^{3}x\sqrt{g}\,\Omega_{1}=\\!-\\!\int
d^{3}x[\sqrt{g}\,F^{0j}_{a}\partial_{0}A_{j}^{a}+[D_{j}(\sqrt{g}\,F^{0j})]_{a}A_{0}^{a}].$
(62)

Gauss’ law requires $[D_{j}(\sqrt{g}\,F^{0j})]_{a}=\sqrt{g}\,J^{0}_{a}$ where

$\sqrt{g}\,J^{0}_{a}=-\lambda\sqrt{g}\,g^{00}\partial_{0}W_{a}+\sum_{n=3}^{5}{\partial{\cal
L}^{n}\over\partial A_{0}^{a}}$ (63)

and therefore

$\int d^{3}x\sqrt{g}\,\Omega_{1}=-\int
d^{3}x\sqrt{g}\,[F^{0j}_{a}\partial_{0}A_{j}^{a}+J^{0}_{a}A_{0}^{a}].$ (64)

The charge density is

$\displaystyle J^{0}_{a}$ $\displaystyle=$ $\displaystyle
g^{00}[-\lambda\,\partial_{0}W_{a}+e(\partial_{0}\overline{\eta}_{b})f_{abc}\eta_{c}$
$\displaystyle+$ $\displaystyle e\psi^{\dagger}h\gamma_{0}T^{a}\psi-
ie(D_{0}\phi)_{i}t^{a}_{ij}\phi_{j}].$

Using $J^{0}_{a}$ in (64) and adding this to the spatial integral of
$\sqrt{g}\,\Omega_{2}$ produces cancellations of some of the $A_{0}^{a}$
dependence and results in

$\displaystyle\hskip-14.22636pt\int d^{3}x[\sqrt{g}\,T^{0}_{\;\;0}+{\cal
L}]=\int d^{3}x\sqrt{g}\Big{\\{}\\!-\\!F^{0j}_{a}\partial_{0}A_{j}^{a}$
$\displaystyle+g^{00}[\lambda(\partial_{0}A_{0}^{a})W^{a}+(\partial_{0}\overline{\eta}_{a})(\partial_{0}\eta_{a})+(\partial_{0}\overline{\eta}_{a})(D_{0}\eta)_{a}$
$\displaystyle+{i\over
2}\big{(}\psi^{\dagger}h\gamma_{0}\partial_{0}\psi-(\partial_{0}\psi)^{\dagger}h\gamma_{0}\psi\big{)}$
(66) $\displaystyle+(D_{0}\phi)_{i}(\partial_{0}\phi_{i})\Big{\\}}.$

###  III.2 Canonical momenta

There are seven canonical momenta

$\displaystyle\pi^{j}_{a}$ $\displaystyle=$ $\displaystyle{\partial{\cal
L}\over\partial(\partial_{0}A_{j}^{a})}=\sqrt{g}\,F^{j0}$
$\displaystyle\pi_{a}^{0}$ $\displaystyle=$ $\displaystyle{\partial{\cal
L}\over\partial(\partial_{0}A_{0}^{a})}=\lambda\sqrt{g}\,g^{00}\,W_{a}$
$\displaystyle p_{a}$ $\displaystyle=$ $\displaystyle{\partial{\cal
L}\over\partial(\partial_{0}\eta_{a})}=\sqrt{g}\,g^{00}\,\partial_{0}\overline{\eta}_{a}$
$\displaystyle\overline{p}_{a}$ $\displaystyle=$ $\displaystyle{\partial{\cal
L}\over\partial(\partial_{0}\overline{\eta}_{a})}=\sqrt{g}\,g^{00}\,(D_{0}\eta)_{a}$
(67) $\displaystyle\pi_{\psi}$ $\displaystyle=$ $\displaystyle{\partial{\cal
L}\over\partial(\partial_{0}\psi)}=i{\sqrt{g}\over
2}\psi^{\dagger}h\gamma^{0}$ $\displaystyle\pi_{\psi^{\dagger}}$
$\displaystyle=$ $\displaystyle{\partial{\cal
L}\over\partial(\partial_{0}\psi^{\dagger})}=-i{\sqrt{g}\over
2}h\gamma^{0}\psi$ $\displaystyle\pi^{\phi}_{i}$ $\displaystyle=$
$\displaystyle{\partial{\cal
L}\over\partial(\partial_{0}\phi_{i})}=\sqrt{g}\,g^{00}\,(D_{0}\phi)_{i}\,.$

The rather cumbersome equation (66) is more recognizable when expressed in
terms of the canonical momenta:

$\displaystyle\hskip-14.22636pt\int d^{3}x[\sqrt{g}\,T^{0}_{\;\;0}+{\cal
L}]=\int
d^{3}x\Big{\\{}\pi^{j}_{a}\,\partial_{0}A_{j}^{a}+\pi_{a}^{0}\,\partial_{0}A_{0}^{a}$
$\displaystyle\hskip
42.67912pt+p_{a}\partial_{0}\eta_{a}+(\partial_{0}\overline{\eta}_{a})\overline{p}_{a}$
$\displaystyle\hskip
42.67912pt+\pi_{\psi}\partial_{0}\psi+(\partial_{0}\psi^{\dagger})\pi_{\psi^{\dagger}}+\pi^{\phi}_{i}\partial_{0}\phi_{i}\Big{\\}}.$
(68)

Of the seven terms involving the canonical momenta the fourth and the sixth
have the canonical momenta on the right, as they should be. Eq. (68) may be
summarized as

$\int d^{3}x\sqrt{g}\,T^{0}_{\;\;0}=\int
d^{3}x\bigg{[}\sum_{s}\Pi_{s}\partial_{0}\chi_{s}-{\cal L}\bigg{]}.$ (69)

The right hand side is the Legendre transform of the $\partial_{0}\chi_{s}$
dependence of the Lagrangian to the $\Pi_{s}$ dependence of the canonical
Hamiltonian. This proves the equality

$\int d^{3}x\sqrt{g}\,T^{0}_{\;\;0}=\int d^{3}x\sqrt{g}\,\Theta^{0}_{\;\;0}$
(70)

using Gauss’s law but not the dynamical Euler-Lagrange equations.

It is perhaps worth noting that the constraint
$[D_{j}(\sqrt{g}\,F^{0j}]_{a}=\sqrt{g}J^{0}_{a}$ may be written in terms of
the canonical momenta

$\displaystyle[D_{j}\pi^{j}]_{a}$ $\displaystyle=$
$\displaystyle\pi^{0}_{a}\,\partial_{0}W_{a}+ef_{abc}p_{b}\eta_{c}$ (71)
$\displaystyle-$ $\displaystyle ie\pi_{\psi}T^{a}\psi-
ie\,\pi_{i}^{\phi}t^{a}_{ij}\phi_{j}$

and this relation is independent of the metric.

As mentioned in the Introduction, Appendix D contains another test of the
equality with a Lagrangian density that contains the Ricci tensor
$R^{\mu\nu}$.

##  IV General argument

This section investigates a more general context in which the form of the
Lagrangian density is not specified, except that it has only first derivatives
of the fields. The equality of the two Hamiltonians for a static background
metric is again demonstrated.

#### Divergence of the canonical EMT:

The divergence of the canonical tensor (3) is

$\partial_{\mu}\big{(}\sqrt{g}\,\Theta^{\mu}_{\;\;\nu}\big{)}=\sum_{s}\partial_{\mu}\Big{[}{\partial{\cal
L}\over\partial(\partial_{\mu}\chi_{s})}\partial_{\nu}\chi_{s}\Big{]}-\partial_{\nu}{\cal
L}.$ (72)

The spacetime dependence of ${\cal L}$ occurs in both the fields and the
metric:

$\partial_{\nu}{\cal L}=\sum_{s}\Big{[}{\partial{\cal
L}\over\partial\chi_{s}}(\partial_{\nu}\chi_{s})+{\partial{\cal
L}\over\partial(\partial_{\mu}\chi_{s})}\partial_{\mu}\partial_{\nu}\chi_{s}\Big{]}-\partial_{\nu}{\cal
L}\big{|}_{\chi}.$ (73)

The last term requires differentiating the spacetime dependence of the metric
while keeping all the fields $\chi_{s}$ fixed. Substitution above gives

$\displaystyle\partial_{\mu}\big{(}\sqrt{g}\,\Theta^{\mu}_{\;\;\nu}\big{)}$
$\displaystyle=$ $\displaystyle\sum_{s}{\cal
M}_{s}(\partial_{\nu}\chi_{s})-\partial_{\nu}{\cal L}\big{|}_{\chi}$ (74)
$\displaystyle{\cal M}_{s}$ $\displaystyle\equiv$
$\displaystyle\partial_{\mu}\Big{(}{\partial{\cal
L}\over\partial(\partial_{\mu}\chi_{s})}\Big{)}-{\partial{\cal
L}\over\partial\chi_{s}}.$ (75)

${\cal M}_{s}$ vanishes if the Euler-Lagrange equations are imposed but even
then $\partial_{\mu}(\sqrt{g}\,\Theta^{\mu}_{\;\;\nu})\neq 0$ for a general
metric.

#### Divergence of the Hilbert EMT:

The covariant divergence of $T^{\mu}_{\;\;\nu}$ is computed from the fact that
the action is invariant under a coordinate transformation $x^{\nu}\to
x^{\prime\nu}$; see Sec 94 of Landau  or Sec 12.3 of Weinberg1 . The metric
and the fields (scalar, ghost, spin 1/2 fermion, and gauge) transform as
follows:

$\displaystyle g^{\prime}_{\mu\nu}(x^{\prime})$ $\displaystyle=$
$\displaystyle{\partial x^{\alpha}\over\partial x^{\prime\mu}}{\partial
x^{\beta}\over\partial x^{\prime\nu}}\,g_{\alpha\beta}(x)$ (76)
$\displaystyle\phi_{i}^{\prime}(x^{\prime})$ $\displaystyle=$
$\displaystyle\phi_{i}(x)$ $\displaystyle\eta_{a}^{\prime}(x^{\prime})$
$\displaystyle=$ $\displaystyle\eta_{a}(x)$
$\displaystyle\psi^{\prime}(x^{\prime})$ $\displaystyle=$
$\displaystyle\psi(x)$ (77) $\displaystyle A_{\alpha}^{\prime a}(x^{\prime})$
$\displaystyle=$ $\displaystyle{\partial x^{\lambda}\over\partial
x^{\prime\alpha}}\,A_{\lambda}^{a}(x).$

(The covariant vierbein transforms the same as the covariant gauge field but
it will not be needed.) Invariance of the action means that

$\int d^{4}x^{\prime}\,{\cal
L}(g_{\mu\nu}^{\prime}(x^{\prime}),\chi^{\prime}(x^{\prime}))=\int
d^{4}x\,{\cal L}(g_{\mu\nu}(x),\chi(x)).$

Relabeling of the integration variable gives

$\int d^{4}x\,{\cal L}(g_{\mu\nu}^{\prime}(x),\chi^{\prime}(x))=\int
d^{4}x\,{\cal L}(g_{\mu\nu}(x),\chi(x)).$

The action is invariant under a change in the functional form of the metric
and the fields at the same position $x$:

$\displaystyle\Delta g_{\mu\nu}(x)$ $\displaystyle\equiv$ $\displaystyle
g^{\prime}_{\mu\nu}(x)-g_{\mu\nu}(x)$ (78) $\displaystyle\Delta\chi_{s}(x)$
$\displaystyle\equiv$ $\displaystyle\chi^{\prime}_{s}(x)-\chi_{s}(x).$ (79)

Let

$x^{\prime\nu}=x^{\nu}+\xi^{\nu}(x)$ (80)

where $\xi^{\nu}(x)$ is an arbitrary, infinitesimal function. The change in
the metric is

$\Delta g_{\mu\nu}=-(\xi_{\mu})_{;\nu}-(\xi_{\nu})_{;\mu}.$ (81)

For the scalars, ghosts, and spin 1/2 fermions

$\Delta\chi_{s}=-\xi^{\nu}\partial_{\nu}\chi_{s};$ (82)

for the vector potential there is an additional term

$\Delta
A_{\alpha}^{a}=-\xi^{\nu}\partial_{\nu}A_{\alpha}^{a}-(\partial_{\alpha}\xi^{\nu})A_{\nu}^{a}.$
(83)

Under these variations the action is invariant. The variation with respect to
covariant metric gives the contravariant energy-momentum tensor but with the
opposite sign from (1):

$\displaystyle 0\\!$ $\displaystyle=$ $\displaystyle\\!-\\!\int
d^{4}x{\sqrt{g}\over 2}\,T^{\mu\nu}\Delta g_{\mu\nu}+\sum_{s}\int
d^{4}x\,{\cal M}_{s}\,\xi^{\nu}\partial_{\nu}\chi_{s}$ (84)
$\displaystyle\hskip 56.9055pt+\int d^{4}x\,{\cal
M}^{\mu}_{a}(\partial_{\mu}\xi^{\nu})A_{\nu}^{a}.$

In the second term the sum on fields $s$ includes a term for the gauge
potential; in the third term the explicit form is

$\displaystyle{\cal M}_{a}^{\mu}=\partial_{\lambda}\Big{(}{\partial{\cal
L}\over\partial(\partial_{\lambda}A_{\mu}^{a})}\Big{)}-{\partial{\cal
L}\over\partial A_{\mu}^{a}}.$ (85)

An integration by parts in the first and third term yields

$\displaystyle\int d^{4}x\sqrt{g}\,(T^{\mu\nu})_{:\mu}\xi_{\nu}$
$\displaystyle=$ $\displaystyle\sum_{s}\int d^{4}x\,{\cal
M}_{s}\,\xi^{\nu}\partial_{\nu}\chi_{s}$ (86) $\displaystyle-$
$\displaystyle\int d^{4}x\,\partial_{\mu}({\cal
M}_{a}^{\mu}A_{\nu}^{a})\xi^{\nu}.$

Since $\xi^{\nu}(x)$ is an arbitrary function, the integrands must be equal:

$\sqrt{g}\,(T^{\mu}_{\;\;\nu})_{;\mu}=\sum_{s}{\cal
M}_{s}(\partial_{\nu}\chi_{s})-\partial_{\mu}({\cal M}_{a}^{\mu}A_{\nu}^{a}).$
(87)

The first term in (85) is $-\partial_{\mu}(\sqrt{g}\,F^{\mu\alpha})_{a}$ which
combines with $\partial{\cal L}^{1}/\partial A_{\alpha}^{a}$ to give the gauge
covariant derivative $-[D_{\mu}(\sqrt{g}\,F^{\mu\alpha})]_{a}$. The remaining
terms from the gauge fixing, ghosts, spin 1/2 fermions, and scalars define the
current density

$\sqrt{g}\,J^{\alpha}_{a}=-\lambda\partial_{\nu}(\sqrt{g}\,g^{\nu\alpha}W_{a})+\sum_{n=3}^{5}{\partial{\cal
L}^{n}\over\partial A_{\alpha}^{a}}$ (88)

and so

${\cal
M}_{a}^{\alpha}=[D_{\mu}(\sqrt{g}\,F^{\mu\alpha})]_{a}+\sqrt{g}\,J^{\alpha}_{a}.$
(89)

The constraint of Gauss’s law requires

${\cal M}^{0}_{a}=0.$ (90)

Therefore the last term in (87) is really only a spatial divergence
$\partial_{j}({\cal M}_{a}^{j}A_{\nu}^{a})$ though the form
$\partial_{\mu}(M^{\mu}_{a}A_{\nu}^{a})$ will at times be used below.

#### Comparison of divergences of the Hilbert EMT and the canonical EMT.

The terms of the form ${\cal M}_{s}(\partial_{\nu}\chi_{s})$ in (87) also
appear in the canonical divergence (74) and so (87) can be expressed as

$\displaystyle\partial_{\mu}(\sqrt{g}\,T^{\mu}_{\;\;\nu})-{\sqrt{g}\over
2}(\partial_{\nu}g_{\alpha\beta})T^{\alpha\beta}$ (91) $\displaystyle\hskip
42.67912pt=\partial_{\mu}(\sqrt{g}\,\Theta^{\mu}_{\;\;\nu})+\partial_{\nu}{\cal
L}\big{|}_{\chi}-\partial_{\mu}({\cal M}_{a}^{\mu}A_{\nu}^{a}).$

This holds for a general metric and arbitrary fields using Gauss’s law but not
the dynamical Euler-Lagrange equations.

For simplicity suppose ${\cal L}$ has only first and second derivatives of the
metric, as is the case for the general gauge theory in Secs. II and III. The
second and fourth terms of Eq. (91) require the derivatives

$\displaystyle\hskip-5.69046pt-{\sqrt{g}\over 2}T^{\alpha\beta}={\partial{\cal
L}\over\partial g_{\alpha\beta}}-\partial_{\mu}\bigg{[}{\partial{\cal
L}\over\partial
g_{\alpha\beta,\mu}}\bigg{]}+\partial_{\mu}\partial_{\rho}\bigg{[}{\partial{\cal
L}\over\partial g_{\alpha\beta,\mu\rho}}\bigg{]}$
$\displaystyle\hskip-5.69046pt\partial_{\nu}{\cal
L}\Big{|}_{\chi}={\partial{\cal L}\over\partial
g_{\alpha\beta}}g_{\alpha\beta,\nu}+{\partial{\cal L}\over\partial
g_{\alpha\beta,\mu}}g_{\alpha\beta,\nu\mu}+{\partial{\cal L}\over\partial
g_{\alpha\beta,\mu\rho}}g_{\alpha\beta,\nu\mu\rho}.$

The difference between these two is a total derivative; Eq. (91) becomes

$\partial_{\mu}(\sqrt{g}\,T^{\mu}_{\;\;\nu})=\partial_{\mu}(\sqrt{g}\,\Theta^{\mu}_{\;\;\nu})+\partial_{\mu}\Sigma^{\mu}_{\;\;\nu}-\partial_{\mu}(A_{\nu}^{a}{\cal
M}^{\mu}_{a})$ (92)

where

$\Sigma^{\mu}_{\;\;\nu}\equiv{\partial{\cal L}\over\partial
g_{\alpha\beta,\mu}}g_{\alpha\beta,\nu}\\!+\\!{\partial{\cal L}\over\partial
g_{\alpha\beta,\mu\rho}}g_{\alpha\beta,\nu\rho}\\!-\\!\partial_{\rho}\Big{(}{\partial{\cal
L}\over\partial g_{\alpha\beta,\mu\rho}}\Big{)}g_{\alpha\beta,\nu}.$

The derivatives of the metric are not tensors and so $\Sigma^{\mu}_{\;\;\nu}$
is not a tensor. (If ${\cal L}$ has any number of metric derivatives of the
metric the form (92) still holds but $\Sigma^{\mu}_{\;\;\nu}$ is more
complicated.) Because of Gauss’s law (90) the spatial integral of (92) is

${d\over dt}\int d^{3}x\sqrt{g}\,T^{0}_{\;\;\nu}={d\over dt}\int
d^{3}x\,\Big{[}\sqrt{g}\,\Theta^{0}_{\;\;\nu}+\Sigma^{0}_{\;\;\nu}\Big{]}.$
(93)

Since the time dependence of the fields and the metric is arbitrary the
integrals must be equal:

$\int d^{3}x\sqrt{g}\,T^{0}_{\;\;\nu}=\int
d^{3}x\Big{[}\sqrt{g}\,\Theta^{0}_{\;\;\nu}+\Sigma^{0}_{\;\;\nu}\Big{]}.$ (94)

#### Case 1: Minkowski metric.

If the metric is chosen to be $(\eta_{\alpha\beta})={\rm diag}(1,-1,-1,-1)$,
then $\Sigma^{\mu}_{\;\;\nu}=0$ in (94). The resulting equality holds for
arbitrary fields and thus is more general than the usual result (9).

#### Case 2: Arbitrary time-dependent metric but ${\cal L}$ has no derivatives
of the metric.

These conditions are satisfied by the gauge boson ${\cal L}^{1}$ and by the
scalar boson ${\cal L}^{5}$ if the $\xi R\phi_{i}^{2}$ term is omitted.
Obviously $\Sigma^{\mu}_{\;\;\nu}=0$.

#### Case 3: Static metric.

This includes the case of principle interest since ${\cal L}$ for a general
gauge theory contains first derivatives of the metric in the gauge-fixing term
and the spin connection $\Gamma_{\mu}$ for fermions, and second derivatives of
the metric in the $\xi R\phi_{i}^{2}$ term. For a static metric
$\Sigma^{0}_{\;\;0}=0$ and so

$\int d^{3}x\sqrt{g}\,T^{0}_{\;\;0}=\int d^{3}x\sqrt{g}\,\Theta^{0}_{\;\;0}.$
(95)

The dynamical field equations have not been used. This agrees with the
explicit calculations leading to (70) and explains the miraculous
cancellations for the example considered in Appendix D.

##  Appendix A Christoffel symbol and curvature tensor for static metric

A static metric is time-independent and $g_{0j}=0$. Christoffel symbols with
an odd number of time components vanish:

$\Gamma_{00}^{0}=\Gamma_{k0}^{j}=\Gamma_{k\ell}^{0}=0.$ (96)

The Christoffel symbols with two 0’s are

$\displaystyle\Gamma^{j}_{00}$ $\displaystyle=$ $\displaystyle-{1\over
2}g^{jk}\partial_{k}g_{00}$ (97) $\displaystyle\Gamma^{0}_{k0}$
$\displaystyle=$ $\displaystyle{1\over 2}g^{00}\partial_{k}g_{00}.$ (98)

$\Gamma^{j}_{k\ell}$ is non-vanishing and independent of $g_{00}$. Two useful
contractions are

$\displaystyle\Gamma^{j}_{jk}$ $\displaystyle=$
$\displaystyle{1\over\sqrt{\gamma}}\partial_{k}\sqrt{\gamma}$ (99)
$\displaystyle g^{jk}\Gamma^{\ell}_{jk}$ $\displaystyle=$
$\displaystyle-{1\over\sqrt{\gamma}}\partial_{j}(\sqrt{\gamma}\,g^{j\ell})$
(100)

where $|{\rm det}(g_{\alpha\beta})|=g_{00}\,\gamma$. The Riemann-Christoffel
tensor with four spatial components is independent of $g_{00}$:
${}^{(4)}R_{ijk\ell}=\,^{(3)}R_{ijk\ell}$. If there is one time component
$R_{0jk\ell}=0.$ If there are two time components

$R_{0j0k}=-{1\over 2}\partial_{j}\partial_{k}g_{00}+{1\over
2}\Gamma^{\ell}_{jk}\partial_{\ell}g_{00}+{1\over
4}{(\partial_{j}g_{00})(\partial_{k}g_{00})\over g_{00}}.$ (101)

The Ricci tensor with two spatial indices is

${}^{(4)}R_{jk}=g^{00}R_{0j0k}+\,^{(3)}R_{jk}$ (102)

where $g^{ab}R_{ajbk}=\,^{(3)}R_{jk}$ is independent of $g_{00}$; if there are
two time indices

${}^{(4)}R_{00}$ $\displaystyle=$ $\displaystyle g^{jk}R_{0j0k}$ (103)
$\displaystyle=$ $\displaystyle-{g_{00}\over
2\sqrt{g}}\partial_{j}\Big{[}\sqrt{g}\,g^{jk}{\partial_{k}g_{00}\over
g_{00}}\Big{]};$

and if one time index ${}^{(4)}R_{0k}=0$. The Ricci scalar is

${}^{(4)}R=2g^{00}g^{jk}R_{0j0k}+\,^{(3)}R$ (104)

##  Appendix B Calculation of $T_{\mu\nu}^{4}$ for fermions with arbitrary
time-dependent metric

This appendix contains the detailed calculation of $T_{\mu\nu}^{4}$ displayed
in Eq. (II.4). The fermion field $\psi$ is not required to satisfy the Dirac
equation.

The Lagrangian density (34) may be written

$\displaystyle{\cal L}^{4}$ $\displaystyle=$ $\displaystyle\sqrt{g}{1\over
2}\Big{[}\psi^{\dagger}(K\psi)+(K\psi)^{\dagger}\psi\Big{]}$ (105)
$\displaystyle K$ $\displaystyle=$ $\displaystyle
ih\gamma^{\mu}\nabla_{\mu}-h(m_{f}+Y_{i}\phi_{i}).$

The variation of ${\cal L}^{4}$ with respect to the metric is

$\displaystyle\delta{\cal L}^{4}$ $\displaystyle=$ $\displaystyle-\;{1\over
2}g_{\mu\nu}\,\delta g^{\mu\nu}\,{\cal L}^{4}$ $\displaystyle+$
$\displaystyle{1\over 2}\sqrt{g}\Big{[}\psi^{\dagger}(\delta K\psi)+(\delta
K\psi)^{\dagger}\psi\Big{]}.$

In AW1  the variations are shown to be

$\displaystyle\delta K$ $\displaystyle=$ $\displaystyle{i\over 2}(\delta
g^{\mu\nu})h\gamma_{\mu}\nabla_{\nu}+(\delta G)K+K(\delta G)+\delta X$
$\displaystyle\delta G$ $\displaystyle=$ $\displaystyle{1\over
8}\eta^{\alpha\beta}e_{(\alpha)}^{\lambda}[\gamma_{\lambda},\gamma_{\nu}]\,\delta
e_{(\beta)}^{\nu}$ (107) $\displaystyle\delta X$ $\displaystyle=$
$\displaystyle{i\over
8}(\delta\Gamma_{\lambda\nu}^{\mu})h\gamma^{\lambda}[\gamma_{\mu},\gamma^{\nu}].$

Because $(\delta X)^{\dagger}=-\delta X$ it disappears from (B) and so

$\displaystyle\delta{\cal L}^{4}$ $\displaystyle=$ $\displaystyle-{1\over
2}g_{\mu\nu}\,{\cal L}^{4}\,\delta g^{\mu\nu}$ (108)
$\displaystyle\hskip-28.45274pt+{i\over
4}\sqrt{g}\Big{[}\psi^{\dagger}h\gamma_{\mu}\nabla_{\nu}\psi-(\nabla_{\nu}\psi)^{\dagger}h\gamma_{\mu}\psi\Big{]}\delta
g^{\mu\nu}$ $\displaystyle+$ $\displaystyle{1\over
2}\Big{[}\Delta_{1}+\Delta_{2}\Big{]}$ $\displaystyle\Delta_{1}$
$\displaystyle\equiv$ $\displaystyle\sqrt{g}\Big{[}\psi^{\dagger}(\delta
GK\psi)+(\delta GK\psi)^{\dagger}\psi\Big{]}$ $\displaystyle\Delta_{2}$
$\displaystyle\equiv$ $\displaystyle\sqrt{g}\Big{[}\psi^{\dagger}(K\delta
G\psi)+(K\delta G\psi)^{\dagger}\psi\Big{]}.$

$\Delta_{2}$ contains derivatives of the vierbein because of $K\delta G$. To
simplify $\Delta_{2}$ the following identity valid for arbitrary spinor fields
$\psi_{1}$ and $\psi_{2}$, is useful

$\sqrt{g}\,\psi_{1}^{\dagger}(K\psi_{2})-\sqrt{g}(K\psi_{1})^{\dagger}\psi_{2}=-\partial_{\lambda}(\sqrt{g}\,\psi_{1}^{\dagger}h\gamma^{\lambda}\psi_{2}).$
(109)

For the first term in $\Delta_{2}$ take $\psi_{1}=\psi$ and $\psi_{2}=\delta
G\psi$; for the second term in $\Delta_{2}$ take $\psi_{1}=K\delta G\psi$ and
$\psi_{2}=\psi$: the result is

$\Delta_{2}=\Delta_{1}+i\partial_{\lambda}\Big{[}\sqrt{g}\,\psi^{\dagger}h\gamma^{\lambda}\delta
G\psi-\sqrt{g}(\delta G\psi)^{\dagger}h\gamma^{\lambda}\psi\Big{]}.$ (110)

Since $(\delta G)^{\dagger}=-h(\delta G)h^{-1}$ this is

$\Delta_{2}=\Delta_{1}+i\partial_{\lambda}\Big{[}\sqrt{g}\,\psi^{\dagger}h\\{\gamma^{\lambda},\delta
G\\}\psi\Big{]}.$ (111)

The variation of ${\cal L}^{4}$ becomes

$\displaystyle\delta{\cal L}^{4}$ $\displaystyle=$ $\displaystyle-{1\over
2}g_{\mu\nu}\delta g^{\mu\nu}{\cal L}^{4}$ $\displaystyle+$ $\displaystyle
i{\sqrt{g}\over
4}\big{[}\psi^{\dagger}h\gamma_{\mu}\nabla_{\nu}\psi-(\nabla_{\nu}\psi)^{\dagger}h\gamma_{\mu}\psi\big{]}\delta
g^{\mu\nu}$ $\displaystyle+$
$\displaystyle\sqrt{g}\Big{[}\psi^{\dagger}(\delta
G)K\psi+(K\psi)^{\dagger}(\delta G)^{\dagger}\psi\big{]}$ $\displaystyle+$
$\displaystyle
i\partial_{\lambda}\Big{[}\sqrt{g}\,\psi^{\dagger}h\\{\gamma^{\lambda},\delta
G\\}\psi\Big{]}.$

The total derivative in the fourth line does not contribute to the variation
of the action. From (107) the derivative of $G$ with respect to the vierbein
is

$e_{\mu(\beta)}{\partial G\over\partial e^{\nu}_{(\beta)}}={1\over
8}[\gamma_{\mu},\gamma_{\nu}],$ (113)

and the derivative respect to the metric tensor is

${\partial G\over\partial g^{\mu\nu}}={1\over 2}\Big{[}e_{\mu(\beta)}{\partial
G\over\partial e^{\nu}_{(\beta)}}+e_{\nu(\beta)}{\partial G\over\partial
e^{\mu}_{(\beta)}}\Big{]}=0.$ (114)

Consequently the energy-momentum tensor is determined by just the first two
lines of (B):

$\displaystyle T_{\mu\nu}^{4}$ $\displaystyle=$ $\displaystyle{i\over
4}\Big{[}\psi^{\dagger}h\gamma_{\mu}\nabla_{\nu}\psi+\psi^{\dagger}h\gamma_{\nu}\nabla_{\mu}\psi\Big{]}$
$\displaystyle-$ $\displaystyle{i\over
4}\Big{[}(\nabla_{\nu}\psi)^{\dagger}h\gamma_{\mu}\psi+(\nabla_{\mu}\psi)^{\dagger}h\gamma_{\nu}\psi\Big{]}$
$\displaystyle-$ $\displaystyle g_{\mu\nu}\,{\cal L}^{4}/\sqrt{g}.$

##  Appendix C Proof that $\int d^{3}x\sqrt{g}\,g^{00}\,T_{00}^{5B}=0$

The “extra” piece (52) in the energy-momentum tensor for scalar bosons is

$T_{\mu\nu}^{5B}=-R_{\mu\nu}\Psi+\Psi_{;\mu;\nu}-g_{\mu\nu}\Psi^{;\rho}_{\;\;;\rho}.$
(116)

where $\Psi=\xi\phi_{i}^{2}$. This came from the term $-{1\over
2}\xi\sqrt{g}\,(\delta R)\phi_{i}^{2}$ in (48). The following applies to any
action of the form

$-{1\over 2}\int d^{4}x\sqrt{g}\,\Psi\,R$ (117)

where $\Psi$ is a coordinate scalar. A Lagrangian density of the form
$\sqrt{g}\,X^{\mu}\partial_{\mu}R$ or $\sqrt{g}\,Y^{\mu\nu}R_{;\mu;\nu}$ has
an action of the form (117) after an integration by parts.

#### Static metric:

To analyze $T_{00}^{5B}$ for a static metric, organize the $\mu=\nu=0$
component as

$\displaystyle\sqrt{g}\,g^{00}\,T_{00}^{5B}$ $\displaystyle=$ $\displaystyle
A^{0}_{\;\;0}+B^{0}_{\;\;0}$ $\displaystyle A^{0}_{\;\;0}$ $\displaystyle=$
$\displaystyle-{\sqrt{g}\over g_{00}}R_{00}\Psi$ (118) $\displaystyle
B^{0}_{\;\;0}$ $\displaystyle=$
$\displaystyle\sqrt{g}\big{[}\Psi^{;0}_{\;\;;0}-\Psi^{;\lambda}_{\;\;;\lambda}\big{]}.$

From (103)

$A^{0}_{\;\;0}={1\over
2}\partial_{j}\Big{[}\sqrt{g}\,g^{jk}{\partial_{k}g_{00}\over
g_{00}}\Big{]}\Psi.$ (119)

In $B^{0}_{\;\;0}$ the time derivatives of the fields all cancel and leave

$B^{0}_{\;\;0}=-{\sqrt{g}\over
g_{00}}\Gamma_{00}^{k}\partial_{k}\Psi-\partial_{k}\big{[}\sqrt{g}\,g^{kj}\partial_{j}\Psi)\big{]}.$
(120)

Using (97) gives a more complicated looking result:

$B^{0}_{\;\;0}={1\over 2}\sqrt{g}\,g^{jk}{\partial_{j}g_{00}\over
g_{00}}\partial_{k}\Psi-\partial_{k}\big{[}\sqrt{g}\,g^{jk}\partial_{j}\Psi)\big{]}$
(121)

but the sum with $A^{0}_{\;\;0}$ gives another total derivative:

$A^{0}_{\;\;0}+B^{0}_{\;\;0}={1\over
2}\partial_{j}\Big{[}\sqrt{g}\,g^{jk}{\partial_{k}g_{00}\over
g_{00}}\Psi\Big{]}-\partial_{k}\big{[}\sqrt{g}\,g^{jk}\partial_{j}\Psi)\big{]}.$
(122)

Consequently

$\int d^{3}x\sqrt{g}\,g^{00}T_{00}^{5B}=0.$ (123)

##  Appendix D A complicated example

This appendix presents the details of the example mentioned in Sec. I in which
${\cal L}$ depends on the Ricci curvature tensor $R^{\mu\nu}$. Despite the
complications the result is again that the Hilbert Hamiltonian is equal to the
canonical Hamiltonian for a static metric even without using the field
equation. The Lagrangian density is

${\cal L}=\sqrt{g}\,R^{\mu\nu}(\partial_{\mu}\phi)(\partial_{\nu}\phi)$ (124)

and could be added to the conventional Lagrangian density for a scalar field
if multiplied by a coefficient of mass dimension $M^{-2}$. The question is not
whether this ${\cal L}$ is a physically acceptable addition but whether the
resulting Hamiltonians, Hilbert and canonical, are equal. The canonical
energy-momentum pseudo-tensor (3) is

$\sqrt{g}\,\Theta^{\mu}_{\;\;\nu}=2\sqrt{g}\,R^{\mu\alpha}(\partial_{\alpha}\phi)(\partial_{\nu}\phi)-\delta^{\mu}_{\;\;\nu}{\cal
L}.$ (125)

For a static background metric

$\Theta^{0}_{\;\
0}=R^{00}\partial_{0}\phi\,\partial_{0}\phi-R^{jk}\partial_{j}\phi\,\partial_{k}\phi.$
(126)

The field equations have not been used.

#### Hilbert $T_{\mu\nu}$ for a general metric:

The Hilbert energy-momentum tensor for a general metric is more complicated to
compute. It is convenient to organize ${\cal L}$ as

${\cal
L}=\sqrt{g}\,R_{\alpha\beta}\,g^{\alpha\mu}g^{\beta\nu}\,\Phi_{\mu\nu},$ (127)

where $\Phi_{\mu\nu}=(\partial_{\mu}\phi)(\partial_{\nu}\phi)$ is a tensor
independent of the metric. One needs the variation of the covariant Ricci
tensor with respect to the contravariant $\delta g^{\mu\nu}$ given in Eq.
(10.9.3) of Weinberg1 :

$\displaystyle\delta R_{\alpha\beta}$ $\displaystyle=$ $\displaystyle{1\over
2}g_{\mu\nu}(\delta g^{\mu\nu})_{;\alpha;\beta}+{1\over
2}g_{\alpha\mu}g_{\beta\nu}(\delta g^{\mu\nu})^{;\lambda}_{\;\;;\lambda}$
(128) $\displaystyle-$ $\displaystyle{1\over 2}g_{\alpha\mu}(\delta
g^{\mu\nu})_{;\beta;\nu}-{1\over 2}g_{\beta\nu}(\delta
g^{\mu\nu})_{;\alpha;\mu}.$

The variational derivative of the action allows the covariant derivatives of
$\delta g^{\mu\nu}$ to be shifted to the the fields and leads to

$\displaystyle T_{\mu\nu}$ $\displaystyle=$ $\displaystyle
2\Phi_{\mu\alpha}R^{\alpha}_{\;\;\nu}+2\Phi_{\nu\alpha}R^{\alpha}_{\;\;\mu}-g_{\mu\nu}\Phi_{\alpha\beta}R^{\alpha\beta}$
$\displaystyle+$ $\displaystyle
g_{\mu\nu}(\Phi_{\alpha\beta})^{;\alpha;\beta}+(\Phi_{\mu\nu})^{;\lambda}_{\;\;;\lambda}$
$\displaystyle-$
$\displaystyle(\Phi_{\mu\alpha})_{;\nu}^{\;\;;\alpha}-(\Phi_{\nu\alpha})_{;\mu}^{\;\;;\alpha}.$

This holds for a general metric.

#### Hilbert $T_{00}$ for a static metric:

Specialize to a static metric, set $\mu=\nu=0$, and use
$R^{0}_{\;\;j}=R^{j}_{\;\;0}=0$ to obtain

$\displaystyle T_{00}$ $\displaystyle=$ $\displaystyle P_{00}+Q_{00}$
$\displaystyle P_{00}$ $\displaystyle=$ $\displaystyle
g_{00}\Big{[}3R^{00}\Phi_{00}-R^{jk}\Phi_{jk}\Big{]}$ (130) $\displaystyle
Q_{00}$ $\displaystyle=$ $\displaystyle
g_{00}(\Phi_{\alpha\beta})^{;\alpha;\beta}+(\Phi_{00})^{;\lambda}_{\;\;;\lambda}-2(\Phi_{0\alpha})_{;0}^{\;\;;\alpha}.$

Note that $P_{00}$ contains a factor $3$ not present in $\Theta_{00}$. In
$Q_{00}$ all the double time derivatives cancel and leave

$Q_{00}=g_{00}[(\Phi_{0\ell})^{;\ell;0}-(\Phi_{0\ell})^{;0;\ell}]+g_{jk}(\Phi_{00})^{;j;k}+g_{00}(\Phi_{jk})^{;j;k}.$

It is convenient to change contravariant derivatives to covariant derivatives

$Q_{00}=g_{00}[(\Phi^{0\ell})_{;\ell;0}-(\Phi^{0\ell})_{;0;\ell}]+g^{jk}(\Phi_{00})_{;j;k}+g_{00}(\Phi^{jk})_{;j;k}.$

The term in square brackets may be evaluated in terms of the curvature tensor

$\displaystyle(\Phi^{0\ell})_{;\ell;0}-(\Phi^{0\ell})_{;0;\ell}$
$\displaystyle=$ $\displaystyle-R^{\ell}_{\;\;0\ell
0}\Phi^{00}+R^{0}_{\;\;j0k}\Phi^{jk}$ $\displaystyle=$ $\displaystyle-
R_{00}\Phi^{00}+[R_{jk}-R^{\ell}_{\;\;j\ell k}]\Phi^{jk}$

and therefore

$\displaystyle P_{00}+Q_{00}$ $\displaystyle=$ $\displaystyle
g_{00}\,2R^{00}\Phi_{00}-g_{00}R^{\ell}_{\;\;j\ell k}\Phi^{jk}$
$\displaystyle+$ $\displaystyle
g^{jk}(\Phi_{00})_{;j;k}+g_{00}(\Phi^{jk})_{;j;k}.$

The difference between the Hilbert energy density and the canonical energy
density is

$\displaystyle\sqrt{g}\,[T^{0}_{\;\;0}-\Theta^{0}_{\;\;0}]$ $\displaystyle=$
$\displaystyle\sqrt{g}\,[R^{00}\Phi_{00}+R^{jk}\Phi_{jk}]$ $\displaystyle+$
$\displaystyle X_{1}+X_{2}+X_{3}$ $\displaystyle X_{1}$ $\displaystyle\equiv$
$\displaystyle\sqrt{g}\,g^{jk}(\Phi^{0}_{\;\;0})_{;j;k}$ $\displaystyle X_{2}$
$\displaystyle\equiv$ $\displaystyle\sqrt{g}\,(\Phi^{jk})_{;j;k}$ (133)
$\displaystyle X_{3}$ $\displaystyle\equiv$
$\displaystyle-\sqrt{g}\,R^{\ell}_{\;\;j\ell k}\Phi^{jk}$

#### Analysis of $X_{1}$:

To simplify $X_{1}$ use (96) and (100) to obtain

$\displaystyle g^{jk}(\Phi^{0}_{\;\;0})_{;j;k}$ $\displaystyle=$
$\displaystyle
g^{jk}[\partial_{k}(\Phi^{0}_{\;\;0})_{j}-\Gamma_{jk}^{\ell}(\Phi^{0}_{\;\;0})_{;\ell}]$
(134) $\displaystyle=$ $\displaystyle
g^{jk}\partial_{k}(\Phi^{0}_{\;\;0})_{;j}+{1\over\sqrt{\gamma}}\partial_{k}(\sqrt{\gamma}\,g^{k\ell})(\Phi^{0}_{\;\;0})_{;\ell}$
$\displaystyle=$
$\displaystyle{1\over\sqrt{\gamma}}\partial_{k}[\sqrt{\gamma}\,g^{jk}(\Phi^{0}_{\;\;0})_{;j}].$

Therefore

$X_{1}=\sqrt{g_{00}}\,\partial_{k}[\sqrt{\gamma}\,g^{jk}(\Phi^{0}_{\;\;0})_{;j}].$
(135)

In the volume integral of $X_{1}$ a spatial integration by parts gives

$\int d^{3}x\,X_{1}=-{1\over 2}\int
d^{3}x\,\sqrt{g}\,g^{jk}{\partial_{k}g_{00}\over
g_{00}}(\Phi^{0}_{\;\;0})_{;j}.$ (136)

Since $(\Phi^{0}_{\;\;0})_{;j}=\partial_{j}\Phi^{0}_{\;\;0}$ another
integration by parts gives

$\int d^{3}x\,X_{1}={1\over 2}\int
d^{3}x\,\partial_{j}\Big{[}\sqrt{g}\,g^{jk}{\partial_{k}g_{00}\over
g_{00}}\Big{]}\Phi^{0}_{\;\;0}.$ (137)

From the identity (103) this is

$\displaystyle\int d^{3}x\,X_{1}$ $\displaystyle=$ $\displaystyle-\int
d^{3}x\sqrt{g}\,R^{0}_{\;\;0}\Phi^{0}_{\;\;0}$ (138) $\displaystyle=$
$\displaystyle-\int d^{3}x\sqrt{g}\,R^{00}\Phi_{00}.$

#### Analysis of $X_{2}$:

To simplify $X_{2}$ use (99)

$\displaystyle(\Phi^{jk})_{;j;k}$ $\displaystyle=$
$\displaystyle\partial_{k}\big{[}(\Phi^{jk})_{;j}\big{]}+\Gamma^{k}_{k\ell}(\Phi^{j\ell})_{;j}$
(139) $\displaystyle=$
$\displaystyle\partial_{k}\big{[}(\Phi^{jk})_{;j}\big{]}+{1\over\sqrt{\gamma}}(\partial_{\ell}\sqrt{\gamma})(\Phi^{j\ell})_{;j}$
$\displaystyle=$
$\displaystyle{1\over\sqrt{\gamma}}\partial_{k}\big{[}\sqrt{\gamma}\,(\Phi^{jk})_{;j}\big{]};$

therefore

$X_{2}=\sqrt{g_{00}}\,\partial_{k}[\sqrt{\gamma}\,(\Phi^{jk})_{;j}].$ (140)

In the volume integral of $X_{2}$ a spatial integration by parts yields

$\int d^{3}x\,X_{2}=-{1\over 2}\int
d^{3}x\sqrt{g}\,(\Phi^{jk})_{;j}{\partial_{k}g_{00}\over g_{00}}.$ (141)

The necessary covariant derivative is

$\displaystyle(\Phi^{jk})_{;j}$ $\displaystyle=$
$\displaystyle\partial_{j}\Phi^{jk}+\Gamma_{j\ell}^{j}\Phi^{\ell
k}+\Gamma_{j\ell}^{k}\Phi^{j\ell}$ (142) $\displaystyle=$
$\displaystyle{1\over\sqrt{\gamma}}\partial_{j}\big{[}\sqrt{\gamma}\,\Phi^{jk}\big{]}+\Gamma_{j\ell}^{k}\Phi^{j\ell}.$

Substitution into (141) and integration by parts gives

$\displaystyle\int d^{3}x\;X_{2}$ $\displaystyle=$ $\displaystyle\int
d^{3}x{\sqrt{g}\over g_{00}}\Big{[}{\partial_{j}\partial_{k}g_{00}\over
2}-{\partial_{j}g_{00}\partial_{k}g_{00}\over 4g_{00}}\Big{]}\Phi^{jk}$ (143)
$\displaystyle-$ $\displaystyle{1\over 2}\int d^{3}x\,{\sqrt{g}\over
g_{00}}\,(\partial_{\ell}g_{00})\Gamma^{\ell}_{jk}\Phi^{jk}.$

Comparison with (101) shows that

$\displaystyle\int d^{3}x\,X_{2}$ $\displaystyle=$ $\displaystyle-\int
d^{3}x\sqrt{g}\,g^{00}\,R_{0j0k}\Phi^{jk}.$ (144)

Combining this with $X_{3}$ from (133) gives

$\displaystyle\int d^{3}x\,[X_{2}+X_{3}]$ $\displaystyle=$ $\displaystyle-\int
d^{3}x\sqrt{g}\,[R^{0}_{\;\;j0k}+R^{\ell}_{\;\;j\ell k}]\Phi^{jk}$ (145)
$\displaystyle=$ $\displaystyle-\int d^{3}x\sqrt{g}\,R_{jk}\Phi^{jk}$

#### Result:

From (138) and (145)

$\displaystyle\int d^{3}x[\sqrt{g}\,R^{00}\Phi_{00}+X_{1}]$ $\displaystyle=$
$\displaystyle 0$ (146) $\displaystyle\int
d^{3}x\,[\sqrt{g}\,R^{jk}\Phi_{jk}+X_{2}+X_{3}]$ $\displaystyle=$
$\displaystyle 0.$ (147)

And so from (D)

$\int d^{3}x\sqrt{g}\,[T^{0}_{\;\;0}-\Theta^{0}_{\;\;0}]=0$ (148)

which shows that the Hilbert and canonical Hamiltonians are equal.

## References

  * (1) D. Hilbert, Die Grundlagen der Physik, Nachr. Ges. Wiss. Gott., Math-Phys., Kl. 27, 395 (1915).
  * (2) C. Becchi, A. Rouet, and R. Stora, Renormalization of the abelian Higgs-Kibble model, Comm. Math. Phys., 42, 127 (1975).
  * (3) I.V. Tyutin, Gauge invariance in field theory and statistical physics in operator formalism, Lebedev Institute preprint N39 (1975), arXiv:0812.0580.
  * (4) L.D. Landau and E.M. Lifshitz, The Classical Theory of Fields, 4’th ed., Pergamon Press, New York, 1975.
  * (5) S. Weinberg, Gravitation and Cosmology: Principles and Applications of the General Theory of Relativity, John Wiley & Sons, New York, 1972.
  * (6) E. Noether, Invariante Variationsprobleme, Nachr. Ges. Wiss. Gött., Math.-Phys., Klasse 235 (1918), arXiv:physics/0503066.
  * (7) F.J. Belinfante, On the spin angular momentum of mesons, Physica 6, 887 (1939): On the current and the density of the electric charge, the energy, the linear momentum and the angular momentum of arbitrary fields, Physica 7, 449 (1940).
  * (8) L. Rosenfeld, Sur le tenseur d’impulsion-énergie, Mémoires Acad. Roy. Belg. Sci., 18, 1 (1940).
  * (9) S. Weinberg, The Quantum theory of fields Vol. I, Cambridge Univ. Press, Cambridge, UK (1995); p. 316.
  * (10) G. Muñoz, Lagrangian field theories and energy-momentum tensors, Am. Jour. Phys. 64, 1153 (1996).
  * (11) R.E. Gamboa Saravi, On the energy-momentum tensor, Jour. Phys. A 37, 9573 (2004).
  * (12) J.M. Pons, Noether symmetries, energy-momentum tensors, and conformal invariance in classical field theory, J. Math. Phys. 52, 012904 (2011).
  * (13) D.N. Blaschke, F. Gieres, M. Reboud, and M. Schweda, The energy-momentum tensor(s) in classical gauge theories, Nucl. Phys. B, 912, 192 (2016).
  * (14) R.V. Ilin and S.A. Paston, Exact relation between canonical and metric energy-momentum tensors for higher derivative tensor field theories, Eur. Phys. J. Plus 134, 21 (2019).
  * (15) A. Freese, Noether’s theorems and the energy-momentum tensor in quantum gauge theories, Phys. Rev. D, 106, 125012 (2022).
  * (16) M.J. Gotay and J.E. Marsden, Stress-energy-momentum tensors and the Belinfante-Rosenfeld formula, Contemp. Math. 132, 367 (1992).
  * (17) M. Forger and H. Römer, Currents and the energy-momentum tensor in classical field theory: a fresh look at an old problem, Ann. Phys. 309, 306 (2004).
  * (18) M.R. Baker, N. Kiriushcheva, and S. Kuzmin, Noether and Hilbert (metric) energy-momentum tensors are not, in general, equivalent, Nucl. Phys. B, 962, 115240 (2021).
  * (19) M. Sánchez, On the geometry of static spacetimes, Nonlinear Analysis, 63, e455 (2005).
  * (20) S.A. Fulling, Nonuniqueness of canonical field quantization in Riemannian spacetime, Phys. Rev. D, 7, 2850 (1973).
  * (21) J. Dereziński and D. Siemssen, Feynman propagators on static spacetimes, Rev. Math. Phys. 30, 1850006 (2018).
  * (22) H.A. Weldon, Fermions without vierbeins in curved space-time, Phys. Rev. D, 63, 104010 (2001).


# Conference Paper Title*
*Note: Sub-titles are not captured in Xplore and should not be used ††thanks: Identify applicable funding agency here. If none, delete this.

Danylo Lykov  Computational Science Division
Argonne National Laboratory
Lemont, IL 60439, U.S.A.
<EMAIL_ADDRESS>Yuri Alexeev  Computational Science Division
Argonne National Laboratory
Lemont, IL 60439, U.S.A.
<EMAIL_ADDRESS>
# Importance of Diagonal Gates in Tensor Network Simulations

Danylo Lykov  Computational Science Division
Argonne National Laboratory
Lemont, IL 60439, U.S.A.
<EMAIL_ADDRESS>Yuri Alexeev  Computational Science Division
Argonne National Laboratory
Lemont, IL 60439, U.S.A.
<EMAIL_ADDRESS>
###### Abstract

In this work we present two techniques that tremendously increase the
performance of tensor-network based quantum circuit simulations. The
techniques are implemented in the QTensor package and benchmarked using
Quantum Approximate Optimization Algorithm (QAOA) circuits. The techniques
allowed us to increase the depth and size of QAOA circuits that can be
simulated. In particular, we increased the QAOA depth from 2 to 5 and the size
of a QAOA circuit from 180 to 244 qubits. Moreover, we increased the speed of
simulations by up to 10 million times. Our work provides important insights
into how various techniques can dramatically speed up the simulations of
circuits.

##  I Introduction

Quantum information science has a tremendous potential to speed up
calculations of certain problems over classical calculations [1]. To continue
the advances in this field, however, often requires classically simulating
quantum circuits. Such simulation is done by using classical simulation
algorithms that replicate the behavior of executing quantum circuits on
quantum hardware on classical hardware such as personal computers or high-
performance computing (HPC) systems. These algorithms play an important role
and can be used to (1) verify the correctness of quantum hardware, (2) help
the development of hybrid classical-quantum algorithms, (3) find optimal
circuit parameters for hybrid variational quantum algorithms, (4) validate the
design of new quantum circuits, and (5) verify quantum supremacy and advantage
claims.

Several approaches have been employed to simulate quantum circuits. The major
types include the state-vector evolution approach [2, 3, 4, 5, 6, 7], linear
algebra open system simulation [8], and tensor network contractions [9, 10,
11, 12]. All these simulators have various advantages and disadvantages. For
example, the state-vector evolution approach, while being relatively easy to
implement, has an exponential memory requirement with respect to the number of
qubits in the circuit, which is a major bottleneck preventing the quantum
simulations beyond approximately 46 qubits on modern supercomputers.

In our opinion the most promising type of simulator is the tensor network
contraction approach. It is especially efficient for simulating shallow-depth
circuits. This approach can be sensitive to the connectivity of a quantum
circuit and the types of gates. In this paper we describe the tensor network
simulator implementation and show two optimization techniques that enable
dramatic speedup of simulations. We use quantum circuits from the Quantum
Approximate Optimization Algorithm (QAOA) algorithm since it is a promising
candidate for demonstrating quantum advantage and benchmarking quantum
devices.

All simulations in our paper used QTensor [13], developed at Argonne National
Laboratory. It is a quantum circuit simulator that uses a tensor network
contraction approach with a special focus on the simulation of QAOA circuits.
It supports simulating both probability amplitudes and energy expectation
values.

In the following section we introduce the tensor network contraction approach
and describe the QAOA quantum circuits. In particular, we show how the usage
of the Feynman path formalism provides the possibility for optimization. We
then describe the optimization techniques and the resulting speedup of
simulations. The final section contains our conclusions and further directions
of research.

@R=1em @C=0.75em
&0 H H Z^2β H
1 H Z^2γ H Z^2β H
2 H Z^2γ Z^2γ H Z^2β H
3 H Z^2γ Z^2γ Z^2γ H Z^2β H

Figure 1: Quantum circuit that generates QAOA ansatz state for MaxCut problem
on a 4-node complete graph. This widely used decomposition of QAOA into common
set of basis gates is not optimal for the classical simulation of the output
state. Figure 2:  Line graphs of tensor networks for calculating QAOA ansatz
state using different optimizations. “Default” and “diagonal” show line graphs
of tensor network for the circuit shown in Figure 1, using a full-matrix gates
and diagonal gates approach, respectively. “ZZ gates + diagonal” is obtained
by using the diagonal gates approach on a simplified quantum circuit obtained
by applying Equation 4. This figure demonstrates how improving the conversion
of a quantum algorithm to a tensor network can reduce the complexity of the
network, providing speedups for both finding contraction order and the
contraction itself.

##  II QAOA algorithm

The QAOA algorithm, introduced by Farhi and Goldstone in 2016 [14], is a
seminal hybrid quantum-classical algorithm for approximate optimization. The
algorithm can be used to find approximate solutions to NP-complete
combinatorial optimization problems. Here we will demonstrate how it works to
solve the MaxCut problem and all benchmarking simulations are performed for
MaxCut, but this work also applies to other types of tensor network
simulations.

The goal of the MaxCut problem is to color all vertices of a given graph
$G=(V,E)$, such that the two resulting parts of the graph are connected to
each other by the maximum number of edges. The cost function for MaxCut is
$C=\frac{1}{2}\sum_{<jk>\in E}-Z_{j}Z_{k}+1$, where $Z_{i}$ is a label of each
vertex. To solve this problem using QAOA, one has to find optimal parameters
for the parametrized ansatz state $\ket{\gamma\beta}$ such that the
expectation value of the Hamiltonian cost function
$\braket{\gamma\beta}{\hat{H}}{\gamma\beta}$ is maximized. The ansatz state
depends on two parameter vectors $\gamma$ and $\beta$. The length of the
parameter vector, denoted $p$, is an important parameter that defines the
quality of the solution. For a QAOA depth $p$ with MaxCut on graph $G=(V,E)$,
the ansatz state is equal to

$\ket{\gamma\beta}_{p}=\prod_{k=1}^{p}U_{C}(\gamma_{k})U_{B}(\beta_{k})\ket{+},$
(1)

where $U_{B}(\beta)=e^{-\imath\beta\sum_{j\in V}X_{j}}$ and
$U_{C}(\gamma)=e^{-\imath\frac{\gamma}{2}\sum_{(i,j)\in E}(I-Z_{i}Z_{j})}$.
Substituting $U_{B}$ and $U_{C}$ into (1) and discarding the global phase, we
obtain

$\ket{\gamma\beta}_{p}=\prod_{q=1}^{p}\ [\prod_{ij\in E,k\in
V}e^{\imath\gamma_{q}Z_{i}Z_{j}}e^{-\imath\beta_{q}X_{k}}]|+\rangle.$ (2)

A quantum circuit that generates the ansatz state for MaxCut on a fully
connected 4-node graph is shown in Figure 1. For a more detailed description
of QAOA see [14].

The optimal $\gamma,\beta$ parameters correspond to the minimum of the
Hamiltonian cost function expectation value, which can be calculated as
$E=\bra{\gamma\beta}C\ket{\gamma\beta}$. Note that $C$ is a sum of $|E|$
elements, where each element corresponds to an edge of the original graph on
which we solve MaxCut. Hence, the expectation value is $E=\sum_{k}E_{k}$,
where each element is a matrix element of a local operator that acts on two
qubits. This locality gives room for efficient optimization by canceling all
the conjugate gates that commute through that local operator. This
optimization, called lightcone optimization, was introduced by Farhi and
Goldstone in [14].

The energy calculation is an important part of the QAOA method, since one can
use a classical computer to optimize the $\gamma,\beta$ parameters without
having to use noisy quantum devices. In this work, however, we focus on
simulating a single amplitude of the ansatz state as a benchmark for
demonstrating the optimizations. The results for energy simulations will be
discussed in future works.

##  III Methodology

###  III-A Tensor network approach

Quantum computers operate by applying gates to a quantum state that describes
a quantum system consisting of $N$ subsystems (qubits). One way to describe
the evolution of the quantum system is to apply quantum gates in matrix form
on the wavefunction in the form of a state vector. With the state-vector
evolution approach, each gate action should be described as an operator that
acts on the whole system, even if the gate is local to a certain subsystem of
qubits. As a result, the whole state vector needs to be stored, which is
extremely inefficient in terms of computational resources and memory.

The tensor network approach associates a state vector of the system with a
tensor of $N$ indices. Each index in this tensor labels the state of a
particular subsystem. That is, the dimension of the index is equal to number
of states of the subsystem, which is always 2 in our case. Each gate that acts
on a subsystem can then be described as a tensor. The amplitudes of the
resulting state can be calculated by summing the product of the state tensor
and the operator tensor over the index of the subsystem.

For example, given a system of two qubits and operator $\hat{X}_{0}$ acting on
the first qubit, the resulting state in the state-vector formalism would be
$\ket{\phi}=\hat{X}_{0}\otimes\hat{I}_{1}\ket{\psi}$. In tensor network
representation, this equation is
$\phi_{i^{\prime}j}=X_{i^{\prime}i}\psi_{ij}$.

If the system is in a product state, then the corresponding state-tensor is a
product of smaller tensors representing each subsystem state. In particular, a
2-qubit system in a state $\ket{0}$ is represented by
$\psi_{ij}=\begin{pmatrix}1\\\ 0\end{pmatrix}_{i}\begin{pmatrix}1\\\
0\end{pmatrix}_{j}$. Note that the size of this object is $2N$ compared with
that of $2^{N}$ in the state-vector notation. More details on tensor network
formalism are available in [15].

###  III-B Tensor network contraction

Simulation of probability amplitudes of a quantum state can be done by
contracting a tensor network that represents the quantum circuit that
generates the state.

The contraction of a general tensor network can be written by using a line
graph approach as following:

$R_{i_{1},\dots,i_{p}}=\sum_{j_{1},\dots,j_{q}}\prod_{e_{i}\in
F}W^{i}_{e_{i}},$ (3)

where tensor indices $i_{...},j_{...}\in U$ are represented by vertices of a
hypergraph $L=(U,F)$, $e\in F$ is a hyperedge of $L$, edges are tuples of
indices $e_{i}=(v_{1},v_{2},\dots,v_{d}),\forall k\ v_{k}\in U$, and tensors
$W^{i}_{e_{i}}$ have the number of dimensions $d$ , the same as the number of
vertices in a corresponding edge. For two-level quantum systems, where each
tensor dimension has size 2, the sum (3) has $2^{q}$ elements, and each
element corresponds to assignment of $0,1$ to each variable.

Instead of calculating every element of this sum, one can merge tensors with
each other, producing an intermediary tensor after each merge operation. One
way to do this is by selecting some vertices $j_{i}$ from all contracted
vertices $\\{j_{k}\\}_{k=1}^{q}$ and evaluating values of a new intermediary
tensor by summing over $j_{i}$ a product of only those tensors that have
$j_{i}$ as their index. The order in which the $j_{i}$ are selected determines
the size of the largest tensor that needs to be stored as an intermediate step
in the contraction. Thus the total contraction speed and memory requirements
are determined by this intermediate largest tensor, which can reach a very
large number of dimensions. More information on ordering tensor networks is
available in [16], [12], [17].

##  IV Optimization techniques

To speed up and reduce memory requirements of tensor network contraction, we
applied two techniques, which we describe in detail in this section. In the
first technique we combined gates, and in the second technique we took
advantage of the diagonal properties of the gates.

###  IV-A Optimization of QAOA circuit structure

A typical QAOA circuit is shown in Figure 1. We note that Pauli-Z gates are
enclosed by two CNOT gates or by Hadamard gates. One can merge these gates in
a specialized 2-qubit gate with a parameter $\gamma$ or parameter $\beta$
respectively, as shown in the equations below.

$\Qcircuit<EMAIL_ADDRESS>H\\\ \targ\gate{Z^{2\gamma}}\targ\qw\gate{H}\gate{Z^{2\beta}}\gate H}\hskip
10.00002pt\raisebox{-11.99998pt}{=}\hskip
10.00002pt\Qcircuit<EMAIL_ADDRESS>\ghost{ZZ}\qw\gate{X^{2\beta}}}$ (4)

$\hat{ZZ}=e^{i\gamma\hat{Z}_{i}\hat{Z}_{j}}$ (5)

This gate optimization technique reduces the complexity of the tensor network
line graph, as shown in Figure 2. It also makes finding an optimal tensor
contraction sequence easier since the line graph has fewer vertices.

###  IV-B Diagonal gate simplification

A certain property of tensors $W^{i}_{e_{i}}$ can provide an opportunity for
optimization in terms of how these tensors are stored and computed. Each index
of sum (3) can have a value $0$ or $1$ for an $N$-qubit system, and each
assignment of values to indices corresponds to a single Feynman path which
evaluates to an element of the sum (3). Since the value of each Feynman path
is a product of values of different tensors, we know in advance that if for
some assignment the value of any tensor is 0, the whole contribution is 0 as
well.

In particular, if a tensor $W^{i_{0}}$ from Equation 3 is diagonal, in other
words $W^{i_{0}}_{lm}=\alpha_{l}\delta_{lm}$, then for any assignment of
indices $(l,m)=e_{i_{0}}$, $l,m\in U$ from sum (3) in which values of the
diagonal tensor indices match, the corresponding element in the sum will be
equal to zero. The tensor $W^{i_{0}}$ can then be safely removed from the
tensor network and replaced by $\alpha_{l}$ without changing the result.

Here is a 2-gate example demonstrating how our diagonalization technique is
applied.

$\begin{split}|\phi\rangle&=\hat{U}\hat{D}|\psi\rangle\phi_{i}=\sum_{jk}U_{ij}D_{jk}\psi_{k}\\\
&=\sum_{jk}U_{ij}\alpha_{j}\delta_{jk}\psi_{k}=\sum_{j}U_{ij}\alpha_{j}\psi_{j}\end{split}$
(6)

We note that QAOA circuits have only one type of a 2-qubit gate:
$\hat{ZZ}=e^{i\gamma\hat{Z}_{i}\hat{Z}_{j}}$. The $\hat{Z}$ gate is diagonal,
as is $\hat{Z}_{i}\hat{Z}_{j}$; therefore, the matrix of the $\hat{ZZ}$ gate
in the 2-qubit basis will be diagonal.

$\hat{ZZ(\gamma)}=e^{i\gamma\hat{Z}_{i}\hat{Z}_{j}}=\text{diag}(e^{i\gamma},e^{-i\gamma},e^{-i\gamma},e^{i\gamma})$
(7)

We can use this fact to replace the 4-index tensor $U_{ijkl}$ representing a
generic 2-qubit gate with a 2-index tensor
$U_{ij}=(\begin{smallmatrix}\rho&\overline{\rho}\\\
\overline{\rho}&\rho\end{smallmatrix})$, $\rho=e^{i\gamma}$ that represents a
diagonal gate. This significantly reduces the computational cost for tensor
contraction and the memory requirements to store these tensors.

##  V Results

Figure 3:  Number of FLOPs to calculate a single amplitude of QAOA ansatz
state for MaxCut using a different number of QAOA iterations. Each line shows
a combination of optimization techniques, with “diagonal + ZZ gates” being the
most advanced one. The shaded region shows 1-$\sigma$ interval over 5 random
graphs.  Figure 4:  Number of FLOPs to calculate a single amplitude of QAOA
ansatz state with p=1 for MaxCut on random 3-regular graphs with 160 nodes.
The shaded region shows 1-$\sigma$ interval over 5 random graphs.

In this section we evaluate the simulation complexity of different
combinations of quantum circuits. For this work we used the number of FLOPs
required for contraction as the main metric of simulation complexity. We used
only the FLOPs metric because it is easy to use and both computational and
memory requirements can be easily estimated from each other. The number of
FLOPs can be estimated as $2^{C}$, where $C$ is a contraction width, or the
number of dimensions of the largest intermediary tensor. Thus, one can safely
assume that the maximum memory in bytes for the contraction will be
$16*2^{C}$, positing the size of a single complex number to be 16 bytes.

First, we selected 5 random 3-regular graphs, for which we formulated the
MaxCut problem by using QAOA. Then, each graph was used to generate quantum
circuits that produce QAOA ansatz. There are two types of circuits: one using
ordinary decomposition of 2-qubit gates into three gates and another using the
$\hat{ZZ}$ gate simplification, as described in Section IV-A, where the
complexity of the circuit is reduced. For each quantum circuit, we constructed
a tensor network using two approaches: with diagonal simplification and
without it, as described in Section IV-B. The tensor network was then sliced
to produce the first amplitude of the ansatz state when all its indices are
contracted. We then used the `rgreedy` algorithm from the QTensor package with
`n_repeats=10` and `temp=0.02` to obtain a contraction sequence, which we used
to estimate the number of FLOPs required for the contraction. Dependence of
the contraction complexity from the contraction ordering time is shown in
Figure 4. The experiments in this paper aim to demonstrate the difference
between simulation of quantum circuits optimized using different techniques,
rather than absolute values of the simulation cost. Hence, we pick relatively
modest ordering algorithm parameters that result in 1 second of ordering time.

Further analysis of contraction complexity is shown in Figure 3. In this
figure, the number of FLOPs for simulating a single amplitude of QAOA ansatz
circuit versus the number of QAOA iterations $p$ is shown. The data in the
plot is evaluated for five random 3-regular graphs. From the figure one can
see that diagonal gates and $\hat{ZZ}$ gate optimization techniques
dramatically reduce the number of FLOPs compared with the original unoptimized
tensor network graphs.

We also analyzed how the number of FLOPs is correlated with the size of the
circuit in terms of the number of qubits $N$. Figure 5 shows the number of
FLOPs for ansatz simulation of QAOA MaxCut on 3-regular graphs of different
sizes and fixed p=1. We note that improvement in performance grows with the
size of a circuit, showing that the diagonal gate simplification
proportionally reduces the contraction width $C$, while the $\hat{ZZ}$ gates
simplification produces a similar amount of improvement for all sizes.

From the analysis of Figures 3, 4, and 5, it is surprising to find out that
using only $\hat{ZZ}$ gate optimization is not enough to get significant
computational and memory savings. We note that using the diagonal gates is
what really provides dramatically better results, especially when combined
with gate optimization.

Figure 5:  The number of FLOPs to calculate a single amplitude of QAOA ansatz
state for MaxCut on random 3-regular graphs of different sizes. The number of
nodes in the graph corresponds to the number of qubits in the quantum circuit.
Each line shows a combination of optimization techniques, with “diagonal + ZZ
gates” being the most advanced one. The shaded region shows 1-$\sigma$
interval over 5 random graphs.

The simulation of quantum circuits is usually a memory-bound task because of
memory requirements to store an intermediate tensor. The optimization
techniques described in this paper allow simplification of a tensor network
structure with $\hat{ZZ}$ and diagonal gates, which in turn helped us find the
optimal tensor contraction sequence. As a result, we extended the depth $p$
and the number of qubits $N$ of the largest circuits that is feasible to
simulate using a laptop or a supercomputer, as shown in Tables I and II. A
laptop is assumed to have 4 GB of memory, and a supercomputer is assumed to
have 800 TB of aggregated memory.

Our optimization techniques also can be applied to the simulation of the QAOA
energy expectation value. Thus, it would allow us to find parameters for even
larger circuits with higher depth.

##  VI Conclusions

| Default | With diagonal | With ZZ gates and diagonal
---|---|---|---
Laptop | 2 | 3 | 3
Supercomputer | 2 | 4 | 5
TABLE I:  The maximum number of QAOA iterations $p$ for which one can simulate a single amplitude of ansatz state for MaxCut on a 40-node random regular graph.  | Default | With diagonal | With ZZ gates and diagonal
---|---|---|---
Laptop | 118 | 156 | 160
Supercomputer | 180 | 240 | 244
TABLE II:  The maximum number of nodes of a 3-regular graph for which one can
simulate a single amplitude of the MaxCut QAOA ansatz state.

In this work, we implemented and demonstrated that $\hat{ZZ}$ gate
optimization and diagonal gate techniques can lead to dramatic savings in
terms of memory and computation requirements. As a result, we were able to
simulate much larger QAOA circuits both in size and in depth, as shown in
Tables I and II.

We were able to increase $p$ from 2 to 5 and the size of a QAOA circuit $N$
from 180 to 244 qubits on a supercomputer. These numbers were estimated
without actually running on a supercomputer, but the laptop results have been
actually verified.

The tensor network contraction method for simulation of quantum circuits is a
powerful approach that has the potential to simulate very large quantum
circuits. At the same time, however, a lot of improvements, simplifications,
and approximations can be used to improve the simulations and dramatically
decrease memory and computational requirements. For example, in this work we
sped up quantum simulations by up to 10 million times, as can be seen in
Figure 3 in the “diagonal+ZZ gates” curve versus “default” curve for $p=5$.
Moreover, there is room to speed up simulations by an even larger factor. This
work underscores how one needs to be careful when comparing tensor network
simulations against classical solvers and quantum hardware for demonstration
of quantum supremacy and advantage. Our work provides important insights into
how various optimization techniques can speed up tensor network simulations
and what other techniques can be used to achieve this goal.

## Acknowledgments

Danylo Lykov and Yuri Alexeev are supported by the Defense Advanced Research
Projects Agency (DARPA) grant. Yuri Alexeev is also supported in a part by the
Exascale Computing Project (17-SC-20-SC), a joint project of the U.S.
Department of Energy’s Office of Science and National Nuclear Security
Administration, responsible for delivering a capable exascale ecosystem,
including software, applications, and hardware technology, to support the
nation’s exascale computing imperative. This material is based upon work
supported by the U.S. Department of Energy, Office of Science, under contract
DE-AC02-06CH11357. This work used the resources of the Argonne Leadership
Computing Facility, which is DOE Office of Science User Facility supported
under Contract DE-AC02-06CH11357. We thank Cameron Ibrahim and Alexey Galda
for insightful discussions.

## References

  * [1] Y. Alexeev, D. Bacon, K. R. Brown, R. Calderbank, L. D. Carr, F. T. Chong, B. DeMarco, D. Englund, E. Farhi, B. Fefferman, A. Gorshkov, A. Houck, J. Kim, S. Kimmel, M. Lange, S. Lloyd, M. Lukin, D. Maslov, P. Maunz, C. Monroe, J. Preskill, M. Roetteler, M. Savage, and J. Thompson, “Quantum computer systems for scientific discovery,” _PRX Quantum_ , vol. 2, no. 1, p. 017001, 2021.
  * [2] K. De Raedt, K. Michielsen, H. De Raedt, B. Trieu, G. Arnold, M. Richter, T. Lippert, H. Watanabe, and N. Ito, “Massively parallel quantum computer simulator,” _Computer Physics Communications_ , vol. 176, no. 2, pp. 121–136, 2007.
  * [3] M. Smelyanskiy, N. P. Sawaya, and A. Aspuru-Guzik, “qHiPSTER: the quantum high performance software testing environment,” _arXiv preprint arXiv:1601.07195_ , 2016.
  * [4] T. Häner and D. S. Steiger, “0.5 petabyte simulation of a 45-qubit quantum circuit,” in _Proceedings of the International Conference for High Performance Computing, Networking, Storage and Analysis_. ACM, 2017, p. 33.
  * [5] X.-C. Wu, S. Di, E. M. Dasgupta, F. Cappello, H. Finkel, Y. Alexeev, and F. T. Chong, “Full-state quantum circuit simulation by using data compression,” in _Proceedings of the High Performance Computing,Networking, Storage and Analysis International Conference (SC19)_. Denver, CO, USA: IEEE Computer Society, 2019.
  * [6] X.-C. Wu, S. Di, F. Cappello, H. Finkel, Y. Alexeev, and F. T. Chong, “Amplitude-aware lossy compression for quantum circuit simulation,” in _Proceedings of 4th International Workshop on Data Reduction for Big Scientific Data (DRBSD-4) at SC18_ , 2018.
  * [7] X.-C. Wu, S. Di, F. Cappello, H. Finkel, Y. Alexeev, and F. Chong, “Memory-efficient quantum circuit simulation by using lossy data compression,” in _Proceedings of the 3rd International Workshop on Post-Moore Era Supercomputing (PMES) at SC18_ , Denver, CO, USA, 2018.
  * [8] (2020) QuaC (quantum in c) is a parallel time dependent open quantum systems solver. [Online]. Available: https://github.com/0tt3r/QuaC
  * [9] I. L. Markov and Y. Shi, “Simulating quantum computation by contracting tensor networks,” _SIAM Journal on Computing_ , vol. 38, no. 3, pp. 963–981, 2008\.
  * [10] E. Pednault, J. A. Gunnels, G. Nannicini, L. Horesh, T. Magerlein, E. Solomonik, and R. Wisnieff, “Breaking the 49-qubit barrier in the simulation of quantum circuits,” _arXiv preprint arXiv:1710.05867_ , 2017\.
  * [11] S. Boixo, S. V. Isakov, V. N. Smelyanskiy, and H. Neven, “Simulation of low-depth quantum circuits as complex undirected graphical models,” _arXiv preprint arXiv:1712.05384_ , 2017.
  * [12] D. Lykov, R. Schutski, A. Galda, V. Vinokur, and Y. Alexeev, “Tensor network quantum simulator with step-dependent parallelization,” _arXiv preprint arXiv:2012.02430_ , 2020.
  * [13] D. Lykov, “QTensor,” https://github.com/danlkv/qtensor, 2021.
  * [14] E. Farhi and A. W. Harrow, “Quantum supremacy through the quantum approximate optimization algorithm,” _arXiv preprint arXiv:1602.07674_ , 2016.
  * [15] A. Cichocki, N. Lee, I. Oseledets, A.-H. Phan, Q. Zhao, D. P. Mandic _et al._ , “Tensor networks for dimensionality reduction and large-scale optimization: Part 1 – low-rank tensor decompositions,” _Foundations and Trends® in Machine Learning_ , vol. 9, no. 4-5, pp. 249–429, 2016.
  * [16] R. Schutski, D. Lykov, and I. Oseledets, “An adaptive algorithm for quantum circuit simulation,” _arXiv preprint arXiv:1911.12242_ , 2019.
  * [17] R. Dechter, “Bucket elimination: A unifying framework for several probabilistic inference,” _CoRR_ , vol. abs/1302.3572, 2013. [Online]. Available: http://arxiv.org/abs/1302.3572