Dgamma - Maple Help

Physics[Dgamma] - the Dirac gamma matrices

 Calling Sequence Dgamma[mu]

Parameters

 mu - an integer between 1 and the dimension, or any algebraic expression generically representing it (when the dimension is equal to 4, mu = 5 is also allowed)

Description

 • The Dgamma[mu] command is used to represent the Dirac ${\mathrm{\gamma }}_{\mathrm{\mu }}$ matrices, where $\mathrm{\mu }$ ranges from 1 to the dimension d of spacetime; these are noncommutative objects satisfying

${{\gamma }}_{}^{\mu }{{\gamma }}_{}^{\nu }+{{\gamma }}_{}^{\nu }{{\gamma }}_{}^{\mu }=2{g}_{}^{\mu ,\nu }$

 where the products in the above are noncommutative, constructed by using the * operator of the Physics package, and ${g}_{\mathrm{\mu },\mathrm{\nu }}$ is the metric tensor. The properties of the Dirac matrices are derived from this defining relation (anticommutator algebra) above. The Simplify command simplifies products of Dirac matrices and the Trace command computes traces of these products, taking this defining relation into account.
 • This defining anticommutator algebra satisfied by the Dirac matrices is invariant under a unitary transformation. Thus these matrices are determined up to a transformation of that kind, and conventions are necessary to construct their representations. The most common representations are the standard (also known as Dirac), the chiral (also known as Weyl or spinor), and the Majorana representations.
 • When the Physics package is loaded, the default spacetime is of Minkowski type with signature (- - - +). With that signature, the standard representation for Dirac's matrices, uniform in the literature, is:

${{\mathrm{\gamma }}}_{}^{0}=\left[\begin{array}{cc}𝕀& 0\\ 0& -𝕀\end{array}\right],{{\mathrm{\gamma }}}_{}^{k}=\left[\begin{array}{cc}0& -{{\mathrm{\sigma }}}_{}^{k}\\ {{\mathrm{\sigma }}}_{}^{k}& 0\end{array}\right]$

 where $𝕀$ is the 2 x 2 identity matrix, k runs from 1 to 3, ${{\mathrm{\sigma }}}_{}^{k}=-\mathrm{σ__k}$ (due to the signature (---+)), and $\mathrm{σ__k}$ are the three Pauli matrices. (All of ${{\mathrm{\sigma }}}_{}^{0}=\mathrm{σ__0}\equiv 𝕀$ and $\mathrm{σ__k}$ are represented by Psigma, and together form the four vector Psigma[mu], displayed as $\mathrm{σ__μ}$.) As is the case for all spacetime tensors, when the position of the timelike component is the last one (the case when the signature is (---+)), the value d of a spacetime index in d dimensions is also represented by the number 0.
 • The conventions for the chiral and Majorana representations are not uniform in the literature. The conventions adopted here are the same ones shown in Wikipedia and in ref.[1-3], so that in the chiral representation, the ${{\mathrm{\gamma }}}_{}^{k}$ are the same as in the standard representation, while ${{\mathrm{\gamma }}}_{}^{0}$ changes to

${{\mathrm{\gamma }}}_{}^{0}=\left[\begin{array}{cc}0& 𝕀\\ 𝕀& 0\end{array}\right]$

 The convention implemented for the Majorana representation, that is, a representation where all the nonzero components of the Dirac matrices are imaginary, is

${{\mathrm{\gamma }}}_{}^{0}=\left[\begin{array}{cc}0& {{\mathrm{\sigma }}}_{2}\\ {{\mathrm{\sigma }}}_{2}& 0\end{array}\right],{{\mathrm{\gamma }}}_{}^{1}=\left[\begin{array}{cc}i{{\mathrm{\sigma }}}_{3}& 0\\ 0& i{{\mathrm{\sigma }}}_{3}\end{array}\right],{{\mathrm{\gamma }}}_{}^{2}=\left[\begin{array}{cc}0& -{{\mathrm{\sigma }}}_{2}\\ {{\mathrm{\sigma }}}_{2}& 0\end{array}\right],{{\mathrm{\gamma }}}_{}^{3}=\left[\begin{array}{cc}-i{{\mathrm{\sigma }}}_{1}& 0\\ 0& -i{{\mathrm{\sigma }}}_{1}\end{array}\right]$

 where $ⅈ$ is the imaginary unit (to represent it with a lowercase letter as in the above, see interface imaginaryunit).
 • The form of the contravariant Dirac matrices shown above for the three representations does not change with the signature, which could be (- - - +) (default when you load Physics), (+ - - -), (+ + + -) or (- + + +). To query about the signature, enter Setup(signature).  To change the value of the signature see Setup.
 • In all of these three representations, the timelike component of the Dirac matrices is Hermitian: ${{\mathrm{\gamma }}}_{}^{0}=\left({{{\mathrm{\gamma }}}_{}^{0}}^{†}\right)$, and the spacelike components are anti-Hermitian: ${{\mathrm{\gamma }}}_{}^{k}=-\left({{{\mathrm{\gamma }}}_{}^{k}}^{†}\right)$. In a four dimensional Minkowski spacetime, an Hermitian matrix ${{\mathrm{\gamma }}}_{}^{5}={{{\mathrm{\gamma }}}_{}^{5}}^{†}$ satisfying

${{\mathrm{\gamma }}}_{}^{\mathrm{\mu }}{{\mathrm{\gamma }}}_{}^{5}+{{\mathrm{\gamma }}}_{}^{5}{{\mathrm{\gamma }}}_{}^{\mathrm{\mu }}=0,{{\mathrm{\gamma }}}^{5}{{\mathrm{\gamma }}}_{}^{5}=1$

 is given by:

${{\mathrm{\gamma }}}_{}^{5}=-i{{\mathrm{\gamma }}}_{}^{0}{{\mathrm{\gamma }}}_{}^{1}{{\mathrm{\gamma }}}_{}^{2}{{\mathrm{\gamma }}}_{}^{3}$

 Note the minus sign on the right-hand side of this definition, according to [1], [2] and [3], but not Wikipedia and not uniform in the literature. This definition of ${{\mathrm{\gamma }}}_{}^{5}$ can also be written as

${{\mathrm{\gamma }}}_{}^{5}=\left(\frac{i}{4!}\right){\mathrm{\epsilon }}_{\mathrm{\alpha },\mathrm{\beta },\mathrm{\mu },\mathrm{\nu }}{{\mathrm{\gamma }}}_{}^{\mathrm{\mu }}{{\mathrm{\gamma }}}_{}^{\mathrm{\nu }}{{\mathrm{\gamma }}}_{}^{\mathrm{\alpha }}{{\mathrm{\gamma }}}_{}^{\mathrm{\beta }}$

 from where there is no distinction between a covariant or contravariant character for its index, ${{\mathrm{\gamma }}}_{5}={{\mathrm{\gamma }}}_{}^{5}$.
 • The form of the Dirac matrices implemented in the case of an Euclidean spacetime, for the standard, chiral, and Majorana representations, is obtained from the formulas above for the contravariant Dirac matrices by performing a Wick rotation, equivalent to multiplying the ${{\mathrm{\gamma }}}_{}^{k}$ by $-i$, while ${{\mathrm{\gamma }}}_{}^{0}$ remains unchanged, and ${{\mathrm{\gamma }}}_{}^{5}$ is given by

${{\mathrm{\gamma }}}_{}^{5}=-{{\mathrm{\gamma }}}_{}^{1}{{\mathrm{\gamma }}}_{}^{2}{{\mathrm{\gamma }}}_{}^{3}{{\mathrm{\gamma }}}_{}^{0}$

 These Euclidean Dirac matrices are all Hermitian, ${{\mathrm{\gamma }}}_{}^{\mathrm{\mu }}={{{\mathrm{\gamma }}}_{}^{\mathrm{\mu }}}^{†}$, including ${{\mathrm{\gamma }}}_{}^{5}$, and they all satisfy the same defining equations and anticommutation algebra rules stated in the previous paragraphs for a Minkowski spacetime.
 • The following are some representation-free frequently used identities for the Dirac matrices, valid provided the dimension, $d$, is greater than 1, expressed by using the sum rule for repeated indices:

${{\mathrm{\gamma }}}_{\mathrm{\mu }}{{\mathrm{\gamma }}}_{}^{\mathrm{\mu }}=d$

${{\mathrm{\gamma }}}_{\mathrm{\mu }}{{\mathrm{\gamma }}}_{\mathrm{\nu }}{{\mathrm{\gamma }}}_{}^{\mathrm{\mu }}=\left(2-d\right){{\mathrm{\gamma }}}_{\mathrm{\nu }}$

${{\mathrm{\gamma }}}_{\mathrm{\mu }}{{\mathrm{\gamma }}}_{\mathrm{\alpha }}{{\mathrm{\gamma }}}_{\mathrm{\beta }}{{\mathrm{\gamma }}}_{}^{\mathrm{\mu }}=4{g}_{\mathrm{\alpha },\mathrm{\beta }}+\left(d-4\right){{\mathrm{\gamma }}}_{\mathrm{\alpha }}{{\mathrm{\gamma }}}_{\mathrm{\beta }}$

${{\mathrm{\gamma }}}_{\mathrm{\mu }}{{\mathrm{\gamma }}}_{\mathrm{\alpha }}{{\mathrm{\gamma }}}_{\mathrm{\beta }}{{\mathrm{\gamma }}}_{\mathrm{\rho }}{{\mathrm{\gamma }}}_{}^{\mathrm{\mu }}=-2{{\mathrm{\gamma }}}_{\mathrm{\rho }}{{\mathrm{\gamma }}}_{\mathrm{\beta }}{{\mathrm{\gamma }}}_{\mathrm{\alpha }}-\left(d-4\right){{\mathrm{\gamma }}}_{\mathrm{\alpha }}{{\mathrm{\gamma }}}_{\mathrm{\beta }}{{\mathrm{\gamma }}}_{\mathrm{\rho }}$

 • Some representation-free identities for the traces of products of Dirac matrices in four dimensions are:

$\mathrm{Trace}\left({{\mathrm{\gamma }}}_{}^{\mathrm{\mu }}\right)=0$

$\mathrm{Trace}\left({{\mathrm{\gamma }}}_{}^{\mathrm{\mu }}{{\mathrm{\gamma }}}_{}^{\mathrm{\nu }}\right)=4{g}_{}^{\mathrm{\mu },\mathrm{\nu }}$

$\mathrm{Trace}\left({{\mathrm{\gamma }}}_{}^{\mathrm{\mu }}{{\mathrm{\gamma }}}_{}^{\mathrm{\nu }}{{\mathrm{\gamma }}}_{}^{\mathrm{\rho }}{{\mathrm{\gamma }}}_{}^{\mathrm{\sigma }}\right)=4{g}_{}^{\mathrm{\mu },\mathrm{\nu }}{g}_{}^{\mathrm{\rho },\mathrm{\sigma }}-4{g}_{}^{\mathrm{\mu },\mathrm{\rho }}{g}_{}^{\mathrm{\nu },\mathrm{\sigma }}+4{g}_{}^{\mathrm{\mu },\mathrm{\sigma }}{g}_{}^{\mathrm{\nu },\mathrm{\rho }}$

$\mathrm{Trace}\left({{\mathrm{\gamma }}}_{}^{5}\right)=\mathrm{Trace}\left({{\mathrm{\gamma }}}_{}^{\mathrm{\mu }}{{\mathrm{\gamma }}}_{}^{\mathrm{\nu }}{{\mathrm{\gamma }}}_{}^{5}\right)=0$

$\mathrm{Trace}\left({{\mathrm{\gamma }}}_{}^{\mathrm{\mu }}{{\mathrm{\gamma }}}_{}^{\mathrm{\nu }}{{\mathrm{\gamma }}}_{}^{\mathrm{\rho }}{{\mathrm{\gamma }}}_{}^{\mathrm{\sigma }}{{\mathrm{\gamma }}}_{}^{5}\right)=4i{\mathrm{\epsilon }}_{}^{\mathrm{\mu },\mathrm{\nu },\mathrm{\rho },\mathrm{\sigma }}$

 and the Trace of any product of an odd number of ${{\mathrm{\gamma }}}_{}^{\mathrm{\mu }}$ is zero. Note the sign +, not -, in the right-hand side of the last formula, related to the convention used for ${{\mathrm{\gamma }}}_{}^{5}$. To compute using these formulas, you can use the Physics commands Trace, g_ for the metric and LeviCivita for the totally antisymmetric symbol $\mathrm{\epsilon }$.

Examples

 > $\mathrm{with}\left(\mathrm{Physics}\right):$
 > $\mathrm{Setup}\left(\mathrm{mathematicalnotation}=\mathrm{true}\right)$
 $\left[{\mathrm{mathematicalnotation}}{=}{\mathrm{true}}\right]$ (1)

Represent the imaginary unit with the lowercase i to distinguish it clearly from the number 1.

 > $\mathrm{interface}\left(\mathrm{imaginaryunit}=i\right)$
 ${I}$ (2)

The Dgamma command is implemented as a tensor, which means you can compute with Dgamma[mu] entering tensorial expressions and have all the properties of tensors taken into account (see Physics,Tensors). For instance, the covariant and components are given by

 > $\mathrm{Dgamma}\left[\right]$
 ${{\mathrm{Dgamma}}}_{{\mathrm{μ}}}{=}\left(\left[\begin{array}{cccc}{\mathrm{Dgamma}}_{1}& {\mathrm{Dgamma}}_{2}& {\mathrm{Dgamma}}_{3}& {\mathrm{Dgamma}}_{4}\end{array}\right]\right)$ (3)
 > $\mathrm{Dgamma}\left[\mathrm{~}\right]$
 ${{\mathrm{Dgamma}}}_{{\mathrm{~mu}}}{=}\left(\left[\begin{array}{cccc}{\mathrm{Dgamma}}_{\mathrm{~1}}& {\mathrm{Dgamma}}_{\mathrm{~2}}& {\mathrm{Dgamma}}_{\mathrm{~3}}& {\mathrm{Dgamma}}_{\mathrm{~4}}\end{array}\right]\right)$ (4)

Note that (since Maple 2019) when Physics is loaded the standard representation for the Dirac matrices is automatically set. For the default signature, (- - - +), the traditional standard matrix representation is that of the contravariant components

 > $\mathrm{Library}:-\mathrm{RewriteInMatrixForm}\left(\mathrm{Dgamma}\left[\mathrm{~}\right]\right)$
 ${{\mathrm{Dgamma}}}_{{\mathrm{~mu}}}{=}\left(\left[\begin{array}{cccc}\left[\begin{array}{rrrr}0& 0& 0& 1\\ 0& 0& 1& 0\\ 0& -1& 0& 0\\ -1& 0& 0& 0\end{array}\right]& \left[\begin{array}{cccc}0& 0& 0& -I\\ 0& 0& I& 0\\ 0& I& 0& 0\\ -I& 0& 0& 0\end{array}\right]& \left[\begin{array}{rrrr}0& 0& 1& 0\\ 0& 0& 0& -1\\ -1& 0& 0& 0\\ 0& 1& 0& 0\end{array}\right]& \left[\begin{array}{rrrr}1& 0& 0& 0\\ 0& 1& 0& 0\\ 0& 0& -1& 0\\ 0& 0& 0& -1\end{array}\right]\end{array}\right]\right)$ (5)

To change that representation to the chiral or Majorana representations see Setup. As is conventional in the Physics package, you can get the definition of a tensor indexing it with the keyword definition

 > $\mathrm{Dgamma}\left[\mathrm{definition}\right]$
 ${\mathrm{%AntiCommutator}}{}\left({{\mathrm{Dgamma}}}_{{\mathrm{~mu}}}{,}{{\mathrm{Dgamma}}}_{{\mathrm{~nu}}}\right){=}{2}{}{{\mathrm{g_}}}_{{\mathrm{~mu}}{,}{\mathrm{~nu}}}$ (6)

The value $0$ of a spacetime index of a tensor is always mapped into the value of the position of the time-like component (the different sign in the signature)

 > $\mathrm{Setup}\left(\mathrm{signature}\right)$
 $\left[{\mathrm{signature}}{=}{\mathrm{- - - +}}\right]$ (7)
 > $\mathrm{Library}:-\mathrm{PositionOfTimelikeComponent}\left(\right)$
 ${4}$ (8)

So with the current signature you can use Dgamma[0] to represent Dgamma[4]

 > $\mathrm{Dgamma}\left[0\right]$
 ${{\mathrm{\gamma }}}_{{4}}$ (9)

You can access the current matrix representation of each component of ${\mathrm{\gamma }}_{\mathrm{\mu }}$ in several ways, the simplest being

 > $\mathrm{Dgamma}\left[0,\mathrm{matrix}\right]$
 ${{\mathrm{Dgamma}}}_{{4}}{=}\left(\left[\begin{array}{rrrr}1& 0& 0& 0\\ 0& 1& 0& 0\\ 0& 0& -1& 0\\ 0& 0& 0& -1\end{array}\right]\right)$ (10)
 > $\mathrm{Dgamma}\left[\mathrm{~1},\mathrm{matrix}\right]$
 ${{\mathrm{Dgamma}}}_{{\mathrm{~1}}}{=}\left(\left[\begin{array}{rrrr}0& 0& 0& 1\\ 0& 0& 1& 0\\ 0& -1& 0& 0\\ -1& 0& 0& 0\end{array}\right]\right)$ (11)

The ${\mathrm{\gamma }}_{5}$ matrix in the standard representation

 > $\mathrm{Dgamma}\left[5,\mathrm{matrix}\right]$
 ${{\mathrm{Dgamma}}}_{{5}}{=}\left(\left[\begin{array}{rrrr}0& 0& -1& 0\\ 0& 0& 0& -1\\ -1& 0& 0& 0\\ 0& -1& 0& 0\end{array}\right]\right)$ (12)
 > $\mathrm{Dgamma}\left[5,\mathrm{definition}\right]$
 ${{\mathrm{\gamma }}}_{{5}}{=}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{5}}}^{\phantom{{}}{5}}{,}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{5}}}^{\phantom{{}}{5}}{=}{-i}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{0}}}^{\phantom{{}}{0}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{1}}}^{\phantom{{}}{1}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{2}}}^{\phantom{{}}{2}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{3}}}^{\phantom{{}}{3}}{,}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{5}}}^{\phantom{{}}{5}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{5}}}^{\phantom{{}}{5}}{=}{1}{,}{\mathrm{%AntiCommutator}}{}\left({{\mathrm{Dgamma}}}_{{\mathrm{~mu}}}{,}{{\mathrm{Dgamma}}}_{{\mathrm{~5}}}\right){=}{0}{,}{\mathrm{%AntiCommutator}}{}\left({{\mathrm{Dgamma}}}_{{\mathrm{~mu}}}{,}{{\mathrm{Dgamma}}}_{{\mathrm{~nu}}}\right){=}{2}{}{{g}}_{\phantom{{}}\phantom{{\mathrm{\mu }}}\phantom{{,}}\phantom{{\mathrm{\nu }}}}^{\phantom{{}}{\mathrm{\mu }}{,}{\mathrm{\nu }}}$ (13)

This definition includes several equations, two of which have AntiCommutators on the left-hand sides. A quick way of verifying tensorial equations including their matricial form is to use $\mathrm{value}\left(\mathrm{TensorArray}\left(\left[%\right],\mathrm{performmatrixoperations}\right)\right)$. One can apply this command selectively, for example for the first three of these defining equations, then to only the fourth one

 > $\mathrm{value}\left(\mathrm{TensorArray}\left(\left[\right]\left[1..3\right],\mathrm{performmatrixoperations}\right)\right)$
 $\left[\left(\left[\begin{array}{rrrr}0& 0& -1& 0\\ 0& 0& 0& -1\\ -1& 0& 0& 0\\ 0& -1& 0& 0\end{array}\right]\right){=}\left(\left[\begin{array}{rrrr}0& 0& -1& 0\\ 0& 0& 0& -1\\ -1& 0& 0& 0\\ 0& -1& 0& 0\end{array}\right]\right){,}\left(\left[\begin{array}{rrrr}0& 0& -1& 0\\ 0& 0& 0& -1\\ -1& 0& 0& 0\\ 0& -1& 0& 0\end{array}\right]\right){=}\left(\left[\begin{array}{rrrr}0& 0& -1& 0\\ 0& 0& 0& -1\\ -1& 0& 0& 0\\ 0& -1& 0& 0\end{array}\right]\right){,}\left(\left[\begin{array}{rrrr}1& 0& 0& 0\\ 0& 1& 0& 0\\ 0& 0& 1& 0\\ 0& 0& 0& 1\end{array}\right]\right){=}{1}\right]$ (14)
 > $\mathrm{value}\left(\mathrm{TensorArray}\left(\left[\right]\left[4\right],\mathrm{performmatrixoperations}\right)\right)$
 $\left[\begin{array}{cccc}\left(\left[\begin{array}{rrrr}0& 0& 0& 0\\ 0& 0& 0& 0\\ 0& 0& 0& 0\\ 0& 0& 0& 0\end{array}\right]\right)=0& \left(\left[\begin{array}{rrrr}0& 0& 0& 0\\ 0& 0& 0& 0\\ 0& 0& 0& 0\\ 0& 0& 0& 0\end{array}\right]\right)=0& \left(\left[\begin{array}{rrrr}0& 0& 0& 0\\ 0& 0& 0& 0\\ 0& 0& 0& 0\\ 0& 0& 0& 0\end{array}\right]\right)=0& \left(\left[\begin{array}{rrrr}0& 0& 0& 0\\ 0& 0& 0& 0\\ 0& 0& 0& 0\\ 0& 0& 0& 0\end{array}\right]\right)=0\end{array}\right]$ (15)

You can compute with the tensor components and later represent them in matrix form, or perform the corresponding matrix operations

 > $\mathrm{Dgamma}\left[1\right]\mathrm{Dgamma}\left[2\right]+\mathrm{Dgamma}\left[0\right]$
 ${{\mathrm{\gamma }}}_{{1}}{}{{\mathrm{\gamma }}}_{{2}}{+}{{\mathrm{\gamma }}}_{{4}}$ (16)
 > $\mathrm{Library}:-\mathrm{RewriteInMatrixForm}\left(\right)$
 ${\mathrm{.}}{}\left(\left[\begin{array}{rrrr}0& 0& 0& -1\\ 0& 0& -1& 0\\ 0& 1& 0& 0\\ 1& 0& 0& 0\end{array}\right]{,}\left[\begin{array}{cccc}0& 0& 0& I\\ 0& 0& -I& 0\\ 0& -I& 0& 0\\ I& 0& 0& 0\end{array}\right]\right){+}\left(\left[\begin{array}{rrrr}1& 0& 0& 0\\ 0& 1& 0& 0\\ 0& 0& -1& 0\\ 0& 0& 0& -1\end{array}\right]\right)$ (17)
 > $\mathrm{Library}:-\mathrm{PerformMatrixOperations}\left(\right)$
 $\left[\begin{array}{cccc}1-I& 0& 0& 0\\ 0& 1+I& 0& 0\\ 0& 0& -1-I& 0\\ 0& 0& 0& -1+I\end{array}\right]$ (18)

The Dirac matrices have representation-free properties; for example, for the trace of the product of two of them,

 > $\mathrm{Dgamma}\left[\mathrm{\mu }\right]\mathrm{Dgamma}\left[\mathrm{\nu }\right]$
 ${{\mathrm{\gamma }}}_{{\mathrm{\mu }}}{}{{\mathrm{\gamma }}}_{{\mathrm{\nu }}}$ (19)
 > $\mathrm{Trace}\left(\right)$
 ${4}{}{{g}}_{{\mathrm{\mu }}{,}{\mathrm{\nu }}}$ (20)
 > $\mathrm{Dgamma}\left[1\right]\mathrm{Dgamma}\left[2\right]+\mathrm{Dgamma}\left[2\right]\mathrm{Dgamma}\left[1\right]$
 ${{\mathrm{\gamma }}}_{{1}}{}{{\mathrm{\gamma }}}_{{2}}{+}{{\mathrm{\gamma }}}_{{2}}{}{{\mathrm{\gamma }}}_{{1}}$ (21)
 > $\mathrm{Trace}\left(\right)$
 ${0}$ (22)

Consider the following five products of Dirac matrices and their simplification using Simplify

 > $\mathrm{e0}≔{\mathrm{Dgamma}\left[\mathrm{\mu }\right]}^{2}$
 ${\mathrm{e0}}{≔}{{\mathrm{\gamma }}}_{{\mathrm{\mu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\mu }}}}^{\phantom{{}}{\mathrm{\mu }}}$ (23)
 > $\mathrm{Simplify}\left(\mathrm{e0}\right)$
 ${4}$ (24)
 > $\mathrm{e1}≔\mathrm{Dgamma}\left[\mathrm{\mu }\right]\mathrm{Dgamma}\left[\mathrm{~nu}\right]\mathrm{Dgamma}\left[\mathrm{\mu }\right]$
 ${\mathrm{e1}}{≔}{{\mathrm{\gamma }}}_{{\mathrm{\mu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\nu }}}}^{\phantom{{}}{\mathrm{\nu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\mu }}}}^{\phantom{{}}{\mathrm{\mu }}}$ (25)
 > $\mathrm{Simplify}\left(\mathrm{e1}\right)$
 ${-}{2}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\nu }}}}^{\phantom{{}}{\mathrm{\nu }}}$ (26)
 > $\mathrm{e2}≔\mathrm{Dgamma}\left[\mathrm{\mu }\right]\mathrm{Dgamma}\left[\mathrm{~lambda}\right]\mathrm{Dgamma}\left[\mathrm{~nu}\right]\mathrm{Dgamma}\left[\mathrm{\mu }\right]$
 ${\mathrm{e2}}{≔}{{\mathrm{\gamma }}}_{{\mathrm{\mu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\lambda }}}}^{\phantom{{}}{\mathrm{\lambda }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\nu }}}}^{\phantom{{}}{\mathrm{\nu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\mu }}}}^{\phantom{{}}{\mathrm{\mu }}}$ (27)
 > $\mathrm{Simplify}\left(\mathrm{e2}\right)$
 ${4}{}{{g}}_{\phantom{{}}\phantom{{\mathrm{\lambda }}}\phantom{{,}}\phantom{{\mathrm{\nu }}}}^{\phantom{{}}{\mathrm{\lambda }}{,}{\mathrm{\nu }}}$ (28)
 > $\mathrm{e3}≔\mathrm{Dgamma}\left[\mathrm{\mu }\right]\mathrm{Dgamma}\left[\mathrm{~lambda}\right]\mathrm{Dgamma}\left[\mathrm{~nu}\right]\mathrm{Dgamma}\left[\mathrm{~rho}\right]\mathrm{Dgamma}\left[\mathrm{\mu }\right]$
 ${\mathrm{e3}}{≔}{{\mathrm{\gamma }}}_{{\mathrm{\mu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\lambda }}}}^{\phantom{{}}{\mathrm{\lambda }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\nu }}}}^{\phantom{{}}{\mathrm{\nu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\rho }}}}^{\phantom{{}}{\mathrm{\rho }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\mu }}}}^{\phantom{{}}{\mathrm{\mu }}}$ (29)
 > $\mathrm{Simplify}\left(\mathrm{e3}\right)$
 ${-}{2}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\rho }}}}^{\phantom{{}}{\mathrm{\rho }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\nu }}}}^{\phantom{{}}{\mathrm{\nu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\lambda }}}}^{\phantom{{}}{\mathrm{\lambda }}}$ (30)
 > $\mathrm{e4}≔\mathrm{Dgamma}\left[\mathrm{\mu }\right]\mathrm{Dgamma}\left[\mathrm{~lambda}\right]\mathrm{Dgamma}\left[\mathrm{~nu}\right]\mathrm{Dgamma}\left[\mathrm{~rho}\right]\mathrm{Dgamma}\left[\mathrm{~sigma}\right]\mathrm{Dgamma}\left[\mathrm{\mu }\right]$
 ${\mathrm{e4}}{≔}{{\mathrm{\gamma }}}_{{\mathrm{\mu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\lambda }}}}^{\phantom{{}}{\mathrm{\lambda }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\nu }}}}^{\phantom{{}}{\mathrm{\nu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\rho }}}}^{\phantom{{}}{\mathrm{\rho }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\sigma }}}}^{\phantom{{}}{\mathrm{\sigma }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\mu }}}}^{\phantom{{}}{\mathrm{\mu }}}$ (31)
 > $\mathrm{Simplify}\left(\mathrm{e4}\right)$
 ${2}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\sigma }}}}^{\phantom{{}}{\mathrm{\sigma }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\lambda }}}}^{\phantom{{}}{\mathrm{\lambda }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\nu }}}}^{\phantom{{}}{\mathrm{\nu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\rho }}}}^{\phantom{{}}{\mathrm{\rho }}}{+}{2}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\rho }}}}^{\phantom{{}}{\mathrm{\rho }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\nu }}}}^{\phantom{{}}{\mathrm{\nu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\lambda }}}}^{\phantom{{}}{\mathrm{\lambda }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\sigma }}}}^{\phantom{{}}{\mathrm{\sigma }}}$ (32)

Verify the simplification of $\mathrm{e1}$.

 > $\mathrm{e1}=$
 ${{\mathrm{\gamma }}}_{{\mathrm{\mu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\nu }}}}^{\phantom{{}}{\mathrm{\nu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\mu }}}}^{\phantom{{}}{\mathrm{\mu }}}{=}{-}{2}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\nu }}}}^{\phantom{{}}{\mathrm{\nu }}}$ (33)
 > $\mathrm{SumOverRepeatedIndices}\left(\right)$
 ${{\mathrm{\gamma }}}_{{1}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\nu }}}}^{\phantom{{}}{\mathrm{\nu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{1}}}^{\phantom{{}}{1}}{+}{{\mathrm{\gamma }}}_{{2}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\nu }}}}^{\phantom{{}}{\mathrm{\nu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{2}}}^{\phantom{{}}{2}}{+}{{\mathrm{\gamma }}}_{{3}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\nu }}}}^{\phantom{{}}{\mathrm{\nu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{3}}}^{\phantom{{}}{3}}{+}{{\mathrm{\gamma }}}_{{4}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\nu }}}}^{\phantom{{}}{\mathrm{\nu }}}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{4}}}^{\phantom{{}}{4}}{=}{-}{2}{}{{\mathrm{\gamma }}}_{\phantom{{}}\phantom{{\mathrm{\nu }}}}^{\phantom{{}}{\mathrm{\nu }}}$ (34)

Rewrite this equation as an array with 4 tensorial equations as components (for each of the values o the contravariant spacetime index $\mathrm{\nu }$)

 > $T≔\mathrm{TensorArray}\left(\right)$
 $\left[\begin{array}{cccc}\mathrm{*}{}\left({\mathrm{Dgamma}}_{1},\mathrm{^}{}\left({\mathrm{Dgamma}}_{\mathrm{~1}},2\right)\right)+\mathrm{*}{}\left({\mathrm{Dgamma}}_{2},{\mathrm{Dgamma}}_{\mathrm{~1}},{\mathrm{Dgamma}}_{\mathrm{~2}}\right)+\mathrm{*}{}\left({\mathrm{Dgamma}}_{3},{\mathrm{Dgamma}}_{\mathrm{~1}},{\mathrm{Dgamma}}_{\mathrm{~3}}\right)+\mathrm{*}{}\left({\mathrm{Dgamma}}_{4},{\mathrm{Dgamma}}_{\mathrm{~1}},{\mathrm{Dgamma}}_{\mathrm{~4}}\right)=-2{}{\mathrm{Dgamma}}_{\mathrm{~1}}& \mathrm{*}{}\left({\mathrm{Dgamma}}_{1},{\mathrm{Dgamma}}_{\mathrm{~2}},{\mathrm{Dgamma}}_{\mathrm{~1}}\right)+\mathrm{*}{}\left({\mathrm{Dgamma}}_{2},\mathrm{^}{}\left({\mathrm{Dgamma}}_{\mathrm{~2}},2\right)\right)+\mathrm{*}{}\left({\mathrm{Dgamma}}_{3},{\mathrm{Dgamma}}_{\mathrm{~2}},{\mathrm{Dgamma}}_{\mathrm{~3}}\right)+\mathrm{*}{}\left({\mathrm{Dgamma}}_{4},{\mathrm{Dgamma}}_{\mathrm{~2}},{\mathrm{Dgamma}}_{\mathrm{~4}}\right)=-2{}{\mathrm{Dgamma}}_{\mathrm{~2}}& \mathrm{*}{}\left({\mathrm{Dgamma}}_{1},{\mathrm{Dgamma}}_{\mathrm{~3}},{\mathrm{Dgamma}}_{\mathrm{~1}}\right)+\mathrm{*}{}\left({\mathrm{Dgamma}}_{2},{\mathrm{Dgamma}}_{\mathrm{~3}},{\mathrm{Dgamma}}_{\mathrm{~2}}\right)+\mathrm{*}{}\left({\mathrm{Dgamma}}_{3},\mathrm{^}{}\left({\mathrm{Dgamma}}_{\mathrm{~3}},2\right)\right)+\mathrm{*}{}\left({\mathrm{Dgamma}}_{4},{\mathrm{Dgamma}}_{\mathrm{~3}},{\mathrm{Dgamma}}_{\mathrm{~4}}\right)=-2{}{\mathrm{Dgamma}}_{\mathrm{~3}}& \mathrm{*}{}\left({\mathrm{Dgamma}}_{1},{\mathrm{Dgamma}}_{\mathrm{~4}},{\mathrm{Dgamma}}_{\mathrm{~1}}\right)+\mathrm{*}{}\left({\mathrm{Dgamma}}_{2},{\mathrm{Dgamma}}_{\mathrm{~4}},{\mathrm{Dgamma}}_{\mathrm{~2}}\right)+\mathrm{*}{}\left({\mathrm{Dgamma}}_{3},{\mathrm{Dgamma}}_{\mathrm{~4}},{\mathrm{Dgamma}}_{\mathrm{~3}}\right)+\mathrm{*}{}\left({\mathrm{Dgamma}}_{4},\mathrm{^}{}\left({\mathrm{Dgamma}}_{\mathrm{~4}},2\right)\right)=-2{}{\mathrm{Dgamma}}_{\mathrm{~4}}\end{array}\right]$ (35)

Perform all the matrix operations in each of the components of this array.

 > $\mathrm{Library}:-\mathrm{PerformMatrixOperations}\left(T\right)$
 $\left[\begin{array}{cccc}\left(\left[\begin{array}{rrrr}0& 0& 0& -2\\ 0& 0& -2& 0\\ 0& 2& 0& 0\\ 2& 0& 0& 0\end{array}\right]\right)=\left(\left[\begin{array}{rrrr}0& 0& 0& -2\\ 0& 0& -2& 0\\ 0& 2& 0& 0\\ 2& 0& 0& 0\end{array}\right]\right)& \left(\left[\begin{array}{cccc}0& 0& 0& 2{}I\\ 0& 0& -2{}I& 0\\ 0& -2{}I& 0& 0\\ 2{}I& 0& 0& 0\end{array}\right]\right)=\left(\left[\begin{array}{cccc}0& 0& 0& 2{}I\\ 0& 0& -2{}I& 0\\ 0& -2{}I& 0& 0\\ 2{}I& 0& 0& 0\end{array}\right]\right)& \left(\left[\begin{array}{rrrr}0& 0& -2& 0\\ 0& 0& 0& 2\\ 2& 0& 0& 0\\ 0& -2& 0& 0\end{array}\right]\right)=\left(\left[\begin{array}{rrrr}0& 0& -2& 0\\ 0& 0& 0& 2\\ 2& 0& 0& 0\\ 0& -2& 0& 0\end{array}\right]\right)& \left(\left[\begin{array}{rrrr}-2& 0& 0& 0\\ 0& -2& 0& 0\\ 0& 0& 2& 0\\ 0& 0& 0& 2\end{array}\right]\right)=\left(\left[\begin{array}{rrrr}-2& 0& 0& 0\\ 0& -2& 0& 0\\ 0& 0& 2& 0\\ 0& 0& 0& 2\end{array}\right]\right)\end{array}\right]$ (36)

With the conventions used, among ${\mathrm{\gamma }}_{\mathrm{\mu }}$, only ${\mathrm{\gamma }}_{0}$ (consequently, when $d=4,{\mathrm{\gamma }}_{5}$ too) changes in form between the chiral and standard representations.

The standard representation is also defined in lower dimensions. For example, if you change the dimension to 3 and check the signature

 > $\mathrm{Setup}\left(\mathrm{dimension}=3,\mathrm{signature}\right)$
 ${\mathbit{Warning, unable to define the Pauli sigma matrices \left(Psigma\right) as a tensor in a spacetime with dimension =}}{}{\mathbf{3}}{}{\mathbit{where the metric is not Euclidean. You can still refer to the Pauli matrices using}}{}{{\mathbit{Psigma}}}_{{\mathbit{x}}}{}{\mathbit{,}}{}{{\mathbit{Psigma}}}_{{\mathbit{y}}}{}{\mathbit{and}}{}{{\mathbit{Psigma}}}_{{\mathbit{z}}}$
 $\mathrm{The dimension and signature of the tensor space are set to}{}\left[3{,}{}{}\left(\mathrm{- - +}\right)\right]$
 $\left[{\mathrm{dimension}}{=}{3}{,}{\mathrm{signature}}{=}{\mathrm{- - +}}\right]$ (37)
 > $\mathrm{Dgamma}\left[\mathrm{~1},\mathrm{matrix}\right]$
 ${{\mathrm{Dgamma}}}_{{\mathrm{~1}}}{=}\left(\left[\begin{array}{cc}0& I\\ I& 0\end{array}\right]\right)$ (38)
 > $\mathrm{Setup}\left(\mathrm{dimension}=2\right)$
 ${\mathbit{Warning, unable to define the Pauli sigma matrices \left(Psigma\right) as a tensor in a space with dimension =}}{}{\mathbf{2}}{}{\mathbit{< 3. You can still refer to the Pauli matrices using}}{}{{\mathbit{Psigma}}}_{{\mathbit{x}}}{}{\mathbit{,}}{}{{\mathbit{Psigma}}}_{{\mathbit{y}}}{}{\mathbit{and}}{}{{\mathbit{Psigma}}}_{{\mathbit{z}}}$
 ${\mathbit{Warning, unable to set the algebra of Pauli matrices \left(Psigma\right) in tensorial form in a space with dimension =}}{}{\mathbf{2}}{}{\mathbit{< 3}}$
 $\mathrm{The dimension and signature of the tensor space are set to}{}\left[2{,}{}{}\left(\mathrm{- +}\right)\right]$
 $\left[{\mathrm{dimension}}{=}{2}\right]$ (39)
 > $\mathrm{Dgamma}\left[\mathrm{~1},\mathrm{matrix}\right]$
 ${{\mathrm{Dgamma}}}_{{\mathrm{~1}}}{=}\left(\left[\begin{array}{rr}0& 1\\ -1& 0\end{array}\right]\right)$ (40)

Reset the dimension to 4 and check the metric

 > $\mathrm{Setup}\left(\mathrm{dimension}=4\right)$
 $\mathrm{Defined Pauli sigma matrices \left(Psigma\right):}{}{\mathrm{\sigma }}_{1}{},{}{\mathrm{\sigma }}_{2}{},{}{\mathrm{\sigma }}_{3}{},{}{\mathrm{\sigma }}_{0}$
 $\mathrm{__________________________________________________}$
 $\mathrm{The dimension and signature of the tensor space are set to}{}\left[4{,}{}{}\left(\mathrm{- - - +}\right)\right]$
 $\left[{\mathrm{dimension}}{=}{4}\right]$ (41)
 > $\mathrm{g_}\left[\right]$
 ${}_{}$