1 Introduction

The relativistic quantum dynamics of scalar and spin-\(\frac{1}{2}\) particles on curved background space-time geometries as well as Gödel, and Gödel-type metrics have been investigated by various authors (see [1] and references therein). The Klein–Gordon and Dirac equations in a Gödel-type space-times with positive, zero and negative curvatures were first studied in [2]. The close relationship between the quantum dynamics of the scalar particle in the background of general relativity with the Gödel solutions and the Landau levels in flat, spherical and hyperbolic spaces were investigated in [3, 4]. Later, the same problem was studied by solving the Klein–Gordon equation in the Som–Raychaudhuri space-time in [5]. The authors in [6] solved the Klein–Gordon equation in a family of Gödel-type solutions with the cosmic string and analyzed the similarity of the energy eigenvalue with the Landau levels in flat, spherical and hyperbolic spaces. Quantum influence of topological defects in a Gödel-type space-times in flat, spherical and hyperbolic cases, were investigated in [7]. The relativistic quantum dynamics of a Dirac particle with topological defects in a Gödel-type space-times with torsion have been investigated in [8]. The relativistic quantum dynamics of an electrically charged particle described by the Klein–Gordon oscillator subject to a Coulomb-type potential was investigated in [9]. Weyl fermions in a family of Gödel-type geometries with topological defects were investigated in [10]. The relativistic quantum dynamics of a scalar particle in 4D curved space-time with the cosmic string was investigated in [11]. The relativistic quantum dynamics of scalar and spin-\(\frac{1}{2}\) particles subject to various kind of potentials have been investigated in several areas of physics (e.g., [12,13,14,15,16,17,18,19,20,21,22,23,24,25,26]). Linear confinement of quantum particle by introducing a linear scalar potential into the relativistic system by modifying the mass term has great importance for models of confinement of quarks [27]. It is worth mentioning that the linear scalar potential has attracted a great interest in atomic and molecular physics [28,29,30,31,32,33], and in the relativistic quantum mechanics [9, 34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50].

Interactions of the Dirac oscillator with the gravitational fields produced by topological defects were investigated in [51]. The influence of Aharonov–Casher effect on the Dirac oscillator in three different scenarios of general relativity: the Minkowski space-time, the cosmic string and the cosmic dislocation space-time were studied in [52]. The influence of non-inertial effects on the Dirac oscillator in the cosmic string space-time was investigated in [53]. The Dirac equation in a class of topologically trivial flat Gödel-type space-time was investigated in [54]. Dirac fermions in the Som–Raychaudhuri space-time with a linear scalar and vector potentials were investigated in [36]. A new model for study the confinement of spin-half particles in a two-dimensional quantum ring systems described by the Dirac equation with a new coupling were studied in [55]. The Dirac oscillator in the context of Doubly General Relativity was investigated in [56]. Effects of gravitational fields produced by topological defects on the Dirac field and oscillator in a spinning cosmic string was examined in [57]. The dynamics of 2D Dirac oscillator in the space-time of a magnetic cosmic string were investigated in [58]. The generalized Dirac oscillator in the cosmic string space-time replacing the momentum \(p_{\mu }\) with its alternative \(p_{\mu }+m\,\omega \,\beta \,f_{\mu } (x_{\mu })\) was studied in [59]. In particular, the quantum dynamics was considered for the function \(f_{\mu } (x_{\mu })\) to be taken as Cornell-type, exponential-type and singular potentials form. The generalized Dirac oscillator was introduced in (2 + 1)-dimensional the world [60]. The Dirac oscillator under the influence of non-inertial effects in a rotating frame in the cosmic string space-time were investigated in [61]. The Dirac oscillator has also been analyzed in various physical systems, such as in the presence of external fields [62], and in the presence of a magnetic quantum flux [63,64,65,66]. Investigation of magnetization and persistent current of mass-less Dirac fermions confined in a quantum dot in a graphene layer with topological defects were done in [67]. Non-inertial effects on the Dirac oscillator in the background space-time generated by a cosmic string have been investigated [68,69,70]. The (1 + 2)-dimensional Dirac oscillator in the presence of a homogeneous magnetic field in an Aharonov–Casher system were investigated in [71]. The relativistic quantum dynamics of spin-half particle by solving the Dirac equation in (1 + 2)-dimensional Gürses space-time was investigated in [72].

The Klein–Gordon oscillator [73, 74] was inspired by the Dirac oscillator [75] applied to half-integer spin particles. The spectral distribution of energy levels and eigenfunction describing the state of a particle by solving the Klein–Gordon equation in one-dimensional version of the Minkowski space-time were studied in [76]. The Klein–Gordon oscillator in the cosmic string space-time in the presence of external fields were studied in [77]. The Klein–Gordon oscillator in the presence of a Coulomb-type potential was investigated by two ways: (1) by modifying the mass term \(m \rightarrow m+S(r)\) [78] and (2) via the minimal coupling [9] besides a linear scalar potential. The relativistic quantum effects on the Klein–Gordon oscillator with linear scalar and Coulomb-type potentials were investigated in [49]. The Klein–Gordon oscillator has also been investigated in various physical system, such as in the background space-time generated by the cosmic string [79], in the background of a Gödel-type space-time under the influence of gravitational fields produced by topological defects [80], in the background of the Som–Raychaudhuri space-time with a disclination parameter [6], Aharonov–Bohm effect for bound states on a scalar particle in a space-time with a spacelike dislocation [81], in non-commutative (NC) phase space [82], in (1 + 2)-dimensional Gürses space-time background [83], and in (1 + 2)-dimensional Gürses space-time background subject to Coulomb-type potential [84].

Our intention now is to extend the above studies not only to two-, three-, and four-dimensions but to consider this dynamics in general background space-time produced by topological defects using the Kaluza–Klein theory [85,86,87]. This new proposal establishes that the electromagnetism can be introduced through an extra (compactified) dimension in the space-time where, the spatial dimension becomes five-dimensional. These sources of gravitational fields play an important role in condensed matter physics systems [88,89,90,91]. Besides, the topological defects like the cosmic strings [92], domain walls [93], and global mono-pole [94] provides a tiny relation between the effects in cosmology and gravitation. In condensed matter physics systems where, topological defects analogue to the cosmic strings appear in phase transitions in liquid crystals [95, 96]. In addition, the Kaluza–Klein theory has found wide applications in string theory [97], in the presence of torsion [98, 99], fermions [100,101,102], and in the studies of Lorentz symmetry violation (LSV) in [103,104,105]. Based on these generalizations of topological defects space-time within the Kaluza–Klein theory, analogue effects to the Aharonov–Bohm effect for bound states were investigated in [7, 106,107,108,109]. The Klein–Gordon oscillator on curved background within the Kaluza–Klein theory were investigated in [7]. Some other physical systems in the Kaluza–Klein theory were studied in [100, 110,111,112,113].

The relativistic quantum dynamics of scalar particle of mass m is described by the Klein–Gordon equation:

$$\begin{aligned} \frac{1}{\sqrt{-g}}\,\partial _{\mu } (\sqrt{-g}\,g^{\mu \nu }\,\partial _{\nu }\,\Psi )=m^2\,\Psi , \end{aligned}$$
(1)

with g is the determinant of metric tensor with \(g^{\mu \nu }\) its inverse. If one introduces a scalar potential into the Klein–Gordon equation by modifying the mass term: \(m \rightarrow m + S (r)\) [114] where, S(r) is the scalar potential. The KG-equation becomes

$$\begin{aligned} \frac{1}{\sqrt{-g}}\,\partial _{\mu } (\sqrt{-g}\,g^{\mu \nu }\,\partial _{\nu }\,\Psi )=(m + S(r))^2\,\Psi . \end{aligned}$$
(2)

To couple the Klein–Gordon field with the oscillator [73, 74], the following change in the momentum operator is considered [115]:

$$\begin{aligned} p_{\mu }\rightarrow p_{\mu }+i\,m\,\omega \,X_{\mu }, \end{aligned}$$
(3)

where \(\omega \) is the frequency of oscillatory particle and the vector \(X_{\mu }=(0, r, 0, 0, 0)=r\,{\hat{r}}\) where, r being the distance of the particle from the string. To generalize the Klein–Gordon oscillator we have replaced \(\mathbf {r}\) by the function f(r) into \(X_{\mu }\) as:

$$\begin{aligned} X_{\mu }=(0, f(r), 0, 0, 0)=f(r)\,{\hat{r}}. \end{aligned}$$
(4)

Therefore, we have the following generalized Klein–Gordon oscillator equation:

$$\begin{aligned}&\frac{1}{\sqrt{-g}}\,(\partial _{\mu }+m\,\omega \,X_{\mu })\sqrt{-g}\,g^{\mu \nu }\,(\partial _{\nu }-m\,\omega \,X_{\nu })\,\Psi \nonumber \\&\quad =(m+ S(r))^2\,\Psi . \end{aligned}$$
(5)

This paper comprises as follow: in Sect. 2, we study the generalized Klein–Gordon oscillator in the cosmic string space-time in the Kaluza–Klein theory subject to a linear scalar potential; in Sect. 3, the generalized Klein–Gordon oscillator in the background of a magnetic cosmic string in the Kaluza–Klein theory subject to a linear scalar potential, and finally the conclusion in Sect. 4.

2 Generalized Klein–Gordon oscillator in the cosmic string space-time with a linear scalar potential in the Kaluza–Klein theory

The purpose of this section is to study the Klein–Gordon equation in the background space-time generated by the cosmic string within the Kaluza–Klein theory subject to a linear scalar potential. Linear scalar potential is introduced into the relativistic system by modifying the mass term discussed earlier and this kind of potential has great importance in different branch of physics mentioned in the introduction.

The first study of topological defects in the Kaluza–Klein theory was carried out in [110] where, a series of cylindrically symmetric solutions of Einstein and Einstein–Gauss–Bonet equations, were investigated. Various solutions of the cosmic string form in five-dimensions, such as: neutral cosmic string, cosmic dislocation, superconducting cosmic, multi-cosmic string space-time were studied there. The metric corresponding to this geometry can be written as,

$$\begin{aligned} ds^2=-dt^2+dr^2+\alpha ^2\,r^2\,d\phi ^2+dz^2+dx^2, \end{aligned}$$
(6)

where t is the time coordinate, x is the coordinate associated with the fifth additional dimensions and \((r, \phi , z)\) are cylindrical coordinates. These coordinates assumed the ranges \(-\infty< (t, z) < \infty \), \(0 \le r < \infty \), \(0 \le \phi \le 2\,\pi \), and \(0< x < 2\,\pi \,a\) where, a is the radius of the compact dimension x. The \(\alpha \) parameter characterizing the cosmic string and in terms of linear mass density \(\mu \) is \(\alpha =1-4\,\mu \) [92], where \(G=1=c=\hbar \). Cosmology and gravitation imposes limits of \(\alpha \) parameter which is restricted to \(\alpha < 1\) [92]. Moreover, in condensed matter physics systems, this restriction is free and the opposite case \(\alpha > 1\), the known negative disclination [113] can occur in several systems as those described by [96].

By considering the line element (6) into Eq. (5), we obtain the following differential equation:

$$\begin{aligned}&\left[ -\partial _{t}^2+\partial _{z}^2+\partial _{x}^2+\partial _{r}^2+\frac{1}{r}\,\partial _{r}+\frac{1}{\alpha ^2\,r^2}\,\partial _{\phi }^2\right. \nonumber \\&\quad -m\,\omega \,\left( f'(r)+\frac{f (r)}{r}\right) -m^2\,\omega ^2\,f^{2} (r)\nonumber \\&\quad \left. -(m+ S(r))^2\right] \,\Psi =0. \end{aligned}$$
(7)

The above equation is independent of \(t, \phi ,z, x\), so we choose the following ansatz for the function \(\Psi \)

$$\begin{aligned} \Psi (t, r, \phi , z, x)=e^{i\,(-E\,t+l\,\phi +k\,z+q\,x)}\,\psi (r), \end{aligned}$$
(8)

where E is the total energy, \(l=0,\pm \,1,\pm \,2\ldots \in \mathbf{Z}\) are the eigenvalue of the z-component of the angular momentum operator, and kq are constants.

Substituting the above ansatz into Eq. (7), we get the following radial wave-equation for \(\psi (r)\):

$$\begin{aligned}&\psi ''(r)+\frac{1}{r}\,\psi '(r)+\left[ E^2-k^2-q^2-\frac{l^2}{\alpha ^2\,r^2}q\right. \nonumber \\&\quad -m\,\omega \,\left( f'(r)+\frac{f (r)}{r}\right) \nonumber \\&\quad \left. -m^2\,\omega ^2\,f^{2}(r)-(m+S(r))^2\right] \,\psi (r)=0. \end{aligned}$$
(9)

In this work, we consider a special kind of potential which has many applications including the linear confinement of quarks which we discussed in the introduction is given by

$$\begin{aligned} S(r)=k_{L}\,r. \end{aligned}$$
(10)

where \(k_{L}\) is the linear confining parameter.

We choose the function f(r) as Cornell-type potential form given by [59, 116]

$$\begin{aligned} f(r)=a\,r+\frac{b}{r},\quad a, b>0. \end{aligned}$$
(11)

Substituting the function Eq. (11) into Eq. (9) and using the potential (10), we obtain the following equation:

$$\begin{aligned} \psi ''(r)+\frac{1}{r}\,\psi '(r)+\left[ \lambda -\tilde{\omega }^2\,r^2-\frac{\xi ^2_{s}}{r^2}-2\,m\,k_{L}\,r\right] \,\psi (r)=0, \end{aligned}$$
(12)

where

$$\begin{aligned}&\lambda =E^2-k^2-q^2-m^2-2\,m\,\omega \,a-2\,m^2\,\omega ^2\,a\,b,\nonumber \\&\tilde{\omega }=\sqrt{m^2\,\omega ^2\,a^2+k^{2}_{L}},\nonumber \\&\xi _{s}=\sqrt{\frac{l^2}{\alpha ^2}+m^2\,\omega ^2\,b^2}. \end{aligned}$$
(13)

Transforming \(\rho =\sqrt{\tilde{\omega }}\,r\) into Eq. (12), we obtain

$$\begin{aligned} \psi ''(\rho )+\frac{1}{\rho }\,\psi '(\rho )+\left[ \lambda _0-\rho ^2-\frac{\xi ^2_{s}}{\rho ^2}-\theta \,\rho \right] \,\psi (\rho )=0, \end{aligned}$$
(14)

where

$$\begin{aligned} \lambda _0=\frac{\lambda }{\tilde{\omega }},\quad \theta =\frac{2\,m\,k_{L}}{\tilde{\omega }^{\frac{3}{2}}}. \end{aligned}$$
(15)

Now, we use the appropriate boundary conditions to investigate the bound states solution in this problem. It is require that the regularity of wave-function at the origin and the normalizability at infinity. Then we proceed with the analysis of the asymptotic behaviour of the radial eigenfunction at origin and in the infinite. These conditions are necessary since the wave-function must be well-behaved in these limit, and thus, bound states of the energy eigenvalue for the confinement can be obtained. With these conditions, we obtain the convergence of the wave-function at the origin (\(\rho \rightarrow 0\)) and at infinity (\(\rho \rightarrow \infty \)). Let us impose the requirement that \(\psi (\rho ) \rightarrow 0\) both at \(\rho \rightarrow 0\) and \(\rho \rightarrow \infty \). Suppose the possible solution to Eq. (14) is

$$\begin{aligned} \psi (\rho )=\rho ^{|\xi _{s}|}\,e^{-\frac{1}{2}\,(\theta +\rho )\,\rho }\,H (\rho ), \end{aligned}$$
(16)

where \(H (\rho )\) is an unknown function. Substituting the solution Eq. (16) into Eq. (14), we obtain

$$\begin{aligned} H''(\rho )+\left[ \frac{\gamma }{\rho }-\theta -2\,\rho \right] \,H'(\rho )+\left[ -\frac{Q}{\rho }+\Theta \right] \,H (\rho )=0, \end{aligned}$$
(17)

where

$$\begin{aligned}&\gamma =1+2\,\xi _s,\nonumber \\&\Theta =\lambda _0+\frac{\theta ^2}{4}-2\,(1+\xi _s),\nonumber \\&Q=\frac{\theta }{2}\,(1+2\,\xi _s). \end{aligned}$$
(18)

Equation (17) is the biconfluent Heun differential equation [9, 33, 49, 116,117,118,119] with \(H (\rho )\) is the Heun polynomials function.

The above Eq. (17) can be solved by the power series method [120]

$$\begin{aligned} H (\rho )=\sum ^{\infty }_{i=0} c_{i}\,\rho ^{i}. \end{aligned}$$
(19)

Substituting Eq. (19) into Eq. (17), we get the following recurrernce relation for the coefficients:

$$\begin{aligned} c_{n+2}= & {} \frac{1}{(n+2)(n+1+\gamma )}\nonumber \\&\times \, [\{Q+\theta \,(n+1) \}\,c_{n+1}-(\Theta -2\,n)\,c_{n}]. \end{aligned}$$
(20)

And the various coefficients are

$$\begin{aligned} c_1=\frac{Q}{\gamma }\,c_0,\quad c_2=\frac{1}{2\,(1+\gamma )}\,[(Q+\theta )\,c_{1}-\Theta \,c_{0}]. \end{aligned}$$
(21)

The bound states solution to Eq. (17) can be obtained because there is no divergence of the wave-function both at \(\rho \rightarrow 0\) and \(\rho \rightarrow \infty \). As we have written the function \(H (\rho )\) as a power series expansion around the origin in Eq. (19). Thereby, the bound states solution can be achieved by imposing that the power series expansion becomes a polynomial of degree n. Through the recurrence relation Eq. (20), we can see that the power series expansion becomes a polynomial of degree n by imposing two conditions [9, 33, 116, 118, 119, 121,122,123,124]:

$$\begin{aligned} \Theta =2\,n. \end{aligned}$$
(22)

And

$$\begin{aligned} c_{n+1}=0,\quad (n=1,2,3,4,\ldots ). \end{aligned}$$
(23)

Using the condition \(\Theta =2\,n\), we get the following eigenvalue \(E_{n,l}\):

$$\begin{aligned}&\lambda _0+\frac{\theta ^2}{4}-2\,(1+\xi _s)=2\,n\nonumber \\&\quad \Rightarrow E^{2}_{n,l}=k^2+q^2+m^2+2\,m\,\omega \,a+2\,m^2\,\omega ^2\,a\,b\nonumber \\&\qquad +2\,\tilde{\omega }\,\left( n+1+\sqrt{\frac{l^2}{\alpha ^2}+m^2\,\omega ^2\,b^2}\right) -\frac{m^2\,k^{2}_{L}}{\tilde{\omega }^2}. \end{aligned}$$
(24)

Equation (24) is the bound states energy eigenvalue of a scalar particle associated with nth radial modes.

The corresponding wave-function is given by

$$\begin{aligned} \psi _{n,l} (\rho )=\rho ^{|\xi _s|}\,e^{-\frac{1}{2}\,\left[ \frac{2\,m\,k_{L}}{\tilde{\omega }^{\frac{3}{2}}}+\rho \right] \,\rho }\,H (\rho ). \end{aligned}$$
(25)

Now, we impose the additional condition \(c_{n+1}=0\) to find the individual energy levels and corresponding wave function one by one as done in [9, 33, 121, 122]. As example, for \(n=1\), we have \(c_2=0\) which implies

$$\begin{aligned}&c_1=\frac{2}{Q+\theta }\,c_0 \Rightarrow \frac{Q}{\gamma }=\frac{2}{Q+\theta }\nonumber \\&\quad \Rightarrow \tilde{\omega }_{1,l}=\left[ m^2\,k^2_{L 1}\,\left( \frac{3}{2}+\sqrt{\frac{l^2}{\alpha ^2}+m^2\,\omega ^2\,b^2}\right) \right] ^{\frac{1}{3}}, \end{aligned}$$
(26)

where we have adjusted the parameter \(k_{L}\) such that the first degree polynomial solution for \(n=1\) can be obtained [116]. Therefore, the ground state energy eigenvalue for \(n=1\) is given by

$$\begin{aligned}&E^{2}_{1,l}=k^2+q^2+m^2+2\,m\,\omega \,a+2\,m^2\,\omega ^2\,a\,b\nonumber \\&\quad +2\,\tilde{\omega }_{1,l}\,\left( n+1+\sqrt{\frac{l^2}{\alpha ^2}+m^2\,\omega ^2\,b^2}\right) -\frac{m^2\,k^{2}_{L 1}}{\tilde{\omega }^2_{1,l}}, \end{aligned}$$
(27)

where \(\tilde{\omega }_{1,l}\) is given by Eq. (26). The corresponding wave-function is given by

$$\begin{aligned} \psi _{1,l} (\rho )=\rho ^{\sqrt{\frac{l^2}{\alpha ^2}+m^2\,\omega ^2\,b^2}}\,e^{-\frac{1}{2}\,(2\,c_1+\rho )\,\rho }\,(c_0+c_1\,\rho ), \end{aligned}$$
(28)

where

$$\begin{aligned} c_1=\frac{1}{\sqrt{\frac{3}{2}+\sqrt{\frac{l^2}{\alpha ^2}+m^2\,\omega ^2\,b^2}}}. \end{aligned}$$
(29)

We discuss below few case of the above relativistic energy eigenvalue Eq. (24) of the relativistic system.

Case 1: If one choose \(b \rightarrow 0\), \(a \rightarrow 1\), that is, the Klein–Gordon oscillator subject to a linear scalar potential in the cosmic string space-time in the Kaluza–Klein theory.

The energy eigenvalue Eq. (24) becomes

$$\begin{aligned} E^{2}_{n,l}=k^2+q^2+m^2+2\,m\,\omega +2\,\tilde{\omega }_{n,l}\,\left( n+1+\frac{|l|}{\alpha }\right) -\frac{m^2\,k^{2}_{L}}{\tilde{\omega }^2_{n,l}}. \end{aligned}$$
(30)

Equation (30) is the energy eigenvalue of the Klein–Gordon oscillator field in the cosmic string background within the Kaluza–Klein theory subject to a linear scalar potential. Note that for \(k=0=q\), the energy eigenvalue Eq. (30) reduces to the result obtained in [49]. Thus the relativistic energy eigenvalue Eq. (30) is the generalised result in five-dimensions in comparison to those obtained in (1 + 2)-dimensional case in [49].

Therefore, the bound state energy eigenvalue for \(n=1\) is given by

$$\begin{aligned} E^{2}_{1,l}= & {} k^2+q^2+m^2+2\,m\,\omega +2\,\tilde{\omega }_{1,l}\,\left( n+1+\frac{|l|}{\alpha }\right) \nonumber \\&-\frac{m^2\,k^{2}_{L 1}}{\tilde{\omega }^2_{1,l}}. \end{aligned}$$
(31)

And the corresponding wave function is

$$\begin{aligned} \psi _{1,l} (\rho )=\rho ^{\frac{|l|}{\alpha }}\,e^{-\frac{1}{2}\,(2\,c_1+\rho )\,\rho }\,(c_0+c_1\,\rho ), \end{aligned}$$
(32)

where

$$\begin{aligned} c_1=&\frac{1}{\sqrt{\frac{3}{2}+\frac{|l|}{\alpha }}},\nonumber \\ \tilde{\omega }_{1,l}=&\left[ m^2\,k^2_{L 1}\,\left( \frac{3}{2}+\frac{|l|}{\alpha }\right) \right] ^{\frac{1}{3}}. \end{aligned}$$
(33)

Case 2: If one choose \(k_{L} \rightarrow 0\), that is, without any scalar potential in the relativistic system.

From Eq. (12), we obtain the following equation

$$\begin{aligned} \psi ''(r)+\frac{1}{r}\,\psi '(r)+\left[ \lambda -m^2\,\omega ^2\,a^2\,r^2-\frac{\xi ^2_{s}}{r^2}\right] \,\psi (r)=0, \end{aligned}$$
(34)

Introducing a new variable \(s=m\,\omega \,a\,r^2\) into the above equation, we obtain [125]

$$\begin{aligned} \psi ''(s)+\frac{1}{s}\,\psi ' (s)+\frac{1}{s^2}\,(-\xi _1\,s^2+\xi _2\,s-\xi _3)\,\psi (s)=0, \end{aligned}$$
(35)

where

$$\begin{aligned} \xi _1=\frac{1}{4},\quad \xi _2=\frac{\lambda }{4\,m\,\omega \,a},\quad \xi _3=\frac{\xi ^2_{s}}{4}. \end{aligned}$$
(36)

Compairing the above Eq. (35) with (A.1) in appendix A, we get

$$\begin{aligned}&\alpha _1=1,\quad \alpha _2=0,\quad \alpha _3=0,\quad \alpha _4=0,\quad \alpha _5=0,\nonumber \\&\alpha _6=\xi _1,\quad \alpha _7=-\xi _2,\quad \alpha _8=\xi _3,\quad \alpha _9=\xi _1,\nonumber \\&\alpha _{10}=1+2\,\sqrt{\xi _3},\quad \alpha _{11}=2\,\sqrt{\xi _1},\quad \alpha _{12}=\sqrt{\xi _3},\nonumber \\&\alpha _{13}=-\sqrt{\xi _1}. \end{aligned}$$
(37)

The energy eigenvalue using (36)–(37) into the Eq. (A.8) in appendix A is given by

$$\begin{aligned}&(2\,n+1)\,\sqrt{\xi _1}-\xi _2+2\,\sqrt{\xi _1\,\xi _3}=0\nonumber \\&\quad \Rightarrow E^{2}_{n,l}=k^2+q^2+m^2+2\,m^2\,\omega ^2\,a\,b\nonumber \\&\qquad +2\,m\,\omega \,a\,\left( 2\,n+2+\sqrt{\frac{l^2}{\alpha ^2}+m^2\,\omega ^2\,b^2}\right) , \end{aligned}$$
(38)

where \(n=0,1,2,3,\ldots \).

If one choose \(b \rightarrow 0\), \(a \rightarrow 1\), that is, the Klein–Gordon oscillator in the cosmic string without potential in the Kaluza–Klein theory. Then, the energy eigenvalue (38) becomes

$$\begin{aligned} E^{2}_{n,l}=k^2+q^2+m^2+4\,m\,\omega \,\left( n+1+\frac{|l|}{2\,\alpha }\right) \end{aligned}$$
(39)

which is similar to the result obtained in [7] (see Eq. (12) in [7]). We can see that Eq. (38) is the extended energy eigenvalue of the generalized Klein–Gordon oscillator in the cosmic string space-time without potential in the Kaluza–Klein theory.

Case 3: If one choose \(b \rightarrow 0\), \(a \rightarrow 0\), the Klein–Gordon particle subject to linear scalar potential in a cosmic string background in a Kaluza–Klein theory.

In that case, Eq. (12) becomes

$$\begin{aligned}&\psi ''(r)+\frac{1}{r}\,\psi '(r)+\left[ E^2-m^2-k^2-q^2\right. \nonumber \\&\left. -k^2_{L}\,r^2-\frac{l^2}{\alpha ^2\,r^2}\right] \,\psi (r)=0. \end{aligned}$$
(40)

Transforming \(s=K_{L}\,r^2\) into the above equation, we obtain the following differential equation [125]

$$\begin{aligned}&\psi ''(s)+\frac{1}{s}\,\psi '(s)+\frac{1}{s^2}\,\left[ \frac{E^2-m^2-k^2-q^2}{4\,k_{L}}\,s\right. \nonumber \\&\quad \left. -\frac{1}{4}\,s^2-\frac{l^2}{4\,\alpha ^2}\right] \,\psi (s)=0. \end{aligned}$$
(41)

As done earlier, we obtain the following energy eigenvalue of the system

$$\begin{aligned} E_{n,l}=\pm \,\sqrt{k^2+q^2+m^2+2\,k_{L}\,\left( 2\,n+1+\frac{|l|}{\alpha }\right) }. \end{aligned}$$
(42)

Equation (42) is the relativistic energy eigenvalue of a scalar particle in the cosmic string space-time in the Kaluza–Klein theory with a linear scalar potential.

3 Generalized Klein–Gordon oscillator in the magnetic cosmic string space-time with a linear scalar potential in the Kaluza–Klein theory

In this section, we investigate analogue effect to the Aharonov–Bohm effect for bound states [7, 81, 106,107,108,109] solution of a scalar particle. By using the Kaluza–Klein theory, we introduce a magnetic flux through the line element of the cosmic string and thus write the generalized Klein–Gordon oscillator equation in five-dimensional space-time subject to a linear scalar potential. This kind of potential has great reserach interested and used for the confinement of quark models and in other branches of physics discussed earlier.

Let us consider the quantum dynamics of a scalar particle moving in the magnetic cosmic string background. In the Kaluza–Klein theory [113], the corresponding metric with the magnetic quantum flux \(\Phi \) passing along the symmetry axis of the string assumes the following form

$$\begin{aligned} ds^2=-dt^2+dr^2+\alpha ^2\,r^2\,d\phi ^2+dz^2+\left( dx+\frac{\Phi }{2\,\pi }\,d\phi \right) ^2 \end{aligned}$$
(43)

with cylindrical coordinates are used. The quantum dynamics is described by Eq. (2) with the following change in the inverse matrix tensor \(g^{\mu \nu }\),

$$\begin{aligned} g^{\mu \nu }=\left( \begin{array}{lllll} -1 &{} 0 &{} \quad 0 &{} 0 &{} \quad 0 \\ \quad 0 &{} 1 &{} \quad 0 &{} 0 &{} \quad 0 \\ \quad 0 &{} 0 &{} \quad \frac{1}{\alpha ^2\,r^2} &{} 0 &{} -\frac{\Phi }{2\,\pi \,\alpha ^2\,r^2} \\ \quad 0 &{} 0 &{} \quad 0 &{} 1 &{} \quad 0 \\ \quad 0 &{} 0 &{} -\frac{\Phi }{2\,\pi \,\alpha ^2\,r^2} &{} 0 &{} 1+\frac{\Phi ^2}{4\,\pi ^2\,\alpha ^2\,r^2} \end{array} \right) . \end{aligned}$$
(44)

By considering the line element (43) into Eq. (5), we obtain the following differential equation:

$$\begin{aligned}&\left[ -\partial _{t}^2+\partial _{r}^2+\frac{1}{r}\,\partial _{r}+\frac{1}{\alpha ^2\,r^2}\,\left( \partial _{\phi }-\frac{\Phi }{2\,\pi }\,\partial _{x}\right) ^2\right. \nonumber \\&\quad +\, \partial _{z}^2+\partial _{x}^2-m\,\omega \,\left( f' (r)+\frac{f(r)}{r}\right) \nonumber \\&\quad \left. -\, m^2\,\omega ^2\,f^{2}(r)-(m + S(r))^2\right] \,\Psi (r)=0. \end{aligned}$$
(45)

Since the space-time is independent of \(t, \phi , z, x\), substituting the ansatz Eq. (8) into Eq. (45), we get the following equation:

$$\begin{aligned}&\psi ''(r)+\frac{1}{r}\,\psi '(r)+\left[ E^2-k^2-q^2-\frac{l^2_{eff}}{r^2}\right. \nonumber \\&\quad -\,m\,\omega \,\left( f'(r)+\frac{f(r)}{r}\right) \nonumber \\&\quad \left. - \,m^2\,\omega ^2\,f^{2}(r)-(m+S (r))^2\right] \,\psi (r)=0, \end{aligned}$$
(46)

where

$$\begin{aligned} l_{eff}=\frac{1}{\alpha }\,\left( l-\frac{q\,\Phi }{2\,\pi }\right) \end{aligned}$$
(47)

is called the effective angular quantum number which depends on the cosmic string parameter as well as the magnetic quantum flux.

Substituting the function Eq. (11) into Eq. (46) and using the scalar potential Eq. (10), we obtain the following equation:

$$\begin{aligned} \psi ''(r){+}\frac{1}{r}\,\psi '(r){+}\left[ \lambda -\tilde{\omega }^2\,r^2-\frac{\chi ^2_{eff}}{r^2}-2\,m\,k_{L}\,r\right] \,\psi (r)=0, \end{aligned}$$
(48)

where

$$\begin{aligned} \lambda =&E^2-k^2-q^2-m^2-2\,m\,\omega \,a-2\,m^2\,\omega ^2\,a\,b,\nonumber \\ \tilde{\omega }=&\sqrt{m^2\,\omega ^2\,a^2+k^{2}_{L}},\nonumber \\ \chi _{eff}=&\sqrt{l^2_{eff}+m^2\,\omega ^2\,b^2}. \end{aligned}$$
(49)

Transforming \(\rho =\sqrt{\tilde{\omega }}\,r\) into Eq. (48), we get

$$\begin{aligned} \psi ''(\rho )+\frac{1}{\rho }\,\psi '(\rho )+\left[ \lambda _0-\rho ^2-\frac{\chi ^2_{eff}}{\rho ^2}-\theta \,\rho \right] \,\psi (\rho )=0, \end{aligned}$$
(50)

where \(\lambda _0, \theta \) are in Eq. (15).

As similar to the technique done earlier, suppose the solution to Eq. (50) is

$$\begin{aligned} \psi (\rho )=\rho ^{\chi _{eff}}\,e^{-\frac{1}{2}\,(\theta +\rho )\,\rho }\,H (\rho ). \end{aligned}$$
(51)

Substituting Eq. (51) into Eq. (50), we get the biconfluent Heun’s differential equation [9, 33, 49, 116,117,118,119] form:

$$\begin{aligned} H''(\rho )+\left[ \frac{\bar{\gamma }}{\rho }-\theta -2\,\rho \right] \,H'(\rho )+\left[ -\frac{{\bar{Q}}}{r}+{\bar{\Theta }}\right] \,H (\rho )=0, \end{aligned}$$
(52)

where

$$\begin{aligned}&{{\bar{\gamma }}}=(1+2\,\chi _{eff}),\nonumber \\&{{\bar{\Theta }}}=\lambda _0+\frac{\theta ^2}{4}-2\,(1+\chi _{eff}),\nonumber \\&{{\bar{Q}}}=\frac{\theta }{2}\,(1+2\,\chi _{eff}). \end{aligned}$$
(53)

Substituting Eq. (19) into Eq. (52), we get the following recurrernce relation for the coefficients:

$$\begin{aligned} c_{n+2}=\frac{1}{(n+2)(n+1+\gamma )}\,[\{{{\bar{Q}}}+\theta \,(n+1) \}\,c_{n+1}-({{\bar{\Theta }}}-2\,n)\,c_{n}]. \end{aligned}$$
(54)

And the various coefficients are

$$\begin{aligned} c_1=\frac{{\bar{Q}}}{{\bar{\gamma }}}\,c_0,\quad c_2=\frac{1}{2\,(1+\gamma )}\,[({{\bar{Q}}}+\theta )\,c_{1}-{{\bar{\Theta }}}\,c_{0}]. \end{aligned}$$
(55)

A polynomial form of degree n for the function H(r) is achieved when we impose requirement that the series solution terminates. For this, we must have [9, 33, 116, 118, 119, 121,122,123,124]

$$\begin{aligned} {{\bar{\Theta }}}=2\,n. \end{aligned}$$
(56)

And

$$\begin{aligned} c_{n+1}=0,\quad (n=1,2,3,4,\ldots ). \end{aligned}$$
(57)

Using the condition \({{\bar{\Theta }}}=2\,n\), we obtain the following energy eigenvalue \(E_{n,l}\):

$$\begin{aligned} E^{2}_{n,l}= & {} k^2+q^2+m^2+2\,m\,\omega \,a+2\,m^2\,\omega ^2\,a\,b-\frac{m^2\,k^{2}_{L}}{\tilde{\omega }^2}\nonumber \\&+ 2\,\tilde{\omega }\,\left( n+1+\sqrt{\frac{1}{\alpha ^2}\,\left( l-\frac{q\,\Phi }{2\,\pi }\right) ^2+m^2\,\omega ^2\,b^2}\right) .\nonumber \\ \end{aligned}$$
(58)

Equation (58) is the energy eigenvalue associated with nth radial modes for the generalized Klein–Gordon oscillator in the magnetic cosmic string with a linear scalar potential in the Kaluza–Klein theory. We can see in comparision to the case without magnetic flux as obtained earlier by Eq. (24), the angular quantum number l is shifted, \(l \rightarrow l_{eff}=\frac{1}{\alpha }\,(l-\frac{q\,\Phi }{2\,\pi })\), an effective angular quantum number. We see that the relativistic energy eigenvalue Eq. (58) depends on the Aharonov–Bohm geometric quantum phase [109]. Thus, we have that \(E_{n,{{\bar{l}}}} (\Phi +\Phi _0)=E_{n,{{\bar{l}}}\pm \tau } (\Phi )\) where, \(\Phi _0=\mp \,\frac{2\,\pi \,\alpha }{q}\,\tau \) with \(\tau =1,2,3,\ldots \) and \({{\bar{l}}}=\frac{l}{\alpha }\). This dependence of the relativistic energy eigenvalue on the geometric quantum phase gives rise to the analogoue effects to the Aharonov–Bohm effect for bound states [81, 106,107,108,109].

The corresponding wave-function is given by

$$\begin{aligned} \psi _{n,l} (\rho )=\rho ^{\sqrt{\frac{\left( l-\frac{q\,\Phi }{2\,\pi }\right) ^2}{\alpha ^2}+m^2\,\omega ^2\,b^2}}\,e^{-\frac{1}{2}\,(\theta +\rho )\,\rho }\,H (\rho ). \end{aligned}$$
(59)

Now, we impose the additional condition \(c_{n+1}=0\) in the above eigenvalue problem to obtain the individual energy levels and corresponding wave-function one by one as done in [9, 33, 121, 122]. As example, for \(n=1\), we have \(c_2=0\) which implies

$$\begin{aligned}&c_1=\frac{2}{{{\bar{Q}}}+{{\bar{\beta }}}}\,c_0 \Rightarrow \frac{{\bar{Q}}}{{{\bar{\gamma }}}}=\frac{2}{{{\bar{Q}}}+{\bar{\beta }}}\nonumber \\&\quad \Rightarrow B^2_{2}=\frac{1}{1+A_2} \Rightarrow \tilde{\omega }_{1,l}\nonumber \\&\quad =\left[ m^2\,k^2_{L 1}\,\left( \frac{3}{2}+\sqrt{\frac{\left( l-\frac{q\,\Phi }{2\,\pi }\right) ^2}{\alpha ^2}+m^2\,\omega ^2\,b^2}\right) \right] ^{\frac{1}{3}}. \end{aligned}$$
(60)

Therefore, the ground state energy level for \(n=1\) is given by

$$\begin{aligned}&E^{2}_{1,l}=k^2+q^2+m^2+2\,m\,\omega \,a+2\,m^2\,\omega ^2\,a\,b\nonumber \\&\quad +2\,\tilde{\omega }_{1,l}\,\left( n+1+\sqrt{\frac{\left( l-\frac{q\,\Phi }{2\,\pi }\right) ^2}{\alpha ^2}+m^2\,\omega ^2\,b^2}\right) \nonumber \\&\quad -\frac{m^2\,k^{2}_{L 1}}{\tilde{\omega }^2_{1,l}}, \end{aligned}$$
(61)

where \(\tilde{\omega }_{1,l}\) is given by Eq. (60). The corresponding wave-function is

$$\begin{aligned} \psi _{1,l} (\rho )=\rho ^{\sqrt{\frac{\left( l-\frac{q\,\Phi }{2\,\pi }\right) ^2}{\alpha ^2}+m^2\,\omega ^2\,b^2}}\,e^{-\frac{1}{2}\,(2\,c_1+\rho )\,\rho }\,(c_0+c_1\,\rho ), \end{aligned}$$
(62)

where

$$\begin{aligned} c_1=\frac{1}{\sqrt{\frac{3}{2}+\sqrt{\frac{\left( l-\frac{q\,\Phi }{2\,\pi }\right) ^2}{\alpha ^2}+m^2\,\omega ^2\,b^2}}}. \end{aligned}$$
(63)

Below we discuss few cases of the above energy eigenvalue of the relativistic system considered in this section.

Case 1: If one choose \(b \rightarrow 0\), \(a \rightarrow 1\).

In that case, the energy eigenvalue Eq. (58) becomes

$$\begin{aligned} E^{2}_{n,l}= & {} k^2+q^2+m^2+2\,m\,\omega +2\,\tilde{\omega }_{n,l}\,\left( n+1+\frac{|l-\frac{q\,\Phi }{2\,\pi }|}{\alpha }\right) \nonumber \\&-\frac{m^2\,k^{2}_{L}}{\tilde{\omega }^2_{n,l}}. \end{aligned}$$
(64)

Equation (64) is the energy eigenvalue associated with \(n^{th}\) radial modes for the Klein–Gordon oscillator in the magnetic cosmic string background with a linear scalar potential in the Kaluza–Klein theory.

The bound state energy level for \(n=1\) is given by

$$\begin{aligned}&E^{2}_{1,l}=k^2+q^2+m^2+2\,m\,\omega \,a\nonumber \\&\quad +2\,\tilde{\omega }_{1,l}\,\left( n+1+\frac{|l-\frac{q\,\Phi }{2\,\pi }|}{\alpha }\right) -\frac{m^2\,k^{2}_{L 1}}{\tilde{\omega }^2_{1,l}}. \end{aligned}$$
(65)

And the corresponding wave-function is

$$\begin{aligned} \psi _{1,l} (\rho )=\rho ^{\frac{|l-\frac{q\,\Phi }{2\,\pi }|}{\alpha }}\,e^{-\frac{1}{2}\,(2\,c_1+\rho )\,\rho }\,(c_0+c_1\,\rho ), \end{aligned}$$
(66)

where

$$\begin{aligned}&c_1=\frac{1}{\sqrt{\frac{3}{2}+\frac{|l-\frac{q\,\Phi }{2\,\pi }|}{\alpha }}},\nonumber \\&\tilde{\omega }_{1,l}=\left[ m^2\,k^2_{L 1}\,\left( \frac{3}{2}+\frac{|l-\frac{q\,\Phi }{2\,\pi }|}{\alpha }\right) \right] ^{\frac{1}{3}}. \end{aligned}$$
(67)

Case 2: If one choose \(k_{L} \rightarrow 0\), that is, without any linear scalar potential into the considered system.

In that case, from Eq. (48) we have the following equation

$$\begin{aligned} \psi ''(r)+\frac{1}{r}\,\psi '(r)+\left[ \lambda -m^2\,\omega ^2\,a^2\,r^2-\frac{\chi ^2_{eff}}{r^2}\right] \,\psi (r)=0 \end{aligned}$$
(68)

which can be transformed to the following equation [125]

$$\begin{aligned} \psi ''(s)+\frac{1}{s}\,\psi ' (s)+\frac{1}{s^2}\,(-\xi _1\,s^2+\xi _2\,s-\xi _3)\,\psi (s)=0, \end{aligned}$$
(69)

where

$$\begin{aligned} \xi _1=\frac{1}{4},\quad \xi _2=\frac{\lambda }{4\,m\,\omega \,a},\quad \xi _3=\frac{\chi ^2_{eff}}{4}. \end{aligned}$$
(70)

The energy eigenvalue is given by

$$\begin{aligned} E^{2}_{n,l}= & {} k^2+2\,m^2\,\omega ^2\,a\,b+q^2+m^2+2\,m\,\omega \,a\,\left( 2\,n+2\right. \nonumber \\&\left. +\sqrt{\frac{(l-\frac{q\,\Phi }{2\,\pi })^2}{\alpha ^2}+m^2\,\omega ^2\,b^2}\right) , \end{aligned}$$
(71)

where \(n=0,1,2,3,\ldots \). Equation (71) is the energy eigenvalue associated with nth radial modes for the generalized Klein–Gordon oscillator in the magnetic cosmic string without potential in the Kaluza–Klein theory.

If one choose \(b \rightarrow 0\), \(a \rightarrow 1\), that is, the Klein–Gordon oscillator in the magnetic cosmic string background in the Kaluza–Klein theory, the energy eigenvalue Eq. (71) becomes

$$\begin{aligned} E^{2}_{n,l}=k^2+q^2+m^2+4\,m\,\omega \,\left( n+1+\frac{|l-\frac{q\,\Phi }{2\,\pi }|}{2\,\alpha }\right) \end{aligned}$$
(72)

which is similar to the result obtained in [7] (see Eq. (25) in [7]). Thus Eq. (71) is the extended energy eigenvalue of the generalized Klein–Gordon oscillator in the magnetic cosmic string background without potential in the Kaluza–Klein theory.

Case 3: If one choose \(b \rightarrow 0\), \(a \rightarrow 0\), the Klein–Gordon particle subject to a linear scalar potential into the relativistic system.

In that case, Eq. (61) becomes

$$\begin{aligned}&\psi ''(r)+\frac{1}{r}\,\psi '(r)+\left[ E^2-m^2-k^2-q^2-k^2_{L}\,r^2-\frac{l^2_{eff}}{r^2}\right] \nonumber \\&\quad \psi (r)=0. \end{aligned}$$
(73)

Transforming \(s=k_{L}\,r^2\) into the above equation, we obtain [125]

$$\begin{aligned}&\psi ''(s)+\frac{1}{s}\,\psi '(s)\nonumber \\&\quad +\frac{1}{s^2}\,\left[ \frac{E^2-m^2-k^2-q^2}{4\,k_{L}}\,s-\frac{1}{4}\,s^2-\frac{l^2_{eff}}{4}\right] \nonumber \\&\psi (s)=0. \end{aligned}$$
(74)

The energy eigenvalue of the system is

$$\begin{aligned} E^{2}_{n,l}=k^2+q^2+m^2+2\,k_{L}\,\left( 2\,n+1+\frac{|l-\frac{q\,\Phi }{2\,\pi }|}{\alpha }\right) , \end{aligned}$$
(75)

where \(n=0,1,2,3,\ldots \). Equation (75) is the energy eigenvalue of a scalar field in the magnetic cosmic string background in the Kaluza–Klein theory with a linear scalar potential.

In all the above cases, we can see that there is an effective angular quantum number, \(l \rightarrow l_{eff}=\frac{1}{\alpha }\,(l-\frac{q\,\Phi }{2\,\pi })\). Therefore, the above relativistic energy eigenvalue depends on the geometric quantum phase [109]. Thus, we have that \(E_{n,{{\bar{l}}}} (\Phi +\Phi _0)=E_{n,{{\bar{l}}} \pm \tau } (\Phi )\) where, \(\Phi _0=\mp \,\frac{2\,\pi \,\alpha }{q}\,\tau \) with \(\tau =1,2,3,\ldots \) and \({{\bar{l}}}=\frac{l}{\alpha }\). This dependence of the relativistic energy eigenvalue on the geometric quantum phase gives rise to the analogoue effect to the Aharonov–Bohm effect for bound states [7, 81, 106,107,108,109].

Formula (47) suggests that, when the particle circles the string, the wave-function changes according to

$$\begin{aligned} \Psi \rightarrow \Psi '=e^{2\,i\,\pi \,l_{eff}}\,\Psi =e^{i\,\frac{2\,\pi }{\alpha }\,\left( l-\frac{q\,\Phi }{2\,\pi }\right) }\,\Psi . \end{aligned}$$
(76)

An immediate consequence of Eq. (47) is that the angular momentum operator may be redefined as

$$\begin{aligned} {\hat{l}}_{eff}=-\frac{i}{\alpha }\,\left( \partial _{\phi }-i\,\frac{q\,\Phi }{2\,\pi }\right) , \end{aligned}$$
(77)

where the additional term, \(-\frac{q\,\Phi }{2\,\pi \,\alpha }\), takes into account the Aharonov–Bohm magnetic quantum flux \(\Phi \).

4 Conclusions

In Ref. [7], authors studied the relativistic scalar particle in the cosmic string, magnetic cosmic string and cosmic dispiration background in the Kaluza–Klein theory. They solved the Klein–Gordon oscillator without any potential and obtained the relativistic energy eigenvalue and eigenfunction. In Ref. [49], the relativistic quantum dynamics of a scalar particle in (1 + 2)-dimensional space-time with topological defects subject to a linear scalar potential were studied. They solved the Klein–Gordon oscillator in the considered framework and obtained the relativistic energy eigenvalue and wave-function.

In this work, we have investigated the relativistic quantum dynamics of a scalar particle interacting with gravitational field produced by topological defects via the generalized Klein–Gordon oscillator in the cosmic string and magnetic cosmic string space-time within the Kaluza–Klein theory subject to a linear scalar potential. We have determined the manner in which the non-trivial topology due to topological defects and the magnetic quantum flux modifies the energy spectrum and wave-function of the relativistic system. We have studied the quantum dynamics of a scalar particle interacting with an external field sources, by using the five-dimensional version of the General Relativity. The quantum dynamics in the usual as well as magnetic cosmic string cases allow us to obtain the energy eigenvalue and wave-functions depending on the external parameters characterizing the background space-time, a result known by gravitational analogue of the well studied Aharonov–Bohm effect.

In Sect. 2, we have studied the relativistic quantum dynamics of a scalar particle in the background of cosmic string space-time in the Kaluza–Klein theory with a linear scalar potential. In this study, we have considered the Cornell-type potential form function \(f(r)=a\,r+\frac{b}{r}\) [59, 116] and a linear scalar potential \(S(r)=k_{L}\,r\) where, \(k_{L}\) is the linear confining parameter. Then, we have solved the generalized Klein–Gordon oscillator subject to this potential in the cosmic string background space-time in the Kaluza–Klein theory. We have obtained the bound states energy eigenvalue Eq. (24) and corresponding wave-function Eq. (25). By imposing the additional recurrence condition \(c_{n+1}=0\) in the eiegnvalue problem, for example, \(n=1\), we have evaluated the ground state energy level Eq. (27) and corresponding wave-function Eqs. (28)–(29), respectively. We have seen that gravitational field produced by topological defects and the scalar potential modifies the energy spectrum. Furthermore, we have discussed three cases 1–3 and seen that the energy eigenvalue in very special case reduces to the result obtained in [49] (for case 1) and in [7] (for case 2).

In Sect. 3, we have studied the relativistic quantum dynamics of a scalar particle in the magnetic cosmic string within the Kaluza–Klein theory with a linear scalar potential. We have chosen the same function \(f(r)=a\,r+\frac{b}{r}\) considered earlier and the linear scalar potential \(S(r)=k_{L}\,r\) into the relativistic system. We have derived the radial wave-equation of the generalized Klein–Gordon oscillator by choosing this function f(r) subject to this potential in the magnetic cosmic string in the Kaluza–Klein theory. We have obtained the bound states energy eigenvalue Eq. (58) and corresponding wave-function Eq. (59). By imposing the additional condition \(c_{n+1}=0\), for example \(n=1\), we have obtained the ground state energy level and eigenfunction. In addition, we have discussed few cases 1–3 and obtained the relativistic energy eigenvalue. We have seen in case 2 that the energy eigenvalue reduces to the result obtained in [7] in very special case. In this section, we have seen that the relativistic energy eigenvalue obtained here depends on the geometric quantum phase [109]. Thus, we have that \(E_{n,{{\bar{l}}}} (\Phi +\Phi _0)=E_{n,{{\bar{l}}} \pm \tau } (\Phi )\) where, \(\Phi _0=\mp \,\frac{2\,\pi \,\alpha }{q}\,\tau \) with \(\tau =1,2,3,\ldots \) and \({{\bar{l}}}=\frac{l}{\alpha }\). This dependence of the relativistic energy eigenvalue on the geometric quantum phase \(\Phi \) gives rise to the analogoue effect to the Aharonov–Bohm effect for bound states [81, 106,107,108,109]. Besides, even though there is no direct intractions between the particle and external fields, influence on the energy eigenvalue is due to the internal magnetic quantum flux \(\Phi \) yielding an effective angular quantum number \(l \rightarrow l_{eff}=\frac{1}{\alpha }\,(l-\frac{q\,\Phi }{2\,\pi })\). For \(\alpha \rightarrow 1\), the change in angular quantum number \(\bigtriangleup \,l=l-l_{eff}\) is directly proportional to the magnetic quantum flux \(\Phi \). So we have shown some results which are in addition to the previous results obtained in [7, 49] present many interesting effects. This is the fundamental subject in physics and the connection between these theories (gravitation and quantum mechanics) are not well understood.