1 Introduction

Despite the successes and probes of General Relativity (GR), it presents issues at IR and UV scales pointing out that it is not the final theory of gravity [1, 2]. Clearly there are problems with quantization of spacetime geometry (the lack of a final Quantum Gravity Theory) and with large scale structure (the unknown dark side to fit astrophysical and cosmological dynamics).

In this context, modified theories of gravity (obtained by extending or changing the Hilbert–Einstein action) could be suitable to fix Dark Energy and Dark Matter issues emerging along the cosmic history. Basically, the philosophy consists in considering extended/modified gravitational Lagrangians where extra-terms in the field equations could play the role of the “Dark” components and explain the expansion of the universe and the large scale structure. Dark Matter and Dark Energy, in fact, represent a controversial problem in cosmology and astrophysics, since they are supposed to cover almost 95% of the universe content but have never been observed at fundamental scales even if they manifest their effects at large scales.

Nevertheless, extending/modifying GR allows to overcome several other issues, see e.g. [3, 4]. In particular, they provide new polarization modes for gravitational waves [5], are capable of describing the fundamental plane of galaxies [6, 7], can fit Dark Energy dynamics [8,9,10,11,12,13], can address astrophysical structures through corrections to the Newtonian potential [14]. From another point of view, modified theories may better adapt to the QFT formalism for several reasons: it is possible to extend the action in order to construct super-renormalizable theories [15] or to build up effective theories towards quantum gravity [16].

Among extended theories of gravity, f(R) gravity is a straightforward extension where the hypothesis of linearity of the Ricci scalar R into the Hilbert–Einstein action is relaxed [17,18,19,20,21,22,23,24].

However also non-minimal couplings as in the Brans-Dicke theory as well as higher-order curvature invariants like \(f(R, \Box R, \Box ^2 R...\Box ^k R)\) or \(f(R, R^{\mu \nu } R_{\mu \nu }, R^{\mu \nu p \sigma } R_{\mu \nu p \sigma })\) can be considered in this program of extending GR [12, 17, 21].

Another point of view approaches gravity as a theory of the translational group where affinities play a major role [25,26,27]. It is the so called Teleparallel Equivalent General Relativity where the antisymmetric part of the connection is taken into account, the so called Weitzenböck connection, constructed on tetrads [28,29,30]. In this picture, spacetime dynamics is given by torsion instead of curvature and the Equivalence Principle is not necessary to fix causal and geodesic structure.

Finally, also non-metricity can be considered in the debate of define the physical variables of gravity and then curvature, torsion and non-metricity or, alternatively, metric, tetrads and non-metricity can give the geometric description of the gravitational field [31].

In this perspective, a peculiar role is played by the topological invariants which intervene in the formulation of any quantum field theory on curved space. Specifically, the so called Gauss–Bonnet (GB) topological invariant has a crucial role in trace anomaly and in the regularization of the theory at least at one-loop level [32]. This invariant can have an important role also in cosmology as pointed out in [33, 34]. It emerges in gravitational actions containing second-order curvature invariants like

$$\begin{aligned} S = \int \sqrt{-g} f(R,R^{\mu \nu } R_{\mu \nu }, R^{\mu \nu p \sigma } R_{\mu \nu p \sigma }) d^4 x\,, \end{aligned}$$
(1)

see for example [36]. Here, the curvature terms can be combined as

$$\begin{aligned} \mathcal {G} = R^2 - 4R_{\mu \nu } R^{\mu \nu } + R_{\mu \nu p \sigma } R^{\mu \nu p \sigma }\,, \end{aligned}$$
(2)

which is the GB invariant acting as a constraint among the second-order curvature terms. According to this consideration, a theory like \(f(R,\mathcal {G})\) can exhaust all the degrees of freedom related to the second-order curvature invariants which is dynamically equivalent to a theory with two scalar fields [37].

However, in (3+1)-dimensions, it is well known that an action like \(S = \int \sqrt{-g} \mathcal {G}\, d^4x\) is trivial, while it is not so in (4+1)-dimensions (or more). This result is directly linked to the GB theorem, which states that the integral of the GB term over the manifold is the Euler characteristic of the manifold, i.e a topological invariant.

Despite of this result, considering any function \(f(\mathcal {G})\ne \mathcal {G}\) can be mathematically and physically relevant, also in 4D, for the following reasons. In general, \(f(R,\mathcal {G})\) gravity is taken into account to recover GR, in a given limit, assuming \(f(R,\mathcal {G})=R+f(\mathcal {G})\). Observational and theoretical constraints have been obtained also for other forms of \(f(R,\mathcal {G})\) [38, 39] but pure \(f(\mathcal {G})\) theories are not, in general, considered because GR seems excluded.

In this paper, we deal with actions depending only on the topological surface term. From a mathematical point of view, the related dynamics is simpler and often analytically solvable.

Besides this technical point, it is worth stressing that, in homogeneous and isotropic cosmology, terms containing squared Ricci and Riemann tensors contribute dynamically as the squared Ricci scalar in the GB invariant. This is particularly evident for the cosmological scale factor evolving as exponential function or power-law functions. According to this observation, as soon as \(f(\mathcal {G}) \sim \mathcal {G}^{\frac{1}{2}}\) holds, a GR-like behavior is expected. This means that, by a theory containing only topological terms, GR can be, in principle, recovered without inserting by hands the Hilbert–Einstein term in the gravitational action. In other words, starting from a theory regular and consistent with quantum considerations [32], one could recover GR results at IR scales avoiding some pathologies.

A detailed treatment of the GB action in spherically symmetric configuration is reported in [40].

As a general remark, considering theories as \(R+f(\mathcal {G})\) and \(f(R)+f(\mathcal {G})\) is particularly useful in high energy regimes of gravity. Specifically, the introduction of \(\mathcal {G}\) leads to improve the inflationary scenario, where two acceleration phases can be led by R and \(\mathcal {G}\) respectively giving rise to a R-dominated phase and a \(\mathcal {G}\)-dominated phase. Being \(\mathcal {G}\) dominant in stronger curvature regimes, its contribution, through a non-linear function \(f(\mathcal {G})\), rules the universe behavior at very early stages extending the Starobinsky model [37]. Both f(R) and \(f(\mathcal {G})\) fields can cooperate to the slow rolling phase with a behavior depending on the strength of the corresponding coupling constant. In general, the contributions of f(R) and \(f(\mathcal {G})\) give rise to a potential, whose minima can be separated by a barrier, representing a double inflationary scenario where the Gauss–Bonnet term dominates at very early epochs and the Ricci scalar at moderate early epochs. Finally, realistic scenarios converge towards standard GR. On the other hand, \(f(\mathcal {G})\) terms contribute to late accelerated expansion as discussed in [33, 34] and theories like \(f(R,\mathcal {G})\) satisfy the Solar System constraints [35].

This work is focused on \(f(\mathcal {G})\) cosmology studied by the Noether Symmetry Approach [41]. The main result is that the existence of symmetries selects models of the form \(f(\mathcal {G})=\mathcal {G}^k\), with k any real number. Then, for \(k=1/2\), GR is recovered as one of the models allowed by symmetries.

As pointed out in [42,43,44], the search for symmetries in modified theories of gravity plays a fundamental role in order to get suitable equations of motion through a selection criterion motivated by physical reasons.

In this framework, as shown in [4, 18, 20, 25, 41, 45], thanks to Lagrange multipliers, one can find the cosmological point-like Lagrangians to develop the Noether approach. Adopting a Friedmann–Robertson–Walker (FRW) metric in 4-dimensions, the Lagrange multiplier for \(f(\mathcal {G})\) results

$$\begin{aligned} \mathcal {G}= 24 \left( \frac{\ddot{a}\dot{a}^2}{a^3}\right) \,. \end{aligned}$$
(3)

It is easy to see that it comes from a 4-divergence

$$\begin{aligned} \sqrt{-g} \, \mathcal {G}= 8 \frac{d}{dt}(\dot{a}^3)\,, \end{aligned}$$
(4)

and hence, when integrated, it gives only a trivial contribution. In other words, when we consider the extension \(f(\mathcal {G})\), a straightforward integration by parts of the Lagrange multiplier allows to write the non-vanishing point-like canonical Lagrangian as a function of the scale factor a, the field \(\mathcal {G}\) and their first derivatives. We have a configuration space \(\mathcal {Q}\equiv \{ a,\mathcal {G}\}\) equipped with tangent space \(T\mathcal {Q}\equiv \{ a,\dot{a},\mathcal {G}, \dot{\mathcal {G}}\}\). This is a 2-dimensional minisuperspace which can be easily quantized in view of quantum cosmology considerations.

The layout of the paper is the following. In Sect. 2), we introduce the main features of the GB gravity and cosmology in n dimensions. Section 3 is devoted to the Noether Symmetry Approach for \(f(\mathcal {G})\) cosmology. In Sect. 4, we find symmetries for GB cosmology, showing that we can recover GR and find exact cosmological solutions. Secs. 5.1 and 5.2 are respectively devoted to the coupling between modified GB action and a scalar field, and models given by a sum of GB functions. Quantum cosmology considerations are developed in Sect. 6, where we find the Wave Function of the Universe for the minisuperspace \(T\mathcal {Q}\equiv \{ a,\dot{a},\mathcal {G}, \dot{\mathcal {G}}\}\). Discussion and conclusions are reported in Sect. 7.

2 Gauss–Bonnet cosmology

Let us now discuss some basic results of GB gravity and cosmology. First of all, we introduce the GB topological invariant \(\mathcal {G}\). In n-dimensions, assuming gravity as a gauge theory of the local Lorentz group on the tangent bundle, the GB term is:

$$\begin{aligned} \mathcal {G}= \epsilon _{a_1,a_2,a_3 \ldots a_n} R^{a_1,a_2} \wedge R^{a_3,a_4} \wedge e^{a_5} \wedge \cdots \wedge e^{a_n}, \end{aligned}$$
(5)

being \(R^{a_i,a_j}\) the two form curvature, \(e^k\) the set of zero forms defining the basis and \(\epsilon _{a_1,a_2,a_3 \ldots a_n}\) the Levi-Civita symbol. This GB term is part of the n-dimensional Lovelock Lagrangian [46, 47] which, in four dimensions, can be expressed as:

$$\begin{aligned} L^{(4)}&=\epsilon _{abcd} \left[ \alpha _2 R^{ab} \wedge R^{cd} + \alpha _1 R^{ab} \wedge e^c \wedge e^d \right. \nonumber \\&\quad + \left. \alpha _0 e^a \wedge e^a \wedge e^b \wedge e^c \wedge e^d\right] , \end{aligned}$$
(6)

where the first term is the GB invariant, the second the Ricci scalar and the third the cosmological constant. Even though the Gauss Bonnet term naturally emerges in the Lovelock gravity under the gauge formalism, we will deal with the covariant representation of \(\mathcal {G}\), which is given by Eq. (2). Here, we consider a general analytic function of \(\mathcal {G}\) and the action

$$\begin{aligned} S = \int \sqrt{-g} f(\mathcal {G}) \; d^nx. \end{aligned}$$
(7)

Varying it with respect to the metric, we find the following field equations

$$\begin{aligned}&2R \nabla _\mu \nabla _\nu f'(\mathcal {G}) - 2g_{\mu \nu } R \Box f'(\mathcal {G}) - 4R^\lambda _\mu \nabla _\lambda \nabla _\nu f'(\mathcal {G}) \nonumber \\ {}&\quad + 4R_{\mu \nu } \Box f'(\mathcal {G}) + 4 g_{\mu \nu } R^{p \sigma } \nabla _p \nabla _\sigma f'(\mathcal {G}) \nonumber \\ {}&\quad + 4 R_{\mu \nu p \sigma } \nabla ^p \nabla ^\sigma f'(\mathcal {G}) + \frac{1}{2} g_{\mu \nu }[f(\mathcal {G}) - \mathcal {G}f'(\mathcal {G})] = T_{\mu \nu }, \end{aligned}$$
(8)

where \(\Box \) is the n-dimensional D’Alembert operator (\(\Box = g_{\mu \nu } \nabla ^\mu \nabla ^\nu \)) and the prime indicates the derivative with respect to \(\mathcal {G}\). \(T_{\mu \nu } \) stands for the energy-momentum tensor of matter and, for simplicity, we used physical units (\(\hbar = c = k_B = 8\pi G = 1\)). In [35, 48,49,50], one can found the generalization of this action to the case \(f(R,\mathcal {G})\) in 4-dimensions.

In order to obtain the form of the GB scalar in cosmology, we have to calculate the n-dimensional Riemann tensor, Ricci tensor and Ricci scalar in FRW metric. We choose for the interval

$$\begin{aligned} ds^2 = dt^2 - a(t)^2 \delta _{ij} dx^i dx^j, \end{aligned}$$
(9)

where the index ij label all the spatial dimensions and run from 1 to n. We assume the spatially flat case. The non-null curvature components are:

$$\begin{aligned}&R = -2(n-1) \frac{\ddot{a}}{a} - (n-2) (n-1) \frac{\dot{a}^2}{a^2}\,, \quad R_{00} = (n-1) \frac{\ddot{a}}{a}\,,\nonumber \\&R_{ij} = \left[ (n-2) \dot{a}^2 + a \ddot{a} \right] \delta _{ij}\,, R_{0i0j} = a \ddot{a} \delta _{ij}\,,\nonumber \\&R_{ijm \ell } =a^2 \dot{a}^2 \delta _{im} \delta _{j \ell }. \end{aligned}$$
(10)

By properly contracting the above quantities, the n-dimensional GB term turns out to be

$$\begin{aligned} \mathcal {G}= & {} \frac{(n-3)(n-2)(n-1) \left[ (n-4) \dot{a}^4 + 4 a \dot{a}^2 \ddot{a}\right] }{a^4} \nonumber \\\equiv & {} p(n) \frac{\left[ (n-4) \dot{a}^4 + 4 a \dot{a}^2 \ddot{a}\right] }{a^4}, \end{aligned}$$
(11)

with \(p(n) = (n-1)(n-2)(n-3)\). As we can see, in less than four dimensions it vanishes regardless of the value of the scale factor, while in 4-dimensions, it turns into a topological surface term of the form given in Eq. (3).

Dynamics can be derived both starting from field Eq. (8) or from the Euler–Lagrange equations derived from a point-like Lagrangian. Because of our further considerations related to the Noether Theorem, let us construct the point-like Lagrangian. It can be found thanks to the Lagrange multipliers method, with constraint (11), as follows:

$$\begin{aligned} S = \int \left[ \sqrt{-g} f(\mathcal {G}) - \lambda \left\{ \mathcal {G} - \frac{(n-3)(n-2)(n-1) \left[ (n-4) \dot{a}^4 + 4 a \dot{a}^2 \ddot{a}\right] }{a^4} \right\} + \mathcal {L}_m \right] d^nx , \end{aligned}$$
(12)

being \(\mathcal {L}_m\) the matter Lagrangian. Considering the cosmological volume element in n-dimensions, the action can be written as

$$\begin{aligned} S =2 \pi ^2 \int \left[ a^{n-1} f(\mathcal {G}) - \lambda \left\{ \mathcal {G} - \frac{(n-3)(n-2)(n-1) \left[ (n-4) \dot{a}^4 + 4 a \dot{a}^2 \ddot{a}\right] }{a^4} \right\} + \mathcal {L}_m \right] d^nx . \end{aligned}$$
(13)

By varying the action with respect to \(\mathcal {G}\), we are able to find \(\lambda \):

$$\begin{aligned} \delta S = \frac{\partial S}{\partial \mathcal {G}} \delta \mathcal {G} = a^{n-1} f'(\mathcal {G}) - \lambda = 0 \;\;\;\;\;\; \lambda = a^{n-1} f'(\mathcal {G}).\nonumber \\ \end{aligned}$$
(14)

Replacing in Eq. (13) and integrating out the second derivative, the Lagrangian finally takes the form:

$$\begin{aligned} \mathcal {L}&= \frac{1}{3} a^{n-5} \left[ (4 - n) p(n) \dot{a}^4 f'(\mathcal {G})+ 3 a^4 [f(\mathcal {G}) - \mathcal {G}f'(\mathcal {G})] \right. \nonumber \\&\quad \left. -4 a p(n) \dot{a}^3 \dot{\mathcal {G}} f''(\mathcal {G}) \right] + \mathcal {L}_m \end{aligned}$$
(15)

The dynamical system is given by the two Euler–Lagrange equations coming from Lagrangian (15), with respect to the scale factor a and the GB scalar \(\mathcal {G}\). The system is completed by the Energy condition \(E_\mathcal {L}= \displaystyle \left( \dot{a} \partial _{\dot{a}} + \dot{\mathcal {G}} \partial _{\dot{\mathcal {G}}}- 1 \right) \mathcal {L}= 0\). Finally we have

$$\begin{aligned} {\left\{ \begin{array}{ll} -(n-4)(n-5) p(n) \dot{a}^4 f'(\mathcal {G}) - (n-1) a^4 [f(\mathcal {G}) - \mathcal {G}f'(\mathcal {G})] - 4 (n-4) p(n) a \dot{a}^2 [\ddot{a} f'(\mathcal {G})+ \dot{a} \dot{\mathcal {G}} f'(\mathcal {G})] +\\ \displaystyle - 4 a^2 p(n) \dot{a} [2 \dot{\mathcal {G}} \ddot{a} f''(\mathcal {G}) + \dot{a} \ddot{\mathcal {G}} f''(\mathcal {G}) + \dot{a} \dot{\mathcal {G}}^2 f'''(\mathcal {G})]=0 \\ \\ \mathcal {G}=p(n) \frac{\left[ (n-4) \dot{a}^4 + 4 a \dot{a}^2 \ddot{a}\right] }{a^4} \\ \\ (4 - n) p(n) \dot{a}^4 f'(\mathcal {G}) - a^4 [f(\mathcal {G}) - \mathcal {G}f'(\mathcal {G})] - 4 a p(n) \dot{a}^3 \dot{\mathcal {G}} f''(\mathcal {G}) = 0. \end{array}\right. } \end{aligned}$$
(16)

It is worth noticing that the equation for \(\mathcal {G}\) provides exactly the cosmological constraint on the GB scalar (11). It is impossible to solve the above equations without selecting the form of the \(f(\mathcal {G})\) function. In order to do this, we adopt the Noether Symmetry Approach by which one can select reliable models according to the existence of symmetries. The approach is also physically motivated because symmetries correspond to conservation laws.

3 The Noether symmetry approach

In this section we sketch the Noether symmetry approach [41], that we will apply in the next section, to the previous cosmological point-like Lagrangian. Let us consider the following transformations which leave the Euler–Lagrange equations invariant with respect to a change of coordinates:

$$\begin{aligned} {\left\{ \begin{array}{ll} \mathcal {L}(t,q^i \dot{q}^i) \rightarrow \mathcal {L}(\overline{t}, \overline{q}^i, \dot{\overline{q}}^i)\\ \overline{t} = t + \epsilon \xi (t,q^i) + O(\epsilon ^2)\\ \overline{q}^i = q^i + \epsilon \eta ^i(t,q^i) + O(\epsilon ^2). \end{array}\right. } \end{aligned}$$
(17)

In order to find the generator of transformations, we need to find the transformation law of the first derivative since, being the time involved in the transformation, the quantity \(\dot{\overline{q}}^i\) does not trivially correspond to \(\displaystyle \frac{d \overline{q}^i}{d t}\). For the first derivative, we have:

$$\begin{aligned} \dot{\overline{q}}^i = \frac{d \overline{q}^i}{d \overline{t}} = \frac{d q^i + \epsilon d\eta ^i(t,q^i)}{dt + \epsilon d \xi (t, q^i)} = \displaystyle \frac{\frac{d q^i}{dt} + \epsilon \frac{d\eta ^i(t,q^i)}{dt}}{1 + \epsilon \frac{d \xi (t, q^i)}{dt}} \nonumber \\= \left( \frac{d q^i}{dt} + \epsilon \frac{d\eta ^i(t,q^i)}{dt}\right) \left( 1+ \epsilon \frac{d \xi (t, q^i)}{dt}\right) ^{-1} . \end{aligned}$$
(18)

which, up to the first order, takes the form

$$\begin{aligned}&\dot{\overline{q}}^i = \left( \frac{d q^i}{dt} + \epsilon \frac{d\eta ^i(t,q^i)}{dt}\right) \left( 1 - \epsilon \frac{d \xi (t, q^i)}{dt}\right) + O(\epsilon ^2) \nonumber \\&\quad \ \,= \frac{d q^i}{dt} + \epsilon \left[ \frac{d\eta ^i(t,q^i)}{dt} {-} \frac{d q^i}{dt} \frac{d \xi (t, q^i)}{dt}\right] {+} O(\epsilon ^2) \sim \dot{q}^i \nonumber \\&\qquad \ + \epsilon \left[ \dot{\eta }^i - \dot{q}^i \dot{\xi } \right] . \end{aligned}$$
(19)

Let us now define \(\eta ^{i \; [1]} = \dot{\eta }^i - \dot{q}^i \dot{\xi }\) so that we have:

$$\begin{aligned} {\left\{ \begin{array}{ll} \mathcal {L}(t,q^i \dot{q}^i) \rightarrow \mathcal {L}(\overline{t}, \overline{q}^i, \dot{\overline{q}}^i)\\ \overline{t} = t + \epsilon \xi (t,q^i) + O(\epsilon ^2)\\ \overline{q}^i = q^i + \epsilon \eta ^i(t,q^i) + O(\epsilon ^2)\\ \dot{\overline{q}}^i = \dot{q}^i + \epsilon \eta ^{i \; [1]} \end{array}\right. } \end{aligned}$$
(20)

and finally the generator of transformation has the form

$$\begin{aligned} X^{[1]}&= \xi \frac{\partial }{\partial t} + \eta ^i \frac{\partial }{\partial q^i} + \eta ^{i \; [1]} \frac{\partial }{\partial \dot{q}^i} = \xi \frac{\partial }{\partial t} + \eta ^i \frac{\partial }{\partial q^i} \nonumber \\ {}&\quad + (\dot{\eta }^i - \dot{q}^i \dot{\xi }) \frac{\partial }{\partial \dot{q}^i}. \end{aligned}$$
(21)

It is called the first prolongation of Noether’s vector. We assume that our Lagrangian is not dependent on higher order derivatives and hence it is not necessary to calculate the transformation of \(\ddot{q}^i\); nevertheless, it is possible to further extend the Noether vector to the n-prolongation as follows:

$$\begin{aligned} X^{[n]} = \xi \frac{\partial }{\partial t} + \eta ^i \frac{\partial }{\partial q^i} + \eta ^{i \; [1]} \frac{\partial }{\partial \dot{q}^i} + \cdots + \eta ^{i \; [n]} \frac{\partial }{\partial \frac{d^n q^i}{dt^n}} \end{aligned}$$
(22)

here, it is

$$\begin{aligned} \eta ^{i \; [n]} = \frac{d \eta ^{i \; [n-1]}}{dt} - \dot{\xi } \frac{d^n q^i}{dt^n}. \end{aligned}$$
(23)

Let us show that if the coordinates transformation (20) leaves the equations of motion invariant, then the system satisfies the Noether identity

$$\begin{aligned} X^{[1]} \mathcal {L}+ \dot{\xi } \mathcal {L}= \dot{g}(t,q^i), \end{aligned}$$
(24)

where g is a generic function depending on coordinates and time. In order to prove the condition (24), we recall that the Euler–Lagrange equations are invariant if the following condition holds:

$$\begin{aligned} \frac{d\overline{t}}{dt} {\overline{\mathcal {L}}} = \mathcal {L}+ \epsilon \dot{g}. \end{aligned}$$
(25)

Deriving Eq. (25) with respect to \(\epsilon \) and then setting \(\epsilon = 0\), we obtain:

$$\begin{aligned} \frac{d\overline{t}}{dt} \frac{\partial {\overline{\mathcal {L}}}}{\partial \epsilon } + {\overline{\mathcal {L}}}\frac{\partial }{\partial \epsilon } \left( \frac{d\overline{t}}{dt}\right) = \dot{g} . \end{aligned}$$
(26)

We can observe that \(\displaystyle \frac{d\overline{t}}{dt} = \frac{\partial \overline{t}}{\partial t} + \frac{\partial \overline{t}}{\partial q^i} \dot{q}^i = 1 + \epsilon \frac{\partial \xi }{\partial q^i} \dot{q}^i\) that for \(\epsilon = 0\), it is equal to 1. Furthermore, assuming that it is possible to swap the order of derivatives, we have that \(\displaystyle \frac{\partial }{\partial \epsilon } \left( \frac{d\overline{t}}{dt}\right) = \frac{d}{dt}\frac{\partial \overline{t}}{\partial \epsilon } = \dot{\xi }\). Replacing these results into (26) we obtain:

$$\begin{aligned} \xi \frac{\partial {\overline{\mathcal {L}}}}{\partial t} + \eta ^i \frac{\partial {\overline{\mathcal {L}}}}{\partial \overline{q}^i} + \eta ^{[1]\; i} \frac{\partial {\overline{\mathcal {L}}}}{\partial \dot{\overline{q}}^i} + \dot{\xi } {\overline{\mathcal {L}}} = \dot{g} , \end{aligned}$$
(27)

which is nothing else but (24). From this, it follows that systems satisfying the condition (24) lead to the conserved quantity

$$\begin{aligned} I(t,q^i,\dot{q}^i) = \displaystyle \xi \left( \dot{q}^i \frac{\partial \mathcal {L}}{\partial \dot{q}^i} - \mathcal {L}\right) - \eta ^i \frac{\partial \mathcal {L}}{\partial \dot{q}^i} + g(t,q^i) , \end{aligned}$$
(28)

which is a first integral of motion. For other techniques to integrate dynamical systems useful for cosmology see also [51,52,53].

4 Noether symmetries in N-dimensional \(f(\mathcal {G})\) cosmology

Let us now apply the first prolongation of Noether vector to the Lagrangian (15) whose generator, in our minisuperspace, takes the form:

$$\begin{aligned} X = \xi (a,\mathcal {G},t) \partial _t + \alpha (a,\mathcal {G},t) \partial _a + \beta (a,\mathcal {G},t) \partial _\mathcal {G}\,. \end{aligned}$$
(29)

In order to find symmetries, we apply the Noether identity and set terms with derivative powers of a and \(\mathcal {G}\) equal to zero. Therefore, the application of (21) to (15) gives a system of four differential equations plus the constraints on the infinitesimal generators \(\alpha , \beta , \xi \). It reads:

$$\begin{aligned} {\left\{ \begin{array}{ll} \displaystyle (n-1) a^2 \alpha (f- \mathcal {G}f') - 4 p(n) \dot{a}^2 \dot{\mathcal {G}} f''\partial _t \alpha - a^3 \left[ \beta f'' - (f - \mathcal {G}f') \partial _t \xi \right] = 0\\ \displaystyle (n-4) \left[ f' \partial _t \alpha + a f'' \partial _t \beta \right] = 0 \\ \displaystyle (n-4 ) \alpha f'' + a \beta f''' + a f'' \left( 3 \partial _a \alpha + \partial _\mathcal {G}\beta - 3 \partial _t \xi \right) = 0 \\ \displaystyle (n-4)(n-5) \alpha f' + (n-4) a \beta f'' - (n-4 ) a f' \left( 3 \partial _t \xi - 4 \partial _a \alpha \right) + 4 a^2 f'' \partial _a \beta = 0\,, \end{array}\right. } \end{aligned}$$
(30)

with \( \xi = \xi (t)\,, \alpha = \alpha (a,t)\,, g = g_0\,.\) Here, we neglect a priori the possibility \(p(n) = 0\). Only three solutions satisfy the whole system; all of them provides the same dependence of the infinitesimal generator on the variables, namely

$$\begin{aligned} \alpha = \alpha _0 a\,, \quad \beta = \beta _0 \mathcal {G}\,, \quad \xi = \xi _0 t + \xi _1, \end{aligned}$$
(31)

but with different values of the constants \(\alpha _0, \beta _0, \xi _0\). The final solutions with the corresponding infinitesimal generators are:

$$\begin{aligned}&1): \,\, \alpha = \alpha _0 a\,, \quad \beta = \beta _0 \mathcal {G}\,, \quad \xi = \alpha _0 \left( \frac{n-1}{3}\right) t + \xi _1\,, \qquad f(\mathcal {G}) = f_0 \mathcal {G}\nonumber \\&2): \,\, \alpha = \alpha _0 a\,, \quad \beta = - 4 \xi _0 \mathcal {G}\,, \quad \xi = \xi _0 t + \xi _1\,, \qquad f(\mathcal {G}) = \frac{ 4 f_0 \xi _0}{\alpha _0(n-1) + \xi _0} \mathcal {G}^{\frac{\alpha _0(n-1) + \xi _0}{4 \xi _0}} \nonumber \\&3): \,\, \alpha = 0\,, \quad \beta = \beta _0 \mathcal {G}\,, \quad \xi =0\,, \qquad f(\mathcal {G}) = f_0 \mathcal {G}+ f_1, \end{aligned}$$
(32)

where the exponent of the second function must be different from 1. The first and the third solution are non-trivial only in more than 4 dimensions, while the second provides contributions to the equations of motion even for \(n=4\). Without loss of generality, in order to find the dynamics of the scale factor, we choose the function \(f(\mathcal {G}) = f_0 \mathcal {G}^k\), where we define

$$\begin{aligned} \frac{\alpha _0(n-1) + \xi _0}{4 \xi _0} = k \end{aligned}$$
(33)

and we incorporated the coefficient of \(\mathcal {G}^k\) into \(f_0\). Here \(k\in {\mathbb {R}}\). In this way, the point-like Lagrangian can be written as

$$\begin{aligned} \mathcal {L}&= -\frac{1}{3}a^{n-5} \mathcal {G}^{k-2} \left[ 3 (k-1) a^4 \mathcal {G}^2 + k (n-4) \mathcal {G}p(n) \dot{a}^4 \right. \nonumber \\ {}&\quad +\left. 4 k (k-1)a p(n) \dot{a}^3\dot{\mathcal {G}} \right] . \end{aligned}$$
(34)

The Euler–Lagrange Eq. (16) can now be exactly solved providing the following solutions:

$$\begin{aligned}&a(t) = a_0 e^{q t}\,, \qquad \mathcal {G}(t) = n p(n) \, q^4 \,,\qquad k= \frac{n}{4}\nonumber \\&a(t) = a_0 t^{- 4\frac{(k-1)\left( 4k- 1\right) }{4k -n}}\,, \nonumber \\&\mathcal {G}(t) = \frac{256 \left[ (k-1)\left( 4k- 1 \right) \right] ^3 \left[ 4 + n(4k-5) \right] p(n)}{(nt - 4kt)^4},\nonumber \\ \end{aligned}$$
(35)

with q constant. It is worth noticing that the de-Sitter-like expansion only holds in more that 4 dimensions, unlike the power-law solutions which is valid even for \(n=4\). However, the \(n=4\) case deserves a separate treatment. In next sections we will focus on 4-dimensions in presence of matter. It is interesting to observe that the function containing a linear GB term leads to a solution with several free parameters which should be fixed out by experimental observations. It provides a vacuum exponential acceleration.

5 \(f(\mathcal {G})\) cosmology in 4-dimensions

Let us now discuss specifically the four-dimensional case; in particular, we will derive the Noether symmetries coming from the 4-dimensional Lagrangian and the related cosmological solutions in presence of matter. After, we will also consider the case of GB term non-minimally coupled with a scalar field. We introduce the matter Lagrangian through the choice \(\mathcal {L}_m = \rho _0 a^{-3 w}\), where w represents the ratio between pressure and density \(p = w \, \rho \), that is the Equation of State of a perfect fluid. For \(w = 0\), we have dust matter, for \(w = \frac{1}{3}\), we have radiation. The case \(w = -1\), in turn, corresponds to the cosmological constant. Therefore, being \(p(4) = 6\), the Lagrangian (15), in 4-dimensions, is

$$\begin{aligned} \mathcal {L}^{(4)} = a^3[ f(\mathcal {G}) - \mathcal {G}f'(\mathcal {G})] - 8 \dot{a}^3 f''(\mathcal {G}) \dot{\mathcal {G}} + \rho _0 a^{-3 w} . \end{aligned}$$
(36)

The Euler–Lagrange equations of the above Lagrangian read as:

$$\begin{aligned} {\left\{ \begin{array}{ll} \displaystyle \frac{d}{dt}\frac{\partial \mathcal {L}}{\partial \dot{\mathcal {G}}} = \frac{\partial \mathcal {L}}{\partial \mathcal {G}} \;\;\; \rightarrow \;\;\; \mathcal {G}= 24 \frac{\dot{a}^2 \ddot{a}}{a^3}\\ \\ \displaystyle \frac{d}{dt}\frac{\partial \mathcal {L}}{\partial \dot{a}} = \frac{\partial \mathcal {L}}{\partial a} \;\;\; \rightarrow \;\;\; a^2[f(\mathcal {G}) - \mathcal {G}f'(\mathcal {G})] + 16 \dot{a} \ddot{a} \dot{\mathcal {G}} f''(\mathcal {G}) + 8\dot{a}^2[f''(\mathcal {G}) \ddot{\mathcal {G}} + f'''(\mathcal {G}) \dot{\mathcal {G}}^2] + 3 \rho _0 w a^{-3w-1} . \end{array}\right. } \end{aligned}$$
(37)

The first equation is the Lagrange multiplier in 4-dimensions. Finally we have to take into account the energy condition

$$\begin{aligned} E_\mathcal {L}= \dot{a} \frac{\partial \mathcal {L}}{\partial \dot{a}} + \dot{\mathcal {G}} \frac{\partial \mathcal {L}}{\partial \dot{\mathcal {G}}} - \mathcal {L}= 0 , \end{aligned}$$
(38)

which gives

$$\begin{aligned} a^3[f(\mathcal {G}) - \mathcal {G}f'(\mathcal {G})] + 24 \dot{a}^3 f''(\mathcal {G}) \dot{\mathcal {G}} + \rho _0 a^{-3 w} = 0 . \end{aligned}$$
(39)

Applying the Noether condition (24) to the Lagrangian (36), we get a system of two differential equations, since the second equation appearing into (30) canceled out for \(n=4\) and the fourth trivially reduces to \(\partial _a \beta =0\). The system takes the form:

$$\begin{aligned} {\left\{ \begin{array}{ll} \displaystyle 3 \alpha a^2 [ f(\mathcal {G}) - \mathcal {G}f'(\mathcal {G}) - w \rho _0 a^{-3(w+1)}] - \beta a^3 \mathcal {G}f''(\mathcal {G}) + \partial _t \xi a^3 [ f(\mathcal {G}) - \mathcal {G}f'(\mathcal {G})] = 0\\ \displaystyle 3 \partial _a \alpha f''(\mathcal {G}) + \beta f'''(\mathcal {G}) - 3 \partial _t \xi \; f''(\mathcal {G}) + \partial _\mathcal {G}\beta \; f''(\mathcal {G}) = 0 \\ \displaystyle \xi = \xi (t)\,, \quad \alpha = \alpha (a)\,, \quad \beta = \beta (\mathcal {G}) \quad g = g_0. \end{array}\right. } \end{aligned}$$
(40)

The presence of the matter Lagrangian does not cause any changes in the system resolution, so that the function and the infinitesimal generator turn out to be the \(n=4\) case of (32) assigning the Noether vector, namely

$$\begin{aligned} {\left\{ \begin{array}{ll} \alpha = \alpha _0 a\,, \quad \xi _0 t + \xi _1\,, \quad \beta = -4 \xi _0 \mathcal {G}\,, \quad g = g_0 \\ \displaystyle f(\mathcal {G}) = \frac{f_0 \mathcal {G}^k}{k}\,, \qquad k \ne 1 . \end{array}\right. } \end{aligned}$$
(41)

By using the above solutions and incorporating the constant k into \(f_0\), we can rewrite the point-like Lagrangian as

$$\begin{aligned} \mathcal {L}= - f_0 (k-1) \mathcal {G}^k a^3 - 8 f_0 k (k-1) \mathcal {G}^{k-2} \dot{a}^3 \dot{\mathcal {G}} - \rho _0 a^{-3w} . \end{aligned}$$
(42)

Euler–Lagrange equations and energy condition coming from (42) lead to the system

$$\begin{aligned} {\left\{ \begin{array}{ll} \displaystyle \mathcal {G}= 24 \frac{\dot{a}^2 \ddot{a}}{a^3}\\ \\ \displaystyle -8 f_0 k (k-1)(k-2) \dot{a}^2 \mathcal {G}^{k-3} \dot{\mathcal {G}}^2 - 8 f_0 k(k-1) \dot{a} \mathcal {G}^{k-2} \left( 2 \ddot{a} \dot{\mathcal {G}} + \dot{a} \ddot{\mathcal {G}}\right) +f_0 (k-1) a^2 \mathcal {G}^k -\rho _0 w a^{-3 w-1} = 0\\ \\ \displaystyle -24 f_0 k (k-1) \dot{a}^3 \mathcal {G}^{k-2} \dot{\mathcal {G}} + f_0 (k-1) a^3 \mathcal {G}^k +\rho _0 a^{-3w}= 0 . \end{array}\right. } \end{aligned}$$
(43)

There are two kinds of solutions of the above system; the first can be obtained neglecting the matter Lagrangian. In this case, when geometric contributions are greater than matter ones, the only solution reads

$$\begin{aligned} a(t) = a_0 t^{1-4k} \;\;\;\;\;\; \mathcal {G}(t) = -96 k(1-4k)^3 t^{-4} \equiv \mathcal {G}_0 t^{-4} , \nonumber \\ \end{aligned}$$
(44)

which is a power-law expansion and, as expected, it is contained into (35). Without neglecting \(\mathcal {L}_m\), we find another set of solutions, namely:

$$\begin{aligned} {\left\{ \begin{array}{ll} a(t) = a_0 t^{1-4k} \;\;\;\;\;\; \mathcal {G}(t) = -96 k(1-4k)^3 t^{-4} \equiv \mathcal {G}_0 t^{-4} \,\,\,\,\,\,\,\, w = 0\\ \\ a(t) = e^{n t} \,\,\,\,\,\,\, \mathcal {G}(t) = 24 m^4 \,\,\,\,\,\,\, w = -1 . \end{array}\right. } \end{aligned}$$
(45)

The former is the solution for dust matter, while in the latter the matter plays the role of cosmological constant. Nevertheless, from Eq. (44), we can distinguish the cosmological eras depending on the geometrical contributions even in vacuum:

$$\begin{aligned} \begin{aligned}&k = \frac{1}{8} \; \rightarrow \; a(t) \sim t^{\frac{1}{2}} \; \;\; \mathcal {G}= - \frac{3}{2} t^{-4} \;\; \rightarrow \; \mathrm {Radiation} \\&k = \frac{1}{6}\; \rightarrow a(t) \sim t^{\frac{1}{3}} \; \;\; \mathcal {G}= - \frac{16}{27} t^{-4} \;\; \rightarrow \; \hbox {Stiff matter} \\&k = \frac{1}{12} \; \rightarrow \; a(t) \sim t^{\frac{2}{3}} \; \;\; \mathcal {G}= - \frac{64}{27} t^{-4} \;\; \rightarrow \; \hbox {Dust matter} . \end{aligned} \end{aligned}$$
(46)

Cosmological solutions (44) are, therefore, in agreement with the FRW solutions of GR but are recovered without imposing the Ricci scalar in the gravitational action. It is worth noticing that in all cases the Gauss–Bonnet term turns out to be negative, so that the function \(f(\mathcal {G}) = f_0 \mathcal {G}^k\) may lead to some problems for fractional even values of k. To avoid these kind of singularities, we want to stress that the function \(f(\mathcal {G})\) is still a solution of Noether’s system even including the modulus of theThe Gauss–Bonnet term, i.e. \(f(\mathcal {G}) = f_0 |\mathcal {G}|^k\). same happens in several other modified theories; for example, in f(R) gravity, the Noether approach provides the solution \(f(R) \sim R^{3/2}\) [54], whose time power-law solution \( a(t) \sim t^p\) leads to a complex function for \(p<0\) and \(p > 1/2\). Hence, without loss of generality and in agreement with Noether’s approach, we can always require the function into the action to be positive. However, as shown in [55] for \(f(R)\sim |R|^{3/2}\), some exact solutions can imply transitions from decelerated/accelerated behaviors, that is dust/dark energy behaviors according to the values of solution parameters. In the present case, however, we are discussing only exact solutions emerging from Noether’s symmetries where there is no change of concavity in the evolution of the scale factor and then no transitions from decelerated to accelerated behaviors and viceversa.

5.1 Brans–Dicke coupling

Dynamics can be improved by coupling the GB function coming from the existence of Noether symmetries with a scalar field \(\phi \). In such a way the scalar-tensor action reads:

$$\begin{aligned} S = \int \sqrt{-g}\left[ \phi \mathcal {G}^k + \frac{\omega (\phi )}{\phi } \partial ^\mu \phi \partial _\mu \phi + V(\phi )\right] d^4 x . \end{aligned}$$
(47)

In this perspective, we can consider the simplest form of scalar-tensor theories, with zero potential and \(\omega (\phi ) \equiv \omega \), that is a Brans-Dicke theory coupled with GB geometry. The action becomes:

$$\begin{aligned} S = \int \sqrt{-g}\left[ \phi \mathcal {G}^k + \frac{\omega }{\phi } \partial ^\mu \phi \partial _\mu \phi \right] d^4 x . \end{aligned}$$
(48)

In this case, the field equations can be written as:

$$\begin{aligned}&2k R \nabla _\mu \nabla _\nu \mathcal {G}^{k-1} - 2 k g_{\mu \nu } R \Box \mathcal {G}^{k-1} - 4 k R^\lambda _\mu \nabla _\lambda \nabla _\nu \mathcal {G}^{k-1} + 4 k R_{\mu \nu } \Box \mathcal {G}^{k-1} \nonumber \\&+ 4 k g_{\mu \nu } R^{p \sigma } \nabla _p \nabla _\sigma \mathcal {G}^{k-1} + 4 k R_{\mu \nu p \sigma } \nabla ^p \nabla ^\sigma \mathcal {G}^{k-1} + \frac{1}{2} (1-k) g_{\mu \nu }[\mathcal {G}^{k}] + \nonumber \\&-{\frac{\omega }{\phi ^{2}}}(\partial _{\mu }\phi \partial _{\nu }\phi -{\frac{1}{2}}g_{{\mu \nu }}\partial _{p}\phi \partial ^{p}\phi )-{\frac{1}{\phi }}(\nabla _{\mu }\nabla _{\nu }\phi -g_{{\mu \nu }}\Box \phi )= 0 . \end{aligned}$$
(49)

As above, the corresponding point-like Lagrangian is

$$\begin{aligned} \mathcal {L}&= k(1-k) \phi (t) \dot{a}(t)^3 \mathcal {G}(t)^{k-2} G'(t) -k \dot{a}(t)^3 \mathcal {G}(t)^{k-1} \dot{\phi }(t)\nonumber \\ {}&\quad + (1-k) a(t)^3 \phi (t) \mathcal {G}(t)^k - \frac{\omega a(t)^3 \dot{\phi }(t)^2}{\phi (t)} . \end{aligned}$$
(50)

Euler–Lagrange equations and the energy condition for (50) are

$$\begin{aligned}&\frac{d}{dt} \frac{\partial \mathcal {L}}{\partial \dot{a}} = \frac{\partial \mathcal {L}}{\partial a} \;\; \rightarrow \;\; \frac{6 \omega a^2 \dot{a} \dot{\phi }}{\phi }+ 3 k \dot{a}^2 \ddot{a} \mathcal {G}^{k-1}\nonumber \\ {}&+ a^3 \left[ (k-1) \mathcal {G}^k- \frac{\omega \left( \dot{\phi }^2- 2 \phi \ddot{p}\right) }{\phi ^2}\right] =0\nonumber \\&\frac{d}{dt} \frac{\partial \mathcal {L}}{\partial \dot{\phi }} = \frac{\partial \mathcal {L}}{\partial \phi } \;\; \rightarrow \;\; \frac{3 a^2 \left[ (k-1) \phi ^2 \mathcal {G}^k+ \omega \dot{\phi }^2\right] }{\phi }\nonumber \\ {}&-3 k \dot{a} \mathcal {G}^{k-3} \left\{ \mathcal {G}\left[ 2 \mathcal {G}\ddot{a} \dot{\phi }+\dot{a} \left( 2 (k-1) \dot{G} \dot{\phi }+\mathcal {G}\ddot{\phi }\right) \right] +\right. \nonumber \\&\left. (k-1) \phi \left[ 2 \mathcal {G}\ddot{a} \dot{\mathcal {G}}+\dot{a} \left( \mathcal {G}\ddot{G}+(k-2) \dot{\mathcal {G}}^2\right) \right] \right\} = 0\nonumber \\&\frac{d}{dt} \frac{\partial \mathcal {L}}{\partial \dot{\mathcal {G}}} = \frac{\partial \mathcal {L}}{\partial \mathcal {G}} \;\; \rightarrow \;\; \mathcal {G}= \frac{\dot{a}^2 \ddot{a}}{a^3}\nonumber \\&\dot{q^i} \frac{\partial \mathcal {L}}{\partial \dot{q^i}} - \mathcal {L}= 0 \;\; \rightarrow \;\; \nonumber \frac{a^3 \left[ (k-1) \phi ^2 \mathcal {G}^k- \omega \dot{\phi }^2\right] }{\phi }\nonumber \\ {}&- k \dot{a}^3 \mathcal {G}^{k-2} \left[ 2 (k-1) \phi \dot{\mathcal {G}}+3 \mathcal {G}\dot{\phi }\right] = 0 \; \end{aligned}$$

and can be easily solved giving the de Sitter solution

$$\begin{aligned}&a(t) = a_0 e^{nt}\,, \;\;\;\;\; \phi (t) = \exp \left\{ \left[ n^{2k} \frac{\sqrt{\omega (k-1)}}{\omega }\right] t \right\} \,,\;\;\;\;\nonumber \\&\mathcal {G}(t) = 24 n^4 . \end{aligned}$$
(51)

By coupling the scalar field to GB term, accelerated expansion is recovered even if the scalar-field self-interaction potential \(V(\phi )\) is not present. Einstein’s gravity, even in this case, is recovered for \(k= \frac{1}{2}\); contributions to GB term coming from Riem\(^2\) and Ricci\(^2\), in some cosmological context, are comparable to \(R^2\), so that \(\sqrt{\mathcal {G}} = \sqrt{R^2 - 4 \mathbf{Ricci} ^2 + \mathbf{Riem} ^2 } \sim \sqrt{R^2}\). It means that, in some epochs, \(R^2\) and \(\mathcal {G}\) are dynamically equivalent up to a constant term. In fact, considering power-law solutions of the form \(a(t) \sim t^p\), we have

$$\begin{aligned}&\mathcal {G}= 24 \frac{\ddot{a} \dot{a}^2}{a^3} = \frac{24 p^3(p-1)}{t^4} \qquad \nonumber \\&R = -6 \left( \frac{\ddot{a}}{a} + \frac{\dot{a}^2}{a^2} \right) = \frac{6p (2p-1)}{t^2} \end{aligned}$$
(52)

so that it is clear that \(\mathcal {G}\sim R^2\) being p a number. The same holds for exponential solutions, where both R and \(\mathcal {G}\) are constants and independent of time. Therefore, \(\mathcal {G}\) and \(R^2\) can be considered dynamically equivalent on the solutions (up to a constant factor) if homogeneity and isotropy hold. A more general case is the one concerning the sum of different powers of \(\mathcal {G}\) that can be easily reduced to to \(R+f(\mathcal {G})\) or \(f(R)+f(\mathcal {G})\).

5.2 The case \(\mathcal {G}^n + \mathcal {G}^k\)

In this section we deal with the case of a function made of a sum of powers of the GB term, in 4-dimensions. Even though it is not directly a solution of the Noether system and it does not contain symmetries in this metric, it could be very relevant for several reasons. We mainly want to stress that in cosmology, in some epochs, GR is recovered with the choice \(f(\mathcal {G}) = \sqrt{\mathcal {G}}\). In spherical symmetry, something similar happens for different k, as shown in [40], where the Noether approach is applied to a pure spherically symmetric GB theory. A function like

$$\begin{aligned} f(\mathcal {G}) = f_0 \mathcal {G}^{\frac{1}{2}} + f_1 \mathcal {G}^{n} , \end{aligned}$$
(53)

can easily be compared to the case \(f(R,\mathcal {G})=R+f(\mathcal {G})\), often discussed in literature in view to recover GR in suitable limits [33, 34].

We generalize the concept by considering the function \(f(\mathcal {G}) = f_0 \mathcal {G}^n + f_1 \mathcal {G}^k\); the Lagrangian is a particular case of (36) and it reads:

$$\begin{aligned} \mathcal {L}&= -a^3 \left[ f_0(n-1) \mathcal {G}^n + f_1 (k-1) \mathcal {G}^k \right] \nonumber \\ {}&\quad - 8\left[ f_0 n(n-1) \mathcal {G}^{n-2} + f_1 k(k-1) \mathcal {G}^{k-2} \right] \dot{a}^3 \dot{\mathcal {G}} . \end{aligned}$$
(54)

The Euler–Lagrange equations and the energy condition are:

$$\begin{aligned} \displaystyle \frac{d}{dt}\frac{\partial \mathcal {L}}{\partial \dot{\mathcal {G}}} = \frac{\partial \mathcal {L}}{\partial \mathcal {G}} \;\;\; \rightarrow \;\;\;&\mathcal {G}= 24 \frac{\dot{a}^2 \ddot{a}}{a^3} \nonumber \\ \displaystyle \frac{d}{dt}\frac{\partial \mathcal {L}}{\partial \dot{a}} = \frac{\partial \mathcal {L}}{\partial a} \;\;\; \rightarrow \;\;\;&3 a^2 \left[ f_0 (n-1) \mathcal {G}^n+ f_1 (k-1) G^k\right] -24 \dot{a} \left[ f_0 n \left( n^2-3 n+2\right) \dot{a} \mathcal {G}^{n-3} \dot{\mathcal {G}}^2 +\right. \nonumber \\&+f_1 k \left( k^2-3 k+2\right) \dot{a} \mathcal {G}^{k-3} \dot{\mathcal {G}}^2+f_0 n (n-1) \mathcal {G}^{n-2} \left( 2 \ddot{a} \dot{\mathcal {G}}+\dot{a} \ddot{G}\right) + \nonumber \\&\left. + f_1 k (k-1) \mathcal {G}^{k-2} \left( 2 \ddot{a} \dot{\mathcal {G}}+\dot{a} \ddot{G}\right) \right] \nonumber \\ \dot{a} \frac{\partial \mathcal {L}}{\partial \dot{a}} + \dot{\mathcal {G}} \frac{\partial \mathcal {L}}{\partial \dot{\mathcal {G}}} - \mathcal {L}= 0 \;\;\; \rightarrow \;\;\;&a^3 \left[ f_0 (n-1) \mathcal {G}^n +f_1 (k-1) \mathcal {G}^k\right] - 24 \dot{a}^3 \dot{\mathcal {G}} \left[ f_0 n (n-1) \mathcal {G}^{n-2}+f_1 k (k-1) \mathcal {G}^{k-2}\right] .\nonumber \\ \end{aligned}$$
(55)

The system admits the following de Sitter solution:

$$\begin{aligned} a(t) = a_0 e^{mt} \;\;\; \mathcal {G}(t) = 24 m^4 \;\;\; \text {with} \;\; m = \left[ -24^{n - k}\; \frac{f_0}{f_1} \left( \frac{n-1}{k-1}\right) \right] ^{\frac{1}{4(k-n)}}\,.\nonumber \\ \end{aligned}$$
(56)

This means that dark energy [33] and inflation [37] can be easily recovered in this framework.

6 Quantum cosmology and the wave function of the universe

The above considerations allow to develop also quantum cosmology for the minisuperspace \(T\mathcal {Q}\equiv \{a,\dot{a}, \mathcal {G}, \dot{\mathcal {G}}\}\). Starting from Lagrangian (42) we can calculate the related Hamiltonian as a function of momenta:

$$\begin{aligned} \mathcal {H} = \frac{f_0}{k} \mathcal {G}^k a^3 + \pi _a \left( -\frac{\pi _\mathcal {G}}{8f_0} \mathcal {G}^{2-k} \right) ^{\frac{1}{3}} , \end{aligned}$$
(57)

where \(\pi _a=\frac{\partial {{\mathcal {L}}}}{\partial \dot{a}}\) and \(\pi _{\mathcal {G}}=\frac{\partial {{\mathcal {L}}}}{\partial \dot{\mathcal {G}}}\) according to the Legendre transformations.

Thanks to the Noether symmetries, we can insert into (57), a cyclic variable which allows to fully quantize the theory. From Eq. (44), it is easy to see that the quantity \(\displaystyle \frac{\dot{a}}{\mathcal {G}^k}\) is a constant of motion. Immediately, it is

$$\begin{aligned} \frac{\dot{a}^3}{\mathcal {G}^{3k}} = \Sigma _0 , \end{aligned}$$
(58)

and then we can rewrite \(\pi _\mathcal {G}\) as

$$\begin{aligned} \pi _\mathcal {G}= -8 f_0 \Sigma _0 \mathcal {G}^{4k-2} . \end{aligned}$$
(59)

Replacing this result into (57), we can write the Hamiltonian in the simpler form:

$$\begin{aligned} \mathcal {H} = \frac{f_0}{k} \mathcal {G}^k a^3 + \pi _a \left( \Sigma _0 \mathcal {G}^{3k} \right) ^{\frac{1}{3}} . \end{aligned}$$
(60)

Now, thanks to the quantization rules coming from the Arnowitt–Deser–Misner (ADM) formalism [56, 57], we can define the operators

$$\begin{aligned} {\left\{ \begin{array}{ll} \displaystyle \pi _\mathcal {G}= -i \frac{\partial }{\partial \mathcal {G}}\\ \\ \displaystyle \pi _a = - i \frac{\partial }{\partial a} \\ \\ \displaystyle \mathcal {H} \psi = 0 . \end{array}\right. } \end{aligned}$$
(61)

The third equation is the so-called Wheeler-de Witt Equation and \(\psi \) is the Wave Function of the Universe [56,57,58,59,60].

From the first equations, being \(\displaystyle \pi _\mathcal {G}= -8 f_0 \Sigma _0 \mathcal {G}^{4k-2}\), the quantity \(\displaystyle \pi _\mathcal {G}\mathcal {G}^{2-4k}\) is a constant of motion. More precisely the quantized equation of momentum can be written as:

$$\begin{aligned} i \frac{\partial }{\partial \mathcal {G}} \psi (a,\mathcal {G}) = 8 f_0 \Sigma _0 \mathcal {G}^{4k-2} \psi (a,\mathcal {G}), \end{aligned}$$
(62)

so that we get the system

$$\begin{aligned} {\left\{ \begin{array}{ll} \pi _\mathcal {G}\psi = -i \frac{\partial }{\partial \mathcal {G}} \psi \;\;\;\;\; \rightarrow \;\;\;\;\; \psi (a,\mathcal {G}) = A(a) \; \displaystyle \exp \left\{ i \; \frac{8 f_0 \Sigma _0 \mathcal {G}^{4k-1}}{1-4k}\right\} \\ \mathcal {H} \psi = 0 \;\;\;\; \rightarrow \;\;\;\; \displaystyle \frac{f_0}{k} \left( \Sigma _0 \right) ^{-\frac{1}{3}} a^3 A(a) - i \displaystyle \frac{\partial A(a)}{\partial a} = 0 . \end{array}\right. } \end{aligned}$$
(63)

The latter equation has the solution:

$$\begin{aligned} A(a) = A_0 \exp \left\{ -\frac{i}{4} \frac{f_0}{k} \left( \Sigma _0 \right) ^{-\frac{1}{3}} a^4 \right\} \end{aligned}$$
(64)

and hence finally the Wave Function of the Universe is

$$\begin{aligned} \psi (a,\mathcal {G}) = \psi _0 \exp \left\{ i\left[ -\frac{f_0}{4k} \left( \Sigma _0 \right) ^{-\frac{1}{3}} a^4 + \frac{8 f_0 \Sigma _0 \mathcal {G}^{4k-1}}{1-4k} \right] \right\} . \nonumber \\ \end{aligned}$$
(65)

According to the Hartle criterion [61, 62], an oscillating Wave Function means correlations among variables and then the possibility to find classical trajectories (i.e. observable universes). In fact, considering the WKB approximation, it is \(\psi (a,\mathcal {G}) \sim e^{iS}\) (where S is the action), we have, from (65),

$$\begin{aligned} S = -\frac{f_0}{4k} \left( \Sigma _0 \right) ^{-\frac{1}{3}} a^4 + \frac{8 f_0 \Sigma _0}{1-4k} \mathcal {G}^{4k-1} \end{aligned}$$
(66)

and, after some trivial calculations, we notice that Hamilton–Jacobi equation with respect to the scale factor provides the third equations of motion in (43):

$$\begin{aligned} \displaystyle \frac{\partial S}{\partial a} = \pi _a \;\;\;\; \rightarrow \;\;\;\; \mathcal {G}^k a^3 = 24 \mathcal {G}^{k-2} \dot{a}^3 \dot{\mathcal {G}} . \end{aligned}$$
(67)

The second Hamilton–Jacobi equation \(\displaystyle \left( \frac{\partial S}{\partial \mathcal {G}} = \pi _\mathcal {G}\right) \) instead, is nothing but the identity \(\pi _\mathcal {G}= \Sigma _0\) which can be recast into the second equation of motion of (43). In this sense, classical trajectories, and then observable universes, are recovered. As reported in [20, 63], oscillatory behaviors of the Wave Function of the Universe are related to conserved quantities coming from Noether symmetries. If the number of symmetries is equal to the variables of minisuperspace, the dynamical system is fully integrable and the Wave Function fully oscillating. As a consequence, we can state that Noether symmetries select observable universes.

7 Discussion and conclusions

In this paper, we discussed \(f(\mathcal {G})\) cosmology via the Noether Symmetry Approach. The main results are that the existence of symmetries selects a power-law form of \( \displaystyle f(\mathcal {G}) = f_0 \mathcal {G}^k\) and, in 4-dimensions, with the further constraint \(k \ne 1\), we can obtain interesting dynamics. Furthermore, we can observe that the case \(k=1\) is not allowed, in agreement with the fact that \(\displaystyle S = \int _{{\mathcal {M}}} \mathcal {G}d^4x = \chi ({\mathcal {M}})\), being \(\chi ({\mathcal {M}})\) the Euler characteristic. Moreover, taking into account the definition of the Gauss Bonnet invariant \(\mathcal {G}\) and considering that, in FRW cosmology \(R_{\mu \nu } R^{\mu \nu }\), \(R^{\mu \nu p \sigma } R_{\mu \nu p \sigma } \ll R^2\), for \(k = 1/2\) we can recover Einstein’s gravity. In other words, GR can be seen as a particular case of \(f(\mathcal {G})\) theory without asking for the corrected theory \(R+f(\mathcal {G})\). In this framework, it is possible to obtain both exponential and power-law cosmological solutions also in presence of standard matter. The former can be recovered only in 5-dimensions or more, while the latter can be found even in 4-dimensions. In 4-dimensions, de Sitter solutions are possible only adding an extra term \(\mathcal {L}_m \sim e^{-3w}\) with \(w=-1\). Nevertheless, coupling \(\mathcal {G}^k\) to a scalar field \(\phi \), de Sitter exponential law is immediately recovered also in in vacuum.

Furthermore, we analyzed the sum \(f(\mathcal {G}) = f_0 \mathcal {G}^n + f_1 \mathcal {G}^k\) which, according to the above considerations, naturally can give \(f(R,\mathcal {G})=R+f(\mathcal {G})\). Also in this case, we found exact solutions.

Finally, we discussed the quantum cosmology for the minisuperspace related to the variables a and \(\mathcal {G}\). Also in this case, symmetries have a key role for the interpretation of the Wave Function of the Universe. They allow to find out oscillatory behaviors and then the possibility to apply the Hartle criterion, which states that oscillations mean correlations between variables and then the possibility to achieve classical trajectories, that is observables universes.

As a concluding remark, considering extended Gauss–Bonnet cosmology can result useful from several points of view, in particular, for avoiding ghost modes [5] and other pathologies present in GR and in other modified gravity theories. Beside this fact, it seems a natural approach towards quantum fields in curved spaces and, finally, towards quantum gravity [64].