# Classification of generalised higher-order Einstein-Maxwell Lagrangians

Aimeric Colléaux, David Langlois, Karim Noui

► To cite this version:

Aimeric Colléaux, David Langlois, Karim Noui. Classification of generalised higher-order Einstein-Maxwell Lagrangians. Journal of High Energy Physics, 2024, 03, pp.041. 10.1007/JHEP03(2024)041. hal-04385650

HAL Id: hal-04385650

https://hal.science/hal-04385650

Submitted on 4 Apr 2024

HAL is a multi-disciplinary open access
archive for the deposit and dissemination of sci-
entific research documents, whether they are pub-
lished or not. The documents may come from
teaching and research institutions in France or
abroad, or from public or private research centers.

L'archive ouverte pluridisciplinaire HAL, est
destinée au dépôt et à la diffusion de documents
scientifiques de niveau recherche, publiés ou non,
émanant des établissements d'enseignement et de
recherche français ou étrangers, des laboratoires
publics ou privés.

<figure><img src="image_1.png" /></figure>

Distributed under a Creative Commons Attribution 4.0 International License
<figure><img src="image_1.png" /></figure>

RECEIVED: February 8, 2024

ACCEPTED: February 12, 2024

PUBLISHED: March 7, 2024

# Classification of generalised higher-order Einstein-Maxwell Lagrangians

Aimeric Colléaux<sup>1, a</sup> David Langlois<sup>1, b</sup> and Karim Noui<sup>1, c</sup>

E-mail: aimericcx@gmail.com, langlois@apc.univ-paris7.fr, karim.noui@ijclab.in2p3.fr

**ABSTRACT:** We classify all higher-order generalised Einstein-Maxwell Lagrangians that include terms linear in the curvature tensor and quadratic in the derivatives of the electromagnetic field strength tensor. Using redundancies due to the Bianchi identities, dimensionally dependent identities and boundary terms, we show that a general Lagrangian of this form can always be reduced to a linear combination of only 21 terms, with coefficients that are arbitrary functions of the two scalar invariants derived from the field strength. We give an explicit choice of basis where these 21 terms include 3 terms linear in the Riemann tensor and 18 terms quadratic in the derivatives of the field strength.

**KEYWORDS:** Classical Theories of Gravity, Gauge Symmetry, Effective Field Theories

ARXIV ePRINT: 2312.14814

<footnote><sup>a</sup>Astrophysics Research Center, The Open University of Israel, Ra’anana, Israel</footnote>

<footnote><sup>b</sup>Astroparticule et Cosmologie, Université Paris Cité, CNRS, F-75013 Paris, France</footnote>

<footnote><sup>c</sup>Laboratoire de Physique des deux Infinis IJCLab, Université Paris Saclay, CNRS, Orsay, France</footnote>
<figure><img src="image_2.png" /></figure>

# Classification of generalised higher-order Einstein-Maxwell Lagrangians

Aimeric Colléaux<sup>1, a</sup> David Langlois<sup>1, b</sup> and Karim Noui<sup>1, c</sup>

E-mail: aimericcx@gmail.com, langlois@apc.univ-paris7.fr, karim.noui@ijclab.in2p3.fr

**ABSTRACT:** We classify all higher-order generalised Einstein-Maxwell Lagrangians that include terms linear in the curvature tensor and quadratic in the derivatives of the electromagnetic field strength tensor. Using redundancies due to the Bianchi identities, dimensionally dependent identities and boundary terms, we show that a general Lagrangian of this form can always be reduced to a linear combination of only 21 terms, with coefficients that are arbitrary functions of the two scalar invariants derived from the field strength. We give an explicit choice of basis where these 21 terms include 3 terms linear in the Riemann tensor and 18 terms quadratic in the derivatives of the field strength.

**KEYWORDS:** Classical Theories of Gravity, Gauge Symmetry, Effective Field Theories

ARXIV ePRINT: 2312.14814

<footnote><sup>a</sup>Astrophysics Research Center, The Open University of Israel, Ra’anana, Israel</footnote>

<footnote><sup>b</sup>Astroparticule et Cosmologie, Université Paris Cité, CNRS, F-75013 Paris, France</footnote>

<footnote><sup>c</sup>Laboratoire de Physique des deux Infinis IJCLab, Université Paris Saclay, CNRS, Orsay, France</footnote>
# Contents

<table><tbody><tr><td>1</td><td>Introduction</td><td>1</td></tr><tr><td>2</td><td>Higher-order Einstein-Maxwell theories</td><td>3</td></tr><tr><td>3</td><td>Riemann-dependent terms</td><td>6</td></tr><tr><td>4</td><td>Quadratic terms in ∇F</td><td>7</td></tr><tr><td>4.1</td><td>Two main families of terms</td><td>7</td></tr><tr><td>4.2</td><td>Bianchi identities</td><td>8</td></tr><tr><td>4.3</td><td>Dimensionally dependent identities</td><td>9</td></tr><tr><td>5</td><td>Boundary terms</td><td>11</td></tr><tr><td>5.1</td><td>Dressed vertex vectors</td><td>11</td></tr><tr><td>5.2</td><td>Divergence of the vertex vectors</td><td>11</td></tr><tr><td>5.3</td><td>Divergenceless vectors</td><td>12</td></tr><tr><td>5.4</td><td>DDIs for the boundary terms</td><td>13</td></tr><tr><td>6</td><td>Basis of elementary Lagrangians</td><td>13</td></tr><tr><td>7</td><td>Conclusions</td><td>14</td></tr><tr><td>A</td><td>Dimensionally dependent identities</td><td>15</td></tr><tr><td>A.1</td><td>Diagrammatic classification</td><td>16</td></tr><tr><td>A.2</td><td>Colour bounds and Laplace expansions</td><td>18</td></tr><tr><td>A.3</td><td>Algebraic basis of scalar invariants in two, three and four dimensions</td><td>19</td></tr><tr><td>A.4</td><td>Redundancy of 2-index H tensor</td><td>20</td></tr><tr><td>A.5</td><td>Connected scalar diagrams</td><td>21</td></tr></tbody></table>

## 1 Introduction

The construction of scalar-tensor theories and vector-tensor theories with non-minimal coupling to the spacetime curvature in 4 dimensions was explored systematically by Horndeski almost half a century ago [1, 2]. In doing so, he imposed the apparently reasonable restriction that the equations of motion should be second-order. This condition was believed, until a few years ago, to be indispensable to avoid the presence of extra degrees of freedom, known as Ostrogradski ghosts, which are expected to lead to problematic instabilities.<fnref n="1" />

However, it was later realised that imposing second-order equations of motion turns out to be too restrictive. Indeed, as shown explicitly in the context of scalar-tensor theories, it is possible to construct Lagrangians that lead to higher-order (third or fourth order) equations of

<footnote n="1">¹From the EFT (Effective Field Theory) point of view, extra degrees of freedom of this type might be acceptable, provided they cannot be excited in the regime of validity of the theory.</footnote>
# Contents

<table><tr><td>1</td><td>Introduction</td><td>1</td></tr><tr><td>2</td><td>Higher-order Einstein-Maxwell theories</td><td>3</td></tr><tr><td>3</td><td>Riemann-dependent terms</td><td>6</td></tr><tr><td>4</td><td>Quadratic terms in ∇F</td><td>7</td></tr><tr><td>4.1</td><td>Two main families of terms</td><td>7</td></tr><tr><td>4.2</td><td>Bianchi identities</td><td>8</td></tr><tr><td>4.3</td><td>Dimensionally dependent identities</td><td>9</td></tr><tr><td>5</td><td>Boundary terms</td><td>11</td></tr><tr><td>5.1</td><td>Dressed vertex vectors</td><td>11</td></tr><tr><td>5.2</td><td>Divergence of the vertex vectors</td><td>11</td></tr><tr><td>5.3</td><td>Divergenceless vectors</td><td>12</td></tr><tr><td>5.4</td><td>DDIs for the boundary terms</td><td>13</td></tr><tr><td>6</td><td>Basis of elementary Lagrangians</td><td>13</td></tr><tr><td>7</td><td>Conclusions</td><td>14</td></tr><tr><td>A</td><td>Dimensionally dependent identities</td><td>15</td></tr><tr><td>A.1</td><td>Diagrammatic classification</td><td>16</td></tr><tr><td>A.2</td><td>Colour bounds and Laplace expansions</td><td>18</td></tr><tr><td>A.3</td><td>Algebraic basis of scalar invariants in two, three and four dimensions</td><td>19</td></tr><tr><td>A.4</td><td>Redundancy of 2-index H tensor</td><td>20</td></tr><tr><td>A.5</td><td>Connected scalar diagrams</td><td>21</td></tr></table>

## 1 Introduction

The construction of scalar-tensor theories and vector-tensor theories with non-minimal coupling to the spacetime curvature in 4 dimensions was explored systematically by Horndeski almost half a century ago [1, 2]. In doing so, he imposed the apparently reasonable restriction that the equations of motion should be second-order. This condition was believed, until a few years ago, to be indispensable to avoid the presence of extra degrees of freedom, known as Ostrogradski ghosts, which are expected to lead to problematic instabilities.<fnref n="1" />

However, it was later realised that imposing second-order equations of motion turns out to be too restrictive. Indeed, as shown explicitly in the context of scalar-tensor theories, it is possible to construct Lagrangians that lead to higher-order (third or fourth order) equations of

<footnote n="1">¹From the EFT (Effective Field Theory) point of view, extra degrees of freedom of this type might be acceptable, provided they cannot be excited in the regime of validity of the theory.</footnote>
motion but do not contain any extra degree of freedom, provided they satisfy some degeneracy conditions [3, 4].<fnref n="2" /> These theories, dubbed DHOST theories in [7], were fully classified up to quadratic order (in second derivatives of the scalar field) in [3] and up to cubic order later in [8] (see [9] and [10] for reviews). This type of construction was also considered in the case of vector-tensor theories of gravity, dubbed generalised Proca theories [11–14], as well as in higher order extensions of Einstein-Maxwell theory from disformal transformations [15, 16]. In the present work, we focus our attention on U(1) vector-tensor theories non-minimally coupled to gravity, including derivatives of the field strength in their Lagrangian.

From the results of Horndeski in [2], it can be seen that in flat four-dimensional spacetime, there is no theory quadratic in the derivatives of the field strength which yields second order field equations. Note that this result has been partially extended to arbitrary dimensions in [17]. Historically, the first theory of this type has been proposed many decades ago by Bopp and Podolsky in [18, 19] as an improvement of the UV behaviour of classical electrodynamics. For instance, the Coulomb potential is non-singular at the origin in this model. More general Lagrangians quadratic in the derivative of the field strength can also be found in the context of quantum electrodynamics (QED), where the derivative expansion of the one-loop effective action, obtained by integrating out the electron in an external slowly varying electromagnetic field precisely generate such effective self-interactions, generalising the famous Euler-Heisenberg action [20–25].

As far as effective interactions between gravity and electromagnetism are concerned, the one-(electron)-loop effective action in the presence of weak external gravitational and electromagnetic fields has been found by Drummond and Hathrel [26]. Its generalisations for strong external and slowly varying fields have been investigated in [27, 28] and precisely fall into the family of Lagrangians we are going to study. Interesting implications of these QED-induced non-minimal couplings are ranging from superluminality [29] to gravitational birefringence and their effect on gravitational waves [30, 31]. New non-minimally coupled theories, which preserve the duality-invariance of Maxwell theory and conformal electrodynamics (see [32, 33]), have also been obtained recently [34, 35]. Interestingly, much like non-minimal couplings involving a non-abelian gauge field [36], some models yield non-singular black hole solutions [37].

In the present article, our goal is to classify all possible Lagrangians that are linear in the curvature and quadratic in derivatives of the field strength tensor, without investigating at this stage the presence and nature of potential extra degrees of freedom. A first exploration of the presence of extra degrees of freedom will be considered for the flat case in a future work. Even limiting the Lagrangians to terms linear in the curvature and quadratic in the field strength derivatives, the number of possible terms appears enormous. Fortunately, there exists a number of redundancies, which we exploit systematically in order to drastically reduce the number of terms that need to be taken into account in a generic Lagrangian. These redundancies follow from a) the index symmetries of the various possible scalar terms; b) the Bianchi identities resulting from the U(1) symmetry of the vector field; c) the Bianchi identities of the Riemann tensor; d) the dimensionally dependent identities (DDIs); e) the boundary terms.

<footnote n="2">²See [5, 6] for earlier works pointing to viable theories beyond the Horndeski family, although it was not yet realised that degeneracy was the key ingredient to avoid extra degrees of freedom.</footnote>
motion but do not contain any extra degree of freedom, provided they satisfy some degeneracy conditions [3, 4].<fnref n="2" /> These theories, dubbed DHOST theories in [7], were fully classified up to quadratic order (in second derivatives of the scalar field) in [3] and up to cubic order later in [8] (see [9] and [10] for reviews). This type of construction was also considered in the case of vector-tensor theories of gravity, dubbed generalised Proca theories [11–14], as well as in higher order extensions of Einstein-Maxwell theory from disformal transformations [15, 16]. In the present work, we focus our attention on U(1) vector-tensor theories non-minimally coupled to gravity, including derivatives of the field strength in their Lagrangian.

From the results of Horndeski in [2], it can be seen that in flat four-dimensional spacetime, there is no theory quadratic in the derivatives of the field strength which yields second order field equations. Note that this result has been partially extended to arbitrary dimensions in [17]. Historically, the first theory of this type has been proposed many decades ago by Bopp and Podolsky in [18, 19] as an improvement of the UV behaviour of classical electrodynamics. For instance, the Coulomb potential is non-singular at the origin in this model. More general Lagrangians quadratic in the derivative of the field strength can also be found in the context of quantum electrodynamics (QED), where the derivative expansion of the one-loop effective action, obtained by integrating out the electron in an external slowly varying electromagnetic field precisely generate such effective self-interactions, generalising the famous Euler-Heisenberg action [20–25].

As far as effective interactions between gravity and electromagnetism are concerned, the one-(electron)-loop effective action in the presence of weak external gravitational and electromagnetic fields has been found by Drummond and Hathrel [26]. Its generalisations for strong external and slowly varying fields have been investigated in [27, 28] and precisely fall into the family of Lagrangians we are going to study. Interesting implications of these QED-induced non-minimal couplings are ranging from superluminality [29] to gravitational birefringence and their effect on gravitational waves [30, 31]. New non-minimally coupled theories, which preserve the duality-invariance of Maxwell theory and conformal electrodynamics (see [32, 33]), have also been obtained recently [34, 35]. Interestingly, much like non-minimal couplings involving a non-abelian gauge field [36], some models yield non-singular black hole solutions [37].

In the present article, our goal is to classify all possible Lagrangians that are linear in the curvature and quadratic in derivatives of the field strength tensor, without investigating at this stage the presence and nature of potential extra degrees of freedom. A first exploration of the presence of extra degrees of freedom will be considered for the flat case in a future work. Even limiting the Lagrangians to terms linear in the curvature and quadratic in the field strength derivatives, the number of possible terms appears enormous. Fortunately, there exists a number of redundancies, which we exploit systematically in order to drastically reduce the number of terms that need to be taken into account in a generic Lagrangian. These redundancies follow from a) the index symmetries of the various possible scalar terms; b) the Bianchi identities resulting from the U(1) symmetry of the vector field; c) the Bianchi identities of the Riemann tensor; d) the dimensionally dependent identities (DDIs); e) the boundary terms.

<footnote n="2">²See [5, 6] for earlier works pointing to viable theories beyond the Horndeski family, although it was not yet realised that degeneracy was the key ingredient to avoid extra degrees of freedom.</footnote>
Taking into account the first four redundancies, which are purely algebraic, we show that the most general Lagrangian of our interest can be written as a linear combination of 4 Riemann-linear terms and 22 field-strength-quadratic terms, whose coefficients are arbitrary functions of the two scalar invariants constructed from the field-strength tensor. We finally find five independent boundary terms of the appropriate form, which enables us to further reduce the number of terms in the minimal Lagrangian to 21.

The structure of this article is the following. In the next section, we present the general action describing the theories we are interested in, introduce some useful notations, and explain how we will proceed to eliminate redundant terms. In section 3, we examine the Riemann-dependent terms and show that they can be reduced to only 4 terms. We then turn, in section 4 to the major part of this work, where we show that all the terms quadratic in the derivatives of the field strength can be represented by only 22 terms. After this purely algebraic analysis, we discuss, in section 5, how boundary terms can also reduce the minimal number of terms in the most general Lagrangian: we identify 5 relevant boundary terms. As summarised in section 6, this means that the most general Lagrangian can be written as a linear combination of only 21 terms, up to arbitrary coefficients that are scalar functions of the two electromagnetic invariants. We conclude in the final section. More technical aspects on our derivations are provided in an appendix.

## 2 Higher-order Einstein-Maxwell theories

We consider the most general family of four-dimensional abelian vector-tensor theories that are linear in the curvature tensor<fnref n="3" /> and quadratic in the covariant derivative of the Faraday tensor, or field strength,

$$F_{ab} = \nabla_a A_b - \nabla_b A_a \qquad (2.1)$$

where $A_a$ is the gauge potential vector. The action describing these theories can be written in the form

$$S = \int d^4 x \sqrt{-g} \left( L_0 + \frac{1}{4} A^{abcd} R_{abcd} + B^{abc,def} \nabla_a F_{bc} \nabla_d F_{ef} \right), \qquad (2.2)$$

where the scalar $L_0$ and the tensors $A^{abcd}$ and $B^{abc,def}$ contain all possible terms that can be built from combinations of the metric $g_{ab}$, of the Levi-Civita tensor $\epsilon_{abcd}$ and of the Faraday tensor $F_{ab}$. Of course, the tensors $A^{abcd}$ and $B^{abc,def}$ can be simplified by taking into account the symmetries of the Riemann tensor or of the term quadratic in the covariant derivative of $F_{ab}$: for instance, any term in $A^{abcd}$ that is symmetric with respect to the indices $a$ and $b$ is irrelevant since it will disappear after contraction with the Riemann tensor.

Let us first recall that one can construct two scalars from the field strength tensor (2.1), which correspond to the two well-known Lorentz invariants available in standard electromagnetism, namely

$$f_2 \equiv F^{ab} F_{ab}, \qquad f_* \equiv *F_{ab} F^{ab}, \qquad (2.3)$$

<footnote n="3">³Our convention for the Riemann tensor is such that $(\nabla_a \nabla_b - \nabla_b \nabla_a) v_c = R_{abc}{}^d v_d$.</footnote>
Taking into account the first four redundancies, which are purely algebraic, we show that the most general Lagrangian of our interest can be written as a linear combination of 4 Riemann-linear terms and 22 field-strength-quadratic terms, whose coefficients are arbitrary functions of the two scalar invariants constructed from the field-strength tensor. We finally find five independent boundary terms of the appropriate form, which enables us to further reduce the number of terms in the minimal Lagrangian to 21.

The structure of this article is the following. In the next section, we present the general action describing the theories we are interested in, introduce some useful notations, and explain how we will proceed to eliminate redundant terms. In section 3, we examine the Riemann-dependent terms and show that they can be reduced to only 4 terms. We then turn, in section 4 to the major part of this work, where we show that all the terms quadratic in the derivatives of the field strength can be represented by only 22 terms. After this purely algebraic analysis, we discuss, in section 5, how boundary terms can also reduce the minimal number of terms in the most general Lagrangian: we identify 5 relevant boundary terms. As summarised in section 6, this means that the most general Lagrangian can be written as a linear combination of only 21 terms, up to arbitrary coefficients that are scalar functions of the two electromagnetic invariants. We conclude in the final section. More technical aspects on our derivations are provided in an appendix.

## 2 Higher-order Einstein-Maxwell theories

We consider the most general family of four-dimensional abelian vector-tensor theories that are linear in the curvature tensor<fnref n="3" /> and quadratic in the covariant derivative of the Faraday tensor, or field strength,

$$F_{ab} = \nabla_a A_b - \nabla_b A_a \qquad (2.1)$$

where $A_a$ is the gauge potential vector. The action describing these theories can be written in the form

$$S = \int d^4 x \sqrt{-g} \left( L_0 + \frac{1}{4} A^{abcd} R_{abcd} + B^{abc,def} \nabla_a F_{bc} \nabla_d F_{ef} \right), \qquad (2.2)$$

where the scalar $L_0$ and the tensors $A^{abcd}$ and $B^{abc,def}$ contain all possible terms that can be built from combinations of the metric $g_{ab}$, of the Levi-Civita tensor $\epsilon_{abcd}$ and of the Faraday tensor $F_{ab}$. Of course, the tensors $A^{abcd}$ and $B^{abc,def}$ can be simplified by taking into account the symmetries of the Riemann tensor or of the term quadratic in the covariant derivative of $F_{ab}$: for instance, any term in $A^{abcd}$ that is symmetric with respect to the indices $a$ and $b$ is irrelevant since it will disappear after contraction with the Riemann tensor.

Let us first recall that one can construct two scalars from the field strength tensor (2.1), which correspond to the two well-known Lorentz invariants available in standard electromagnetism, namely

$$f_2 \equiv F^{ab} F_{ab}, \qquad f_* \equiv *F_{ab} F^{ab}, \qquad (2.3)$$

<footnote n="3">³Our convention for the Riemann tensor is such that $(\nabla_a \nabla_b - \nabla_b \nabla_a) v_c = R_{abc}{}^d v_d$.</footnote>
where

$$ *F_{ab} \equiv \frac{1}{2} \epsilon_{abcd} F^{cd} \qquad (2.4) $$

is the dual field strength.

In order to use compact notations, it will be very useful to define the tensors $F_I^{ab}$ where the index $I$ corresponds to the number of contracted Faraday tensors, i.e.

$$ F_{2b}^{a} \equiv F_{c}^{a} F_{b}^{c}, \quad F_{3b}^{a} \equiv F_{c}^{a} F_{d}^{c} F_{b}^{d}, \quad \text{etc.} \qquad (2.5) $$

and, for later convenience, we also generalise this notation to include the metric and the field strength, so that

$$ F_{0b}^{a} \equiv g_{b}^{a}, \quad F_{1b}^{a} \equiv F_{b}^{a}. \qquad (2.6) $$

It is worth noting that, due to the Cayley-Hamilton relation in four dimensions, any $F_K^{ab}$ with $K \ge 4$ can always be written in terms of the first four tensors of the tower, namely $F_I^{ab}$ with $0 \le I \le 3$. Indeed, the identity

$$ \delta_{[b}^{a} F^{e_1}_{e_1} F^{e_2}_{e_2} F^{e_3}_{e_3} F^{e_4}_{e_4}] = 0, \qquad (2.7) $$

where the brackets denote antisymmetrisation over the corresponding indices, leads to the Cayley-Hamilton relation

$$ F_{4b}^{a} + \frac{1}{2} f_2 F_{2b}^{a} - \frac{1}{4} (f_4 - \frac{1}{2} f_2^2) \delta_{b}^{a} = 0, \qquad (2.8) $$

where we have introduced

$$ f_4 \equiv F_2^{ab} F_{2ab} = F_{4a}^{a}. \qquad (2.9) $$

This implies that $F_4^{ab}$ can be rewritten as a linear combination of lower weight$^4$ tensors $F_2^{ab}$ and $g_{ab}$, with coefficients that depend on the two scalars $f_2$ and $f_4$.

By induction, all tensors $F_I^{ab}$ with $I$ even can similarly be expressed as linear combinations of the two tensors $F_2^{ab}$ and $g_{ab}$ with coefficients that are functions of the two scalars $f_2$ and $f_4$. Moreover, by contracting (2.8) by $F_c^b$, one finds that $F_5^{ab}$ can be written in terms of $F_3^{ab}$ and $F^{ab}$ and of the scalars $f_2$ and $f_4$. Again by induction, the same applies to any tensor $F_I^{ab}$ with $I$ odd.

As mentioned earlier, we allow the Lagrangian terms in (2.2) to include a dependence on the Levi-Civita tensor $\epsilon_{abcd}$. Since

$$ \epsilon_{abcd} \epsilon^{efgh} = -\delta_{abcd}^{efgh}, \qquad (2.10) $$

where $\delta$ on the right hand side is the generalised Kronecker symbol (which corresponds to an antisymmetrised product of usual Kronecker symbols), any tensor that is constructed with an even number of $\epsilon_{abcd}$, which we call an even-parity tensor, can be equivalently expressed without resorting to $\epsilon_{abcd}$. For odd-parity tensors, i.e. which contains an odd number of

<footnote>$^4$Throughout this paper, the weight of any scalar appearing in the action (2.2) denotes the number of field strength $F$ contained in $A$ or $B$.</footnote>
where

$$ *F_{ab} \equiv \frac{1}{2} \epsilon_{abcd} F^{cd} \qquad (2.4) $$

is the dual field strength.

In order to use compact notations, it will be very useful to define the tensors $F_I^{ab}$ where the index $I$ corresponds to the number of contracted Faraday tensors, i.e.

$$ F_{2b}^{a} \equiv F_{c}^{a} F_{b}^{c}, \quad F_{3b}^{a} \equiv F_{c}^{a} F_{d}^{c} F_{b}^{d}, \quad \text{etc.} \qquad (2.5) $$

and, for later convenience, we also generalise this notation to include the metric and the field strength, so that

$$ F_{0b}^{a} \equiv g_{b}^{a}, \quad F_{1b}^{a} \equiv F_{b}^{a}. \qquad (2.6) $$

It is worth noting that, due to the Cayley-Hamilton relation in four dimensions, any $F_K^{ab}$ with $K \ge 4$ can always be written in terms of the first four tensors of the tower, namely $F_I^{ab}$ with $0 \le I \le 3$. Indeed, the identity

$$ \delta_{[b}^{a} F^{e_1}_{e_1} F^{e_2}_{e_2} F^{e_3}_{e_3} F^{e_4}_{e_4}] = 0, \qquad (2.7) $$

where the brackets denote antisymmetrisation over the corresponding indices, leads to the Cayley-Hamilton relation

$$ F_{4b}^{a} + \frac{1}{2} f_2 F_{2b}^{a} - \frac{1}{4} (f_4 - \frac{1}{2} f_2^2) \delta_{b}^{a} = 0, \qquad (2.8) $$

where we have introduced

$$ f_4 \equiv F_2^{ab} F_{2ab} = F_{4a}^{a}. \qquad (2.9) $$

This implies that $F_4^{ab}$ can be rewritten as a linear combination of lower weight$^4$ tensors $F_2^{ab}$ and $g_{ab}$, with coefficients that depend on the two scalars $f_2$ and $f_4$.

By induction, all tensors $F_I^{ab}$ with $I$ even can similarly be expressed as linear combinations of the two tensors $F_2^{ab}$ and $g_{ab}$ with coefficients that are functions of the two scalars $f_2$ and $f_4$. Moreover, by contracting (2.8) by $F_c^b$, one finds that $F_5^{ab}$ can be written in terms of $F_3^{ab}$ and $F^{ab}$ and of the scalars $f_2$ and $f_4$. Again by induction, the same applies to any tensor $F_I^{ab}$ with $I$ odd.

As mentioned earlier, we allow the Lagrangian terms in (2.2) to include a dependence on the Levi-Civita tensor $\epsilon_{abcd}$. Since

$$ \epsilon_{abcd} \epsilon^{efgh} = -\delta_{abcd}^{efgh}, \qquad (2.10) $$

where $\delta$ on the right hand side is the generalised Kronecker symbol (which corresponds to an antisymmetrised product of usual Kronecker symbols), any tensor that is constructed with an even number of $\epsilon_{abcd}$, which we call an even-parity tensor, can be equivalently expressed without resorting to $\epsilon_{abcd}$. For odd-parity tensors, i.e. which contains an odd number of

<footnote>$^4$Throughout this paper, the weight of any scalar appearing in the action (2.2) denotes the number of field strength $F$ contained in $A$ or $B$.</footnote>
$\epsilon$, they can be rendered even by multiplication with any odd scalar, the simplest being $f_*$ introduced earlier. For example, multiplying $f_*$ by itself, one gets the even scalar

$$f_*^2 = 4 \left(f_4 - \frac{1}{2} f_2^2\right) \equiv 4g_4. \qquad (2.11)$$

As a consequence, we can safely ignore any dependence on $\epsilon_{abcd}$ in the rest of our analysis.<fnref n="5" />

From our discussion above, we conclude that all possible Lagrangian terms can be written as combinations of the form

$$\mathcal{R}_{IJ} \equiv F_I^{ab} F_J^{cd} (\alpha_{IJ} R_{abcd} + \beta_{IJ} R_{acbd}) , \quad \mathcal{F}_{IJK} = \sum_i \gamma_{IJK}^{(i)} F_I^{ab} F_J^{cd} F_K^{ef} (\nabla F \cdot \nabla F)_{ijkl}^{(i)} \qquad (2.13)$$

where $I, J, K \in \{0, 1, 2, 3\}$ and the coefficients $\alpha, \beta, \gamma$ are arbitrary scalar functions of $f_2$ and $f_4$. The last term on the right-hand side of the second relation denotes all possible combinations of the six free indices in $\nabla F \cdot \nabla F$.

Modulo the arbitrary scalar coefficients, the number of terms of the above form is finite but still remains high. As we will see below, this number can be further reduced by systematically taking into account various identities. The first category of identities are the Bianchi identities, both for the Riemann tensor,

$$R_{[abc]d} = 0, \qquad (2.14)$$

and for the field strength

$$\nabla_{[a} F_{bc]} = 0. \qquad (2.15)$$

Other useful identities are the dimensionally dependent identities (DDIs) [38]. These identities simply come from the fact that, in a 4-dimensional spacetime, all tensors that are antisymmetric with respect to 5 indices, or more, automatically vanish, so that

$$\Lambda^{\cdots [a_1 a_2 a_3 a_4 a_5]} = 0, \qquad (2.16)$$

where the dots stand for possible additional indices, which are arbitrary. The Cayley-Hamilton identity (2.8) is one particular example. In this way, one can construct scalar DDIs by contracting all indices, i.e. writing

$$\Lambda^{a_1 a_2 a_3 a_4 a_5}_{[a_1 a_2 a_3 a_4 a_5]} = 0, \qquad (2.17)$$

where $\Lambda$ is an arbitrary 10-index tensor. Note that any quantity involving more than five antisymmetrised indices can be reduced to this form by Laplace's formula for determinants. Moreover, if the tensor $\Lambda$ contains a Kronecker symbol, this would produce an overall $(d-4)$ factor, making the corresponding identity trivial.

Finally, we will also use the possibility to relate different terms up to boundary terms, since the latter are irrelevant in the equations of motion.

$$\Phi S = \tilde{\Phi} \delta_{abcd}^{efgh} F_{ef} F_{gh} S^{abcd} \equiv \tilde{\Phi} \tilde{S} \qquad (2.12)$$

<footnote n="5">⁵Indeed, given an odd scalar $S = \epsilon_{abcd}S^{abcd}$, where the tensor $S^{abcd}$ is of even parity, and a generic function $\Phi$ of $f_2$ and $f_4$, we can write</footnote>

<footnote>where $\tilde{S}$ is a parity even scalar and $\tilde{\Phi} = \Phi/(4\sqrt{g_4})$, choosing the negative branch of the square-root.</footnote>
$\epsilon$, they can be rendered even by multiplication with any odd scalar, the simplest being $f_*$ introduced earlier. For example, multiplying $f_*$ by itself, one gets the even scalar

$$f_*^2 = 4 \left(f_4 - \frac{1}{2} f_2^2\right) \equiv 4g_4. \qquad (2.11)$$

As a consequence, we can safely ignore any dependence on $\epsilon_{abcd}$ in the rest of our analysis.<fnref n="5" />

From our discussion above, we conclude that all possible Lagrangian terms can be written as combinations of the form

$$\mathcal{R}_{IJ} \equiv F_I^{ab} F_J^{cd} (\alpha_{IJ} R_{abcd} + \beta_{IJ} R_{acbd}) , \quad \mathcal{F}_{IJK} = \sum_i \gamma_{IJK}^{(i)} F_I^{ab} F_J^{cd} F_K^{ef} (\nabla F \cdot \nabla F)_{ijklm}^{(i)} \qquad (2.13)$$

where $I, J, K \in \{0, 1, 2, 3\}$ and the coefficients $\alpha, \beta, \gamma$ are arbitrary scalar functions of $f_2$ and $f_4$. The last term on the right-hand side of the second relation denotes all possible combinations of the six free indices in $\nabla F \cdot \nabla F$.

Modulo the arbitrary scalar coefficients, the number of terms of the above form is finite but still remains high. As we will see below, this number can be further reduced by systematically taking into account various identities. The first category of identities are the Bianchi identities, both for the Riemann tensor,

$$R_{[abc]d} = 0, \qquad (2.14)$$

and for the field strength

$$\nabla_{[a} F_{bc]} = 0. \qquad (2.15)$$

Other useful identities are the dimensionally dependent identities (DDIs) [38]. These identities simply come from the fact that, in a 4-dimensional spacetime, all tensors that are antisymmetric with respect to 5 indices, or more, automatically vanish, so that

$$\Lambda^{\cdots [a_1 a_2 a_3 a_4 a_5]} = 0, \qquad (2.16)$$

where the dots stand for possible additional indices, which are arbitrary. The Cayley-Hamilton identity (2.8) is one particular example. In this way, one can construct scalar DDIs by contracting all indices, i.e. writing

$$\Lambda^{a_1 a_2 a_3 a_4 a_5}_{[a_1 a_2 a_3 a_4 a_5]} = 0, \qquad (2.17)$$

where $\Lambda$ is an arbitrary 10-index tensor. Note that any quantity involving more than five antisymmetrised indices can be reduced to this form by Laplace's formula for determinants. Moreover, if the tensor $\Lambda$ contains a Kronecker symbol, this would produce an overall $(d-4)$ factor, making the corresponding identity trivial.

Finally, we will also use the possibility to relate different terms up to boundary terms, since the latter are irrelevant in the equations of motion.

$$\Phi S = \tilde{\Phi} \delta_{abcd}^{efgh} F_{ef} F_{gh} S^{abcd} \equiv \tilde{\Phi} \tilde{S} \qquad (2.12)$$

<footnote n="5">⁵Indeed, given an odd scalar $S = \epsilon_{abcd}S^{abcd}$, where the tensor $S^{abcd}$ is of even parity, and a generic function $\Phi$ of $f_2$ and $f_4$, we can write</footnote>

<footnote>where $\tilde{S}$ is a parity even scalar and $\tilde{\Phi} = \Phi/(4\sqrt{g_4})$, choosing the negative branch of the square-root.</footnote>
### 3 Riemann-dependent terms

We start by the classification of all the terms that are linear in the Riemann tensor, of the form

$$ \mathcal{R}_{IJ} \equiv F_I^{ab} F_J^{cd} (\alpha_{IJ} R_{abcd} + \beta_{IJ} R_{acbd}) \equiv \mathcal{R}_{IJ}^{(\alpha)} + \mathcal{R}_{IJ}^{(\beta)}. \quad (3.1) $$

It can be checked that the sum of the indices $I+J$ has to be even, otherwise one of the indices, say $I$, is even and the other one is odd, which implies that $\mathcal{R}_{IJ}$ vanishes due to the symmetries of the Riemann tensor since $F_I$ is symmetric and $F_J$ antisymmetric. Moreover the terms $\mathcal{R}_{IJ}^{(\alpha)}$ vanish when either $I$ or $J$ is even, again because of the symmetries of the Riemann tensor. The non-trivial terms that remain are thus $\mathcal{R}_{00}^{(\beta)}$, $\mathcal{R}_{02}^{(\beta)}$, $\mathcal{R}_{22}^{(\beta)}$, $\mathcal{R}_{11}$, $\mathcal{R}_{13}$ and $\mathcal{R}_{33}$.

Taking into account the first Bianchi identities for the Riemann tensor (2.14), we obtain the relation

$$ F_I^{ab} F_J^{cd} (R_{abcd} - 2R_{acbd}) = 0, \quad \text{for } I \text{ and } J \text{ odd} \quad (3.2) $$

which shows that all the $\mathcal{R}_{IJ}^{(\beta)}$ can be reexpressed as $\mathcal{R}_{IJ}^{(\alpha)}$ when both $I$ and $J$ are odd. We are now left with $\mathcal{R}_{00}^{(\beta)}$, $\mathcal{R}_{02}^{(\beta)}$, $\mathcal{R}_{22}^{(\beta)}$, $\mathcal{R}_{11}^{(\alpha)}$, $\mathcal{R}_{13}^{(\alpha)}$ and $\mathcal{R}_{33}^{(\alpha)}$.

Finally, we investigate whether some of these terms could be related by scalar DDIs of the form (2.17), when the tensor $\Lambda$ contains the Riemann tensor and products of the field strength. Due to the Bianchi identities (2.14), the antisymmetrisation must involve at most two indices of the Riemann tensor, with the other indices coming from the $F_I$. In order to reach a total of 10 indices, this means that the tensor $\Lambda$ must contain at least three $F_I$, which leads us to relations of the form$^6$

$$ \mathcal{R}_{IJK} \equiv F_{I[a_1}^{a_1} F_{Ja_2}^{a_2} F_{Ka_3}^{a_3} (\alpha_{IJK} R_{a_4 a_5}]^{a_4 a_5} + \beta_{IJK} R^{a_4}_{\quad a_4 a_5}]^{a_5}) = 0, \quad (3.3) $$

where $I, J, K \in \{1, 2, 3\}$ (we do not include the index 0 since it would induce a delta function and therefore a trivial identity) and $4 \le I + J + K \le 6$ (since the terms $\mathcal{R}_{LM}$ are at most of weight 6, i.e. $L + M \le 6$). Even if three $F_I$ appear in the above expressions, the expansion of (3.3) and the contraction of all indices necessarily leads to final terms with at most two $F_I$ contracted with the Riemann tensor, i.e. exactly of the form (3.1).

Eventually we find only two non-trivial expressions from (3.3). The first, corresponding to $(IJK) = (112)$, reads

$$ F_2^{ab} F_2^{cd} R_{abcd} - 2 F^{ab} F_3^{cd} (R_{abcd} - R_{abcd}) + \frac{1}{2} f_2 F^{ab} F^{cd} (R_{abcd} - R_{abcd}) + \frac{1}{4} g_4 R = 0 \quad (3.4) $$

and can be further simplified using (3.2) to yield

$$ 2 F_2^{ab} F_2^{cd} R_{abcd} + 2 F^{ab} F_3^{cd} R_{abcd} - \frac{1}{2} f_2 F^{ab} F^{cd} R_{abcd} + \frac{1}{2} g_4 R = 0. \quad (3.5) $$

The second relation, corresponding to $(IJK) = (123)$, yields, after simplification with (3.2)

$$ F_3^{ab} F_3^{cd} R_{abcd} + f_2 F_2^{ab} F_2^{cd} R_{abcd} + \frac{1}{4} g_4 F^{ab} F^{cd} R_{abcd} + g_4 F_2^{ab} R_{ab} = 0. \quad (3.6) $$

<footnote>$^6$Note that the terms $F_{I[a_1}^{a_1} F_{Ja_2}^{a_2} F_{Ka_3}^{a_3} F_{La_4}^{a_4} R_{a_5]}^{a_5}$ can have the colour indices $(IJKL) = (1111)$ or $(2211)$. In both cases the result is trivial.</footnote>
### 3 Riemann-dependent terms

We start by the classification of all the terms that are linear in the Riemann tensor, of the form

$$ \mathcal{R}_{IJ} \equiv F_I^{ab} F_J^{cd} (\alpha_{IJ} R_{abcd} + \beta_{IJ} R_{acbd}) \equiv \mathcal{R}_{IJ}^{(\alpha)} + \mathcal{R}_{IJ}^{(\beta)}. \quad (3.1) $$

It can be checked that the sum of the indices $I+J$ has to be even, otherwise one of the indices, say $I$, is even and the other one is odd, which implies that $\mathcal{R}_{IJ}$ vanishes due to the symmetries of the Riemann tensor since $F_I$ is symmetric and $F_J$ antisymmetric. Moreover the terms $\mathcal{R}_{IJ}^{(\alpha)}$ vanish when either $I$ or $J$ is even, again because of the symmetries of the Riemann tensor. The non-trivial terms that remain are thus $\mathcal{R}_{00}^{(\beta)}$, $\mathcal{R}_{02}^{(\beta)}$, $\mathcal{R}_{22}^{(\beta)}$, $\mathcal{R}_{11}$, $\mathcal{R}_{13}$ and $\mathcal{R}_{33}$.

Taking into account the first Bianchi identities for the Riemann tensor (2.14), we obtain the relation

$$ F_I^{ab} F_J^{cd} (R_{abcd} - 2R_{acbd}) = 0, \quad \text{for } I \text{ and } J \text{ odd} \quad (3.2) $$

which shows that all the $\mathcal{R}_{IJ}^{(\beta)}$ can be reexpressed as $\mathcal{R}_{IJ}^{(\alpha)}$ when both $I$ and $J$ are odd. We are now left with $\mathcal{R}_{00}^{(\beta)}$, $\mathcal{R}_{02}^{(\beta)}$, $\mathcal{R}_{22}^{(\beta)}$, $\mathcal{R}_{11}^{(\alpha)}$, $\mathcal{R}_{13}^{(\alpha)}$ and $\mathcal{R}_{33}^{(\alpha)}$.

Finally, we investigate whether some of these terms could be related by scalar DDIs of the form (2.17), when the tensor $\Lambda$ contains the Riemann tensor and products of the field strength. Due to the Bianchi identities (2.14), the antisymmetrisation must involve at most two indices of the Riemann tensor, with the other indices coming from the $F_I$. In order to reach a total of 10 indices, this means that the tensor $\Lambda$ must contain at least three $F_I$, which leads us to relations of the form$^6$

$$ \mathcal{R}_{IJK} \equiv F_{I[a_1}^{a_1} F_{Ja_2}^{a_2} F_{Ka_3}^{a_3} (\alpha_{IJK} R_{a_4 a_5}]^{a_4 a_5} + \beta_{IJK} R^{a_4}_{\quad a_4} R^{a_5}_{\quad a_5}) = 0, \quad (3.3) $$

where $I, J, K \in \{1, 2, 3\}$ (we do not include the index 0 since it would induce a delta function and therefore a trivial identity) and $4 \le I + J + K \le 6$ (since the terms $\mathcal{R}_{LM}$ are at most of weight 6, i.e. $L + M \le 6$). Even if three $F_I$ appear in the above expressions, the expansion of (3.3) and the contraction of all indices necessarily leads to final terms with at most two $F_I$ contracted with the Riemann tensor, i.e. exactly of the form (3.1).

Eventually we find only two non-trivial expressions from (3.3). The first, corresponding to $(IJK) = (112)$, reads

$$ F_2^{ab} F_2^{cd} R_{abcd} - 2 F^{ab} F_3^{cd} (R_{abcd} - R_{abcd}) + \frac{1}{2} f_2 F^{ab} F^{cd} (R_{abcd} - R_{abcd}) + \frac{1}{4} g_4 R = 0 \quad (3.4) $$

and can be further simplified using (3.2) to yield

$$ 2 F_2^{ab} F_2^{cd} R_{abcd} + 2 F^{ab} F_3^{cd} R_{abcd} - \frac{1}{2} f_2 F^{ab} F^{cd} R_{abcd} + \frac{1}{2} g_4 R = 0. \quad (3.5) $$

The second relation, corresponding to $(IJK) = (123)$, yields, after simplification with (3.2)

$$ F_3^{ab} F_3^{cd} R_{abcd} + f_2 F_2^{ab} F_2^{cd} R_{abcd} + \frac{1}{4} g_4 F^{ab} F^{cd} R_{abcd} + g_4 F_2^{ab} R_{ab} = 0. \quad (3.6) $$

<footnote>$^6$Note that the terms $F_{I[a_1}^{a_1} F_{Ja_2}^{a_2} F_{Ka_3}^{a_3} F_{La_4}^{a_4} R_{a_5]}^{a_5}$ can have the colour indices $(IJKL) = (1111)$ or $(2211)$. In both cases the result is trivial.</footnote>
The second relation tells us that the term $F_3^{ab}F_3^{cd}R_{abcd}$, of weight 6, can always be replaced by terms of lower weight, up to some scalar multiplicative coefficients,<fnref n="7" /> and therefore does not have to be considered in the Lagrangian. Similarly, the relation (3.5) tells us that one of the first two terms can be expressed in terms of the other one and of lower weight terms.

In summary, all the possible Riemann-linear terms in the action can be written as linear combinations of only four terms, with scalar coefficients that depend on $f_2$ and $f_4$,

$$ \mathcal{R}_1 \equiv R, \quad \mathcal{R}_2 \equiv F^{ab}F^{cd}R_{abcd}, \quad \mathcal{R}_3 \equiv F_2^{ab}R_{ab}, \quad \mathcal{R}_4 \equiv F^{ab}F_3^{cd}R_{abcd} \quad (\text{or } F_2^{ab}F_2^{cd}R_{abcd}). \qquad (3.7) $$

We have kept an alternative choice for the last term, but we will see later that this term can be eliminated in favour of other terms in the Lagrangian, thanks to boundary terms.

# 4 Quadratic terms in $\nabla F$

The goal of this section is to determine the minimal number of terms of the form

$$ B^{abc,def}\nabla_a F_{bc}\nabla_d F_{ef}, \qquad (4.1) $$

taking into account the index symmetries, the Bianchi identities and the dimensional identities.

For a pictorial representation of these terms, one can imagine that each $\nabla_e F_{ab}$ is a three-limb vertex, with a single leg corresponding to the covariant derivative index $e$ and two arms associated with the indices of the antisymmetric tensor $F_{ab}$. Each term in (4.1) thus corresponds to two vertices whose limbs are all connected, and “dressed”, by “coloured” links that consist of

$$ F_I^{ab} \quad \text{with} \quad I \in \{0, 1, 2, 3\}. \qquad (4.2) $$

In the following, we will call the indices $I$ “colour” indices to distinguish them from the spacetime indices denoted by a lowercase latin letter.

## 4.1 Two main families of terms

Among all possible scalar terms, it is useful to distinguish the family where the two vertices share all three links, family which can be subdivided into two subfamilies:

$$ \mathcal{A}_{IJK} = F_I^{ad} F_J^{bf} F_K^{ec} \nabla_e F_{ab} \nabla_f F_{cd} \qquad (4.3) $$

and

$$ \tilde{\mathcal{A}}_{IJK} = F_I^{ad} F_J^{bc} F_K^{ef} \nabla_e F_{ab} \nabla_f F_{cd}. \qquad (4.4) $$

In the first subfamily, each leg is connected to one of the arms of the other vertex, whereas in the second subfamily, the two vertex legs are interconnected.

It is immediate to check that the above terms satisfy the following symmetries under permutation of two colour indices:

$$ \mathcal{A}_{IJK} = (-1)^{I+J+K} \mathcal{A}_{IKJ}, \quad \tilde{\mathcal{A}}_{IJK} = \tilde{\mathcal{A}}_{JIK} = (-1)^{I+J+K} \tilde{\mathcal{A}}_{JIK}, \qquad (4.5) $$

<footnote n="7">⁷Of course, the total weight, when the weight of the scalar coefficients is taken account, is unchanged.</footnote>
The second relation tells us that the term $F_3^{ab}F_3^{cd}R_{abcd}$, of weight 6, can always be replaced by terms of lower weight, up to some scalar multiplicative coefficients,<fnref n="7" /> and therefore does not have to be considered in the Lagrangian. Similarly, the relation (3.5) tells us that one of the first two terms can be expressed in terms of the other one and of lower weight terms.

In summary, all the possible Riemann-linear terms in the action can be written as linear combinations of only four terms, with scalar coefficients that depend on $f_2$ and $f_4$,

$$ \mathcal{R}_1 \equiv R, \quad \mathcal{R}_2 \equiv F^{ab}F^{cd}R_{abcd}, \quad \mathcal{R}_3 \equiv F_2^{ab}R_{ab}, \quad \mathcal{R}_4 \equiv F^{ab}F_3^{cd}R_{abcd} \quad (\text{or } F_2^{ab}F_2^{cd}R_{abcd}). \qquad (3.7) $$

We have kept an alternative choice for the last term, but we will see later that this term can be eliminated in favour of other terms in the Lagrangian, thanks to boundary terms.

# 4 Quadratic terms in $\nabla F$

The goal of this section is to determine the minimal number of terms of the form

$$ B^{abc,def}\nabla_a F_{bc}\nabla_d F_{ef}, \qquad (4.1) $$

taking into account the index symmetries, the Bianchi identities and the dimensional identities.

For a pictorial representation of these terms, one can imagine that each $\nabla_e F_{ab}$ is a three-limb vertex, with a single leg corresponding to the covariant derivative index $e$ and two arms associated with the indices of the antisymmetric tensor $F_{ab}$. Each term in (4.1) thus corresponds to two vertices whose limbs are all connected, and “dressed”, by “coloured” links that consist of

$$ F_I^{ab} \quad \text{with} \quad I \in \{0, 1, 2, 3\}. \qquad (4.2) $$

In the following, we will call the indices $I$ “colour” indices to distinguish them from the spacetime indices denoted by a lowercase latin letter.

## 4.1 Two main families of terms

Among all possible scalar terms, it is useful to distinguish the family where the two vertices share all three links, family which can be subdivided into two subfamilies:

$$ \mathcal{A}_{IJK} = F_I^{ad} F_J^{bf} F_K^{ec} \nabla_e F_{ab} \nabla_f F_{cd} \qquad (4.3) $$

and

$$ \tilde{\mathcal{A}}_{IJK} = F_I^{ad} F_J^{bc} F_K^{ef} \nabla_e F_{ab} \nabla_f F_{cd}. \qquad (4.4) $$

In the first subfamily, each leg is connected to one of the arms of the other vertex, whereas in the second subfamily, the two vertex legs are interconnected.

It is immediate to check that the above terms satisfy the following symmetries under permutation of two colour indices:

$$ \mathcal{A}_{IJK} = (-1)^{I+J+K} \mathcal{A}_{IKJ}, \quad \tilde{\mathcal{A}}_{IJK} = \tilde{\mathcal{A}}_{JIK} = (-1)^{I+J+K} \tilde{\mathcal{A}}_{JIK}, \qquad (4.5) $$

<footnote n="7">⁷Of course, the total weight, when the weight of the scalar coefficients is taken account, is unchanged.</footnote>
which implies that $I + J + K$ must be even to get a nonzero $\tilde{\mathcal{A}}$. As a consequence of these symmetries, one finds 32 independent $\mathcal{A}$ terms,<fnref n="8" /> and 20 independent $\tilde{\mathcal{A}}$ terms.<fnref n="9" />

For the other family of scalar terms, only one link is shared by the two vertices, which leads to three subfamilies, depending whether this link connects two arms, two legs or one leg with an arm, respectively. The corresponding definitions are given by

$$ \mathcal{B}_{IJK} = F_I^{ad} F_J^{eb} F_K^{cf} \nabla_e F_{ab} \nabla_f F_{cd} \quad (4.6) $$

and

$$ \tilde{\mathcal{B}}_{IJK} = F_I^{ef} F_J^{ab} F_K^{cd} \nabla_e F_{ab} \nabla_f F_{cd}, \quad \hat{\mathcal{B}}_{IJK} = F_I^{bf} F_J^{ae} F_K^{cd} \nabla_e F_{ab} \nabla_f F_{cd}. \quad (4.7) $$

These new terms satisfy the following symmetries under exchange of the colour indices,

$$ \mathcal{B}_{IJK} = (-1)^{I+J+K} \mathcal{B}_{IKJ}, \quad \tilde{\mathcal{B}}_{IJK} = (-1)^I \tilde{\mathcal{B}}_{IKJ}. \quad (4.8) $$

Moreover, by exchanging the two arms of a vertex whenever they are interconnected, one obtains the following identities,

$$ \tilde{\mathcal{B}}_{IJK} = (-1)^{J+1} \tilde{\mathcal{B}}_{IJK} = (-1)^{K+1} \tilde{\mathcal{B}}_{IJK}, \quad \hat{\mathcal{B}}_{IJK} = (-1)^{K+1} \tilde{\mathcal{B}}_{IJK}, \quad (4.9) $$

which simply state that the colour indices $J$ and $K$ must be odd in $\tilde{\mathcal{B}}_{IJK}$, whereas $K$ must be odd in $\hat{\mathcal{B}}_{IJK}$. As a consequence of these symmetries, we find 32 independent $\mathcal{B}$ terms (since they have the same symmetries as the $\mathcal{A}$ terms), 8 independent $\tilde{\mathcal{B}}$ terms<fnref n="10" /> and 32 independent $\hat{\mathcal{B}}$ terms.<fnref n="11" /> It is easy to convince oneself that all possible terms can be rewritten into one of the five forms above, up to some trivial permutation of spacetime indices. Overall, given a two-form $F$ in four dimensions, there are 124 scalars of the form (4.1).

## 4.2 Bianchi identities

Let us now exploit the Bianchi identities (2.15) satisfied by the Faraday tensor, which can be written as

$$ \nabla_e F_{ab} + \nabla_a F_{be} + \nabla_b F_{ea} = 0. \quad (4.10) $$

Replacing $\nabla_e F_{ab}$ in the definition (4.3) of $\mathcal{A}$ by the above relation, one obtains the sum of three terms, which are deduced from each other by a “rotation”, i.e. a circular permutation, of the limbs of the first vertex. After some straightforward reshuffling of the indices, this leads to the relation

$$ \mathcal{A}_{IJK} + \mathcal{A}_{KJI} - \tilde{\mathcal{A}}_{IKJ} = 0. \quad (4.11) $$

<footnote n="8">⁸The nonzero independent terms are described by e.g. $J \le K$ for $I$ even, which gives $10 \times 2 = 20$ terms and $J < K$ for $I$ odd, which gives $6 \times 2 = 12$ terms. Hence a total of 32.</footnote>

<footnote n="9">⁹The nonzero independent $\tilde{\mathcal{A}}$ terms are described by $I \le J$ with $I + J$ even for $K$ even, which gives $6 \times 2 = 12$ terms, and $I < J$ with $I + J$ odd for $K$ odd, which gives $4 \times 2 = 8$ terms. Hence a total of 20.</footnote>

<footnote n="10">¹⁰For $I$ even, the independent $\tilde{\mathcal{B}}$ terms are described by $J \le K$, with $J$ and $K$ odd, which gives $2 \times 3 = 6$ terms. For $I$ odd, the independent $\tilde{\mathcal{B}}$ terms are described by $J < K$, with $J$ and $K$ odd, which gives 2 terms. Hence a total of 8.</footnote>

<footnote n="11">¹¹Since $K$ is odd, we have $4 \times 4 \times 2 = 32$ terms.</footnote>
which implies that $I + J + K$ must be even to get a nonzero $\tilde{\mathcal{A}}$. As a consequence of these symmetries, one finds 32 independent $\mathcal{A}$ terms,<fnref n="8" /> and 20 independent $\tilde{\mathcal{A}}$ terms.<fnref n="9" />

For the other family of scalar terms, only one link is shared by the two vertices, which leads to three subfamilies, depending whether this link connects two arms, two legs or one leg with an arm, respectively. The corresponding definitions are given by

$$ \mathcal{B}_{IJK} = F_I^{ad} F_J^{eb} F_K^{cf} \nabla_e F_{ab} \nabla_f F_{cd} \quad (4.6) $$

and

$$ \tilde{\mathcal{B}}_{IJK} = F_I^{ef} F_J^{ab} F_K^{cd} \nabla_e F_{ab} \nabla_f F_{cd}, \quad \hat{\mathcal{B}}_{IJK} = F_I^{bf} F_J^{ae} F_K^{cd} \nabla_e F_{ab} \nabla_f F_{cd}. \quad (4.7) $$

These new terms satisfy the following symmetries under exchange of the colour indices,

$$ \mathcal{B}_{IJK} = (-1)^{I+J+K} \tilde{\mathcal{B}}_{IKJ}, \quad \tilde{\mathcal{B}}_{IJK} = (-1)^I \tilde{\mathcal{B}}_{IKJ}. \quad (4.8) $$

Moreover, by exchanging the two arms of a vertex whenever they are interconnected, one obtains the following identities,

$$ \tilde{\mathcal{B}}_{IJK} = (-1)^{J+1} \tilde{\mathcal{B}}_{IJK} = (-1)^{K+1} \tilde{\mathcal{B}}_{IJK}, \quad \hat{\mathcal{B}}_{IJK} = (-1)^{K+1} \tilde{\mathcal{B}}_{IJK}, \quad (4.9) $$

which simply state that the colour indices $J$ and $K$ must be odd in $\tilde{\mathcal{B}}_{IJK}$, whereas $K$ must be odd in $\hat{\mathcal{B}}_{IJK}$. As a consequence of these symmetries, we find 32 independent $\mathcal{B}$ terms (since they have the same symmetries as the $\mathcal{A}$ terms), 8 independent $\tilde{\mathcal{B}}$ terms<fnref n="10" /> and 32 independent $\hat{\mathcal{B}}$ terms.<fnref n="11" /> It is easy to convince oneself that all possible terms can be rewritten into one of the five forms above, up to some trivial permutation of spacetime indices. Overall, given a two-form $F$ in four dimensions, there are 124 scalars of the form (4.1).

## 4.2 Bianchi identities

Let us now exploit the Bianchi identities (2.15) satisfied by the Faraday tensor, which can be written as

$$ \nabla_e F_{ab} + \nabla_a F_{be} + \nabla_b F_{ea} = 0. \quad (4.10) $$

Replacing $\nabla_e F_{ab}$ in the definition (4.3) of $\mathcal{A}$ by the above relation, one obtains the sum of three terms, which are deduced from each other by a “rotation”, i.e. a circular permutation, of the limbs of the first vertex. After some straightforward reshuffling of the indices, this leads to the relation

$$ \mathcal{A}_{IJK} + \mathcal{A}_{KJI} - \tilde{\mathcal{A}}_{IKJ} = 0. \quad (4.11) $$

<footnote n="8">⁸The nonzero independent terms are described by e.g. $J \le K$ for $I$ even, which gives $10 \times 2 = 20$ terms and $J < K$ for $I$ odd, which gives $6 \times 2 = 12$ terms. Hence a total of 32.</footnote>

<footnote n="9">⁹The nonzero independent $\tilde{\mathcal{A}}$ terms are described by $I \le J$ with $I + J$ even for $K$ even, which gives $6 \times 2 = 12$ terms, and $I < J$ with $I + J$ odd for $K$ odd, which gives $4 \times 2 = 8$ terms. Hence a total of 20.</footnote>

<footnote n="10">¹⁰For $I$ even, the independent $\tilde{\mathcal{B}}$ terms are described by $J \le K$, with $J$ and $K$ odd, which gives $2 \times 3 = 6$ terms. For $I$ odd, the independent $\tilde{\mathcal{B}}$ terms are described by $J < K$, with $J$ and $K$ odd, which gives 2 terms. Hence a total of 8.</footnote>

<footnote n="11">¹¹Since $K$ is odd, we have $4 \times 4 \times 2 = 32$ terms.</footnote>
As a consequence, one finds that all the $\tilde{\mathcal{A}}$ terms can be reexpressed in terms of the $\mathcal{A}$ terms via the relation

$$ \tilde{\mathcal{A}}_{IJK} = \mathcal{A}_{IKJ} + \mathcal{A}_{JKI}. \qquad (4.12) $$

Moreover, for the indices $(IJK)$ such that $I+J+K$ is odd, we have seen that $\tilde{\mathcal{A}}_{IJK} = 0$. One thus obtains additional relations, which provide 10 independent constraints<fnref n="12" /> between the $\mathcal{A}$ terms themselves, leaving 22 independent $\mathcal{A}$ terms.

The Bianchi identities also provide some relations between the 1-limb sharing terms. Indeed, starting from the $\mathcal{B}$ term and effecting a “rotation” of the second vertex, one gets the relation

$$ \mathcal{B}_{IJK} - (-1)^K \mathcal{B}_{IJK} + (-1)^J \hat{\mathcal{B}}_{IJK} = 0. \qquad (4.13) $$

Since $K$ must be odd to have a nonzero $\hat{\mathcal{B}}_{IJK}$, this implies that all the nonzero $\hat{\mathcal{B}}$ terms can be expressed as functions of the $\mathcal{B}$, according to the expression

$$ \hat{\mathcal{B}}_{IJK} = -2(-1)^J \mathcal{B}_{IJK} \quad \text{for } K \text{ odd.} \qquad (4.14) $$

Similarly, a rotation of the first vertex in the expression of $\tilde{\mathcal{B}}_{IJK}$ yields

$$ \tilde{\mathcal{B}}_{IJK} + (-1)^J \hat{\mathcal{B}}_{IJK} - \hat{\mathcal{B}}_{IJK} = 0. \qquad (4.15) $$

For $J$ even, this relation does not bring anything new, since we already know that $\tilde{\mathcal{B}}_{IJK} = 0$ in this case. For $J$ odd, we get $\tilde{\mathcal{B}}_{IJK} = 2\hat{\mathcal{B}}_{IJK}$, which implies $\tilde{\mathcal{B}}_{IJK} = 0$ for $K$ even, which we knew already. Finally, in the case where $J$ and $K$ are odd, we obtain, after substitution of (4.14), the new relation

$$ \tilde{\mathcal{B}}_{IJK} = 4\mathcal{B}_{IJK} \quad \text{for } J \text{ and } K \text{ odd,} \qquad (4.16) $$

which thus determines all the nonzero $\tilde{\mathcal{B}}$ in terms of the $\mathcal{B}$.

In summary, taking into account the index symmetries and the 70 independent Bianchi identities, we have found that all possible terms of the form (4.1) can be expressed as combinations of 22 $\mathcal{A}$ terms and 32 $\mathcal{B}$ terms.

## 4.3 Dimensionally dependent identities

We now consider scalar DDIs of the form (2.17) that provide relations between the $\mathcal{A}$ and $\mathcal{B}$ families of terms. To obtain such terms, the tensor $\Lambda$ in (2.17) must contain two derivatives of $F$ and arbitrary combinations of $F_I$ with possibly internal contractions such that the whole tensor possesses 10 free indices. In other words, the $\Lambda$ tensor can be seen as a (tensor) product

<footnote n="12">¹²One can first consider the cases $I=J$ with $K$ odd, for which (4.12) implies $\mathcal{A}_{IKI} = 0$ and thus $\mathcal{A}_{IJK} = 0$. This yields the 4 constraints $\mathcal{A}_{001} = \mathcal{A}_{003} = \mathcal{A}_{113} = \mathcal{A}_{223} = 0$. Let us now consider the cases $I \neq J$. Since all the constraints are symmetric in the exchange of $I$ and $J$, one can assume $I < J$. If $I+J$ is odd, and $K$ is thus even, one obtains in principle 6 relations, but 2 are redundant with the previous ones, so only 4 remain: $\mathcal{A}_{120} = \mathcal{A}_{012}$, $\mathcal{A}_{302} = \mathcal{A}_{023}$, $\mathcal{A}_{201} = -\mathcal{A}_{102}$, $\mathcal{A}_{212} = 0$. Finally, if $I+J$ is even, and thus $K$ odd, we get 4 relations but 2 are redundant, so only 2 remain: $\mathcal{A}_{203} = -\mathcal{A}_{023}$ and $\mathcal{A}_{313} = 0$.</footnote>
As a consequence, one finds that all the $\tilde{\mathcal{A}}$ terms can be reexpressed in terms of the $\mathcal{A}$ terms via the relation

$$ \tilde{\mathcal{A}}_{IJK} = \mathcal{A}_{IKJ} + \mathcal{A}_{JKI}. \qquad (4.12) $$

Moreover, for the indices $(IJK)$ such that $I+J+K$ is odd, we have seen that $\tilde{\mathcal{A}}_{IJK} = 0$. One thus obtains additional relations, which provide 10 independent constraints<fnref n="12" /> between the $\mathcal{A}$ terms themselves, leaving 22 independent $\mathcal{A}$ terms.

The Bianchi identities also provide some relations between the 1-limb sharing terms. Indeed, starting from the $\mathcal{B}$ term and effecting a “rotation” of the second vertex, one gets the relation

$$ \mathcal{B}_{IJK} - (-1)^K \mathcal{B}_{IJK} + (-1)^J \hat{\mathcal{B}}_{IJK} = 0. \qquad (4.13) $$

Since $K$ must be odd to have a nonzero $\hat{\mathcal{B}}_{IJK}$, this implies that all the nonzero $\hat{\mathcal{B}}$ terms can be expressed as functions of the $\mathcal{B}$, according to the expression

$$ \hat{\mathcal{B}}_{IJK} = -2(-1)^J \mathcal{B}_{IJK} \quad \text{for } K \text{ odd.} \qquad (4.14) $$

Similarly, a rotation of the first vertex in the expression of $\tilde{\mathcal{B}}_{IJK}$ yields

$$ \tilde{\mathcal{B}}_{IJK} + (-1)^J \hat{\mathcal{B}}_{IJK} - \hat{\mathcal{B}}_{IJK} = 0. \qquad (4.15) $$

For $J$ even, this relation does not bring anything new, since we already know that $\tilde{\mathcal{B}}_{IJK} = 0$ in this case. For $J$ odd, we get $\tilde{\mathcal{B}}_{IJK} = 2\hat{\mathcal{B}}_{IJK}$, which implies $\tilde{\mathcal{B}}_{IJK} = 0$ for $K$ even, which we knew already. Finally, in the case where $J$ and $K$ are odd, we obtain, after substitution of (4.14), the new relation

$$ \tilde{\mathcal{B}}_{IJK} = 4\mathcal{B}_{IJK} \quad \text{for } J \text{ and } K \text{ odd,} \qquad (4.16) $$

which thus determines all the nonzero $\tilde{\mathcal{B}}$ in terms of the $\mathcal{B}$.

In summary, taking into account the index symmetries and the 70 independent Bianchi identities, we have found that all possible terms of the form (4.1) can be expressed as combinations of 22 $\mathcal{A}$ terms and 32 $\mathcal{B}$ terms.

## 4.3 Dimensionally dependent identities

We now consider scalar DDIs of the form (2.17) that provide relations between the $\mathcal{A}$ and $\mathcal{B}$ families of terms. To obtain such terms, the tensor $\Lambda$ in (2.17) must contain two derivatives of $F$ and arbitrary combinations of $F_I$ with possibly internal contractions such that the whole tensor possesses 10 free indices. In other words, the $\Lambda$ tensor can be seen as a (tensor) product

<footnote n="12">¹²One can first consider the cases $I=J$ with $K$ odd, for which (4.12) implies $\mathcal{A}_{IKI} = 0$ and thus $\mathcal{A}_{IJK} = 0$. This yields the 4 constraints $\mathcal{A}_{001} = \mathcal{A}_{003} = \mathcal{A}_{113} = \mathcal{A}_{223} = 0$. Let us now consider the cases $I \neq J$. Since all the constraints are symmetric in the exchange of $I$ and $J$, one can assume $I < J$. If $I+J$ is odd, and $K$ is thus even, one obtains in principle 6 relations, but 2 are redundant with the previous ones, so only 4 remain: $\mathcal{A}_{120} = \mathcal{A}_{012}$, $\mathcal{A}_{302} = \mathcal{A}_{023}$, $\mathcal{A}_{201} = -\mathcal{A}_{102}$, $\mathcal{A}_{212} = 0$. Finally, if $I+J$ is even, and thus $K$ odd, we get 4 relations but 2 are redundant, so only 2 remain: $\mathcal{A}_{203} = -\mathcal{A}_{023}$ and $\mathcal{A}_{313} = 0$.</footnote>
of two vertices and of several $F_I$. The systematic exploration of all possible $\Lambda$ tensors and corresponding DDI relations is a bit involved and the details are explained in the appendix.

Many of these identities, especially when the Bianchi identities are taken into account, turn out to be redundant. We have thus identified 32 independent DDIs, which can be obtained from a single type of expression for the $\Lambda$ tensor, which we give here explicitly. In order to express the $\Lambda$ tensor with ten contravariant indices, we introduce the partially antisymmetric tensor

$$ \Delta_{a_1 a_2 a_3 a_4 a_5 b_1 b_2 b_3 b_4 b_5} = \delta^{c_1 c_2 c_3 c_4 c_5}_{a_1 a_2 a_3 a_4 a_5} \prod_{n=1}^{5} g_{c_n b_n}, \qquad (4.17) $$

so that the scalar DDIs (2.17) are now written in the form

$$ \Delta_{a_1 a_2 a_3 a_4 a_5 b_1 b_2 b_3 b_4 b_5} \Lambda^{a_1 a_2 a_3 a_4 a_5 b_1 b_2 b_3 b_4 b_5} = 0. \qquad (4.18) $$

Let us also introduce the “dressed” vertex tensors

$$ T_{IJK}^{abc} \equiv F_I^{ae} F_J^{bf} F_K^{cg} \nabla_e F_{fg}, \qquad (4.19) $$

which are useful for the systematic investigation of all possible DDIs, as discussed in the appendix. The only family of relevant DDI identities can then be obtained from

$$ \mathcal{D}_{IJKL} \equiv \Delta_{a_1 a_2 a_3 a_4 a_5 b_1 b_2 b_3 b_4 b_5} F^{b_4 a_4} F^{b_5 a_5} T_{KLI}^{a_1 a_2 b_1} T_{J00}^{b_2 b_3 a_3} = 0. \qquad (4.20) $$

As said above, only 32 DDIs of this class can cover them all once the Bianchi identity is taken into account. They can be chosen to be:

$$ \left\{ \begin{array}{c} \mathcal{D}_{0000} \ \mathcal{D}_{0100} \ \mathcal{D}_{1000} \ \mathcal{D}_{0002} \ \mathcal{D}_{0101} \ \mathcal{D}_{0110} \ \mathcal{D}_{0200} \ \mathcal{D}_{1001} \\ \mathcal{D}_{1010} \ \mathcal{D}_{1100} \ \mathcal{D}_{2000} \ \mathcal{D}_{2001} \ \mathcal{D}_{2010} \ \mathcal{D}_{2100} \ \mathcal{D}_{3000} \ \mathcal{D}_{1210} \\ \mathcal{D}_{1300} \ \mathcal{D}_{2002} \ \mathcal{D}_{2011} \ \mathcal{D}_{2020} \ \mathcal{D}_{2101} \ \mathcal{D}_{2110} \ \mathcal{D}_{2200} \ \mathcal{D}_{3001} \\ \mathcal{D}_{3010} \ \mathcal{D}_{3100} \ \mathcal{D}_{3110} \ \mathcal{D}_{3200} \ \mathcal{D}_{3030} \ \mathcal{D}_{3201} \ \mathcal{D}_{3210} \ \mathcal{D}_{3300} \end{array} \right\} \qquad (4.21) $$

To give an explicit example, the first DDI of the list above, $\mathcal{D}_{0000}$, gives the relation

$$ \begin{aligned} & f_2 \mathcal{A}_{000} + 4 \mathcal{A}_{002} + 2 \mathcal{A}_{011} - 4 \mathcal{A}_{101} + 2 \mathcal{A}_{200} - f_2 \tilde{\mathcal{A}}_{000} - 2 \tilde{\mathcal{A}}_{002} - 4 \tilde{\mathcal{A}}_{020} + 2 \tilde{\mathcal{A}}_{110} \\ & + f_2 \mathcal{B}_{000} + 4 \mathcal{B}_{002} + 2 \mathcal{B}_{011} - 4 \mathcal{B}_{101} + 8 \mathcal{B}_{110} + 2 \mathcal{B}_{200} + 2 \tilde{\mathcal{B}}_{011} - 4 \tilde{\mathcal{B}}_{011} + 4 \tilde{\mathcal{B}}_{101} = 0. \end{aligned} \qquad (4.22) $$

After simplification using (4.12), this reduces to

$$ 2 \mathcal{A}_{011} - 4 \mathcal{A}_{002} - 2 \mathcal{A}_{200} - f_2 \mathcal{A}_{000} + 2 \mathcal{B}_{011} + 4 \mathcal{B}_{002} - 4 \mathcal{B}_{101} + 2 \mathcal{B}_{200} + f_2 \mathcal{B}_{000} = 0, \qquad (4.23) $$

which provides a new relation between the $\mathcal{A}$ and $\mathcal{B}$ of weight 2.

In summary, the 54 remaining Lagrangian terms quadratic in $\nabla F$, which include 22 $\mathcal{A}$ terms and 32 $\mathcal{B}$ terms can be further reduced to only 22 “seed” terms, since all the other terms can be recovered from these ones. The choice of these 22 terms, together with the four Riemann terms obtained in the previous section, constitutes a choice of basis. There is some flexibility in the choice of the 22 representative terms, but it does not seem possible to eliminate all the $\mathcal{A}$ or all the $\mathcal{B}$.
of two vertices and of several $F_I$. The systematic exploration of all possible $\Lambda$ tensors and corresponding DDI relations is a bit involved and the details are explained in the appendix.

Many of these identities, especially when the Bianchi identities are taken into account, turn out to be redundant. We have thus identified 32 independent DDIs, which can be obtained from a single type of expression for the $\Lambda$ tensor, which we give here explicitly. In order to express the $\Lambda$ tensor with ten contravariant indices, we introduce the partially antisymmetric tensor

$$ \Delta_{a_1 a_2 a_3 a_4 a_5 b_1 b_2 b_3 b_4 b_5} = \delta^{c_1 c_2 c_3 c_4 c_5}_{a_1 a_2 a_3 a_4 a_5} \prod_{n=1}^{5} g_{c_n b_n}, \qquad (4.17) $$

so that the scalar DDIs (2.17) are now written in the form

$$ \Delta_{a_1 a_2 a_3 a_4 a_5 b_1 b_2 b_3 b_4 b_5} \Lambda^{a_1 a_2 a_3 a_4 a_5 b_1 b_2 b_3 b_4 b_5} = 0. \qquad (4.18) $$

Let us also introduce the “dressed” vertex tensors

$$ T_{IJK}^{abc} \equiv F_I^{ae} F_J^{bf} F_K^{cg} \nabla_e F_{fg}, \qquad (4.19) $$

which are useful for the systematic investigation of all possible DDIs, as discussed in the appendix. The only family of relevant DDI identities can then be obtained from

$$ \mathcal{D}_{IJKL} \equiv \Delta_{a_1 a_2 a_3 a_4 a_5 b_1 b_2 b_3 b_4 b_5} F^{b_4 a_4} F^{b_5 a_5} T_{KLI}^{a_1 a_2 b_1} T_{J00}^{b_2 b_3 a_3} = 0. \qquad (4.20) $$

As said above, only 32 DDIs of this class can cover them all once the Bianchi identity is taken into account. They can be chosen to be:

$$ \left\{ \begin{array}{c} \mathcal{D}_{0000} \ \mathcal{D}_{0100} \ \mathcal{D}_{1000} \ \mathcal{D}_{0002} \ \mathcal{D}_{0101} \ \mathcal{D}_{0110} \ \mathcal{D}_{0200} \ \mathcal{D}_{1001} \\ \mathcal{D}_{1010} \ \mathcal{D}_{1100} \ \mathcal{D}_{2000} \ \mathcal{D}_{2001} \ \mathcal{D}_{2010} \ \mathcal{D}_{2100} \ \mathcal{D}_{3000} \ \mathcal{D}_{1210} \\ \mathcal{D}_{1300} \ \mathcal{D}_{2002} \ \mathcal{D}_{2011} \ \mathcal{D}_{2020} \ \mathcal{D}_{2101} \ \mathcal{D}_{2110} \ \mathcal{D}_{2200} \ \mathcal{D}_{3001} \\ \mathcal{D}_{3010} \ \mathcal{D}_{3100} \ \mathcal{D}_{3110} \ \mathcal{D}_{3200} \ \mathcal{D}_{3030} \ \mathcal{D}_{3201} \ \mathcal{D}_{3210} \ \mathcal{D}_{3300} \end{array} \right\} \qquad (4.21) $$

To give an explicit example, the first DDI of the list above, $\mathcal{D}_{0000}$, gives the relation

$$ \begin{aligned} & f_2 \mathcal{A}_{000} + 4 \mathcal{A}_{002} + 2 \mathcal{A}_{011} - 4 \mathcal{A}_{101} + 2 \mathcal{A}_{200} - f_2 \tilde{\mathcal{A}}_{000} - 2 \tilde{\mathcal{A}}_{002} - 4 \tilde{\mathcal{A}}_{020} + 2 \tilde{\mathcal{A}}_{110} \\ & + f_2 \mathcal{B}_{000} + 4 \mathcal{B}_{002} + 2 \mathcal{B}_{011} - 4 \mathcal{B}_{101} + 8 \mathcal{B}_{110} + 2 \mathcal{B}_{200} + 2 \tilde{\mathcal{B}}_{011} - 4 \tilde{\mathcal{B}}_{011} + 4 \tilde{\mathcal{B}}_{101} = 0. \end{aligned} \qquad (4.22) $$

After simplification using (4.12), this reduces to

$$ 2 \mathcal{A}_{011} - 4 \mathcal{A}_{002} - 2 \mathcal{A}_{200} - f_2 \mathcal{A}_{000} + 2 \mathcal{B}_{011} + 4 \mathcal{B}_{002} - 4 \mathcal{B}_{101} + 2 \mathcal{B}_{200} + f_2 \mathcal{B}_{000} = 0, \qquad (4.23) $$

which provides a new relation between the $\mathcal{A}$ and $\mathcal{B}$ of weight 2.

In summary, the 54 remaining Lagrangian terms quadratic in $\nabla F$, which include 22 $\mathcal{A}$ terms and 32 $\mathcal{B}$ terms can be further reduced to only 22 “seed” terms, since all the other terms can be recovered from these ones. The choice of these 22 terms, together with the four Riemann terms obtained in the previous section, constitutes a choice of basis. There is some flexibility in the choice of the 22 representative terms, but it does not seem possible to eliminate all the $\mathcal{A}$ or all the $\mathcal{B}$.
# 5 Boundary terms

We now study whether it is possible to relate some of the 22 terms of the algebraic basis obtained so far, via boundary terms, since the latter are irrelevant in the equations of motion. Boundary terms are of the form $\nabla_a B^a$ where $B$ is some vector. In our case, we are interested in boundary terms $\nabla_a B^a$ that lead, when expanded, to terms quadratic in $\nabla F$, discussed in the previous section, and therefore $B$ must contain a single derivative of $F$.

## 5.1 Dressed vertex vectors

Vectors $B$ of this form are proportional to one of the following contracted dressed vertices:

$$V_{IJ}^{a} \equiv F_{I}^{ce} F_{J}^{ad} \nabla_{e} F_{cd} \qquad (5.1)$$

or

$$\tilde{V}_{IJ}^{a} \equiv F_{I}^{dc} F_{J}^{ae} \nabla_{e} F_{cd} = \frac{1}{I+1} F_{J}^{ae} \nabla_{e} (F_{I+1,d}^{d}) \qquad (5.2)$$

where the last expression shows that $\tilde{V}_{IJ}$ vanishes if $I$ is even.

Replacing $\nabla_e F_{cd}$ in (5.2), or equivalently in (5.1), by $\nabla_{[e}F_{cd]} = 0$ yields the relation

$$V_{IJ} - (-1)^{I} V_{IJ} + \tilde{V}_{IJ} = 0, \qquad (5.3)$$

which implies

$$\tilde{V}_{IJ} = -2V_{IJ} \quad \text{for } I \text{ odd,} \qquad \tilde{V}_{IJ} = 0 \quad \text{for } I \text{ even,} \qquad (5.4)$$

where we have omitted the spacetime index for all vector terms above to simplify the notation. As a consequence, we need to consider only the vectors $V_{IJ}$ since all the non-zero $\tilde{V}_{IJ}$ can be expressed in terms of them.

## 5.2 Divergence of the vertex vectors

Let us now examine, for the above vectors, in which case their divergence leads to only “permissible” terms. In other words, after the full expansion of the vector $B$, one must find only terms of the form (4.1) and, for example, no term of the form $\nabla_a \nabla_b F_{cd}$ which cannot be reduced to a Riemann term.

For $I$ odd, the divergence of

$$V_{IJ}^{a} = -\frac{1}{2} \tilde{V}_{IJ}^{a} = -\frac{1}{2(I+1)} F_{J}^{ae} \nabla_{e} (F_{I+1,d}^{d}) \qquad (5.5)$$

leads to

$$\nabla_a V_{IJ}^a = -\frac{1}{2(I+1)} \left[ (\nabla_a F_J^{ae}) \nabla_e (F_{I+1,d}^d) + F_J^{ae} \nabla_a \nabla_e (F_{I+1,d}^d) \right] \qquad (5.6)$$

where the last term on the right-hand side, which is not permissible, vanishes if $I$ is odd. Therefore, each of the four terms $V_{11}$, $V_{13}$, $V_{31}$ and $V_{33}$ constitutes an appropriate boundary term.

For the other values of $I$ and $J$, it is instructive to expand the divergence of $V_{IJ}$:

$$\nabla_a V_{IJ}^a = F_I^{ce} F_J^{ad} \nabla_a \nabla_e F_{cd} + F_I^{ce} (\nabla_a F_J^{ad}) \nabla_e F_{cd} + F_J^{ad} (\nabla_a F_I^{ce}) \nabla_e F_{cd} \qquad (5.7)$$
# 5 Boundary terms

We now study whether it is possible to relate some of the 22 terms of the algebraic basis obtained so far, via boundary terms, since the latter are irrelevant in the equations of motion. Boundary terms are of the form $\nabla_a B^a$ where $B$ is some vector. In our case, we are interested in boundary terms $\nabla_a B^a$ that lead, when expanded, to terms quadratic in $\nabla F$, discussed in the previous section, and therefore $B$ must contain a single derivative of $F$.

## 5.1 Dressed vertex vectors

Vectors $B$ of this form are proportional to one of the following contracted dressed vertices:

$$V_{IJ}^{a} = F_{I}^{ce} F_{J}^{ad} \nabla_{e} F_{cd} \qquad (5.1)$$

or

$$\tilde{V}_{IJ}^{a} = F_{I}^{dc} F_{J}^{ae} \nabla_{e} F_{cd} = \frac{1}{I+1} F_{J}^{ae} \nabla_{e} (F_{I+1,d}^{d}) \qquad (5.2)$$

where the last expression shows that $\tilde{V}_{IJ}$ vanishes if $I$ is even.

Replacing $\nabla_{e} F_{cd}$ in (5.2), or equivalently in (5.1), by $\nabla_{[e}F_{cd]} = 0$ yields the relation

$$V_{IJ} - (-1)^{I} V_{IJ} + \tilde{V}_{IJ} = 0, \qquad (5.3)$$

which implies

$$\tilde{V}_{IJ} = -2V_{IJ} \quad \text{for } I \text{ odd,} \qquad \tilde{V}_{IJ} = 0 \quad \text{for } I \text{ even,} \qquad (5.4)$$

where we have omitted the spacetime index for all vector terms above to simplify the notation. As a consequence, we need to consider only the vectors $V_{IJ}$ since all the non-zero $\tilde{V}_{IJ}$ can be expressed in terms of them.

## 5.2 Divergence of the vertex vectors

Let us now examine, for the above vectors, in which case their divergence leads to only “permissible” terms. In other words, after the full expansion of the vector $B$, one must find only terms of the form (4.1) and, for example, no term of the form $\nabla_a \nabla_b F_{cd}$ which cannot be reduced to a Riemann term.

For $I$ odd, the divergence of

$$V_{IJ}^{a} = -\frac{1}{2} \tilde{V}_{IJ}^{a} = -\frac{1}{2(I+1)} F_{J}^{ae} \nabla_{e} (F_{I+1,d}^{d}) \qquad (5.5)$$

leads to

$$\nabla_a V_{IJ}^a = -\frac{1}{2(I+1)} \left[ (\nabla_a F_J^{ae}) \nabla_e (F_{I+1,d}^d) + F_J^{ae} \nabla_a \nabla_e (F_{I+1,d}^d) \right] \qquad (5.6)$$

where the last term on the right-hand side, which is not permissible, vanishes if $I$ is odd. Therefore, each of the four terms $V_{11}$, $V_{13}$, $V_{31}$ and $V_{33}$ constitutes an appropriate boundary term.

For the other values of $I$ and $J$, it is instructive to expand the divergence of $V_{IJ}$:

$$\nabla_a V_{IJ}^a = F_I^{ce} F_J^{ad} \nabla_a \nabla_e F_{cd} + F_I^{ce} (\nabla_a F_J^{ad}) \nabla_e F_{cd} + F_J^{ad} (\nabla_a F_I^{ce}) \nabla_e F_{cd} \qquad (5.7)$$
The first term on the right hand side, which is not permissible, can however be rewritten as

$$F_I^{ce} F_J^{ad} \nabla_a \nabla_e F_{cd} = F_I^{ce} F_J^{ad} [\nabla_a, \nabla_e] F_{cd} + F_I^{ce} F_J^{ad} \nabla_e \nabla_a F_{cd}. \quad (5.8)$$

The last term on the right hand side can be slightly rewritten, after exchanging the index labels a and e and the labels c and d, so that one gets

$$F_I^{ce} F_J^{ad} \nabla_a \nabla_e F_{cd} = F_I^{ce} F_J^{ad} [\nabla_a, \nabla_e] F_{cd} - (-1)^{I+J} F_J^{ce} F_I^{ad} \nabla_a \nabla_e F_{cd} \quad (5.9)$$

Reexpressing the commutator of the covariant derivatives in terms of the Riemann tensor, one finally obtains the relation

$$F_I^{ce} F_J^{ad} \nabla_a \nabla_e F_{cd} + (-1)^{I+J} F_J^{ce} F_I^{ad} \nabla_a \nabla_e F_{cd} = F_I^{ce} F_J^{ad} (R_{eac}{}^f F_{df} + R_{ead}{}^f F_{fc}) \quad (5.10)$$

This shows that even if a vertex vector with I even is not an acceptable boundary term, the combination of two such vertices

$$W_{IJ} \equiv V_{IJ} + (-1)^{I+J} V_{JI} \quad (5.11)$$

provides an adequate boundary term. We thus find 7 additional boundary terms: $W_{00}$, $W_{02}$, $W_{22}$, $W_{01}$, $W_{03}$, $W_{12}$ and $W_{23}$. In total, we have thus identified 11 boundary terms. However, as we are going to see below, some of these are redundant.

## 5.3 Divergenceless vectors

One can find relations between some of the 11 boundary terms obtained above, as we now show. One such relation comes from the identity

$$\nabla_a \nabla_b (\Phi F^{ab}) = 0, \quad (5.12)$$

where $\Phi$ is a function of the two invariants $f_2$ and $f_4$, which implies that the vector

$$\nabla_b (\Phi F^{ab}) = \Phi \nabla_b F^{ab} + 2(\partial_2 \Phi) F^{ab} F^{cd} \nabla_b F_{cd} + 4(\partial_4 \Phi) F^{ab} F_3^{cd} \nabla_b F_{cd}, \quad (5.13)$$

is divergenceless. As a consequence, any boundary term constructed from $V_{00}^a = -\nabla_b F^{ab}$ can be considered as redundant since it can be replaced by other terms, according to the relation

$$\nabla_a (\Phi V_{00}^a) = \nabla_a [4(\partial_2 \Phi) V_{11}^a + 8(\partial_4 \Phi) V_{31}^a], \quad (5.14)$$

where we have used (5.4) to replace the $\tilde{V}$ terms on the right hand side by V terms.

Similarly, the identity

$$\nabla_a \nabla_b (\Phi F_3^{ab}) = 0 \quad (5.15)$$

yields the relation

$$\nabla_a (\Phi V_{02}^a + \Phi V_{11}^a + \Phi V_{20}^a) = \nabla_a [4(\partial_2 \Phi) V_{31}^a + 8(\partial_4 \Phi) V_{33}^a], \quad (5.16)$$

which implies that one term among the three terms $V_{02}$, $V_{11}$ and $V_{20}$ is redundant.
The first term on the right hand side, which is not permissible, can however be rewritten as

$$F_I^{ce} F_J^{ad} \nabla_a \nabla_e F_{cd} = F_I^{ce} F_J^{ad} [\nabla_a, \nabla_e] F_{cd} + F_I^{ce} F_J^{ad} \nabla_e \nabla_a F_{cd}. \quad (5.8)$$

The last term on the right hand side can be slightly rewritten, after exchanging the index labels a and e and the labels c and d, so that one gets

$$F_I^{ce} F_J^{ad} \nabla_a \nabla_e F_{cd} = F_I^{ce} F_J^{ad} [\nabla_a, \nabla_e] F_{cd} - (-1)^{I+J} F_J^{ce} F_I^{ad} \nabla_a \nabla_e F_{cd} \quad (5.9)$$

Reexpressing the commutator of the covariant derivatives in terms of the Riemann tensor, one finally obtains the relation

$$F_I^{ce} F_J^{ad} \nabla_a \nabla_e F_{cd} + (-1)^{I+J} F_J^{ce} F_I^{ad} \nabla_a \nabla_e F_{cd} = F_I^{ce} F_J^{ad} (R_{eac}{}^f F_{df} + R_{ead}{}^f F_{fc}) \quad (5.10)$$

This shows that even if a vertex vector with I even is not an acceptable boundary term, the combination of two such vertices

$$W_{IJ} \equiv V_{IJ} + (-1)^{I+J} V_{JI} \quad (5.11)$$

provides an adequate boundary term. We thus find 7 additional boundary terms: $W_{00}$, $W_{02}$, $W_{22}$, $W_{01}$, $W_{03}$, $W_{12}$ and $W_{23}$. In total, we have thus identified 11 boundary terms. However, as we are going to see below, some of these are redundant.

## 5.3 Divergenceless vectors

One can find relations between some of the 11 boundary terms obtained above, as we now show. One such relation comes from the identity

$$\nabla_a \nabla_b (\Phi F^{ab}) = 0, \quad (5.12)$$

where $\Phi$ is a function of the two invariants $f_2$ and $f_4$, which implies that the vector

$$\nabla_b (\Phi F^{ab}) = \Phi \nabla_b F^{ab} + 2(\partial_2 \Phi) F^{ab} F^{cd} \nabla_b F_{cd} + 4(\partial_4 \Phi) F^{ab} F_3^{cd} \nabla_b F_{cd}, \quad (5.13)$$

is divergenceless. As a consequence, any boundary term constructed from $V_{00}^a = -\nabla_b F^{ab}$ can be considered as redundant since it can be replaced by other terms, according to the relation

$$\nabla_a (\Phi V_{00}^a) = \nabla_a [4(\partial_2 \Phi) V_{11}^a + 8(\partial_4 \Phi) V_{31}^a], \quad (5.14)$$

where we have used (5.4) to replace the $\tilde{V}$ terms on the right hand side by V terms.

Similarly, the identity

$$\nabla_a \nabla_b (\Phi F_3^{ab}) = 0 \quad (5.15)$$

yields the relation

$$\nabla_a (\Phi V_{02}^a + \Phi V_{11}^a + \Phi V_{20}^a) = \nabla_a [4(\partial_2 \Phi) V_{31}^a + 8(\partial_4 \Phi) V_{33}^a], \quad (5.16)$$

which implies that one term among the three terms $V_{02}$, $V_{11}$ and $V_{20}$ is redundant.
## 5.4 DDIs for the boundary terms

Finally, one can also find a few non trivial DDIs that provide additional relations between the boundary terms. They are given by

$$ \Delta_{a_1 a_2 a_3 a_4 a_5 b_1 b_2 b_3 b_4 b_5} \nabla^{b_2} (\Phi T_{00I}^{a_1 a_2 b_1} F^{b_3 b_4} F^{a_3 a_4} F^{b_5 a_5}) \propto \nabla^e (\Phi F_I^{ab} \nabla_a C_{be}) = 0. \quad (5.17) $$

where C is the left-hand-side of the Cayley-Hamilton identity (2.8). They provide four relations between the $V_{IJ}$ and the $\tilde{V}_{IJ}$. After the replacement of the $\tilde{V}_{IJ}$ in terms of the $V_{IJ}$, one gets the following relations

$$ W_{03} - W_{12} + \frac{1}{2} f_2 W_{01} = 0, \quad (5.18) $$

$$ V_{13} + V_{31} - \frac{1}{2} W_{22} + \frac{1}{2} f_2 V_{11} - \frac{1}{8} g_4 W_{00} = 0, \quad (5.19) $$

$$ W_{23} + \frac{1}{4} g_4 W_{01} = 0, \quad (5.20) $$

$$ V_{33} + \frac{1}{4} f_2 W_{22} + \frac{1}{4} g_4 (V_{11} - W_{02}) = 0. \quad (5.21) $$

In summary, the four above relations combined with the two relations discussed in the previous subsection means that among the 11 initial boundary terms, only 5 boundary terms are independent.

## 6 Basis of elementary Lagrangians

Thanks to the results of the previous sections, we are now able to rewrite any action of the form (2.2) in terms of a linear combination of 21 terms (not including $L_0$), with coefficients that are arbitrary functions of $f_2$ and $f_4$. One possible choice of these 21 terms is the following: the Riemann-linear terms are

$$ \mathcal{R}_1 \equiv R, \quad \mathcal{R}_2 \equiv F^{ab} F^{cd} R_{abcd}, \quad \mathcal{R}_3 \equiv F_2^{ab} R_{ab}, \quad (6.1) $$

while the 18 terms quadratic in $\nabla F$ chosen among the scalars $\mathcal{A}_{IJK}$ and $\mathcal{B}_{IJK}$ and organised according to their weight (i.e. the sum $I + J + K$), comprise one term of weight 0,

$$ \mathcal{F}_1 \equiv \mathcal{B}_{000} = \nabla^b F_{ab} \nabla^c F_c^a, \quad (6.2) $$

seven terms of weight 2,

$$ \begin{aligned} \mathcal{F}_2 &\equiv \mathcal{A}_{002} = F_2^{ec} \nabla_e F_{ab} \nabla^b F_c^a, & \mathcal{F}_3 &\equiv \mathcal{A}_{200} = F_2^{ad} \nabla^c F_{ab} \nabla^b F_{cd}, \\ \mathcal{F}_4 &\equiv \mathcal{B}_{020} = F_2^{eb} \nabla_e F_{ab} \nabla_c F^{ca}, & \mathcal{F}_5 &\equiv \mathcal{B}_{200} = F_2^{ad} \nabla^b F_{ab} \nabla^c F_{cd}, \\ \mathcal{F}_6 &\equiv \mathcal{A}_{101} = F^{ad} F^{ec} \nabla_e F_{ab} \nabla^b F_{cd}, & \mathcal{F}_7 &\equiv \mathcal{B}_{011} = F^{eb} F^{cf} \nabla_e F_{ab} \nabla_f F_c^a, \\ \mathcal{F}_8 &\equiv \mathcal{B}_{110} = F^{ad} F^{eb} \nabla_e F_{ab} \nabla^c F_{cd}, & & & \end{aligned} \quad (6.3) $$

one term of weight 3,

$$ \mathcal{F}_9 \equiv \mathcal{B}_{210} = F_2^{ad} F^{eb} \nabla_e F_{ab} \nabla^c F_{cd}, \quad (6.4) $$
## 5.4 DDIs for the boundary terms

Finally, one can also find a few non trivial DDIs that provide additional relations between the boundary terms. They are given by

$$ \Delta_{a_1 a_2 a_3 a_4 a_5 b_1 b_2 b_3 b_4 b_5} \nabla^{b_2} (\Phi T_{00I}^{a_1 a_2 b_1} F^{b_3 b_4} F^{a_3 a_4} F^{b_5 a_5}) \propto \nabla^e (\Phi F_I^{ab} \nabla_a C_{be}) = 0. \quad (5.17) $$

where C is the left-hand-side of the Cayley-Hamilton identity (2.8). They provide four relations between the $V_{IJ}$ and the $\tilde{V}_{IJ}$. After the replacement of the $\tilde{V}_{IJ}$ in terms of the $V_{IJ}$, one gets the following relations

$$ W_{03} - W_{12} + \frac{1}{2} f_2 W_{01} = 0, \quad (5.18) $$

$$ V_{13} + V_{31} - \frac{1}{2} W_{22} + \frac{1}{2} f_2 V_{11} - \frac{1}{8} g_4 W_{00} = 0, \quad (5.19) $$

$$ W_{23} + \frac{1}{4} g_4 W_{01} = 0, \quad (5.20) $$

$$ V_{33} + \frac{1}{4} f_2 W_{22} + \frac{1}{4} g_4 (V_{11} - W_{02}) = 0. \quad (5.21) $$

In summary, the four above relations combined with the two relations discussed in the previous subsection means that among the 11 initial boundary terms, only 5 boundary terms are independent.

## 6 Basis of elementary Lagrangians

Thanks to the results of the previous sections, we are now able to rewrite any action of the form (2.2) in terms of a linear combination of 21 terms (not including $L_0$), with coefficients that are arbitrary functions of $f_2$ and $f_4$. One possible choice of these 21 terms is the following: the Riemann-linear terms are

$$ \mathcal{R}_1 \equiv R, \quad \mathcal{R}_2 \equiv F^{ab} F^{cd} R_{abcd}, \quad \mathcal{R}_3 \equiv F_2^{ab} R_{ab}, \quad (6.1) $$

while the 18 terms quadratic in $\nabla F$ chosen among the scalars $\mathcal{A}_{IJK}$ and $\mathcal{B}_{IJK}$ and organised according to their weight (i.e. the sum $I + J + K$), comprise one term of weight 0,

$$ \mathcal{F}_1 \equiv \mathcal{B}_{000} = \nabla^b F_{ab} \nabla^c F_c^a, \quad (6.2) $$

seven terms of weight 2,

$$ \begin{aligned} \mathcal{F}_2 &\equiv \mathcal{A}_{002} = F_2^{ec} \nabla_e F_{ab} \nabla^b F_c^a, & \mathcal{F}_3 &\equiv \mathcal{A}_{200} = F_2^{ad} \nabla^c F_{ab} \nabla^b F_{cd}, \\ \mathcal{F}_4 &\equiv \mathcal{B}_{020} = F_2^{eb} \nabla_e F_{ab} \nabla_c F^{ca}, & \mathcal{F}_5 &\equiv \mathcal{B}_{200} = F_2^{ad} \nabla^b F_{ab} \nabla^c F_{cd}, \\ \mathcal{F}_6 &\equiv \mathcal{A}_{101} = F^{ad} F^{ec} \nabla_e F_{ab} \nabla^b F_{cd}, & \mathcal{F}_7 &\equiv \mathcal{B}_{011} = F^{eb} F^{cf} \nabla_e F_{ab} \nabla_f F_c^a, \\ \mathcal{F}_8 &\equiv \mathcal{B}_{110} = F^{ad} F^{eb} \nabla_e F_{ab} \nabla^c F_{cd}, & & & \end{aligned} \quad (6.3) $$

one term of weight 3,

$$ \mathcal{F}_9 \equiv \mathcal{B}_{210} = F_2^{ad} F^{eb} \nabla_e F_{ab} \nabla^c F_{cd}, \quad (6.4) $$
six terms of weight 4,

$$
\begin{align}
\mathcal{F}_{10} &\equiv \mathcal{A}_{301} = F_3^{ad} F^{ec} \nabla_e F_{ab} \nabla^b F_{cd}, & \mathcal{F}_{11} &\equiv \mathcal{B}_{310} = F_3^{ad} F^{eb} \nabla_e F_{ab} \nabla^c F_{cd}, \nonumber \\
\mathcal{F}_{12} &\equiv \mathcal{B}_{022} = F_2^{eb} F_2^{cf} \nabla_e F_{ab} \nabla_f F_c^a, & \mathcal{F}_{13} &\equiv \mathcal{B}_{220} = F_2^{ad} F_2^{eb} \nabla_e F_{ab} \nabla^c F_{cd}, \tag{6.5} \\
\mathcal{F}_{14} &\equiv \mathcal{B}_{112} = F^{ad} F^{eb} F_2^{cf} \nabla_e F_{ab} \nabla_f F_{cd}, & \mathcal{F}_{15} &\equiv \mathcal{B}_{211} = F_2^{ad} F^{eb} F^{cf} \nabla_e F_{ab} \nabla_f F_{cd}, \nonumber
\end{align}
$$

two terms of weight 5,

$$
\mathcal{F}_{16} \equiv \mathcal{B}_{320} = F_3^{ad} F_2^{eb} \nabla_e F_{ab} \nabla^c F_{cd}, \quad \mathcal{F}_{17} \equiv \mathcal{B}_{212} = F_2^{ad} F^{eb} F_2^{cf} \nabla_e F_{ab} \nabla_f F_{cd}, \quad (6.6)
$$

and one last term of weight 6,

$$
\mathcal{F}_{18} \equiv \mathcal{B}_{312} = F_3^{ad} F^{eb} F_2^{cf} \nabla_e F_{ab} \nabla_f F_{cd}. \qquad (6.7)
$$

Note that the Riemann-linear term $\mathcal{R}_4$, defined in (3.7), does not appear in the basis.
Indeed, using the relations obtained in the previous section from the boundary terms, this term
can be rewritten as a linear combination of the terms in the above basis. Explicitly, one finds

$$
\begin{equation}
\begin{split}
\Phi \mathcal{R}_4 = \Phi \left( 2\mathcal{F}_6 - \frac{1}{2}g_4 \mathcal{R}_1 \right) &+ f_2 g_4 (\partial_4 \Phi) \mathcal{R}_2 + 2\lambda_1 \left( \frac{1}{2} f_2 \mathcal{R}_3 - \mathcal{F}_2 - \mathcal{F}_3 + \mathcal{F}_4 + \mathcal{F}_5 \right) \\
&+ 8f_2 \lambda_2 \left( 2\mathcal{F}_{11} - \mathcal{F}_{13} - \frac{1}{4}g_4 \mathcal{F}_1 \right) + 8\lambda_3 (\mathcal{F}_{14} - \mathcal{F}_{15}) - 2(\lambda_4 - \lambda_5)\mathcal{F}_7 + 2(\lambda_4 - 2\lambda_5)\mathcal{F}_8,
\end{split}
\tag{6.8}
\end{equation}
$$

where

$$
\begin{align}
\lambda_1 &= \Phi + 2g_4(\partial_4 \Phi), \quad \lambda_2 = 3(\partial_4 \Phi) + 2g_4(\partial_{44} \Phi), \quad \lambda_3 = \partial_2 \Phi + 4f_2(\partial_4 \Phi) + 2f_2 g_4(\partial_{44} \Phi) \tag{6.9} \\
\lambda_4 &= -\Phi + 2f_2[\partial_2 \Phi + 2g_4(\partial_{24} \Phi)] + 2(g_4 - 2f_2^2)\partial_4 \Phi, \quad \lambda_5 = -\Phi - 2f_2^2[3(\partial_4 \Phi) + 2g_4(\partial_{44} \Phi)]. \nonumber
\end{align}
$$

In flat spacetime the term $\mathcal{R}_4$ vanishes (as well as the other $\mathcal{R}_i$) and the above relation
implies that one of the $\mathcal{F}_i$, for example $\mathcal{F}_6$, becomes redundant. Hence, any action of the
form (2.2) in Minkowski can be written as a linear combination of 17 terms, all quadratic in
derivatives of $F_{ab}$, with arbitrary functions of $f_2$ and $f_4$ as coefficients.

Finally, let us stress that it is straightforward to adapt our analysis to classify all the
Lagrangians of the form (2.2) where $F_{ab}$ is now an arbitrary 2-form, i.e. not associated with
a U(1) gauge field. The only difference is that one cannot use anymore the relations obtained
from Bianchi identities (2.15). The Riemann-linear terms (3.1) are the same and can be
reduced to a combination of the four terms (3.7). As for the terms of the form (4.1), we again
start with 124 terms, as discussed in section 4.1, and use 88 independent DDIs to reduce
these terms to 36 elementary ones. We then find that among the 14 possible boundary terms,
only 6 of them are independent when we consider their DDIs and the divergenceless vectors.
We thus end up with 30 independent elementary quadratic Lagrangians of the form (4.1). In
conclusion, adding the 4 terms linear in the Riemann tensor, we get a basis of 34 independent
Lagrangians for the most general action (2.2) when $F_{ab}$ is an arbitrary 2-form.

7 Conclusions

In this article, we have classified (and reduced) higher-order Einstein-Maxwell theories
described by Lagrangians that are linear in the Riemann tensor and quadratic in derivatives
six terms of weight 4,

$$
\begin{align}
\mathcal{F}_{10} &\equiv \mathcal{A}_{301} = F_3^{ad} F^{ec} \nabla_e F_{ab} \nabla^b F_{cd}, & \mathcal{F}_{11} &\equiv \mathcal{B}_{310} = F_3^{ad} F^{eb} \nabla_e F_{ab} \nabla^c F_{cd}, \nonumber \\
\mathcal{F}_{12} &\equiv \mathcal{B}_{022} = F_2^{eb} F_2^{cf} \nabla_e F_{ab} \nabla_f F_c^a, & \mathcal{F}_{13} &\equiv \mathcal{B}_{220} = F_2^{ad} F_2^{eb} \nabla_e F_{ab} \nabla^c F_{cd}, \tag{6.5} \\
\mathcal{F}_{14} &\equiv \mathcal{B}_{112} = F^{ad} F^{eb} F_2^{cf} \nabla_e F_{ab} \nabla_f F_{cd}, & \mathcal{F}_{15} &\equiv \mathcal{B}_{211} = F_2^{ad} F^{eb} F^{cf} \nabla_e F_{ab} \nabla_f F_{cd}, \nonumber
\end{align}
$$

two terms of weight 5,

$$
\mathcal{F}_{16} \equiv \mathcal{B}_{320} = F_3^{ad} F_2^{eb} \nabla_e F_{ab} \nabla^c F_{cd}, \quad \mathcal{F}_{17} \equiv \mathcal{B}_{212} = F_2^{ad} F^{eb} F_2^{cf} \nabla_e F_{ab} \nabla_f F_{cd}, \quad (6.6)
$$

and one last term of weight 6,

$$
\mathcal{F}_{18} \equiv \mathcal{B}_{312} = F_3^{ad} F^{eb} F_2^{cf} \nabla_e F_{ab} \nabla_f F_{cd}. \qquad (6.7)
$$

Note that the Riemann-linear term $\mathcal{R}_4$, defined in (3.7), does not appear in the basis.
Indeed, using the relations obtained in the previous section from the boundary terms, this term
can be rewritten as a linear combination of the terms in the above basis. Explicitly, one finds

$$
\begin{equation}
\begin{split}
\Phi \mathcal{R}_4 = \Phi \left( 2\mathcal{F}_6 - \frac{1}{2}g_4 \mathcal{R}_1 \right) &+ f_2 g_4 (\partial_4 \Phi) \mathcal{R}_2 + 2\lambda_1 \left( \frac{1}{2} f_2 \mathcal{R}_3 - \mathcal{F}_2 - \mathcal{F}_3 + \mathcal{F}_4 + \mathcal{F}_5 \right) \\
&+ 8f_2 \lambda_2 \left( 2\mathcal{F}_{11} - \mathcal{F}_{13} - \frac{1}{4} g_4 \mathcal{F}_1 \right) + 8\lambda_3 (\mathcal{F}_{14} - \mathcal{F}_{15}) - 2(\lambda_4 - \lambda_5)\mathcal{F}_7 + 2(\lambda_4 - 2\lambda_5)\mathcal{F}_8,
\end{split}
\tag{6.8}
\end{equation}
$$

where

$$
\begin{align}
\lambda_1 &= \Phi + 2g_4(\partial_4 \Phi), \quad \lambda_2 = 3(\partial_4 \Phi) + 2g_4(\partial_{44} \Phi), \quad \lambda_3 = \partial_2 \Phi + 4f_2(\partial_4 \Phi) + 2f_2 g_4(\partial_{44} \Phi) \tag{6.9} \\
\lambda_4 &= -\Phi + 2f_2[\partial_2 \Phi + 2g_4(\partial_{24} \Phi)] + 2(g_4 - 2f_2^2)\partial_4 \Phi, \quad \lambda_5 = -\Phi - 2f_2^2[3(\partial_4 \Phi) + 2g_4(\partial_{44} \Phi)]. \nonumber
\end{align}
$$

In flat spacetime the term $\mathcal{R}_4$ vanishes (as well as the other $\mathcal{R}_i$) and the above relation
implies that one of the $\mathcal{F}_i$, for example $\mathcal{F}_6$, becomes redundant. Hence, any action of the
form (2.2) in Minkowski can be written as a linear combination of 17 terms, all quadratic in
derivatives of $F_{ab}$, with arbitrary functions of $f_2$ and $f_4$ as coefficients.

Finally, let us stress that it is straightforward to adapt our analysis to classify all the
Lagrangians of the form (2.2) where $F_{ab}$ is now an arbitrary 2-form, i.e. not associated with
a U(1) gauge field. The only difference is that one cannot use anymore the relations obtained
from Bianchi identities (2.15). The Riemann-linear terms (3.1) are the same and can be
reduced to a combination of the four terms (3.7). As for the terms of the form (4.1), we again
start with 124 terms, as discussed in section 4.1, and use 88 independent DDIs to reduce
these terms to 36 elementary ones. We then find that among the 14 possible boundary terms,
only 6 of them are independent when we consider their DDIs and the divergenceless vectors.
We thus end up with 30 independent elementary quadratic Lagrangians of the form (4.1). In
conclusion, adding the 4 terms linear in the Riemann tensor, we get a basis of 34 independent
Lagrangians for the most general action (2.2) when $F_{ab}$ is an arbitrary 2-form.

7 Conclusions

In this article, we have classified (and reduced) higher-order Einstein-Maxwell theories
described by Lagrangians that are linear in the Riemann tensor and quadratic in derivatives
of the field strength tensor. As we have seen, classifying such Lagrangians turns out to be much more complex than for scalar-tensor theories. The main reason is that we need to take into account an important number of dimensionally dependent identities, which renders the analysis of the equivalence between the Lagrangians, when boundary terms are also included, much more subtle but also very interesting.

Our results show that the most general higher-order Einstein-Maxwell Lagrangians considered here can be written as a linear combination of 21 terms whose coefficients are arbitrary functions of the two scalar invariants constructed from the field-strength tensor. We also provide an explicit basis. These results could also be useful to simplify, or more simply to compare, effective actions that contain terms of the form (2.2), such as those appearing in the derivative expansion of the one-loop effective action of QED [23–25]. Furthermore, generalising our approach to gravitational actions could be used in other contexts such as Asymptotic Safety (see e.g. [39], where non-perturbative effects are parametrised by invariants involving form-factors). As mentioned in the previous section, our analysis is readily extendible to the case where the Lagrangians are seen as functionals of a 2-form $F_{ab}$, thus relaxing the U(1) gauge symmetry.

At this stage, we have not investigated the physical properties of the theories (2.2), in particular the nature and the number of their degrees of freedom. As the Lagrangians involve second derivatives of the gauge field $A^a$, which in general cannot be eliminated by integrations by part, they could contain unwanted Ostrogradski ghosts. To avoid these, one must look for a degenerate family of Lagrangians, satisfying degeneracy conditions analogous to those that have been identified in DHOST theories, to ensure that the theory does not propagate Ostrogradski ghosts even though the equations of motion are higher order.

Indeed, a simple preliminary analysis shows that theories of the form (2.2) could propagate up to three Ostrogradski ghosts, in addition to the usual two degrees of freedom of the photon and the two degrees of freedom of the graviton. The problem of finding necessary and sufficient degeneracy conditions to get rid of these ghosts is much more involved than in higher-derivative scalar-tensor theories for the reason that a gauge field $A^a$ has a more complex structure than a scalar field. A first exploration of these aspects will be considered for the flat case in a future work.

## Acknowledgments

This work was supported by the French National Research Agency (ANR) via Grant No. ANR-22-CE31-0015-01 associated with the project StronG. A.C. was supported by the Research Authority of the Open University of Israel (grant number 512343). We acknowledge the use of the xAct package for Mathematica [40] and Mathcha to draw the diagrams.

## A Dimensionally dependent identities

In this appendix we classify dimensionally dependent identities (DDIs) built from the quadratic combination $\nabla F \nabla F$ and arbitrary products of field strength tensors in four dimensions. Our purpose is to identify all the possible 10-index tensors which can appear in (2.17). Given that there can be at most nine field strengths together with $\nabla F \nabla F$ in the corresponding
of the field strength tensor. As we have seen, classifying such Lagrangians turns out to be much more complex than for scalar-tensor theories. The main reason is that we need to take into account an important number of dimensionally dependent identities, which renders the analysis of the equivalence between the Lagrangians, when boundary terms are also included, much more subtle but also very interesting.

Our results show that the most general higher-order Einstein-Maxwell Lagrangians considered here can be written as a linear combination of 21 terms whose coefficients are arbitrary functions of the two scalar invariants constructed from the field-strength tensor. We also provide an explicit basis. These results could also be useful to simplify, or more simply to compare, effective actions that contain terms of the form (2.2), such as those appearing in the derivative expansion of the one-loop effective action of QED [23–25]. Furthermore, generalising our approach to gravitational actions could be used in other contexts such as Asymptotic Safety (see e.g. [39], where non-perturbative effects are parametrised by invariants involving form-factors). As mentioned in the previous section, our analysis is readily extendible to the case where the Lagrangians are seen as functionals of a 2-form $F_{ab}$, thus relaxing the U(1) gauge symmetry.

At this stage, we have not investigated the physical properties of the theories (2.2), in particular the nature and the number of their degrees of freedom. As the Lagrangians involve second derivatives of the gauge field $A^a$, which in general cannot be eliminated by integrations by part, they could contain unwanted Ostrogradski ghosts. To avoid these, one must look for a degenerate family of Lagrangians, satisfying degeneracy conditions analogous to those that have been identified in DHOST theories, to ensure that the theory does not propagate Ostrogradski ghosts even though the equations of motion are higher order.

Indeed, a simple preliminary analysis shows that theories of the form (2.2) could propagate up to three Ostrogradski ghosts, in addition to the usual two degrees of freedom of the photon and the two degrees of freedom of the graviton. The problem of finding necessary and sufficient degeneracy conditions to get rid of these ghosts is much more involved than in higher-derivative scalar-tensor theories for the reason that a gauge field $A^a$ has a more complex structure than a scalar field. A first exploration of these aspects will be considered for the flat case in a future work.

## Acknowledgments

This work was supported by the French National Research Agency (ANR) via Grant No. ANR-22-CE31-0015-01 associated with the project StronG. A.C. was supported by the Research Authority of the Open University of Israel (grant number 512343). We acknowledge the use of the xAct package for Mathematica [40] and Mathcha to draw the diagrams.

## A Dimensionally dependent identities

In this appendix we classify dimensionally dependent identities (DDIs) built from the quadratic combination $\nabla F \nabla F$ and arbitrary products of field strength tensors in four dimensions. Our purpose is to identify all the possible 10-index tensors which can appear in (2.17). Given that there can be at most nine field strengths together with $\nabla F \nabla F$ in the corresponding
scalar invariants, a rough estimate to enumerate possible DDIs is to choose 10 among 24 indices, resulting in around two million possibilities. Thus, it is desirable to obtain some systematic control over such problems.

## A.1 Diagrammatic classification

In order to do so, we use a graphical representation of the various tensorial quantities involved in the scalar invariants of our classification. The coloured field strength is represented by

$$F_I^{ab} \equiv I \langle b \rangle^a \qquad (A.1)$$

while for clarity, we recall the definition of the coloured vertex tensor, given by

$$T_{IJK}^{abc} = F_I^{ae} F_J^{bf} F_K^{cg} \nabla_e F_{fg} = \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw[thick, ->] (0,0) -- (1,0); \node[left] at (0,0) {$a, I$}; \node[right] at (1,0) {$b, J$}; \node[above] at (0.5,0.5) {$c, K$}; \end{tikzpicture} \qquad (A.2)$$

Although we could introduce an orientation on these graphs in order to encode the positions of antisymmetrised indices with respect to that of the covariant derivative, we will refrain to do so, our purpose here being a classification rather than actual calculations of DDIs.

The previous tensorial quantities are sufficient to define all the DDIs, however it is quite convenient to construct other coloured tensors from these building blocks. In particular, we construct and represent the traces of T by

$$V_{IJ}^{a} \equiv g_{bc} T_{I0J}^{bca} = \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw[thick, ->] (0,0) -- (1,0); \node[left] at (0,0) {$a, J$}; \node[right] at (1,0) {$b, J$}; \node[above] at (0.5,0.5) {$c, K$}; \end{tikzpicture} \qquad (A.3)$$

$$\tilde{V}_{IJ}^{a} \equiv g_{bc} T_{J0I}^{abc} = \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw[thick, ->] (0,0) -- (1,0); \node[left] at (0,0) {$a, J$}; \node[right] at (1,0) {$b, J$}; \node[above] at (0.5,0.5) {$c, K$}; \end{tikzpicture} \qquad (A.4)$$

and we will represent by a spring either case

$$S \equiv \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw[thick, ->] (0,0) -- (1,0); \node[left] at (0,0) {$a, J$}; \node[right] at (1,0) {$b, J$}; \node[above] at (0.5,0.5) {$c, K$}; \end{tikzpicture} \quad \text{or} \quad \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw[thick, ->] (0,0) -- (1,0); \node[left] at (0,0) {$a, J$}; \node[right] at (1,0) {$b, J$}; \node[above] at (0.5,0.5) {$c, K$}; \end{tikzpicture} \qquad (A.5)$$

so that $S = \tilde{V}$ or $V$. Let us remark that the elements of the two families introduced in the section 4.1 can easily be reconstructed from these definitions,

$$g_{ae} g_{bf} g_{cd} T_{000}^{abc} T_{JKI}^{def} = A_{IJK}, \quad g_{ad} g_{bf} g_{ce} T_{000}^{abc} T_{JKI}^{def} = \tilde{A}_{IJK}, \qquad (A.6)$$

and

$$g_{ab} V_{IJ}^{a} V_{K0}^{b} = (-1)^{I+J} \mathcal{B}_{JIK}, \quad g_{ab} \tilde{V}_{IJ}^{a} \tilde{V}_{K0}^{b} = (-1)^{J} \tilde{\mathcal{B}}_{JIK}, \quad g_{ab} \tilde{V}_{IJ}^{a} V_{K0}^{b} = - \hat{\mathcal{B}}_{JKI}. \qquad (A.7)$$

This enables to list all the disconnected diagrams representing coloured $\nabla F \nabla F$, built from tensorial products of the previous quantities, which are schematically of the form

$$\{S^2, V\tilde{V}, ST, T^2\}. \qquad (A.8)$$

Furthermore, we show in the penultimate section of this appendix that DDIs built from 2-index tensors, such as $V\tilde{V}$ and $S^2$, are redundant for both disconnected and connected
scalar invariants, a rough estimate to enumerate possible DDIs is to choose 10 among 24 indices, resulting in around two million possibilities. Thus, it is desirable to obtain some systematic control over such problems.

## A.1 Diagrammatic classification

In order to do so, we use a graphical representation of the various tensorial quantities involved in the scalar invariants of our classification. The coloured field strength is represented by

$$F_I^{ab} \equiv I \langle b \rangle^a \qquad (A.1)$$

while for clarity, we recall the definition of the coloured vertex tensor, given by

$$T_{IJK}^{abc} \equiv F_I^{ae} F_J^{bf} F_K^{cg} \nabla_e F_{fg} = \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw[thick, ->] (0,0) -- (1,0); \node[left] at (0,0) {$a, I$}; \node[right] at (1,0) {$b, J$}; \node[above] at (0.5,0.5) {$c, K$}; \end{tikzpicture} \qquad (A.2)$$

Although we could introduce an orientation on these graphs in order to encode the positions of antisymmetrised indices with respect to that of the covariant derivative, we will refrain to do so, our purpose here being a classification rather than actual calculations of DDIs.

The previous tensorial quantities are sufficient to define all the DDIs, however it is quite convenient to construct other coloured tensors from these building blocks. In particular, we construct and represent the traces of T by

$$V_{IJ}^{a} \equiv g_{bc} T_{I0J}^{bca} = \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw[thick, ->] (0,0) -- (1,0); \node[left] at (0,0) {$a, J$}; \node[right] at (1,0) {$b, J$}; \node[above] at (0.5,0.5) {$c, K$}; \end{tikzpicture} \qquad (A.3)$$

$$\tilde{V}_{IJ}^{a} \equiv g_{bc} T_{JI0}^{abc} = \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw[thick, ->] (0,0) -- (1,0); \node[left] at (0,0) {$a, J$}; \node[right] at (1,0) {$b, J$}; \node[above] at (0.5,0.5) {$c, K$}; \end{tikzpicture} \qquad (A.4)$$

and we will represent by a spring either case

$$S \equiv \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw[thick, ->] (0,0) -- (1,0); \node[left] at (0,0) {$a, J$}; \node[right] at (1,0) {$b, J$}; \node[above] at (0.5,0.5) {$c, K$}; \end{tikzpicture} = \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw[thick, ->] (0,0) -- (1,0); \node[left] at (0,0) {$a, J$}; \node[right] at (1,0) {$b, J$}; \node[above] at (0.5,0.5) {$c, K$}; \end{tikzpicture} \qquad (A.5)$$

so that $S = \tilde{V}$ or $V$. Let us remark that the elements of the two families introduced in the section 4.1 can easily be reconstructed from these definitions,

$$g_{ae} g_{bf} g_{cd} T_{000}^{abc} T_{JKI}^{def} = A_{IJK}, \quad g_{ad} g_{bf} g_{ce} T_{000}^{abc} T_{JKI}^{def} = \tilde{A}_{IJK}, \qquad (A.6)$$

and

$$g_{ab} V_{IJ}^{a} V_{K0}^{b} = (-1)^{I+J} \mathcal{B}_{JIK}, \quad g_{ab} \tilde{V}_{IJ}^{a} \tilde{V}_{K0}^{b} = (-1)^{J} \tilde{\mathcal{B}}_{JIK}, \quad g_{ab} \tilde{V}_{IJ}^{a} V_{K0}^{b} = - \hat{\mathcal{B}}_{JKI}. \qquad (A.7)$$

This enables to list all the disconnected diagrams representing coloured $\nabla F \nabla F$, built from tensorial products of the previous quantities, which are schematically of the form

$$\{S^2, V\tilde{V}, ST, T^2\}. \qquad (A.8)$$

Furthermore, we show in the penultimate section of this appendix that DDIs built from 2-index tensors, such as $V\tilde{V}$ and $S^2$, are redundant for both disconnected and connected
diagrams. Therefore, we define only the connected diagrams representing coloured $\nabla F \nabla F$ with more than two indices. There are three families of these given by,

$$X_{IJKLM}^{abcd} \equiv g_{ef} T_{JKI}^{abe} T_{LM0}^{cfd} = \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw (-.5,0) -- (0,0) -- (0.5,0); \node[above] at (-.5,0) {$a, J$}; \node[above] at (0,0) {$I$}; \node[above] at (0.5,0) {$c, L$}; \node[below] at (0,0) {$d, M$}; \node[above] at (0.5,0) {$b, K$}; \end{tikzpicture} \quad (A.9)$$

$$\tilde{X}_{IJKLM}^{abcd} \equiv g_{ef} T_{IJK}^{eab} T_{0LM}^{fcd} = \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw (-.5,0) -- (0,0) -- (0.5,0); \node[above] at (-.5,0) {$a, J$}; \node[above] at (0,0) {$I$}; \node[above] at (0.5,0) {$c, L$}; \node[below] at (0,0) {$d, M$}; \node[above] at (0.5,0) {$b, K$}; \end{tikzpicture} \quad (A.10)$$

$$\hat{X}_{IJKLM}^{abcd} \equiv g_{ef} T_{IJK}^{eab} T_{L0M}^{cfd} = \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw (-.5,0) -- (0,0) -- (0.5,0); \node[above] at (-.5,0) {$a, J$}; \node[above] at (0,0) {$I$}; \node[above] at (0.5,0) {$c, L$}; \node[below] at (0,0) {$d, M$}; \node[above] at (0.5,0) {$b, K$}; \end{tikzpicture} \quad (A.11)$$

In summary, only five families of tensors, {$T^2, ST, \tilde{X}, \hat{X}, X$}, can be used to construct all the dimensionally dependent identities and we will commonly denote them as $H$, a tensor built from coloured $\nabla F \nabla F$. In order to consider quantities involving a pair of five antisymmetrised indices, as required to construct scalar DDIs in four dimensions, they should be completed by products of the coloured field strength tensors, which we will call the completions of $H$.

In order to present an explicit classification of DDIs, we now wish to illustrate how they can be represented using the previous diagrams. A useful example of DDI with a coloured six-index tensor $H$ is given by

$$\Delta_{a_1 a_2 a_3 a_4 a_5 b_1 b_2 b_3 b_4 b_5} H_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} F_{A_1}^{a_4 b_4} F_{A_2}^{a_5 b_5} \equiv \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw (-.5,0) -- (0,0) -- (0.5,0); \node[above] at (-.5,0) {$J_1$}; \node[above] at (0,0) {$J_2$}; \node[above] at (0.5,0) {$J_3$}; \node[above] at (0.5,0) {$I_1$}; \node[above] at (0.5,0) {$I_2$}; \node[above] at (0.5,0) {$I_3$}; \node[above] at (0.5,0) {$A_1$}; \node[above] at (0.5,0) {$A_2$}; \node[above] at (0.5,0) {$b_i$}; \node[below] at (0,0) {$I_1$}; \node[below] at (0,0) {$I_2$}; \node[below] at (0,0) {$I_3$}; \node[below] at (0,0) {$A_1$}; \node[below] at (0,0) {$A_2$}; \node[above] at (0.5,0) {$a_i$}; \end{tikzpicture} \quad (A.12)$$

where $\Delta$ is the partially antisymmetric tensor defined by (4.17). A very similar example is obtained by replacing $F_{A_1}^{a_4 b_4} F_{A_2}^{a_5 b_5}$ with $F_{A_1}^{a_4 a_5} F_{A_2}^{b_4 b_5}$ in the above expression. In what follows, it will be convenient to consider simultaneously these two possible configurations by using the compact representation:<fnref n="13" />

$$\overbrace{\phantom{\Delta}} = \overbrace{\phantom{\Delta}} \text{ or } \overbrace{\phantom{\Delta}} \quad (A.13)$$

The example (A.12), extended with (A.13), corresponds to the third row of figure 1.

All the other relevant diagrams are presented in the other rows of figure 1. There are two main types of DDIs, depending on whether the $H$ tensor has six (first three rows) or four indices (last three rows). The left column indicates the general form of the DDIs, with their most general completions by coloured field strengths and irrespectively of which specific tensors $H$ they are made of. The composition of the $H$ tensor, together with the specific positions of indices involved in the antisymmetrisations are filling the rest of the table. The first three rows correspond to diagrams of the form $T^2$, where all indices of both vertex tensors appear as indices of $H$, while the last three rows, with a 4-index $H$ tensor, are divided into the four families {$ST, \tilde{X}, \hat{X}, X$}, corresponding to various internal contractions of the vertex tensors.

<footnote n="13">¹³It is clear that if $A_i = 0$ in the first configuration, the overall DDI would contain a trivial factor ($d-4$), so that $A_i \in \{1, 2, 3\}$, while the antisymmetry in the second configuration imposes $A_i \in \{1, 3\}$.</footnote>
diagrams. Therefore, we define only the connected diagrams representing coloured $\nabla F \nabla F$ with more than two indices. There are three families of these given by,

$$X_{IJKLM}^{abcd} \equiv g_{ef} T_{JKI}^{abe} T_{LM0}^{cfd} = \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw (-.5,0) -- (0,0) -- (0.5,0); \node[above] at (-.5,0) {$a, J$}; \node[above] at (0,0) {$I$}; \node[above] at (0.5,0) {$c, L$}; \node[below] at (0,0) {$d, M$}; \draw (-.5,0) -- (-.5,1); \draw (-.5,1) -- (0,1); \draw (.5,0) -- (.5,1); \draw (.5,1) -- (0,1); \end{tikzpicture} \quad (A.9)$$

$$\tilde{X}_{IJKLM}^{abcd} \equiv g_{ef} T_{IJK}^{eab} T_{0LM}^{fcd} = \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw (-.5,0) -- (0,0) -- (0.5,0); \node[above] at (-.5,0) {$a, J$}; \node[above] at (0,0) {$I$}; \node[above] at (0.5,0) {$c, L$}; \node[below] at (0,0) {$d, M$}; \draw (-.5,0) -- (-.5,1); \draw (-.5,1) -- (0,1); \draw (.5,0) -- (.5,1); \draw (.5,1) -- (0,1); \end{tikzpicture} \quad (A.10)$$

$$\hat{X}_{IJKLM}^{abcd} \equiv g_{ef} T_{IJK}^{eab} T_{L0M}^{cfd} = \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw (-.5,0) -- (0,0) -- (0.5,0); \node[above] at (-.5,0) {$a, J$}; \node[above] at (0,0) {$I$}; \node[above] at (0.5,0) {$c, L$}; \node[below] at (0,0) {$d, M$}; \draw (-.5,0) -- (-.5,1); \draw (-.5,1) -- (0,1); \draw (.5,0) -- (.5,1); \draw (.5,1) -- (0,1); \end{tikzpicture} \quad (A.11)$$

In summary, only five families of tensors, $\{T^2, ST, \tilde{X}, \hat{X}, X\}$, can be used to construct all the dimensionally dependent identities and we will commonly denote them as $H$, a tensor built from coloured $\nabla F \nabla F$. In order to consider quantities involving a pair of five antisymmetrised indices, as required to construct scalar DDIs in four dimensions, they should be completed by products of the coloured field strength tensors, which we will call the completions of $H$.

In order to present an explicit classification of DDIs, we now wish to illustrate how they can be represented using the previous diagrams. A useful example of DDI with a coloured six-index tensor $H$ is given by

$$\Delta_{a_1 a_2 a_3 a_4 a_5 b_1 b_2 b_3 b_4 b_5} H_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} F_{A_1}^{a_4 b_4} F_{A_2}^{a_5 b_5} \equiv \begin{tikzpicture}[baseline={([yshift=-.5ex]current bounding box.center)}] \draw (-.5,0) -- (0,0) -- (0.5,0); \node[above] at (-.5,0) {$a_i$}; \node[above] at (0,0) {$J_1$}; \node[above] at (0.5,0) {$J_2$}; \node[above] at (0.5,1) {$J_3$}; \node[above] at (0.5,2) {$I_1$}; \node[above] at (0.5,3) {$I_2$}; \node[above] at (0.5,4) {$I_3$}; \node[above] at (0.5,5) {$A_1$}; \node[above] at (0.5,6) {$A_2$}; \draw (-.5,0) -- (-.5,1); \draw (-.5,1) -- (-.5,2); \draw (-.5,2) -- (-.5,3); \draw (-.5,3) -- (-.5,4); \draw (-.5,4) -- (-.5,5); \draw (-.5,5) -- (-.5,6); \draw (.5,0) -- (.5,1); \draw (.5,1) -- (.5,2); \draw (.5,2) -- (.5,3); \draw (.5,3) -- (.5,4); \draw (.5,4) -- (.5,5); \draw (.5,5) -- (.5,6); \end{tikzpicture} \quad (A.12)$$

where $\Delta$ is the partially antisymmetric tensor defined by (4.17). A very similar example is obtained by replacing $F_{A_1}^{a_4 b_4} F_{A_2}^{a_5 b_5}$ with $F_{A_1}^{a_4 a_5} F_{A_2}^{b_4 b_5}$ in the above expression. In what follows, it will be convenient to consider simultaneously these two possible configurations by using the compact representation:<fnref n="13" />

$$\overline{\hspace{1.5cm}} = \overline{\hspace{1.5cm}} \quad \text{or} \quad \overline{\hspace{1.5cm}} \overline{\hspace{1.5cm}} \quad (A.13)$$

The example (A.12), extended with (A.13), corresponds to the third row of figure 1.

All the other relevant diagrams are presented in the other rows of figure 1. There are two main types of DDIs, depending on whether the $H$ tensor has six (first three rows) or four indices (last three rows). The left column indicates the general form of the DDIs, with their most general completions by coloured field strengths and irrespectively of which specific tensors $H$ they are made of. The composition of the $H$ tensor, together with the specific positions of indices involved in the antisymmetrisations are filling the rest of the table. The first three rows correspond to diagrams of the form $T^2$, where all indices of both vertex tensors appear as indices of $H$, while the last three rows, with a 4-index $H$ tensor, are divided into the four families $\{ST, \tilde{X}, \hat{X}, X\}$, corresponding to various internal contractions of the vertex tensors.

<footnote n="13">¹³It is clear that if $A_i = 0$ in the first configuration, the overall DDI would contain a trivial factor ($d-4$), so that $A_i \in \{1, 2, 3\}$, while the antisymmetry in the second configuration imposes $A_i \in \{1, 3\}$.</footnote>
<figure><img src="image_2.png" /><figcaption>**Figure 1.** Classification of scalar dimensionally dependent identities quadratic in $\nabla F$. The first column lists the six general types of DDIs with products of coloured field strengths, while the following columns detail the possible structures for the $H$ tensor, represented by a circle in the first column. First three rows: diagrams of the form $\{T^2\}$. Second three rows: diagrams of the forms $\{ST, \bar{X}, \hat{X}, X\}$.</figcaption></figure>

## A.2 Colour bounds and Laplace expansions

Although the previous DDIs are in principle straightforward to compute, there is a huge number of possibilities, or “valency”, associated with the colour indices. For instance, in the previous example (A.12), a naive estimate would give $4^8$ possibilities. However, given that every (scalar) DDI can be expanded in terms of the 124 scalar invariants classified in (4.3) and (4.6), their total weight must satisfy the following constraint,

$$0 \le \sum_{i} I_{i} + \sum_{j} J_{j} + \sum_{k} A_{k} + K \le 9, \qquad (A.14)$$

where $I_i$ and $J_j$ are respectively the colours of $H$ associated with the indices $b_i$ and $a_i$, $A_k$ are those involved in the completion (see the example (A.12)) and finally $K$ is the colour of the internal link which is present in the last three rows ($K = 0$ for the other diagrams).

This global bound on colours has a local counterpart for each term of the expanded DDIs. To see this, let us consider as an example the dressed partially antisymmetric tensor of the third row of figure 1, obtained by “undressing” the dressed vertices and transferring their colours to the antisymmetric tensor:

$$A_2 \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} = \Delta_{\bar{a}_1 \bar{a}_2 \bar{a}_3 \bar{a}_4 \bar{a}_5 \bar{b}_1 \bar{b}_2 \bar{b}_3 \bar{b}_4 \bar{b}_5} F_{J_1}^{\bar{a}_1 a_1} F_{J_2}^{\bar{a}_2 a_2} F_{J_3}^{\bar{a}_3 a_3} F_{I_1}^{\bar{b}_1 b_1} F_{I_2}^{\bar{b}_2 b_2} F_{I_3}^{\bar{b}_3 b_3} F_{A_1}^{\bar{b}_4 \bar{a}_4} F_{A_2}^{\bar{b}_5 \bar{a}_5}, \quad (A.15)$$

where the “bare” $\Delta$ is defined by (4.17).
<figure><img src="image_3.png" /><figcaption>**Figure 1.** Classification of scalar dimensionally dependent identities quadratic in $\nabla F$. The first column lists the six general types of DDIs with products of coloured field strengths, while the following columns detail the possible structures for the $H$ tensor, represented by a circle in the first column. First three rows: diagrams of the form $\{T^2\}$. Second three rows: diagrams of the forms $\{ST, \tilde{X}, \hat{X}, X\}$.</figcaption></figure>

## A.2 Colour bounds and Laplace expansions

Although the previous DDIs are in principle straightforward to compute, there is a huge number of possibilities, or “valency”, associated with the colour indices. For instance, in the previous example (A.12), a naive estimate would give $4^8$ possibilities. However, given that every (scalar) DDI can be expanded in terms of the 124 scalar invariants classified in (4.3) and (4.6), their total weight must satisfy the following constraint,

$$0 \le \sum_{i} I_{i} + \sum_{j} J_{j} + \sum_{k} A_{k} + K \le 9, \qquad (A.14)$$

where $I_i$ and $J_j$ are respectively the colours of $H$ associated with the indices $b_i$ and $a_i$, $A_k$ are those involved in the completion (see the example (A.12)) and finally $K$ is the colour of the internal link which is present in the last three rows ($K = 0$ for the other diagrams).

This global bound on colours has a local counterpart for each term of the expanded DDIs. To see this, let us consider as an example the dressed partially antisymmetric tensor of the third row of figure 1, obtained by “undressing” the dressed vertices and transferring their colours to the antisymmetric tensor:

$$A_2 \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} \equiv \Delta_{\bar{a}_1 \bar{a}_2 \bar{a}_3 \bar{a}_4 \bar{a}_5 \bar{b}_1 \bar{b}_2 \bar{b}_3 \bar{b}_4 \bar{b}_5} F_{J_1}^{\bar{a}_1 a_1} F_{J_2}^{\bar{a}_2 a_2} F_{J_3}^{\bar{a}_3 a_3} F_{I_1}^{\bar{b}_1 b_1} F_{I_2}^{\bar{b}_2 b_2} F_{I_3}^{\bar{b}_3 b_3} F_{A_1}^{\bar{b}_4 \bar{a}_4} F_{A_2}^{\bar{b}_5 \bar{a}_5}, \quad (A.15)$$

where the “bare” $\Delta$ is defined by (4.17).
Using the Laplace expansion, or cofactor expansion, for determinants with respect to $\bar{a}_5$, we get

$$ \frac{A_2}{A_1} \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} \approx - \left( \bar{A}_1 \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} + A_1 \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} + A_1 \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} + A_1 \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} \right) \quad (A.16) $$

with $\bar{I}_i = I_i + A_2$, $\bar{A} = A_1 + A_2$ and where, in analogy with (A.15), we have introduced

$$ A \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} \equiv \Delta_{\bar{a}_1 \bar{a}_2 \bar{a}_3 \bar{a}_4 \bar{b}_1 \bar{b}_2 \bar{b}_3 \bar{b}_4} F_{J_1}^{\bar{a}_1 a_1} F_{J_2}^{\bar{a}_2 a_2} F_{J_3}^{\bar{a}_3 a_3} F_{I_1}^{\bar{b}_1 b_1} F_{I_2}^{\bar{b}_2 b_2} F_{I_3}^{\bar{b}_3 b_3} F_A^{\bar{b}_4 \bar{a}_4}, \quad (A.17) $$

the bare partially antisymmetric tensor with eight indices being defined similarly to (4.17). The notation $\approx$ signifies that we dropped the terms with $f_2$ and $f_4$ arising from the contraction, as explained in the last section of this appendix. Notice that the relation (A.16) enables us to relate four-dimensional DDIs, which involve antisymmetrisation over five indices, to three-dimensional DDIs, with antisymmetrisation over four indices.

Similarly, expanding the determinant in $\bar{a}_4$ yields

$$ A \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} \approx - \left( \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} + \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} + \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} \right), \quad (A.18) $$

where $\bar{I}_i = I_i + A$, (123) are the permutations of three elements and

$$ \begin{aligned} \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} &\equiv \Delta_{\bar{a}_1 \bar{a}_2 \bar{a}_3 \bar{b}_1 \bar{b}_2 \bar{b}_3} F_{J_1}^{\bar{a}_1 a_1} F_{J_2}^{\bar{a}_2 a_2} F_{J_3}^{\bar{a}_3 a_3} F_{I_1}^{\bar{b}_1 b_1} F_{I_2}^{\bar{b}_2 b_2} F_{I_3}^{\bar{b}_3 b_3} \\ &= \sum_{\sigma \in (123)} (-1)^{I_1+I_2+I_3+\operatorname{sgn}(\sigma)} F_{I_{\sigma_1}+J_1}^{b_{\sigma_1} a_1} F_{I_{\sigma_2}+J_2}^{b_{\sigma_2} a_2} F_{I_{\sigma_3}+J_3}^{b_{\sigma_3} a_3} \end{aligned} \quad (A.19) $$

correspond to two-dimensional DDIs. Since $f_2 \approx f_4 \approx 0$, each term in (A.19), and thus in the four-dimensional DDI (A.15), that contains a $F_{I_i+J_j}$ with $I_i + J_j \ge 4$ can be neglected, due to the Cayley-Hamilton identity. This results in significant valency reductions and enables us to easily obtain specific representatives for the basis of scalar invariants.

## A.3 Algebraic basis of scalar invariants in two, three and four dimensions

Although we are mainly interested in four-dimensional theories, it is instructive, especially after our discussion in the previous section, to consider the same theories in lower dimensions and identify the corresponding DDIs and Bianchi identities.

We observe that the two and four dimensional DDIs can all be obtained from the disconnected diagrams of the third row of figure 1, while three-dimensional ones require the use of the sixth row as well.<fnref n="14" /> Interestingly, when the Bianchi identity is taken into account, four-dimensional DDIs can all be parametrised by the second column of the third row, corresponding to (4.20) in the main text, i.e.

$$ \frac{A_2}{A_1} \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} \nabla_{a_1} F_{a_2 b_1} \nabla_{b_2} F_{b_3 a_3} = \Delta_{a_1 a_2 a_3 a_4 a_5 b_1 b_2 b_3 b_4 b_5} F_A^{b_4 a_4} F_A^{b_5 a_5} T_{J_1 J_2 I_1}^{a_1 a_2 b_1} T_{I_2 I_3 J_3}^{b_2 b_3 a_3}, \quad (A.20) $$

where the dressed partially antisymmetric tensor is defined by (A.15).

<footnote n="14">¹⁴Furthermore, we have observed that, for each row, the two states (A.13) yield equivalent DDIs and the coloured field strengths $F_A$ of the completions can be set to their minimal value $A = 1$. As seen in the next section, these properties are reminiscent of the various forms of the Cayley-Hamilton identity. However, notice that it might not be true when the tensor $H$ has fewer symmetries than $\nabla F \nabla F$.</footnote>
Using the Laplace expansion, or cofactor expansion, for determinants with respect to $\bar{a}_5$, we get

$$ \frac{A_2}{A_1} \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} \approx - \left( \bar{A}_1 \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} + A_1 \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} + A_1 \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} + A_1 \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} \right) \quad (A.16) $$

with $\bar{I}_i = I_i + A_2$, $\bar{A} = A_1 + A_2$ and where, in analogy with (A.15), we have introduced

$$ A \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} \equiv \Delta_{\bar{a}_1 \bar{a}_2 \bar{a}_3 \bar{a}_4 \bar{b}_1 \bar{b}_2 \bar{b}_3 \bar{b}_4} F_{J_1}^{\bar{a}_1 a_1} F_{J_2}^{\bar{a}_2 a_2} F_{J_3}^{\bar{a}_3 a_3} F_{I_1}^{\bar{b}_1 b_1} F_{I_2}^{\bar{b}_2 b_2} F_{I_3}^{\bar{b}_3 b_3} F_A^{\bar{b}_4 \bar{a}_4}, \quad (A.17) $$

the bare partially antisymmetric tensor with eight indices being defined similarly to (4.17). The notation $\approx$ signifies that we dropped the terms with $f_2$ and $f_4$ arising from the contraction, as explained in the last section of this appendix. Notice that the relation (A.16) enables us to relate four-dimensional DDIs, which involve antisymmetrisation over five indices, to three-dimensional DDIs, with antisymmetrisation over four indices.

Similarly, expanding the determinant in $\bar{a}_4$ yields

$$ A \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} \approx - \left( \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} + \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} + \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} \right), \quad (A.18) $$

where $\bar{I}_i = I_i + A$, (123) are the permutations of three elements and

$$ \begin{aligned} \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} &\equiv \Delta_{\bar{a}_1 \bar{a}_2 \bar{a}_3 \bar{b}_1 \bar{b}_2 \bar{b}_3} F_{J_1}^{\bar{a}_1 a_1} F_{J_2}^{\bar{a}_2 a_2} F_{J_3}^{\bar{a}_3 a_3} F_{I_1}^{\bar{b}_1 b_1} F_{I_2}^{\bar{b}_2 b_2} F_{I_3}^{\bar{b}_3 b_3} \\ &= \sum_{\sigma \in (123)} (-1)^{I_1+I_2+I_3+\operatorname{sgn}(\sigma)} F_{I_{\sigma_1}+J_1}^{b_{\sigma_1} a_1} F_{I_{\sigma_2}+J_2}^{b_{\sigma_2} a_2} F_{I_{\sigma_3}+J_3}^{b_{\sigma_3} a_3} \end{aligned} \quad (A.19) $$

correspond to two-dimensional DDIs. Since $f_2 \approx f_4 \approx 0$, each term in (A.19), and thus in the four-dimensional DDI (A.15), that contains a $F_{I_i+J_j}$ with $I_i + J_j \ge 4$ can be neglected, due to the Cayley-Hamilton identity. This results in significant valency reductions and enables us to easily obtain specific representatives for the basis of scalar invariants.

## A.3 Algebraic basis of scalar invariants in two, three and four dimensions

Although we are mainly interested in four-dimensional theories, it is instructive, especially after our discussion in the previous section, to consider the same theories in lower dimensions and identify the corresponding DDIs and Bianchi identities.

We observe that the two and four dimensional DDIs can all be obtained from the disconnected diagrams of the third row of figure 1, while three-dimensional ones require the use of the sixth row as well.<fnref n="14" /> Interestingly, when the Bianchi identity is taken into account, four-dimensional DDIs can all be parametrised by the second column of the third row, corresponding to (4.20) in the main text, i.e.

$$ \frac{A_2}{A_1} \Delta_{J_1 J_2 J_3 I_1 I_2 I_3}^{a_1 a_2 a_3 b_1 b_2 b_3} \nabla_{a_1} F_{a_2 b_1} \nabla_{b_2} F_{b_3 a_3} = \Delta_{a_1 a_2 a_3 a_4 a_5 b_1 b_2 b_3 b_4 b_5} F_A^{b_4 a_4} F_A^{b_5 a_5} T_{J_1 J_2 I_1}^{a_1 a_2 b_1} T_{I_2 I_3 J_3}^{b_2 b_3 a_3}, \quad (A.20) $$

where the dressed partially antisymmetric tensor is defined by (A.15).

<footnote n="14">¹⁴Furthermore, we have observed that, for each row, the two states (A.13) yield equivalent DDIs and the coloured field strengths $F_A$ of the completions can be set to their minimal value $A = 1$. As seen in the next section, these properties are reminiscent of the various forms of the Cayley-Hamilton identity. However, notice that it might not be true when the tensor $H$ has fewer symmetries than $\nabla F \nabla F$.</footnote>
In two dimensions, the Bianchi identity is a tensorial DDI and any scalar is proportional to a single invariant given by

$$ \mathcal{B}_2 = \{\mathcal{B}_{000}\}. \qquad (A.21) $$

In three dimensions, there are 113 DDIs and only three left-over Bianchi identities, so that the algebraic basis of U(1) invariants is eight-dimensional and can be chosen to be

$$ \mathcal{B}_3 = \mathcal{B}_2 \cup \{\mathcal{A}_{000}, \mathcal{B}_{010}, \mathcal{B}_{011}, \mathcal{B}_{110}, \mathcal{B}_{200}, \mathcal{B}_{210}, \mathcal{B}_{211}\}. \qquad (A.22) $$

When the U(1) symmetry is not imposed, in which case the scalars are simply (non-linear) kinetic terms for 2-form fields, the basis is eleven-dimensional and given by

$$ \tilde{\mathcal{B}}_3 = \mathcal{B}_3 \cup \{\tilde{\mathcal{A}}_{000}, \mathcal{A}_{010}, \mathcal{A}_{200}\}. \qquad (A.23) $$

Finally, in four dimensions, we obtain 22 U(1) invariants, which can be chosen as follows,

$$ \mathcal{B}_4 = \mathcal{B}_3 \cup \{\mathcal{A}_{002}, \mathcal{A}_{101}, \mathcal{A}_{200}, \mathcal{A}_{210}, \mathcal{A}_{301}, \mathcal{B}_{020}, \mathcal{B}_{022}, \mathcal{B}_{112}, \mathcal{B}_{120}, \mathcal{B}_{212}, \mathcal{B}_{220}, \mathcal{B}_{310}, \mathcal{B}_{312}, \mathcal{B}_{320}\} \qquad (A.24) $$

while we obtain 36 independent invariants for the kinetic terms of 2-form fields,

$$ \tilde{\mathcal{B}}_4 = \mathcal{B}_4 \cup \{\mathcal{A}_{010}, \mathcal{A}_{021}, \mathcal{A}_{120}, \mathcal{A}_{320}, \tilde{\mathcal{A}}_{000}, \tilde{\mathcal{A}}_{101}, \tilde{\mathcal{A}}_{110}, \tilde{\mathcal{A}}_{200}, \tilde{\mathcal{A}}_{301}, \tilde{\mathcal{A}}_{310}, \tilde{\mathcal{B}}_{011}, \tilde{\mathcal{B}}_{211}, \hat{\mathcal{B}}_{001}, \hat{\mathcal{B}}_{201}\} \qquad (A.25) $$

## A.4 Redundancy of 2-index H tensor

As claimed above, we show that if 2-index tensors, such as $V\tilde{V}$ or one of the loop-shaped tensors (see the diagram (A.2)),

$$ g_{be} g_{cf} T_{000}^{abc} T_{IJK}^{def}, \qquad (A.26) $$

are used to construct DDIs, the result will end up being redundant compare to the Cayley-Hamilton (CH) identity. In order to do so, notice that this identity can be obtained from both

$$ \delta_{[b}^{a} F^{e_1}_{e_1} F^{e_2}_{e_2} F^{e_3}_{e_3} F^{e_4}_{e_4]} \propto \delta_{[b}^{a} F_{a_1 a_2} F_{a_3 a_4]} F^{a_1 a_2} F^{a_3 a_4} = 0. \qquad (A.27) $$

Noticing further that

$$ \delta_{[b}^{a} F_{a_1 a_2} F_{a_3}^{\ a_3} F_{a_4]}^{a_4} F^{a_1 a_2} = 0, \qquad (A.28) $$

in any dimension, this shows that DDIs with two indices constructed solely from products of the field strength are either trivial or redundant compared to CH, given that any higher weight can be obtained multiplying the previous equations by $F_I$ and that we took into consideration the three different ways to antisymmetrise five indices from products of $F$. Notice that colouring each $F$ in the previous equations does not change that result either.

Denoting $H$ an arbitrary 2-index tensor (which for our purpose should be constructed from $\nabla F \nabla F$), the DDIs built from it are divided into two families,

$$ \begin{aligned} H_{[a_1 a_2} (F_I F_J F_K F_L)_{a_3 a_4 a_5]}^{a_1 a_2 a_3 a_4 a_5} &= H_{a_1 a_2} (F_I F_J F_K F_L)_{a_3 a_4 a_5}^{[a_1 a_2 a_3 a_4 a_5]}, \\ H_{[a_1}^{a_1} (F_I F_J F_K F_L)_{a_2 a_3 a_4 a_5]}^{a_2 a_3 a_4 a_5} &= H_{b_1}^{a_1} \delta_{[a_1}^{b_1} (F_I F_J F_K F_L)_{a_2 a_3 a_4 a_5]}^{a_2 a_3 a_4 a_5}, \end{aligned} \qquad (A.29) $$

where the notation with parenthesis means that the indices can be distributed arbitrarily on the tensor product. Thus, they reduce to tensorial DDIs with two indices built from products of $F_I$, i.e. to the Cayley-Hamilton identity.
In two dimensions, the Bianchi identity is a tensorial DDI and any scalar is proportional to a single invariant given by

$$ \mathcal{B}_2 = \{\mathcal{B}_{000}\}. \qquad (A.21) $$

In three dimensions, there are 113 DDIs and only three left-over Bianchi identities, so that the algebraic basis of U(1) invariants is eight-dimensional and can be chosen to be

$$ \mathcal{B}_3 = \mathcal{B}_2 \cup \{\mathcal{A}_{000}, \mathcal{B}_{010}, \mathcal{B}_{011}, \mathcal{B}_{110}, \mathcal{B}_{200}, \mathcal{B}_{210}, \mathcal{B}_{211}\}. \qquad (A.22) $$

When the U(1) symmetry is not imposed, in which case the scalars are simply (non-linear) kinetic terms for 2-form fields, the basis is eleven-dimensional and given by

$$ \tilde{\mathcal{B}}_3 = \mathcal{B}_3 \cup \{\tilde{\mathcal{A}}_{000}, \mathcal{A}_{010}, \mathcal{A}_{200}\}. \qquad (A.23) $$

Finally, in four dimensions, we obtain 22 U(1) invariants, which can be chosen as follows,

$$ \mathcal{B}_4 = \mathcal{B}_3 \cup \{\mathcal{A}_{002}, \mathcal{A}_{101}, \mathcal{A}_{200}, \mathcal{A}_{210}, \mathcal{A}_{301}, \mathcal{B}_{020}, \mathcal{B}_{022}, \mathcal{B}_{112}, \mathcal{B}_{120}, \mathcal{B}_{212}, \mathcal{B}_{220}, \mathcal{B}_{310}, \mathcal{B}_{312}, \mathcal{B}_{320}\} \qquad (A.24) $$

while we obtain 36 independent invariants for the kinetic terms of 2-form fields,

$$ \tilde{\mathcal{B}}_4 = \mathcal{B}_4 \cup \{\mathcal{A}_{010}, \mathcal{A}_{021}, \mathcal{A}_{120}, \mathcal{A}_{320}, \tilde{\mathcal{A}}_{000}, \tilde{\mathcal{A}}_{101}, \tilde{\mathcal{A}}_{110}, \tilde{\mathcal{A}}_{200}, \tilde{\mathcal{A}}_{301}, \tilde{\mathcal{A}}_{310}, \tilde{\mathcal{B}}_{011}, \tilde{\mathcal{B}}_{211}, \hat{\mathcal{B}}_{001}, \hat{\mathcal{B}}_{201}\} \qquad (A.25) $$

## A.4 Redundancy of 2-index H tensor

As claimed above, we show that if 2-index tensors, such as $V\tilde{V}$ or one of the loop-shaped tensors (see the diagram (A.2)),

$$ g_{be} g_{cf} T_{000}^{abc} T_{IJK}^{def}, \qquad (A.26) $$

are used to construct DDIs, the result will end up being redundant compare to the Cayley-Hamilton (CH) identity. In order to do so, notice that this identity can be obtained from both

$$ \delta_{[b}^{a} F^{e_1}_{e_1} F^{e_2}_{e_2} F^{e_3}_{e_3} F^{e_4}_{e_4]} \propto \delta_{[b}^{a} F_{a_1 a_2} F_{a_3 a_4]} F^{a_1 a_2} F^{a_3 a_4} = 0. \qquad (A.27) $$

Noticing further that

$$ \delta_{[b}^{a} F_{a_1 a_2} F_{a_3}^{\ a_3} F_{a_4]}^{\ a_4} F^{a_1 a_2} = 0, \qquad (A.28) $$

in any dimension, this shows that DDIs with two indices constructed solely from products of the field strength are either trivial or redundant compared to CH, given that any higher weight can be obtained multiplying the previous equations by $F_I$ and that we took into consideration the three different ways to antisymmetrise five indices from products of $F$. Notice that colouring each $F$ in the previous equations does not change that result either.

Denoting $H$ an arbitrary 2-index tensor (which for our purpose should be constructed from $\nabla F \nabla F$), the DDIs built from it are divided into two families,

$$ H_{[a_1 a_2} (F_I F_J F_K F_L)_{a_3 a_4 a_5]}^{a_1 a_2 a_3 a_4 a_5} = H_{a_1 a_2} (F_I F_J F_K F_L)_{a_3 a_4 a_5}^{[a_1 a_2 a_3 a_4 a_5]}, \qquad (A.29) $$ $$ H_{[a_1}^{a_1} (F_I F_J F_K F_L)_{a_2 a_3 a_4 a_5]}^{a_2 a_3 a_4 a_5} = H_{b_1}^{a_1} \delta_{[a_1}^{b_1} (F_I F_J F_K F_L)_{a_2 a_3 a_4 a_5]}^{a_2 a_3 a_4 a_5}, $$

where the notation with parenthesis means that the indices can be distributed arbitrarily on the tensor product. Thus, they reduce to tensorial DDIs with two indices built from products of $F_I$, i.e. to the Cayley-Hamilton identity.
## A.5 Connected scalar diagrams

Finally, we explain why it is possible to neglect the traces $f_2 \approx f_4 \approx 0$ in the expansion of generalised Kronecker symbols, without spoiling the dimensionality of the basis of DDIs. Although not necessary, this assumption helps to find representatives for that basis. Of course, in order to obtain precise irreducible decompositions of invariants, this simplification cannot be made. In terms of diagrams, this means that among all the scalar invariants resulting from Laplace expansion, only those represented by connected diagrams can be kept. More precisely, it is clear that any scalar DDI can be expanded to yield

$$S_w = \sum_{2 \le i < j \le k \le l \le m \le n \atop 2 \le p < q \le r \le s \le t \le u \le v \le w \le 9} f_2^i f_4^j S_{w-2(i+2j)}^{(i,j)}, \quad (A.30)$$

where $S_w$ is a linear combination with constant coefficients of the scalar invariants $\{A, \tilde{A}, B, \tilde{B}, \hat{B}\}$ of weight $w$, defined by (4.3) and (4.6), and similarly for each $S^{(i,j)}$. In order to list all independent DDIs, we now show that it is sufficient to set $f_2 \approx f_4 \approx 0$.

Indeed, this simplification would lead to ignore some relevant DDIs only if two DDIs yield (A.30) with the same $S_w$ but different $S^{(i,j)}$. Denoting $\tilde{S}$ this difference of invariants, we could then construct a DDI given by

$$\sum_{2 \le i < j \le k \le l \le m \le n \atop 2 \le p < q \le r \le s \le t \le u \le v \le w \le 9} f_2^i f_4^j \tilde{S}_{w-2(i+2j)}^{(i,j)} = 0, \quad (A.31)$$

which would trivialize when assuming $f_2 \approx f_4 \approx 0$. However, the unicity of the Laplace expansions (A.30) prevents this from happening.

Let us see some examples for low weights, which we recall, are ranging from 0 to 9. First, it is clear that at least 10 indices are needed to build a four-dimensional scalar DDI, so $w \ge 2$ in (A.30). At weight 2, all DDIs have the form

$$S_2 = f_2 S_0^{(1,0)}. \quad (A.32)$$

Thus, (A.31) would imply the existence of a dimensional identity between weight 0 scalars, $\tilde{S}_0 = 0$, which is impossible as we just said. The same would happen at weight 3, so we move to $w = 4$. At this weight, DDIs have the form

$$S_4 = f_2 S_2^{(1,0)} + f_2^2 S_0^{(2,0)} + f_4 S_0^{(0,1)}. \quad (A.33)$$

Thus, a relation of the form (A.31) would yield $f_2 \tilde{S}_2^{(1,0)} + f_2^2 \tilde{S}_0^{(2,0)} + f_4 \tilde{S}_0^{(0,1)} = 0$. Assuming that we have used all the lower weight DDIs, given by (A.32), implies that $\tilde{S}_0^{(0,1)} \neq 0$. Let us now choose a configuration of the two-form field $F$ which fixes one out of its six components, say $f_2 = 0$ and $f_4 \neq 0$. Then, the previous equation becomes a DDI among weight 0 scalar invariants, which is again impossible, unless $F$ is effectively two-dimensional in this configuration, meaning that it would have only one independent component. This is not the case here as only one component among six has been fixed, so again relations such as (A.31) are impossible up to weight 4. It is clear that the same would apply for higher weight terms.

**Open Access.** This article is distributed under the terms of the Creative Commons Attribution License (CC-BY4.0), which permits any use, distribution and reproduction in any medium, provided the original author(s) and source are credited.
## A.5 Connected scalar diagrams

Finally, we explain why it is possible to neglect the traces $f_2 \approx f_4 \approx 0$ in the expansion of generalised Kronecker symbols, without spoiling the dimensionality of the basis of DDIs. Although not necessary, this assumption helps to find representatives for that basis. Of course, in order to obtain precise irreducible decompositions of invariants, this simplification cannot be made. In terms of diagrams, this means that among all the scalar invariants resulting from Laplace expansion, only those represented by connected diagrams can be kept. More precisely, it is clear that any scalar DDI can be expanded to yield

$$S_w = \sum_{2 \le 2(i+2j) \le w \le 9} f_2^i f_4^j S_{w-2(i+2j)}^{(i,j)}, \qquad (A.30)$$

where $S_w$ is a linear combination with constant coefficients of the scalar invariants $\{A, \tilde{A}, B, \tilde{B}, \hat{B}\}$ of weight $w$, defined by (4.3) and (4.6), and similarly for each $S^{(i,j)}$. In order to list all independent DDIs, we now show that it is sufficient to set $f_2 \approx f_4 \approx 0$.

Indeed, this simplification would lead to ignore some relevant DDIs only if two DDIs yield (A.30) with the same $S_w$ but different $S^{(i,j)}$. Denoting $\tilde{S}$ this difference of invariants, we could then construct a DDI given by

$$\sum_{2 \le 2(i+2j) \le w \le 9} f_2^i f_4^j \tilde{S}_{w-2(i+2j)}^{(i,j)} = 0, \qquad (A.31)$$

which would trivialize when assuming $f_2 \approx f_4 \approx 0$. However, the unicity of the Laplace expansions (A.30) prevents this from happening.

Let us see some examples for low weights, which we recall, are ranging from 0 to 9. First, it is clear that at least 10 indices are needed to build a four-dimensional scalar DDI, so $w \ge 2$ in (A.30). At weight 2, all DDIs have the form

$$S_2 = f_2 S_0^{(1,0)}. \qquad (A.32)$$

Thus, (A.31) would imply the existence of a dimensional identity between weight 0 scalars, $\tilde{S}_0 = 0$, which is impossible as we just said. The same would happen at weight 3, so we move to $w = 4$. At this weight, DDIs have the form

$$S_4 = f_2 S_2^{(1,0)} + f_2^2 S_0^{(2,0)} + f_4 S_0^{(0,1)}. \qquad (A.33)$$

Thus, a relation of the form (A.31) would yield $f_2 \tilde{S}_2^{(1,0)} + f_2^2 \tilde{S}_0^{(2,0)} + f_4 \tilde{S}_0^{(0,1)} = 0$. Assuming that we have used all the lower weight DDIs, given by (A.32), implies that $\tilde{S}_0^{(0,1)} \neq 0$. Let us now choose a configuration of the two-form field $F$ which fixes one out of its six components, say $f_2 = 0$ and $f_4 \neq 0$. Then, the previous equation becomes a DDI among weight 0 scalar invariants, which is again impossible, unless $F$ is effectively two-dimensional in this configuration, meaning that it would have only one independent component. This is not the case here as only one component among six has been fixed, so again relations such as (A.31) are impossible up to weight 4. It is clear that the same would apply for higher weight terms.

**Open Access.** This article is distributed under the terms of the Creative Commons Attribution License (CC-BY4.0), which permits any use, distribution and reproduction in any medium, provided the original author(s) and source are credited.
References

[1] G.W. Horndeski, *Second-order scalar-tensor field equations in a four-dimensional space*, Int. J. Theor. Phys. **10** (1974) 363 [INSPIRE].

[2] G.W. Horndeski, *Conservation of charge and the Einstein-Maxwell field equations*, J. Math. Phys. **17** (1976) 1980 [INSPIRE].

[3] D. Langlois and K. Noui, *Degenerate higher derivative theories beyond Horndeski: evading the Ostrogradski instability*, JCAP **02** (2016) 034 [arXiv:1510.06930] [INSPIRE].

[4] D. Langlois and K. Noui, *Hamiltonian analysis of higher derivative scalar-tensor theories*, JCAP **07** (2016) 016 [arXiv:1512.06820] [INSPIRE].

[5] J. Gleyzes, D. Langlois, F. Piazza and F. Vernizzi, *Healthy theories beyond Horndeski*, Phys. Rev. Lett. **114** (2015) 211101 [arXiv:1404.6495] [INSPIRE].

[6] J. Gleyzes, D. Langlois, F. Piazza and F. Vernizzi, *Exploring gravitational theories beyond Horndeski*, JCAP **02** (2015) 018 [arXiv:1408.1952] [INSPIRE].

[7] J. Ben Achour, D. Langlois and K. Noui, *Degenerate higher order scalar-tensor theories beyond Horndeski and disformal transformations*, Phys. Rev. D **93** (2016) 124005 [arXiv:1602.08398] [INSPIRE].

[8] J. Ben Achour et al., *Degenerate higher order scalar-tensor theories beyond Horndeski up to cubic order*, JHEP **12** (2016) 100 [arXiv:1608.08135] [INSPIRE].

[9] D. Langlois, *Dark energy and modified gravity in degenerate higher-order scalar-tensor (DHOST) theories: a review*, Int. J. Mod. Phys. D **28** (2019) 1942006 [arXiv:1811.06271] [INSPIRE].

[10] T. Kobayashi, *Horndeski theory and beyond: a review*, Rept. Prog. Phys. **82** (2019) 086901 [arXiv:1901.07183] [INSPIRE].

[11] G. Tasinato, *Cosmic acceleration from Abelian symmetry breaking*, JHEP **04** (2014) 067 [arXiv:1402.6450] [INSPIRE].

[12] L. Heisenberg, *Generalization of the Proca action*, JCAP **05** (2014) 015 [arXiv:1402.7026] [INSPIRE].

[13] E. Allys, P. Peter and Y. Rodriguez, *Generalized Proca action for an Abelian vector field*, JCAP **02** (2016) 004 [arXiv:1511.03101] [INSPIRE].

[14] J. Beltran Jimenez and L. Heisenberg, *Derivative self-interactions for a massive vector field*, Phys. Lett. B **757** (2016) 405 [arXiv:1602.03410] [INSPIRE].

[15] A.E. Gumrukcuoglu and R. Namba, *Role of matter in gravitation: going beyond the Einstein-Maxwell theory*, Phys. Rev. D **100** (2019) 124064 [arXiv:1907.12292] [INSPIRE].

[16] A. De Felice and A. Naruko, *On metric transformations with a $U(1)$ gauge field*, Phys. Rev. D **101** (2020) 084044 [arXiv:1911.10960] [INSPIRE].

[17] C. Deffayet, A.E. Gümrükçüoğlu, S. Mukohyama and Y. Wang, *A no-go theorem for generalized vector Galileons on flat spacetime*, JHEP **04** (2014) 082 [arXiv:1312.6690] [INSPIRE].

[18] F. Bopp, *Eine lineare Theorie des Elektrons* (in German), Annalen Phys. **430** (1940) 345.

[19] B. Podolsky, *A generalized electrodynamics Part I-non-quantum*, Phys. Rev. **62** (1942) 68 [INSPIRE].

[20] H.W. Lee, P.Y. Pac and H.K. Shin, *Derivative expansions in quantum electrodynamics*, Phys. Rev. D **40** (1989) 4202 [INSPIRE].
References

[1] G.W. Horndeski, *Second-order scalar-tensor field equations in a four-dimensional space*, Int. J. Theor. Phys. **10** (1974) 363 [INSPIRE].

[2] G.W. Horndeski, *Conservation of charge and the Einstein-Maxwell field equations*, J. Math. Phys. **17** (1976) 1980 [INSPIRE].

[3] D. Langlois and K. Noui, *Degenerate higher derivative theories beyond Horndeski: evading the Ostrogradski instability*, JCAP **02** (2016) 034 [arXiv:1510.06930] [INSPIRE].

[4] D. Langlois and K. Noui, *Hamiltonian analysis of higher derivative scalar-tensor theories*, JCAP **07** (2016) 016 [arXiv:1512.06820] [INSPIRE].

[5] J. Gleyzes, D. Langlois, F. Piazza and F. Vernizzi, *Healthy theories beyond Horndeski*, Phys. Rev. Lett. **114** (2015) 211101 [arXiv:1404.6495] [INSPIRE].

[6] J. Gleyzes, D. Langlois, F. Piazza and F. Vernizzi, *Exploring gravitational theories beyond Horndeski*, JCAP **02** (2015) 018 [arXiv:1408.1952] [INSPIRE].

[7] J. Ben Achour, D. Langlois and K. Noui, *Degenerate higher order scalar-tensor theories beyond Horndeski and disformal transformations*, Phys. Rev. D **93** (2016) 124005 [arXiv:1602.08398] [INSPIRE].

[8] J. Ben Achour et al., *Degenerate higher order scalar-tensor theories beyond Horndeski up to cubic order*, JHEP **12** (2016) 100 [arXiv:1608.08135] [INSPIRE].

[9] D. Langlois, *Dark energy and modified gravity in degenerate higher-order scalar-tensor (DHOST) theories: a review*, Int. J. Mod. Phys. D **28** (2019) 1942006 [arXiv:1811.06271] [INSPIRE].

[10] T. Kobayashi, *Horndeski theory and beyond: a review*, Rept. Prog. Phys. **82** (2019) 086901 [arXiv:1901.07183] [INSPIRE].

[11] G. Tasinato, *Cosmic acceleration from Abelian symmetry breaking*, JHEP **04** (2014) 067 [arXiv:1402.6450] [INSPIRE].

[12] L. Heisenberg, *Generalization of the Proca action*, JCAP **05** (2014) 015 [arXiv:1402.7026] [INSPIRE].

[13] E. Allys, P. Peter and Y. Rodriguez, *Generalized Proca action for an Abelian vector field*, JCAP **02** (2016) 004 [arXiv:1511.03101] [INSPIRE].

[14] J. Beltran Jimenez and L. Heisenberg, *Derivative self-interactions for a massive vector field*, Phys. Lett. B **757** (2016) 405 [arXiv:1602.03410] [INSPIRE].

[15] A.E. Gumrukcuoglu and R. Namba, *Role of matter in gravitation: going beyond the Einstein-Maxwell theory*, Phys. Rev. D **100** (2019) 124064 [arXiv:1907.12292] [INSPIRE].

[16] A. De Felice and A. Naruko, *On metric transformations with a $U(1)$ gauge field*, Phys. Rev. D **101** (2020) 084044 [arXiv:1911.10960] [INSPIRE].

[17] C. Deffayet, A.E. Gümrükçüoğlu, S. Mukohyama and Y. Wang, *A no-go theorem for generalized vector Galileons on flat spacetime*, JHEP **04** (2014) 082 [arXiv:1312.6690] [INSPIRE].

[18] F. Bopp, *Eine lineare Theorie des Elektrons* (in German), Annalen Phys. **430** (1940) 345.

[19] B. Podolsky, *A generalized electrodynamics Part I-non-quantum*, Phys. Rev. **62** (1942) 68 [INSPIRE].

[20] H.W. Lee, P.Y. Pac and H.K. Shin, *Derivative expansions in quantum electrodynamics*, Phys. Rev. D **40** (1989) 4202 [INSPIRE].
[21] D. Cangemi, E. D'Hoker and G.V. Dunne, *Derivative expansion of the effective action and vacuum instability for QED in (2 + 1)-dimensions*, Phys. Rev. D 51 (1995) R2513 [hep-th/9409113] [INSPIRE].

[22] V.P. Gusynin and I.A. Shovkovy, *Derivative expansion for the one loop effective Lagrangian in QED*, Can. J. Phys. 74 (1996) 282 [hep-ph/9509383] [INSPIRE].

[23] V.P. Gusynin and I.A. Shovkovy, *Derivative expansion of the effective action for QED in (2 + 1)-dimensions and (3 + 1)-dimensions*, J. Math. Phys. 40 (1999) 5406 [hep-th/9804143] [INSPIRE].

[24] J. Navarro-Salas and S. Pla, (*F*,*G*)-summed form of the QED effective action, Phys. Rev. D 103 (2021) L081702 [arXiv:2011.09743] [INSPIRE].

[25] F. Karbstein, *Derivative corrections to the Heisenberg-Euler effective action*, JHEP 09 (2021) 070 [arXiv:2108.02068] [INSPIRE].

[26] I.T. Drummond and S.J. Hathrell, *QED vacuum polarization in a background gravitational field and its effect on the velocity of photons*, Phys. Rev. D 22 (1980) 343 [INSPIRE].

[27] F. Bastianelli, U. Nucamendi, C. Schubert and V.M. Villanueva, *Photon-graviton mixing in an electromagnetic field*, J. Phys. A 41 (2008) 164048 [arXiv:0711.0992] [INSPIRE].

[28] F. Bastianelli, J.M. Davila and C. Schubert, *Gravitational corrections to the Euler-Heisenberg Lagrangian*, JHEP 03 (2009) 086 [arXiv:0812.4849] [INSPIRE].

[29] C. de Rham and A.J. Tolley, *Causality in curved spacetimes: the speed of light and gravity*, Phys. Rev. D 102 (2020) 084048 [arXiv:2007.01847] [INSPIRE].

[30] D. Ejlli and V.R. Thandlam, *Graviton-photon mixing*, Phys. Rev. D 99 (2019) 044022 [arXiv:1807.00171] [INSPIRE].

[31] D. Ejlli, *Graviton-photon mixing. Exact solution in a constant magnetic field*, JHEP 06 (2020) 029 [arXiv:2004.02714] [INSPIRE].

[32] I. Bandos, K. Lechner, D. Sorokin and P.K. Townsend, *A non-linear duality-invariant conformal extension of Maxwell's equations*, Phys. Rev. D 102 (2020) 121703 [arXiv:2007.09092] [INSPIRE].

[33] B.P. Kosyakov, *Nonlinear electrodynamics with the maximum allowable symmetries*, Phys. Lett. B 810 (2020) 135840 [arXiv:2007.13878] [INSPIRE].

[34] P.A. Cano and Á. Murcia, *Duality-invariant extensions of Einstein-Maxwell theory*, JHEP 08 (2021) 042 [arXiv:2104.07674] [INSPIRE].

[35] P.A. Cano and Á. Murcia, *Exact electromagnetic duality with nonminimal couplings*, Phys. Rev. D 104 (2021) L101501 [arXiv:2105.09868] [INSPIRE].

[36] A.B. Balakin, J.P.S. Lemos and A.E. Zayats, *Regular nonminimal magnetic black holes in spacetimes with a cosmological constant*, Phys. Rev. D 93 (2016) 024008 [arXiv:1512.02653] [INSPIRE].

[37] P.A. Cano and Á. Murcia, *Resolution of Reissner-Nordström singularities by higher-derivative corrections*, Class. Quant. Grav. 38 (2021) 075014 [arXiv:2006.15149] [INSPIRE].

[38] S.B. Edgar and A. Hoglund, *Dimensionally dependent tensor identities by double antisymmetrization*, J. Math. Phys. 43 (2002) 659 [gr-qc/0105066] [INSPIRE].

[39] B. Knorr, C. Ripken and F. Saueressig, *Form factors in asymptotic safety: conceptual ideas and computational toolbox*, Class. Quant. Grav. 36 (2019) 234001 [arXiv:1907.02903] [INSPIRE].

[40] J.M. Martín-García et al., *xAct: efficient tensor computer algebra for Mathematica*, http://xact.es/ (2002).
[21] D. Cangemi, E. D'Hoker and G.V. Dunne, *Derivative expansion of the effective action and vacuum instability for QED in (2 + 1)-dimensions*, Phys. Rev. D 51 (1995) R2513 [hep-th/9409113] [INSPIRE].

[22] V.P. Gusynin and I.A. Shovkovy, *Derivative expansion for the one loop effective Lagrangian in QED*, Can. J. Phys. 74 (1996) 282 [hep-ph/9509383] [INSPIRE].

[23] V.P. Gusynin and I.A. Shovkovy, *Derivative expansion of the effective action for QED in (2 + 1)-dimensions and (3 + 1)-dimensions*, J. Math. Phys. 40 (1999) 5406 [hep-th/9804143] [INSPIRE].

[24] J. Navarro-Salas and S. Pla, (*F*,*G*)-summed form of the QED effective action, Phys. Rev. D 103 (2021) L081702 [arXiv:2011.09743] [INSPIRE].

[25] F. Karbstein, *Derivative corrections to the Heisenberg-Euler effective action*, JHEP 09 (2021) 070 [arXiv:2108.02068] [INSPIRE].

[26] I.T. Drummond and S.J. Hathrell, *QED vacuum polarization in a background gravitational field and its effect on the velocity of photons*, Phys. Rev. D 22 (1980) 343 [INSPIRE].

[27] F. Bastianelli, U. Nucamendi, C. Schubert and V.M. Villanueva, *Photon-graviton mixing in an electromagnetic field*, J. Phys. A 41 (2008) 164048 [arXiv:0711.0992] [INSPIRE].

[28] F. Bastianelli, J.M. Davila and C. Schubert, *Gravitational corrections to the Euler-Heisenberg Lagrangian*, JHEP 03 (2009) 086 [arXiv:0812.4849] [INSPIRE].

[29] C. de Rham and A.J. Tolley, *Causality in curved spacetimes: the speed of light and gravity*, Phys. Rev. D 102 (2020) 084048 [arXiv:2007.01847] [INSPIRE].

[30] D. Ejlli and V.R. Thandlam, *Graviton-photon mixing*, Phys. Rev. D 99 (2019) 044022 [arXiv:1807.00171] [INSPIRE].

[31] D. Ejlli, *Graviton-photon mixing. Exact solution in a constant magnetic field*, JHEP 06 (2020) 029 [arXiv:2004.02714] [INSPIRE].

[32] I. Bandos, K. Lechner, D. Sorokin and P.K. Townsend, *A non-linear duality-invariant conformal extension of Maxwell's equations*, Phys. Rev. D 102 (2020) 121703 [arXiv:2007.09092] [INSPIRE].

[33] B.P. Kosyakov, *Nonlinear electrodynamics with the maximum allowable symmetries*, Phys. Lett. B 810 (2020) 135840 [arXiv:2007.13878] [INSPIRE].

[34] P.A. Cano and Á. Murcia, *Duality-invariant extensions of Einstein-Maxwell theory*, JHEP 08 (2021) 042 [arXiv:2104.07674] [INSPIRE].

[35] P.A. Cano and Á. Murcia, *Exact electromagnetic duality with nonminimal couplings*, Phys. Rev. D 104 (2021) L101501 [arXiv:2105.09868] [INSPIRE].

[36] A.B. Balakin, J.P.S. Lemos and A.E. Zayats, *Regular nonminimal magnetic black holes in spacetimes with a cosmological constant*, Phys. Rev. D 93 (2016) 024008 [arXiv:1512.02653] [INSPIRE].

[37] P.A. Cano and Á. Murcia, *Resolution of Reissner-Nordström singularities by higher-derivative corrections*, Class. Quant. Grav. 38 (2021) 075014 [arXiv:2006.15149] [INSPIRE].

[38] S.B. Edgar and A. Hoglund, *Dimensionally dependent tensor identities by double antisymmetrization*, J. Math. Phys. 43 (2002) 659 [gr-qc/0105066] [INSPIRE].

[39] B. Knorr, C. Ripken and F. Saueressig, *Form factors in asymptotic safety: conceptual ideas and computational toolbox*, Class. Quant. Grav. 36 (2019) 234001 [arXiv:1907.02903] [INSPIRE].

[40] J.M. Martín-García et al., *xAct: efficient tensor computer algebra for Mathematica*, http://xact.es/ (2002).