1 Introduction

Scalar–tensor gravitational theories are studied extensively as an alternative to General Relativity. Brans–Dicke theory [1] is a simple such theory which was initially formulated in terms of an action constructed from a metric \(g_{\mu \nu }\) and a scalar field \(\phi \), solely based on dimensional arguments, and with the matter Lagrangian being minimally coupled. The effective gravitational constant of the theory varies as the inverse of the scalar field, \(G\sim \frac{1}{\phi }\), and there is no dimensionful parameter in the vacuum theory. The theory respects Mach’s principle and the weak equivalence principle. In a modern context Brans–Dicke theory appears naturally from supergravity models, from string theories at low energies and from dimensional reduction of Kaluza–Klein theories [2,3,4,5,6,7]. An alternative way to derive Brans–Dicke theory is to construct directly the field equations of motion [8] respecting the simple scalar field equation \(\Box \phi =4\pi \lambda {\mathcal {T}}\), where \({\mathcal {T}}={\mathcal {T}}^{\mu }_{\,\,\,\,\mu }\) is the trace of the matter energy-momentum tensor \({\mathcal {T}}^{\mu }_{\,\,\,\,\nu }\) and \(\lambda \) is a dimensionless coupling. The demand for this derivation is that the energy-momentum tensor of the scalar field is made out of terms each of which involves two derivatives of one or two \(\phi \) fields, and \(\phi \) itself. The theory gives the correct Newtonian weak-field limit and in order to avoid the propagation of the fifth force, the coupling between matter and the massless field \(\phi \) should be suppressed, so \(\lambda \) should be very small. Recently there has arisen an increasing interest in cosmology in interacting models between dark matter and dark energy and such a mechanism can be useful to solve the coincidence problem [9,10,11,12,13,14,15,16,17]. However, usually such interactions are chosen ad hoc and do not arise by any physical theory. In [18] it was actually argued that observational evidence supports an interaction between dark matter and dark energy and a violation of the equivalence principle between baryons and dark matter. In any case it would be interesting to violate the standard conservation equation of \({\mathcal {T}}^{\mu }_{\,\,\,\,\nu }\) of Brans–Dicke theory. For example, in [19] an energy exchange model with a modified wave equation for \(\phi \) was considered (for other approaches with modified equations of motion see [20,21,22,23,24]). Useful pieces of information and exhaustive analysis of Brans–Dicke gravity can be found in [25,26,27]. We should note that if the interaction model is to be worked out at the level of an action, then there are various interactions of the matter Lagrangian with the scalar field, all having as limit the Brans–Dicke action in the absence of interactions. The number of such actions can increase in the presence of Newton’s constant \(G_{N}\) or a new mass scale. In [28], analyzing exhaustively the Bianchi identities, the general class of consistent theories generalizing Brans–Dicke theory was found, when the exact energy conservation of the matter stress tensor was relaxed, while preserving the equation \(\Box \phi =4\pi \lambda \mathcal {T}\). This class of theories is parametrized by one or two free functions of the scalar field, but it was found that there are only three theories, each with a specific interaction term, which are unambiguously determined by consistency. These unique and natural theories are certainly the predominant completions of Brans–Dicke theory. In the present paper we are going to focus on the first such theory whose equations of motion appear in Sect. 2 and they contain a new dimensionful parameter \(\nu \) (which is actually an integration constant). In order for the equivalence principle not to be violated at the ranges it has been tested, the parameters \(\lambda ,\nu \) should be chosen appropriately, and mechanisms such as Chameleon [29, 30] or Vainshtein (self screening) [31, 32], or even the existence of distinct conservation laws for baryonic and non-baryonic matter could contribute to this direction. Here, we will find in Sect. 3 the action of the vacuum part of this theory, study its symmetry transformation in Sect. 4, and only partially answer the question of its total action in Sect. 6. Moreover, in [28] the general family of the vacuum Brans–Dicke type of theories were found which satisfy the free wave equation for the scalar field, and this family is parametrized by one free function of \(\phi \). Here, the action of these vacuum theories will be also found in Sect. 5 and turns out to be a particular sector of Horndeski family.

2 Complete Brans–Dicke equations

We start with the complete Brans–Dicke theory presented in [28],

$$\begin{aligned}&G^{\mu }_{\,\,\,\nu }=\frac{8\pi }{\phi } (T^{\mu }_{\,\,\,\nu }+{\mathcal {T}}^{\mu }_{\,\,\,\,\nu }), \end{aligned}$$
(2.1)
$$\begin{aligned}&T^{\mu }_{\,\,\,\nu }=\frac{\phi }{2\lambda (\nu +8\pi \phi ^{2})^{2}}\{ 2[(1+\lambda )\nu +4\pi (2-3\lambda )\phi ^{2}]\phi ^{;\mu }\phi _{;\nu }\nonumber \\&\qquad -\,{}[(1+2\lambda )\nu +4\pi (2-3\lambda )\phi ^{2}]\delta ^{\mu }_{\,\,\,\nu } \phi ^{;\rho }\phi _{;\rho }\}\nonumber \\&\qquad +\,\frac{\phi ^{2}}{\nu +8\pi \phi ^{2}} (\phi ^{;\mu }_{\,\,\,\,;\nu }-\delta ^{\mu }_{\,\,\,\nu }\Box \phi ), \end{aligned}$$
(2.2)
$$\begin{aligned}&\Box \phi =4\pi \lambda {\mathcal {T}}\end{aligned}$$
(2.3)
$$\begin{aligned}&{{\mathcal {T}}}^{\mu }_{\,\,\,\,\nu ;\mu }=\frac{\nu }{\phi (\nu +8\pi \phi ^{2})} {{\mathcal {T}}}^{\mu }_{\,\,\,\,\nu }\phi _{;\mu }. \end{aligned}$$
(2.4)

The parameter \(\nu \) is arbitrary and arises as an integration constant from the integration procedure (its dimensions are mass to the fourth). The parameter \(\lambda \ne 0\) is related to the standard Brans–Dicke parameter \(\omega _{BD}=\frac{2-3\lambda }{2\lambda }\) and controls the strength of the interaction in (2.3), while \(\nu \) controls the strength of the interaction in (2.4). This theory arises out of consistency given that the scalar field equation of motion is (2.3), and \(T^{\mu }_{\,\,\,\,\nu }\) is constructed from terms each of which involves two derivatives of one or two \(\phi \) fields and \(\phi \) itself. The right-hand side of Eq. (2.1) is consistent with the Bianchi identities, i.e. it is covariantly conserved on-shell, and therefore, the system of equations (2.1)–(2.4) is well defined. Moreover, it is the unique theory with an interaction term of the form \(\mathcal {T}^{\mu }_{\,\,\,\,\nu ;\mu } \sim \mathcal {T}^{\mu }_{\,\,\,\, \nu }\phi _{;\mu }\). For \(\nu =0\) it reduces to the Brans–Dicke theory [1] (in units with \(c=1\)),

$$\begin{aligned}&G^{\mu }_{\,\,\,\nu }=\frac{8\pi }{\phi }(T^{\mu }_{\,\,\,\nu }+ {\mathcal {T}}^{\mu }_{\,\,\,\,\nu }), \end{aligned}$$
(2.5)
$$\begin{aligned}&T^{\mu }_{\,\,\,\nu }=\frac{2-3\lambda }{16\pi \lambda \phi }\left( \phi ^{;\mu }\phi _{;\nu }-\frac{1}{2}\delta ^{\mu }_{\,\,\,\nu } \phi ^{;\rho }\phi _{;\rho }\right) \nonumber \\&\quad +\,\frac{1}{8\pi }(\phi ^{;\mu }_{\,\,\,\,;\nu }-\delta ^{\mu }_{\,\,\,\nu }\Box \phi ), \end{aligned}$$
(2.6)
$$\begin{aligned}&\Box \phi =4\pi \lambda {\mathcal {T}}\end{aligned}$$
(2.7)
$$\begin{aligned}&{\mathcal {T}}^{\mu }_{\,\,\,\,\nu ;\mu }=0. \end{aligned}$$
(2.8)

The role of the new parameter \(\nu \) is manifest in (2.4) and measures the deviation from the exact conservation of matter. The Lagrangian of the Brans–Dicke theory is

$$\begin{aligned} S_{BD}= & {} \frac{1}{16\pi }\int \mathrm{d}^{4}x \,\sqrt{-g} \,\left( \phi R-\frac{\omega _{BD}}{\phi } g^{\mu \nu }\phi _{,\mu }\phi _{,\nu }\right) \nonumber \\&+\,\int \mathrm{d}^{4}x \,\sqrt{-g} \,L_{m}, \end{aligned}$$
(2.9)

where \(L_{m}(g_{\kappa \lambda },\Psi )\) is the matter Lagrangian depending on some extra fields \(\Psi \).

3 The vacuum Lagrangian

We will find here the action of the vacuum theory above by setting \({\mathcal {T}}^{\mu }_{\,\,\,\nu }\) to zero. Mimicking the action (2.9), we consider an action of the form

$$\begin{aligned} S_{g}=\frac{1}{16\pi }\int \mathrm{d}^{4}x\,\sqrt{-g}\, [f(\phi )R-h(\phi )\phi ^{;\mu }\phi _{;\mu }], \end{aligned}$$
(3.1)

and we are looking to see if there are functions fh such that Eqs. (2.1)–(2.4) with \({\mathcal {T}}^{\mu }_{\,\,\,\,\nu }=0\) arise under variation of (3.1). The action (3.1) is a sector of the Horndeski Lagrangian [33,34,35] which leads to the most general field equations with second order derivatives. Hopefully, the Lagrangian (3.1) will be sufficient for our purposes. Variation of (3.1) with respect to the metric gives, up to boundary terms,

$$\begin{aligned} \delta _{g}S_{g}= & {} -\frac{1}{16\pi }\int \mathrm{d}^{4}x\,\sqrt{-g}\, \left[ fG^{\mu \nu }-(f''+h)\phi ^{;\mu }\phi ^{;\nu }\phantom {\frac{1}{2}}\right. \nonumber \\&+\left( f''+\frac{1}{2}h\right) g^{\mu \nu }\phi ^{;\rho } \phi _{;\rho }\nonumber \\&\left. \phantom {\frac{1}{2}}-f'(\phi ^{;\mu ;\nu }-g^{\mu \nu }\Box \phi )\right] \delta g_{\mu \nu }, \end{aligned}$$
(3.2)

where a prime denotes differentiation with respect to \(\phi \) and a; stands for the covariant differentiation with respect to \(g_{\mu \nu }\). Therefore, the gravitational field equation is

$$\begin{aligned} {\mathcal {E}}^{\mu }_{\,\,\,\nu }\equiv & {} G^{\mu }_{\,\,\,\nu }- \frac{1}{f}(f''+h)\phi ^{;\mu }\phi _{;\nu }+\frac{1}{f}\left( f''+\frac{1}{2}h\right) \delta ^{\mu }_{\,\,\,\nu }\phi ^{;\rho }\phi _{;\rho }\nonumber \\&-\,\frac{f'}{f}(\phi ^{;\mu }_{\,\,\,\,;\nu }-\delta ^{\mu }_{\,\,\,\nu }\Box \phi )=0. \end{aligned}$$
(3.3)

The trace of Eqs. (3.3) gives

$$\begin{aligned} {\mathcal {E}}^{\mu }_{\,\,\,\mu }=-R+\frac{1}{f}(3f''+h)\phi ^{;\mu }\phi _{;\mu } +3\frac{f'}{f}\Box \phi =0. \end{aligned}$$
(3.4)

In order for (3.3) to coincide with Eq. (2.1), the following conditions on the functions fh should be satisfied:

$$\begin{aligned}&\frac{f'}{f}=\frac{8\pi \phi }{\nu +8\pi \phi ^{2}}\end{aligned}$$
(3.5)
$$\begin{aligned}&\frac{f''}{f}+\frac{h}{f}=\frac{8\pi }{\lambda (\nu +8\pi \phi ^{2})^{2}} \big [(1+\lambda )\nu +4\pi (2-3\lambda )\phi ^{2}\big ],\nonumber \\ \end{aligned}$$
(3.6)
$$\begin{aligned}&\frac{f''}{f}+\frac{1}{2}\,\frac{h}{f}=\frac{4\pi }{\lambda (\nu +8\pi \phi ^{2})^{2}} \big [(1+2\lambda )\nu +4\pi (2-3\lambda )\phi ^{2}\big ].\nonumber \\ \end{aligned}$$
(3.7)

Although Eqs. (3.5)–(3.7) form a system of three conditions for the two unknowns fh, it is, however, consistent. Indeed, differentiating (3.5) with respect to \(\phi \) and combining with (3.6) we get

$$\begin{aligned} \frac{h}{f}=\frac{8\pi }{\lambda (\nu +8\pi \phi ^{2})^{2}} [\nu +4\pi (2-3\lambda )\phi ^{2}]. \end{aligned}$$
(3.8)

Also, subtracting Eqs. (3.6), (3.7) we obtain again (3.8). Thus, we are left with the system of the two equations (3.5), (3.8). The solution of this system is

$$\begin{aligned}&f=\texttt {c} \sqrt{|\nu +8\pi \phi ^{2}|},\end{aligned}$$
(3.9)
$$\begin{aligned}&h= \texttt {c} \frac{8\pi }{\lambda }\, \frac{\nu +4\pi (2-3\lambda )\phi ^{2}}{|\nu +8\pi \phi ^{2}|^{3/2}}, \end{aligned}$$
(3.10)

where \(\texttt {c}\) is an integration constant.

What remains is the satisfaction of Eq. (2.3), namely \(\Box \phi =0\). The variation of (3.1) with respect to the scalar field gives, up to boundary terms,

$$\begin{aligned} \delta _{\phi }S_{g}=\frac{1}{16\pi }\int \mathrm{d}^{4}x\, \sqrt{-g}\,\big (f'R+h'\phi ^{;\mu }\phi _{;\mu } +2h\Box \phi \big )\delta \phi .\nonumber \\ \end{aligned}$$
(3.11)

The scalar field equation is

$$\begin{aligned} {\mathcal {E}}_{\phi }\equiv f'R+h'\phi ^{;\mu }\phi _{;\mu }+2h\Box \phi =0. \end{aligned}$$
(3.12)

Using (3.4) to substitute R in (3.12) we obtain

$$\begin{aligned} \left( 3\frac{f'^{2}}{f}+2h\right) \Box \phi + \left[ f'\left( 3\frac{f''}{f}+\frac{h}{f}\right) +h'\right] \phi ^{;\mu }\phi _{;\mu }=0.\nonumber \\ \end{aligned}$$
(3.13)

Using Eqs. (3.6), (3.8) to get the quantity \(\frac{f''}{f}\) and also the solution (3.9), (3.10), we find that the coefficient of \(\phi ^{;\mu }\phi _{;\mu }\) in (3.13) vanishes. Therefore, the scalar field equation (3.13) becomes

$$\begin{aligned} \frac{16\pi \epsilon \texttt {c}}{\lambda \sqrt{|\nu +8\pi \phi ^{2}|}}\Box \phi =0, \end{aligned}$$
(3.14)

where \(\epsilon =\text {sgn}(\nu +8\pi \phi ^{2})\), which means \(\Box \phi =0\). When \(\epsilon >0\), it is either \(\nu >0\) or \(\nu <0\), \(|\phi |>\sqrt{\frac{|\nu |}{8\pi }}\). When \(\epsilon <0\), it is \(\nu <0\), \(|\phi |<\sqrt{\frac{|\nu |}{8\pi }}\).

Finally, we choose the integration constant \(\texttt {c}=\frac{\eta }{\sqrt{8\pi }}\), where \(\eta =\text {sgn}(\phi )\), to normalize the action (3.1) to the Brans–Dicke action (2.9) in the limit \(\nu =0\). The result is that the vacuum system (2.1)–(2.4) admits a Lagrangian and its action is

$$\begin{aligned} S_{g}= & {} \frac{\eta }{2(8\pi )^{3/2}}\int \mathrm{d}^{4}x\,\sqrt{-g}\, \left[ \sqrt{|\nu +8\pi \phi ^{2}|}\,R\phantom {\frac{1}{2}}\right. \nonumber \\&\left. -\,\frac{8\pi }{\lambda }\, \frac{\nu +4\pi (2-3\lambda )\phi ^{2}}{|\nu +8\pi \phi ^{2}|^{3/2}} g^{\mu \nu }\phi _{,\mu }\phi _{,\nu }\right] . \end{aligned}$$
(3.15)

4 Symmetry transformation of the vacuum action

In this section we will find a transformation of the fields \((g_{\mu \nu },\phi )\rightarrow (\hat{g}_{\mu \nu },\chi )\) such that the vacuum action (3.15) remains form invariant, i.e. it is written as

$$\begin{aligned} S_{g}= & {} \frac{\eta }{2(8\pi )^{3/2}}\int \mathrm{d}^{4}x\,\sqrt{-\hat{g}}\, \left[ \sqrt{|\nu +8\pi \chi ^{2}|}\,\hat{R}\phantom {\frac{1}{2}}\right. \nonumber \\&\left. -\,\frac{8\pi }{\lambda }\, \frac{\nu +4\pi (2-3\lambda )\chi ^{2}}{|\nu +8\pi \chi ^{2}|^{3/2}} \hat{g}^{\mu \nu }\chi _{,\mu }\chi _{,\nu }\right] . \end{aligned}$$
(4.1)

This transformation will therefore be a symmetry of the vacuum action in the Jordan frame. To be precise, we consider a conformal transformation of \(g_{\mu \nu }\) together with a field redefinition for \(\phi \), namely

$$\begin{aligned} \hat{g}_{\mu \nu }=\hat{\Omega }^{2}g_{\mu \nu },\quad \phi =A(\chi ). \end{aligned}$$
(4.2)

If \(\hat{R}\), \(\hat{\Box }\) correspond to \(\hat{g}_{\mu \nu }\), we have the relation

$$\begin{aligned} R=\hat{\omega }^{-2}\left( \hat{R}-6\frac{\hat{\Box }\hat{\omega }}{\hat{\omega }}\right) , \end{aligned}$$
(4.3)

where \(\hat{\omega }=\hat{\Omega }^{-1}\). Then, since \(\hat{\Box }\hat{\omega }=\hat{\omega }''\phi ^{|\mu }\phi _{|\mu }+\hat{\omega }'\,\hat{\Box }\phi \), the action \(S_{g}\) takes the form

$$\begin{aligned} S_{g}= & {} \frac{1}{16\pi }\int \mathrm{d}^{4}x\,\sqrt{-\hat{g}}\,f\hat{\omega }^{2}\nonumber \\&\times \left[ \hat{R}-\left( 6\frac{\hat{\omega }''}{\hat{\omega }}+\frac{h}{f}\right) \phi ^{|\mu }\phi _{|\mu } -6\frac{\hat{\omega }'}{\hat{\omega }}\hat{\Box }{\phi }\right] , \end{aligned}$$
(4.4)

where a | denotes covariant differentiation with respect to \(\hat{g}_{\mu \nu }\) and a prime denotes as usual a differentiation with respect to \(\phi \). After an integration by parts, Eq. (4.4) becomes, up to boundary terms,

$$\begin{aligned} S_{g}= & {} \frac{1}{16\pi }\int \mathrm{d}^{4}x\,\sqrt{-\hat{g}}\,f\hat{\omega }^{2}\nonumber \\&\times \left[ \hat{R}+\left( 6\frac{f'\hat{\omega }'}{f\hat{\omega }}+6\frac{\hat{\omega }'^{2}}{\hat{\omega }^{2}}-\frac{h}{f}\right) \phi ^{|\mu }\phi _{|\mu }\right] , \end{aligned}$$
(4.5)

and finally

$$\begin{aligned} S_{g}= & {} \frac{1}{16\pi }\int \mathrm{d}^{4}x\,\sqrt{-\hat{g}}\,f\hat{\omega }^{2} \left[ \hat{R}+\left( 6\frac{f'\hat{\omega }'}{f\hat{\omega }}+6\frac{\hat{\omega }'^{2}}{\hat{\omega }^{2}}-\frac{h}{f}\right) \phantom {\left( \frac{\mathrm{d}A}{\mathrm{d}\chi }\right) ^{2}}\right. \nonumber \\&\left. \times \left( \frac{\mathrm{d}A}{\mathrm{d}\chi }\right) ^{2}\, \hat{g}^{\mu \nu }\chi _{,\mu }\chi _{\nu }\right] . \end{aligned}$$
(4.6)

The action (4.6) is also written as

$$\begin{aligned} S_{g}= & {} \frac{1}{16\pi }\int \mathrm{d}^{4}x\,\sqrt{-\hat{g}}\,f\hat{\omega }^{2} \left\{ \hat{R}+\left[ 6\frac{\hat{\omega }'}{\hat{\omega }} \,\frac{(f\hat{\omega }^{2})'}{f\hat{\omega }^{2}}\right. \right. \nonumber \\&\left. \left. -\,6\frac{\hat{\omega }'^{2}}{\hat{\omega }^{2}}-\frac{h}{f}\right] \left( \frac{\mathrm{d}A}{\mathrm{d}\chi }\right) ^{2}\, \hat{g}^{\mu \nu }\chi _{,\mu }\chi _{\nu }\right\} . \end{aligned}$$
(4.7)

In order for (4.7) to be identified with (4.1) we should have

$$\begin{aligned}&f\hat{\omega }^{2}=\hat{f}\end{aligned}$$
(4.8)
$$\begin{aligned}&\left[ 6\frac{\hat{\omega }'}{\hat{\omega }} \left( \frac{\hat{f}'}{\hat{f}}-\frac{\hat{\omega }'}{\hat{\omega }}\right) -\frac{h}{f}\right] \left( \frac{\mathrm{d}A}{\mathrm{d}\chi }\right) ^{2}=-\frac{\hat{h}}{\hat{f}}, \end{aligned}$$
(4.9)

where

$$\begin{aligned} \hat{f}=\frac{\eta }{\sqrt{8\pi }}\sqrt{|\nu +8\pi \chi ^{2}|},\quad \hat{h}=\frac{\eta \sqrt{8\pi }}{\lambda } \, \frac{\nu +4\pi (2-3\lambda )\chi ^{2}}{|\nu +8\pi \chi ^{2}|^{3/2}}.\nonumber \\ \end{aligned}$$
(4.10)

Converting the \(\phi \)-derivatives in (4.8) into \(\chi \)-derivatives we get

$$\begin{aligned} \frac{6}{\hat{\omega }}\,\frac{\mathrm{d}\hat{\omega }}{\mathrm{d}\chi }\left( \frac{1}{\hat{f}}\, \frac{\mathrm{d}\hat{f}}{\mathrm{d}\chi }-\frac{1}{\hat{\omega }}\, \frac{\mathrm{d}\hat{\omega }}{\mathrm{d}\chi }\right) -\frac{h}{f}\left( \frac{\mathrm{d}A}{\mathrm{d}\chi }\right) ^{2}=-\frac{\hat{h}}{\hat{f}}. \end{aligned}$$
(4.11)

Since \(\frac{2}{\hat{\omega }}\frac{\mathrm{d}\hat{\omega }}{\mathrm{d}\chi }=\frac{1}{\hat{\omega }^{2}} \frac{\mathrm{d}(\hat{\omega }^{2})}{\mathrm{d}\chi }\), we have from (4.8)

$$\begin{aligned} \frac{2}{\hat{\omega }}\frac{\mathrm{d}\hat{\omega }}{\mathrm{d}\chi }=\frac{1}{\hat{f}} \frac{\mathrm{d}\hat{f}}{\mathrm{d}\chi }-\frac{1}{f}\frac{\mathrm{d}f}{\mathrm{d}\phi }\frac{\mathrm{d}A}{\mathrm{d}\chi }. \end{aligned}$$
(4.12)

Substituting (4.12) into (4.11) we obtain

$$\begin{aligned} \left[ \left( \frac{1}{f}\,\frac{\mathrm{d}f}{\mathrm{d}\phi }\right) ^{2}+ \frac{2h}{3f}\right] \left( \frac{\mathrm{d}A}{\mathrm{d}\chi }\right) ^{2} =\left( \frac{1}{\hat{f}}\,\frac{\mathrm{d}\hat{f}}{\mathrm{d}\chi }\right) ^{2} +\frac{2\hat{h}}{3\hat{f}}, \end{aligned}$$
(4.13)

from which one furthermore gets a separable form,

$$\begin{aligned} \frac{\mathrm{d}\phi }{\sqrt{|\nu +8\pi \phi ^{2}|}} =\pm \frac{\mathrm{d}\chi }{\sqrt{|\nu +8\pi \chi ^{2}|}}, \end{aligned}$$
(4.14)

where \(\text {sgn}(\nu +8\pi \chi ^{2})=\epsilon \).

For \(\epsilon >0\), integration of (4.14) gives

$$\begin{aligned} \phi= & {} \frac{s}{8\pi }\left( \theta \big |4\pi \chi +\sqrt{2\pi } \sqrt{\nu +8\pi \chi ^{2}}\big |^{\pm 1} -\frac{2\pi \nu }{\theta }\big |4\pi \chi \right. \nonumber \\&\left. +\,\sqrt{2\pi }\sqrt{\nu +8\pi \chi ^{2}}\big |^{\mp 1}\right) , \end{aligned}$$
(4.15)

where \(\theta >0\) is integration constant and \(s=\text {sgn}(4\pi \phi +\sqrt{2\pi } \sqrt{\nu +8\pi \phi ^{2}})= \text {sgn}(\theta |4\pi \chi +\sqrt{2\pi }\sqrt{\nu +8\pi \chi ^{2}}|^{\pm 1} +\frac{2\pi \nu }{\theta } |4\pi \chi +\sqrt{2\pi }\sqrt{\nu +8\pi \chi ^{2}}|^{\mp 1})\), or inversely

$$\begin{aligned} \chi= & {} \frac{s'}{8\pi }\left( \theta '\big |4\pi \phi +\sqrt{2\pi } \sqrt{\nu +8\pi \phi ^{2}}\big |^{\pm 1}\phantom {\frac{2\pi \nu }{\theta '}}\right. \nonumber \\&\left. -\,\frac{2\pi \nu }{\theta '}\big |4\pi \phi +\sqrt{2\pi } \sqrt{\nu +8\pi \phi ^{2}}\big |^{\mp 1}\right) , \end{aligned}$$
(4.16)

where \(\theta '=\theta ^{\mp 1}>0\) and \(s'=\text {sgn}(4\pi \chi +\sqrt{2\pi } \sqrt{\nu +8\pi \chi ^{2}})= \text {sgn}(\theta '|4\pi \phi +\sqrt{2\pi }\sqrt{\nu +8\pi \phi ^{2}}|^{\pm 1}+\frac{2\pi \nu }{\theta '}|4\pi \phi +\sqrt{2\pi }\sqrt{\nu +8\pi \phi ^{2}}|^{\mp 1})\).

For \(\epsilon <0\) it is

$$\begin{aligned} \phi =\sqrt{\frac{|\nu |}{8\pi }}\,\sin \left[ c_{1}\pm \arcsin \left( \sqrt{\frac{8\pi }{|\nu |}}\,\chi \right) \right] , \end{aligned}$$
(4.17)

where \(c_{1}\) is an integration constant, or inversely

$$\begin{aligned} \chi =\pm \sqrt{\frac{|\nu |}{8\pi }}\,\sin \left[ \arcsin \left( \sqrt{\frac{8\pi }{|\nu |}} \,\phi \right) -c_{1}\right] . \end{aligned}$$
(4.18)

Finally, since \(\phi (\chi )\) or \(\chi (\phi )\) has been found, the conformal transformation (4.2), which leaves the vacuum action \(S_{g}\) form invariant, is

$$\begin{aligned} \hat{g}_{\mu \nu }=\sqrt{\frac{|\nu +8\pi \phi ^{2}|}{|\nu +8\pi \chi ^{2}|}}\,\,g_{\mu \nu }. \end{aligned}$$
(4.19)

From (4.15), (4.19) we see that in the Brans–Dicke limit \(\nu =0\), we get \(\chi \propto \phi ^{-1}\), \(\hat{g}_{\mu \nu }\propto \phi ^{2}g_{\mu \nu }\), which leads to a symmetry transformation of the Brans–Dicke action (2.9) [26].

5 The Lagrangian of generalized vacuum Brans–Dicke theories

Setting \({\mathcal {T}}^{\mu }_{\,\,\,\,\nu }=0\) in the system (2.1)–(2.4) an extended vacuum Brans–Dicke theory arises, which for \(\nu =0\) reduces to the vacuum Brans–Dicke theory. However, it was shown in [28] that this theory is not the most general vacuum theory respecting the wave equation \(\Box \phi =0\) and the standard assumption for \(T^{\mu }_{\,\,\,\nu }\) being a sum of terms with two derivatives. The most general such theory is

$$\begin{aligned}&G^{\mu }_{\,\,\,\nu }=\frac{8\pi }{\phi }T^{\mu }_{\,\,\,\nu }, \end{aligned}$$
(5.1)
$$\begin{aligned}&T^{\mu }_{\,\,\,\nu }=A(\phi )\phi ^{;\mu }\phi _{;\nu } +B(\phi )\delta ^{\mu }_{\,\,\,\nu }\phi ^{;\rho }\phi _{;\rho } +C(\phi )\phi ^{;\mu }_{\,\,\,\,;\nu }, \end{aligned}$$
(5.2)
$$\begin{aligned}&\Box \phi =0, \end{aligned}$$
(5.3)

where the coefficients ABC satisfy the differential equations

$$\begin{aligned}&A'+B'+\frac{4\pi }{\phi }C(A-2B)-\frac{1}{\phi }(A+B)=0, \end{aligned}$$
(5.4)
$$\begin{aligned}&C'+\frac{8\pi }{\phi }C^{2}-\frac{1}{\phi }C+A+2B=0. \end{aligned}$$
(5.5)

The energy-momentum tensor \(T^{\mu }_{\,\,\,\nu }\) of Eq. (2.2) is easily seen to satisfy the system (5.4), (5.5) and it defines probably the most interesting vacuum theory. However, the solution of Eqs. (5.4), (5.5) in principle contains one arbitrary function of \(\phi \). Here, we will show that the general vacuum theory defined by the system (5.4), (5.5) arises from an action and we will find such an action in general. This contains an arbitrary function and provides the field equations (5.1)–(5.3).

We start with the Horndeski theory which consists of the most general Lagrangian [33], providing second order field equations for both the metric and the scalar field. This theory was recently rediscovered independently [34, 35] and cast in a simpler form, having the following structure:

$$\begin{aligned} S=\int \mathrm{d}^{4}x\,\sqrt{-g}\,\big (\mathcal {L}_{2}+\mathcal {L}_{3}+\mathcal {L}_{4}+\mathcal {L}_{5} \big ), \end{aligned}$$
(5.6)

where

$$\begin{aligned} \mathcal {L}_{2}= & {} G_{2},\end{aligned}$$
(5.7)
$$\begin{aligned} \mathcal {L}_{3}= & {} -G_{3}\square \phi ,\end{aligned}$$
(5.8)
$$\begin{aligned} \mathcal {L}_{4}= & {} G_{4}R+G_{4X} \left[ (\square \phi )^{2}-\phi _{;\mu ;\nu }\phi ^{;\mu ;\nu } \right] ,\end{aligned}$$
(5.9)
$$\begin{aligned} \mathcal {L}_{5}= & {} G_{5}G_{\mu \nu }\phi ^{;\mu ;\nu }-\frac{1}{6}G_{5X} \left[ (\square \phi )^{3}+2\phi _{;\mu ;\nu }\phi ^{;\kappa ;\mu } \phi _{;\kappa }^{\,\,\,\,\,;\nu }\right. \nonumber \\&\left. -\,3\phi _{;\mu ;\nu }\phi ^{;\mu ;\nu }\square \phi \right] . \end{aligned}$$
(5.10)

The functions \(G_{i}\) (\(i=2,3,4,5\)) depend on the scalar field \(\phi \) and its kinetic energy \(X=-\frac{1}{2}\phi ^{;\mu }\phi _{;\mu }\), i.e. \(G_{i}=G_{i}(\phi ,X)\). The field equations for the metric and the scalar field stemming from the variation of (5.6) are, respectively, the following [36]:

$$\begin{aligned}&\mathcal{E}_{\mu \nu }=-\frac{1}{2}G_2 g_{\mu \nu }+G_{2X}X_{\mu \nu }\nonumber \\&\qquad \;\;-\left[ G_{3X}X_{\mu \nu }\square \phi + \frac{1}{2}g_{\mu \nu }G_{3\kappa }\phi ^{\kappa }-G_{3(\mu }\phi _{\nu )}\right] \nonumber \\&\qquad \;\;+\,G_4 G_{\mu \nu }+RG_{4X}X_{\mu \nu }+G_{4\kappa }{^{\kappa }}g_{\mu \nu }-G_{4\mu \nu }\nonumber \\&\qquad \;\;+ \left( G_{4XX}X_{\mu \nu }-\frac{1}{2}G_{4X}g_{\mu \nu }\right) \nonumber [(\square \phi )^2-\phi _{\mu \nu }^2]\nonumber \\&\qquad \;\;+\,2G_{4X}\phi _{\mu \nu }\square \phi -2[G_{4X}\phi _{;(\mu }\square \phi ]_{;\nu )}+(G_{4X}\phi ^{\kappa } \square \phi )_{;\kappa }g_{\mu \nu }\nonumber \\&\qquad \;\;+\,2[G_{4X}\phi _{(\mu }\phi ^{\kappa }{_{\nu )}}]_{;\kappa } -(G_{4X}\phi ^{\kappa }\phi _{\mu \nu })_{;\kappa } -2G_{4X}\phi _{\nu \kappa }\phi ^{\kappa }{_{\mu }}\nonumber \\&\qquad \;\;+\,{G}_{\kappa \lambda }\phi ^{\kappa \lambda } \left( G_{5X}X_{\mu \nu }-\frac{1}{2}G_5g_{\mu \nu }\right) +2G_5\phi ^{\kappa }{_{(\nu }}{G}_{\mu )\kappa }\nonumber \\&\qquad \;\;-\,[G_{5}\phi _{(\mu }{G}_{\nu )\kappa }]^{;\kappa }+ \frac{1}{2}(G_{5}\phi _{\kappa }{G}_{\mu \nu })^{;\kappa } +\frac{1}{2}\{RG_5\phi _{\mu \nu }\nonumber \\&\qquad \;\;-\,G_5\phi {_{\kappa }}^{\kappa }R_{\mu \nu } +\square (G_5\phi _{\mu \nu })+(G_5\phi {_{\kappa }}^{\kappa })_{;\nu ;\mu }\nonumber \\&\qquad \;\;-\,2[G_5\phi {_{(\mu }}^{\kappa }]_{;\nu );\kappa }+ [(G_5\phi ^{\kappa \lambda })_{;\lambda ;\kappa } -\square (G_5\phi {_{\kappa }}^{\kappa })]g_{\mu \nu }\}\nonumber \\&\qquad \;\;-\,\frac{1}{6}\left( G_{5XX}X_{\mu \nu }-\frac{1}{2}G_{5X}g_{\mu \nu }\right) [(\square \phi )^3+2\phi _{\kappa \lambda }^3-3\phi _{\kappa \lambda }^2\square \phi ]\nonumber \\&\qquad \;\;-\,\frac{1}{2}\left\{ G_{5X}(\square \phi )^2\phi _{\mu \nu } -2[G_{5X}(\square \phi )^2\phi _{(\mu }]_{;\nu )}\phantom {\frac{1}{2}}\right. \nonumber \\&\qquad \;\;\left. +\,\frac{1}{2}[G_{5X}(\square \phi )^2\phi _{\kappa }]^{;\kappa }g_{\mu \nu }\right\} \nonumber \\&\qquad \;\;-\,\left\{ G_{5X}\phi _{\kappa \mu }\phi _{\nu \lambda }\phi ^{\lambda \kappa } -[G_{5X}\phi _{(\mu }\phi ^{\lambda }{_{\nu )}}\phi _{\lambda \kappa }]^{;\kappa }\phantom {\frac{1}{2}}\right. \nonumber \\&\qquad \;\;\left. +\,\frac{1}{2}(G_{5X}\phi _{\kappa }\phi _{\lambda \mu } \phi ^{\lambda }{_{\nu }})^{;\kappa }\right\} \nonumber \\&\qquad \;\;+\,\frac{1}{2}\left\{ G_{5X}(\phi _{\kappa \lambda }^2\phi _{\mu \nu }+2\phi _{\mu \kappa } \phi ^{\kappa }{_{\nu }}\square \phi ) -[G_{5X}\phi _{\kappa \lambda }\phi ^{\kappa \lambda }\phi _{(\mu }]_{;\nu )}\phantom {\frac{1}{2}}\right. \nonumber \\&\qquad \;\;+\,\frac{1}{2}(G_{5X}\phi _{\kappa }\phi _{\lambda \rho } \phi ^{\lambda \rho })^{;\kappa }g_{\mu \nu }\nonumber \\&\qquad \;\;\left. -\,2[G_{5X}\phi _{(\mu }\phi _{\nu )\kappa }\square \phi ]^{;\kappa }+ (G_{5X}\phi _{\kappa }\phi _{\mu \nu }\square \phi )^{;\kappa }\right\} =0,\nonumber \\ \end{aligned}$$
(5.11)
$$\begin{aligned}&\mathcal{E}_{\phi }=G_{2\phi }+(G_{2X}\phi ^{\mu })_{;\mu } -\big [G{_{3\mu }}^{\mu }+(G_{3X}\phi ^{\mu }\square \phi )_{;\mu }\nonumber \\&\qquad +\,G_{3\phi }\square \phi \big ]+RG_{4\phi }+G_{4X\phi }[(\square \phi )^2-\phi _{\mu \nu }^2]\nonumber \\&\qquad +\,\{ G_{4XX}\phi _{\kappa }[(\square \phi )^2 -\phi _{\mu \nu }^2]\}^{;\kappa }\nonumber \\&\qquad +\,(RG_{4X}\phi _{\mu })^{;\mu } +2\square (G_{4X}\square \phi )-2(G_{4X}\phi _{\mu \nu })^{;\nu ;\mu }\nonumber \\&\qquad +\,G_{5\phi }{G}_{\mu \nu }\phi ^{\mu \nu } +G_{5}^{\mu \nu }{G}_{\mu \nu }-\frac{1}{6}G_{5X\phi }[(\square \phi )^3\nonumber \\&\qquad +\,2\phi _{\mu \nu }^3 -3\phi _{\mu \nu }^2\square \phi ]+(G_{5X}G^{\mu \nu }\phi _{\mu \nu }\phi _{\kappa })^{;\kappa }\nonumber \\&\qquad -\,\frac{1}{2}\square [G_{5X}(\square \phi )^2]\nonumber \\&\qquad -\,\frac{1}{6}\{G_{5XX}\phi _{\kappa }[(\square \phi )^3 +2\phi _{\mu \nu }^3-3\phi _{\mu \nu }^2\square \phi ]\}^{;\kappa }\nonumber \\&\qquad -\,(G_{5X}\phi ^{\kappa }{_{\mu }}\phi _{\kappa \nu })^{;\nu ;\mu } +\frac{1}{2}\square (G_{5X}\phi _{\mu \nu }^2)\nonumber \\&\qquad +\,(G_{5X}\phi _{\mu \nu }\square \phi )^{;\nu ;\mu }=0. \end{aligned}$$
(5.12)

A subscript \(\phi \) or X denotes a partial differentiation with respect to \(\phi \) or X, while \(X_{\mu \nu }=\frac{\partial X}{\partial g^{\mu \nu }}=-\frac{1}{2}\phi _{,\mu }\phi _{,\nu }\). Parentheses around a couple of indices mean symmetrization with the factor 1/2 included. Also, we denote \(f_{\mu \dots \nu }=f_{;\nu \dots \,;\mu }\) for a function f, while \(\phi _{\mu \nu }^2=\phi _{\mu \nu }\phi ^{\mu \nu }\) and \(\phi _{\mu \nu }^3=\phi _{\mu \nu }\phi ^{\nu \kappa }\phi ^{\mu }{_{\kappa }}\). Despite the fact of the appearance of higher derivatives in (5.11), (5.12), the field equations can be reduced to second order using appropriate identities.

Equations (5.11), (5.12) should coincide with equations (5.1), (5.3). All terms in (5.11), (5.12) multiplied by a X derivative of \(G_{5}\) contain more than two derivatives on \(\phi \). However, combining suitable such terms and using the formula connecting two successive derivatives with the Riemann tensor, terms with lower number of derivatives arise, which are multiplied by the Riemann tensor. Since there are no such structures in (5.1)–(5.3), all these terms should vanish. This requires that \(G_{5X}=0\), i.e. \(G_{5}=G_{5}(\phi )\). Similarly, various terms in (5.11), (5.12) multiplied by a X derivative of \(G_{4}\) contain more than two derivatives on \(\phi \) and therefore \(G_{4X}=0\), i.e. \(G_{4}=G_{4}(\phi )\). The existence of quantities of the form \(G_{3\mu }\phi _{\nu }\) in (5.11) makes it necessary that \(G_{3X}=0\), i.e. \(G_{3}=G_{3}(\phi )\). Finally, the existence of the term \((G_{2X}\phi ^{\mu })_{;\mu }\) in (5.12) leads to \(G_{2XX}=0\), i.e. \(G_{2X}=G_{2X}(\phi )\), which means \(G_{2}=\gamma _{2}(\phi )+g_{2}(\phi )X\). Thus, Eqs. (5.11) and (5.12) take the form

$$\begin{aligned} \mathcal{E}_{\mu \nu }= & {} -\frac{1}{2}G_2 g_{\mu \nu }+G_{2X}X_{\mu \nu } +G_{3(\mu }\phi _{\nu )}-\frac{1}{2}g_{\mu \nu }G_{3\kappa }\phi ^{\kappa }\nonumber \\&+\,G_4 G_{\mu \nu }+G_{4\kappa }{^{\kappa }}g_{\mu \nu }-G_{4\mu \nu }\nonumber \\&-\,\frac{1}{2}G_5{G}_{\kappa \lambda }\phi ^{\kappa \lambda } g_{\mu \nu }+2G_5\phi ^{\kappa }{_{(\nu }}{G}_{\mu )\kappa }- [G_{5}\phi _{(\mu }{G}_{\nu )\kappa }]^{;\kappa }\nonumber \\&+\,\frac{1}{2}(G_{5}\phi _{\kappa }{G}_{\mu \nu })^{;\kappa } +\frac{1}{2}\{RG_5\phi _{\mu \nu } -G_5\phi {_{\kappa }}^{\kappa }R_{\mu \nu }\nonumber \\&+\,\square (G_5\phi _{\mu \nu }) +(G_5\phi {_{\kappa }}^{\kappa })_{;\nu ;\mu } -2[G_5\phi {_{(\mu }}^{\kappa }]_{;\nu );\kappa }\nonumber \\&+\,[(G_5\phi ^{\kappa \lambda })_{;\lambda ;\kappa } -\square (G_5\phi {_{\kappa }}^{\kappa })]g_{\mu \nu }\}=0, \end{aligned}$$
(5.13)
$$\begin{aligned} \mathcal{E}_{\phi }= & {} G_{2\phi }+(G_{2X}\phi ^{\mu })_{;\mu } -G{_{3\mu }}^{\mu }-G_{3\phi }\Box \phi \nonumber \\&+\,RG_{4\phi }+G_{5\phi }{G}_{\mu \nu }\phi ^{\mu \nu }+G_{5}^{\mu \nu }{G}_{\mu \nu }=0. \end{aligned}$$
(5.14)

Now, again there are terms in (5.13) multiplied by \(G_{5}\) which contain more than two derivatives on \(\phi \), thus \(G_{5}=0\). Equations (5.13), (5.14) become

$$\begin{aligned} \mathcal{E}_{\mu \nu }= & {} -\frac{1}{2}G_2 g_{\mu \nu }+G_{2X}X_{\mu \nu } +G_{3(\mu }\phi _{\nu )}\nonumber \\&-\,\frac{1}{2}g_{\mu \nu }G_{3\kappa }\phi ^{\kappa } +G_4 G_{\mu \nu }+G_{4\kappa }{^{\kappa }}g_{\mu \nu }-G_{4\mu \nu }=0,\nonumber \\ \end{aligned}$$
(5.15)
$$\begin{aligned} \mathcal{E}_{\phi }= & {} G_{2\phi }+(G_{2X}\phi ^{\mu })_{;\mu } -G{_{3\mu }}^{\mu }-G_{3\phi }\Box \phi +RG_{4\phi }=0.\nonumber \\ \end{aligned}$$
(5.16)

Equations (5.15), (5.16) are reexpressed as

$$\begin{aligned} {\mathcal {E}}_{\mu \nu }= & {} G_{4}G_{\mu \nu }+(G_{2X}-2G_{3\phi }+2G_{4\phi \phi })X_{\mu \nu }\nonumber \\&-\left( \frac{1}{2}G_{2}-G_{3\phi }X+2G_{4\phi \phi }X-G_{4\phi } \Box \phi \right) g_{\mu \nu }\nonumber \\&-\,G_{4\phi }\phi _{\mu \nu }=0,\end{aligned}$$
(5.17)
$$\begin{aligned} {\mathcal {E}}_{\phi }= & {} G_{2\phi }+RG_{4\phi }+2(G_{3\phi \phi } -G_{2X\phi })X\nonumber \\&+\,(G_{2X}-2G_{3\phi })\Box \phi =0. \end{aligned}$$
(5.18)

Taking the trace of Eq. (5.17) we obtain the Ricci scalar as

$$\begin{aligned} G_{4}R=(2G_{3\phi }-6G_{4\phi \phi }-g_{2})X+3G_{4\phi }\Box {\phi }-2\gamma _{2}. \end{aligned}$$
(5.19)

Substituting this R into (5.18) we get

$$\begin{aligned}&G_{4}\gamma _{2\phi }-2\gamma _{2}G_{4\phi }+[2G_{4\phi }G_{3\phi }-6G_{4\phi }G_{4\phi \phi }-(g_{2} G_{4})_{\phi }\nonumber \\&\quad +\,2G_{4}G_{3\phi \phi }]X+(g_{2}G_{4}-2G_{4}G_{3\phi }+3G_{4\phi }^{2})\Box \phi =0.\nonumber \\ \end{aligned}$$
(5.20)

In order for (5.20) to coincide with the wave equation \(\Box \phi =0\) of (5.3) we should have equivalently

$$\begin{aligned}&G_{4}\gamma _{2\phi }-2\gamma _{2}G_{4\phi }=0\end{aligned}$$
(5.21)
$$\begin{aligned}&2G_{4\phi }G_{3\phi }-6G_{4\phi }G_{4\phi \phi }-(g_{2}G_{4})_{\phi } +2G_{4}G_{3\phi \phi }=0,\nonumber \\ \end{aligned}$$
(5.22)
$$\begin{aligned}&g_{2}G_{4}-2G_{4}G_{3\phi }+3G_{4\phi }^{2}\ne 0. \end{aligned}$$
(5.23)

Equation (5.21) is immediately integrated to

$$\begin{aligned} \gamma _{2}=\gamma _{2o}G_{4}^{2}, \end{aligned}$$
(5.24)

with \(\gamma _{2o}\) an integration constant. Then Eq. (5.17) becomes

$$\begin{aligned}&G_{4}G_{\mu \nu }+(g_{2}-2G_{3\phi }+2G_{4\phi \phi })X_{\mu \nu }\nonumber \\&\quad -\left( \frac{1}{2}g_{2} -G_{3\phi }+2G_{4\phi \phi }\right) Xg_{\mu \nu } -G_{4\phi }\phi _{\mu \nu }\nonumber \\&\quad -\,\frac{1}{2}\gamma _{2}g_{\mu \nu }=0. \end{aligned}$$
(5.25)

The gravitational equation (5.1) is written as

$$\begin{aligned} G_{\mu \nu }+\frac{8\pi }{\phi }(2AX_{\mu \nu }+2BXg_{\mu \nu }-C\phi _{\mu \nu })=0, \end{aligned}$$
(5.26)

where ABC satisfy (5.4), (5.5). In order for (5.25) to coincide with (5.26) we should have

$$\begin{aligned}&g_{2}-2G_{3\phi }+2G_{4\phi \phi }=\frac{16\pi }{\phi }AG_{4}\end{aligned}$$
(5.27)
$$\begin{aligned}&\frac{1}{2}g_{2}-G_{3\phi }+2G_{4\phi \phi }=-\frac{16\pi }{\phi }BG_{4}\end{aligned}$$
(5.28)
$$\begin{aligned}&G_{4\phi }=\frac{8\pi }{\phi }CG_{4},\end{aligned}$$
(5.29)
$$\begin{aligned}&\gamma _{2}=0. \end{aligned}$$
(5.30)

The action (5.6) that has resulted up to now is

$$\begin{aligned} S=\int \mathrm{d}^{4}x\,\sqrt{-g}\,[g_{2}(\phi )X-G_{3}(\phi )\Box \phi +G_{4}(\phi )R], \end{aligned}$$
(5.31)

where the coefficients \(g_{2},G_{3},G_{4}\) obey the system (5.22), (5.23), (5.27)–(5.29). Since the term \(G_{3}\Box \phi \) can be converted through an integration by parts to the term \(2G_{3\phi }X\), the action (5.31) reduces to the simpler form

$$\begin{aligned} S=\frac{1}{16\pi }\int \mathrm{d}^{4}x\,\sqrt{-g}\,[\textsf {f}(\phi )R-\textsf {h} (\phi )\phi ^{;\mu }\phi _{;\mu }], \end{aligned}$$
(5.32)

where \(\textsf {f}=16\pi G_{4}\), \(\textsf {h}=8\pi (g_{2}-2G_{3\phi })\). Since the system of equations for \(g_{2},G_{3},G_{4}\) is pretty complicated, we will find equivalently from the action (5.32) the system of equations that the coefficients \(\textsf {f},\textsf {h}\) should satisfy. From Eqs. (3.3), (3.13) we obtain

$$\begin{aligned}&G^{\mu }_{\,\,\,\nu }-\frac{1}{\textsf {f}}(\textsf {f}\,'' +\textsf {h})\phi ^{;\mu }\phi _{;\nu } +\frac{1}{\textsf {f}}\left( \textsf {f}\,''+\frac{1}{2}\textsf {h}\right) \delta ^{\mu }_{\,\,\,\nu }\phi ^{;\rho }\phi _{;\rho }\nonumber \\&\quad -\,\frac{\textsf {f}\,'}{\textsf {f}}\left( \phi ^{;\mu }_{\,\,\,\,;\nu } -\delta ^{\mu }_{\,\,\,\nu }\Box \phi \right) =0,\end{aligned}$$
(5.33)
$$\begin{aligned}&\left( 3\frac{\textsf {f}\,'^{2}}{\textsf {f}}+2\textsf {h}\right) \Box \phi +\left[ \textsf {f}\,'\left( 3\frac{\textsf {f}\,''}{\textsf {f}} +\frac{\textsf {h}}{\textsf {f}}\right) +\textsf {h}\,'\right] \phi ^{;\mu }\phi _{;\mu }=0.\nonumber \\ \end{aligned}$$
(5.34)

For Eq. (5.34) to coincide with (5.3) one should have

$$\begin{aligned}&\textsf {f}\,'\left( 3\frac{\textsf {f}\,''}{\textsf {f}}+ \frac{\textsf {h}}{\textsf {f}}\right) +\textsf {h}\,'=0\end{aligned}$$
(5.35)
$$\begin{aligned}&3\frac{\textsf {f}\,'^{2}}{\textsf {f}}+2\textsf {h}\ne 0. \end{aligned}$$
(5.36)

Then for Eq. (5.33) to coincide with (5.1),

$$\begin{aligned}&\frac{1}{\textsf {f}}(\textsf {f}\,''+\textsf {h})=\frac{8\pi }{\phi }A,\end{aligned}$$
(5.37)
$$\begin{aligned}&\frac{1}{\textsf {f}}\left( \textsf {f}\,''+\frac{1}{2}\textsf {h}\right) =-\frac{8\pi }{\phi }B,\end{aligned}$$
(5.38)
$$\begin{aligned}&\frac{\textsf {f}\,'}{\textsf {f}}=\frac{8\pi }{\phi }C. \end{aligned}$$
(5.39)

Substituting ABC from (5.37)–(5.39) into (5.4), (5.5), and using (5.35), we see that (5.4), (5.5) are identically satisfied. So, the action (5.32) is valid for the system (5.1)–(5.3) and we are left with Eqs. (5.35) and (5.36). The solution of (5.35) is

$$\begin{aligned} \textsf {h}(\phi )=\frac{\textsf {s}-3\textsf {f}\,'^{2}(\phi )}{2\textsf {f}(\phi )}, \end{aligned}$$
(5.40)

where \(\textsf {s}\) is integration constant. Equation (5.36) is satisfied for \(s\ne 0\). Finally, the action of the system (5.1)–(5.3) takes the form

$$\begin{aligned} S=\frac{1}{16\pi }\int \mathrm{d}^{4}x\,\sqrt{-g}\,\left[ \textsf {f}(\phi )R- \frac{\textsf {s}-3\textsf {f}\,'^{2}(\phi )}{2\textsf {f}(\phi )} g^{\mu \nu }\phi _{,\mu }\phi _{,\nu }\right] .\nonumber \\ \end{aligned}$$
(5.41)

The action (5.41), as well as the coefficients ABC of (5.37)–(5.39), has been expressed in terms of one arbitrary function \(\textsf {f}(\phi )\). The action (3.15) is included in (5.41) if we choose \(\textsf {s}=\frac{2\epsilon }{\lambda }\).

6 A total Lagrangian

Now we consider the total action \(S=S_{g}+S_{m}\) including the matter action

$$\begin{aligned} S_{m}=\int \mathrm{d}^{4}x\,\sqrt{-g}\,J(\phi )L_{m}, \end{aligned}$$
(6.1)

where \(L_{m}(g_{\kappa \lambda },\Psi )\) is the matter Lagrangian. The symbol \(\Psi \) denotes a collection of extra matter fields and \(J(\phi )\) is a function to be determined. The variation of \(S_{m}\) with respect to the metric gives

$$\begin{aligned} \delta _{g}S_{m}=\frac{1}{2}\int \mathrm{d}^{4}x\,\sqrt{-g}\,J(\phi ){\mathcal {T}}^{\mu \nu } \delta g_{\mu \nu }, \end{aligned}$$
(6.2)

where the matter energy-momentum tensor is defined as

$$\begin{aligned} {\mathcal {T}}^{\mu \nu }=\frac{2}{\sqrt{-g}}\frac{\delta (\sqrt{-g}\,L_{m})}{\delta g_{\mu \nu }} \end{aligned}$$
(6.3)

in the Jordan frame we are working with, where \(L_{m}\) is multiplied by the non-trivial factor \(J(\phi )\) in (6.1). The way \({\mathcal {T}}^{\mu \nu }\) arises from \(S_{m}\) is such that the gravitational equation (2.1) can be obtained. The variation of the total action is

$$\begin{aligned} \delta _{g}S=-\frac{1}{16\pi }\int \mathrm{d}^{4}x\,\sqrt{-g}\,f \left( {\mathcal {E}}^{\mu \nu }-8\pi \frac{J}{f}{\mathcal {T}}^{\mu \nu }\right) \delta g_{\mu \nu },\nonumber \\ \end{aligned}$$
(6.4)

and therefore the total gravitational equation of motion is

$$\begin{aligned} {\mathcal {E}}^{\mu }_{\,\,\,\nu }-8\pi \frac{J}{f}{\mathcal {T}}^{\mu }_{\,\,\,\,\nu }=0. \end{aligned}$$
(6.5)

In order for (6.5) to coincide with Eq. (2.1), we should have \(J=\frac{f}{\phi }\), thus

$$\begin{aligned} J(\phi )=\frac{1}{\sqrt{8\pi }}\,\frac{\sqrt{|\nu +8\pi \phi ^{2}|}}{|\phi |}. \end{aligned}$$
(6.6)

Note that, for \(\nu =0\), it becomes \(J=1\). Therefore, a candidate total action for the complete Brans–Dicke theory (2.1)–(2.4) is

$$\begin{aligned} S= & {} \frac{\eta }{2(8\pi )^{3/2}}\int \mathrm{d}^{4}x\,\sqrt{-g}\, \left[ \sqrt{|\nu +8\pi \phi ^{2}|}\,R\phantom {\frac{\sqrt{|\nu +8\pi \phi ^{2}|}}{\phi }}\right. \nonumber \\&-\,\frac{8\pi }{\lambda }\,\frac{\nu +4\pi (2-3\lambda ) \phi ^{2}}{|\nu +8\pi \phi ^{2}|^{3/2}}g^{\mu \nu }\phi _{,\mu }\phi _{,\nu }\nonumber \\&\left. +\,16\pi \frac{\sqrt{|\nu +8\pi \phi ^{2}|}}{\phi }L_{m}(g_{\kappa \lambda },\Psi )\right] . \end{aligned}$$
(6.7)

Notice that due to the interaction term in the conservation equation (2.4) with \(\nu \ne 0\), the matter Lagrangian is non-minimally coupled even in the Jordan frame. We have not yet finished deriving Eq. (2.1), since we have not discussed the derivation of Eqs. (2.3) and (2.4). As for (2.4), if (2.3) has been derived, then (2.4) is the consistency condition in order for the Bianchi identities to be satisfied which have indeed been verified in [28]. Thus, it remains to see if Eq. (2.3) is obtained under variation of (6.7) with respect to \(\phi \). It is evident that a variation of \(S_{m}\) with respect to \(\phi \) will produce a factor \(L_{m}\) which cannot be canceled by any other equation. More precisely, extending Eq. (3.11), we obtain

$$\begin{aligned} \delta _{\phi }S= & {} \frac{1}{16\pi }\int \mathrm{d}^{4}x\,\sqrt{-g}\,\nonumber \\&\times (f'R+h'\phi ^{;\mu }\phi _{;\mu } +2h\Box \phi +16\pi J' L_{m})\delta \phi . \end{aligned}$$
(6.8)

The scalar field equation is thus

$$\begin{aligned} f'R+h'\phi ^{;\mu }\phi _{;\mu }+2h\Box \phi +16\pi J' L_{m}=0. \end{aligned}$$
(6.9)

The trace of Eq. (6.5) gives

$$\begin{aligned} R=\frac{1}{f}(3f''+h)\phi ^{;\mu }\phi _{;\mu }+3\frac{f'}{f}\Box \phi -8\pi \frac{J}{f}{\mathcal {T}}. \end{aligned}$$
(6.10)

From (6.9), (6.10) we obtain

$$\begin{aligned}&\left( 3\frac{f'^{2}}{f}+2h\right) \Box \phi + \left[ f'\left( 3\frac{f''}{f}+\frac{h}{f}\right) +h'\right] \phi ^{;\mu }\phi _{;\mu }\nonumber \\&\quad -\,8\pi \frac{f'}{f}J{\mathcal {T}}+16\pi J' L_{m}=0. \end{aligned}$$
(6.11)

Simplifying this equation, we finally get

$$\begin{aligned} \Box \phi =4\pi \lambda {\mathcal {T}}+\frac{\lambda \nu }{\phi ^{2}}L_{m}. \end{aligned}$$
(6.12)

Therefore, the field equation (2.3) is obtained only if on-shell the numerical value of the matter Lagrangian \(L_{m}\) is zero. For example, for a relativistic perfect fluid, an action functional has been constructed [37] where the matter Lagrangian is proportional to the pressure. Moreover, in [38] the on-shell Lagrangian, i.e. the value of the Lagrangian when the equations of motion hold, is again the pressure, thus for pressureless dust this on-shell value vanishes. Of course, an energy-momentum tensor is normally defined and enters the field equations, because this is computed off-shell.

The result of this section is that, in the case of matter, we have found an action functional of the form (6.7) for the complete Brans–Dicke theory only for particular matter Lagrangians, those which vanish on-shell. This is still meaningful, although of restricted applicability. This result, however, does not mean that we have shown that an action principle does not exist for arbitrary matter Lagrangians. It is an option that actions of a different, more complicated form than (6.7) could in principle exist and provide the full set of field equations with any matter content.

A notice of caution should be added at this point. It is true that if Eq. (2.4) had been derived, then Eq. (2.3) would arise from the satisfaction of the Bianchi identities. Note first that the conservation equation (2.4) is also written as

$$\begin{aligned} \left( \frac{\sqrt{|\nu +8\pi \phi ^{2}|}}{\phi } {\mathcal {T}}^{\mu }_{\,\,\,\,\nu }\right) _{;\mu }=0. \end{aligned}$$
(6.13)

Comparing this equation with the last term in the action (6.7), the one containing \(L_{m}\), one could be tempted to apply the standard diffeomorphism invariance argument for this part of the action and obtain immediately Eq. (6.13). However, this is not correct because of the non-minimal coupling of \(L_{m}\) with \(\phi \).

The action (6.7), whenever applied, can be cast into a canonical form where the Einstein–Hilbert term is only minimally coupled. Of course, the following transformations are also valid in the vacuum case. We perform a new conformal transformation:

$$\begin{aligned} \tilde{g}_{\mu \nu }=\tilde{\Omega }^{2}(\phi )g_{\mu \nu },\quad \tilde{\Omega }=\left( \frac{|\nu +8\pi \phi ^{2}|}{8\pi }\right) ^{\frac{1}{4}}. \end{aligned}$$
(6.14)

If \(\tilde{R}\), \(\tilde{\Box }\) correspond to \(\tilde{g}_{\mu \nu }\) and \(\tilde{\omega }=\tilde{\Omega }^{-1}\), the total action S defined from (3.1), (6.1), using (4.7), takes the form

$$\begin{aligned} S= & {} \frac{1}{16\pi }\int \mathrm{d}^{4}x\,\sqrt{-\tilde{g}}\,f\tilde{\omega }^{2}\nonumber \\&\times \left\{ \tilde{R}+\left[ 6\frac{\tilde{\omega }'}{\tilde{\omega }} \,\frac{(f\tilde{\omega }^{2})'}{f\tilde{\omega }^{2}} -6\frac{\tilde{\omega }'^{2}}{\tilde{\omega }^{2}}-\frac{h}{f}\right] \tilde{g}^{\mu \nu }\phi _{,\mu }\phi _{,\nu }\right\} \nonumber \\&+\,\int \mathrm{d}^{4}x\,\sqrt{-\tilde{g}} \,\frac{f\tilde{\omega }^{4}}{\phi }\,L_{m}(\tilde{\omega }^{2} \tilde{g}_{\kappa \lambda },\Psi ). \end{aligned}$$
(6.15)

Using that \(f\tilde{\omega }^{2}=\eta \), \(\frac{\tilde{\omega }'}{\tilde{\omega }}=\frac{1}{4} \frac{(\tilde{\omega }^{4})'}{\tilde{\omega }^{4}}=-\frac{4\pi \phi }{\nu +8\pi \phi ^{2}}\), we find an action with the Einstein–Hilbert term without non-minimal coupling, but with a non-standard kinetic term

$$\begin{aligned} S= & {} \frac{\eta }{16\pi }\int \mathrm{d}^{4}x\,\sqrt{-\tilde{g}}\, \left[ \tilde{R}-\frac{8\pi }{\lambda (\nu +8\pi \phi ^{2})}\tilde{g}^{\mu \nu }\phi _{,\mu }\phi _{,\nu }\phantom {\frac{2(8\pi )^{\frac{3}{2}}}{\phi \sqrt{|\nu +8\pi \phi ^{2}|}}}\right. \nonumber \\&\left. +\,\frac{2(8\pi )^{\frac{3}{2}}}{\phi \sqrt{|\nu +8\pi \phi ^{2}|}}L_{m}(\tilde{\omega }^{2} \tilde{g}_{\kappa \lambda },\Psi )\right] . \end{aligned}$$
(6.16)

In order to make this kinetic term canonical, we introduce a new scalar field \(\sigma (x)\), instead of \(\phi (x)\), by

$$\begin{aligned} \frac{\mathrm{d}\phi }{\mathrm{d}\sigma }=\sqrt{\frac{|\lambda |}{16\pi }}\,\sqrt{|\nu +8\pi \phi ^{2}|}. \end{aligned}$$
(6.17)

The kinetic term in (6.16) inside the brackets is reexpressed as \(-\frac{1}{2}\epsilon \epsilon _{\lambda }\tilde{g}^{\mu \nu }\sigma _{,\mu }\sigma _{,\nu }\), where \(\epsilon _{\lambda }\) is the sign of \(\lambda \). This is a canonical kinetic term, so the field \(\sigma \) behaves as a usual scalar field in the new conformal frame. If \(\epsilon \epsilon _{\lambda }>0\), then \(\sigma \) is a normal field with positive energy. This is achieved even if the kinetic term in (6.7) is positive. Although \(\phi \) is “apparently” a ghost in this case, since it has the wrong sign, however, \(\sigma \) is not a ghost. On the opposite side, if \(\epsilon \epsilon _{\lambda }<0\), then \(\sigma \) is a ghost.

For \(\epsilon >0\), Eq. (6.17) is integrated to

$$\begin{aligned} \sigma -\sigma _{0}= \sqrt{\frac{2}{|\lambda |}}\,\ln {\Big |4\pi \phi +\sqrt{2\pi } \sqrt{\nu +8\pi \phi ^{2}}\Big |}, \end{aligned}$$
(6.18)

where \(\sigma _{0}\) is integration constant. Redefining \(\sigma _{0}\), we can rewrite (6.18) in the form

$$\begin{aligned} \sigma =\sqrt{\frac{2}{|\lambda |}}\,\ln {\Bigg | \frac{4\pi \phi +\sqrt{2\pi }\sqrt{\nu +8\pi \phi ^{2}}}{4\pi \phi _{0}+\sqrt{2\pi }\sqrt{\nu +8\pi \phi _{0}^{2}}}\Bigg |}, \end{aligned}$$
(6.19)

where \(\phi _{0}\) is integration constant. In the case that the scalar field \(\phi \) is constant with value \(\phi =\phi _{0}\), it will be \(\sigma =0\). In this case there is no need for a conformal transformation and we may then set \(\tilde{\Omega }=1\). Thus, \(\phi _{0}^{2}=1-\frac{\nu }{8\pi }\) and the integration constant \(\phi _{0}\) has been determined (for \(\nu >0\) we should have \(\nu <8\pi \)). We redefine \(\sigma \) by absorbing the translational integration constant \(\sigma _{0}\) of (6.18) into \(\sigma \). Equation (6.18) can be inverted giving

$$\begin{aligned} \phi =\frac{s}{8\pi }\left( e^{\sqrt{\frac{|\lambda |}{2}}\,\sigma }-2\pi \nu e^{-\sqrt{\frac{|\lambda |}{2}}\,\sigma }\right) , \end{aligned}$$
(6.20)

where \(s=\text {sgn}(4\pi \phi +\sqrt{2\pi }\sqrt{\nu +8\pi \phi ^{2}})= \text {sgn}(e^{\sqrt{\frac{|\lambda |}{2}}\,\sigma }+2\pi \nu e^{-\sqrt{\frac{|\lambda |}{2}}\,\sigma })\). The action (6.16) becomes

$$\begin{aligned} S= & {} \frac{\eta }{16\pi }\int \mathrm{d}^{4}x\,\sqrt{-\tilde{g}}\,\left[ \tilde{R}- \frac{1}{2}\epsilon _{\lambda }\tilde{g}^{\mu \nu }\sigma _{,\mu } \sigma _{,\nu }\right. \nonumber \\&\left. +\frac{2\eta (8\pi )^{3}}{\big |e^{\sqrt{2|\lambda |}\,\sigma }-4\pi ^{2}\nu ^{2} e^{-\sqrt{2|\lambda |}\,\sigma }\big |}L_{m}(\tilde{\omega }^{2} \tilde{g}_{\kappa \lambda },\Psi )\right] ,\nonumber \\ \end{aligned}$$
(6.21)

where

$$\begin{aligned} \tilde{\omega }^{2}=\frac{8\pi }{\Big |e^{\sqrt{\frac{|\lambda |}{2}}\,\sigma }+2\pi \nu e^{-\sqrt{\frac{|\lambda |}{2}}\,\sigma }\Big |}. \end{aligned}$$
(6.22)

For the physically more interesting case with \(\phi >0\), both absolute values in (6.21), (6.22) disappear. The Lagrangian (6.21) refers to the Einstein frame where the gravitational coupling is a true constant. In order for \(\sigma \) not to be a ghost, we should have \(\lambda >0\). In the Brans–Dicke limit \(\nu =0\) the coupling to \(L_{m}\) is a simple exponential function of \(\sigma \).

For \(\epsilon <0\), Eq. (6.17) is integrated to

$$\begin{aligned} \sigma -\sigma _{0}=\sqrt{\frac{2}{|\lambda |}}\, \arcsin {\left( \sqrt{\frac{8\pi }{|\nu |}}\,\phi \right) }, \end{aligned}$$
(6.23)

where \(\sigma _{0}\) is integration constant. Redefining \(\sigma _{0}\), we can write (6.23) in the form

$$\begin{aligned} \sigma =\sqrt{\frac{2}{|\lambda |}}\, \left[ \arcsin {\left( \sqrt{\frac{8\pi }{|\nu |}}\,\phi \right) } -\arcsin {\left( \sqrt{\frac{8\pi }{|\nu |}}\,\phi _{0}\right) }\right] ,\nonumber \\ \end{aligned}$$
(6.24)

where \(\phi _{0}\) is integration constant. Again, for \(\phi =\phi _{0}\), \(\sigma =0\), and setting \(\tilde{\Omega }=1\) we get the condition \(\phi _{0}^{2}=\frac{|\nu |}{8\pi }-1\) (we should have \(|\nu |>8\pi \)). We redefine \(\sigma \) by absorbing the translational integration constant \(\sigma _{0}\) of (6.23) into \(\sigma \), and then \(-\frac{\pi }{2}<\sqrt{\frac{|\lambda |}{2}}\,\sigma <\frac{\pi }{2}\). Equation (6.23) can be inverted giving

$$\begin{aligned} \phi =\sqrt{\frac{|\nu |}{8\pi }}\,\sin \left( \sqrt{\frac{|\lambda |}{2}}\,\sigma \right) . \end{aligned}$$
(6.25)

The action (6.16) becomes

$$\begin{aligned} S= & {} \frac{\eta }{16\pi }\int \mathrm{d}^{4}x\,\sqrt{-\tilde{g}}\,\left[ \tilde{R}+ \frac{1}{2}\epsilon _{\lambda }\tilde{g}^{\mu \nu }\sigma _{,\mu } \sigma _{,\nu }\phantom {\frac{4(8\pi )^{2}}{|\nu |\,\sin \big (\sqrt{2|\lambda |}\,\sigma \big )}}\right. \nonumber \\&\left. +\,\frac{4(8\pi )^{2}}{|\nu |\,\sin \big (\sqrt{2|\lambda |}\,\sigma \big )} L_{m}(\tilde{\omega }^{2}\tilde{g}_{\kappa \lambda },\Psi )\right] , \end{aligned}$$
(6.26)

where

$$\begin{aligned} \tilde{\omega }^{2}=\frac{\sqrt{8\pi }}{\sqrt{|\nu |}\,\cos \Big (\sqrt{\frac{|\lambda |}{2}}\,\sigma \Big )}. \end{aligned}$$
(6.27)

In order for \(\sigma \) not to be a ghost, we should have \(\lambda <0\).

7 Conclusions

Relieving the standard exact conservation of matter, but still preserving the simple wave equation of motion for the scalar field sourced by the trace of the matter energy-momentum tensor, it was one recently found the most general completion of Brans–Dicke theory. This class of theories contains three interaction terms in the non-conservation equation of matter and is parametrized by arbitrary functions of the scalar field. Keeping a single interaction term each time to express the energy exchange between the scalar field and ordinary matter, three uniquely defined theories arise from consistency, which form the prominent and natural complete Brans–Dicke theories. Here, for the first such theory, its vacuum part, which arises as the zero-matter limit, is studied. The Lagrangian of this vacuum theory is found in the so called Jordan frame, where the scalar field plays the role of the inverse gravitational parameter in the field equations. In this frame, a symmetry transformation of the vacuum action is also found, which consists of a conformal transformation of the metric together with a redefinition of the scalar field. Since the general family of vacuum theories is not exhausted by the above vacuum theory but contains a free function of the scalar field, the action of this family is found which is also parametrized by an arbitrary function and forms a subclass of the Horndeski theories. As for the full theory with matter, we have not been able to answer the question whether the complete Brans–Dicke theory with a general matter energy-momentum tensor arises or not from a Lagrangian. We have answered this question only in the case that the matter Lagrangian vanishes on-shell, as for example happens in the case of pressureless dust. Due to the interaction term in the conservation equation, the matter Lagrangian is non-minimally coupled even in the Jordan frame. In the Einstein frame where the Einstein–Hilbert term is minimally coupled, two forms of this full action have been found, one with a non-canonical kinetic term and one with a canonical kinetic term, with the matter Lagrangian still being non-minimally coupled, while these forms of the actions still make sense in the vacuum limit.