1 Introduction

It is known that there are strong magnetic fields near supermassive black holes at the center of galaxies [1]. When the external magnetic fields are close to the upper limit \(10^{19}M_{\odot }/M\) Gauss, where \(M_{\odot }\) and M are the masses of the Sun and black holes, they make the black holes strongly magnetized. They can not only influence the motion of charged particles drastically but also change the background black hole geometry. They can affect the dynamics of accretion, and are helpful to explain the observed emission from the black holes.

Some examples of magnetized black hole spacetimes are Schwarzschild, Reissner–Nordström (RN), and Kerr–Newman black holes embedded in the Melvin universe [2, 3]. The vector potential for the magnetic field was given by Wald [4]. The authors of [5] provided a complicated expression of the magnetic vector potential at the magnetized Kerr–Newman solution. These magnetized black hole solutions can be obtained by applying a Harrison magnetizing transformation to the non-magnetized black hole solutions. The magnetized Kerr–Newman solution is an axisymmetric solution of Einstein–Maxwell equations because the rotation axis is aligned to the magnetic field. The magnetic fields in these types of spacetime geometries destroy the existence of a fourth constant of motion (analogous to Carter’s constant in the Kerr metric), and thus lead to the non-integrability of the magnetized black hole spacetimes. This fact was confirmed by finding chaotic motion of electrically neutral particles around the magnetized Schwarzschild black hole [6, 7]. There are imprints of a chaotic pattern in the shadow images and the lensing of the magnetized Schwarzschild black hole [8]. Self-similar fractal structures in the shadow of magnetized Kerr black hole show the chaotic scattering motion of photons near the magnetized Kerr black hole [9]. The authors of [10] studied chaos of electrically charged and neutral particles in the magnetized RN spacetime.

When the strength of an external magnetic field surrounding a black hole is much smaller than the upper limit, it does not influence the background black hole geometry. However, it can strongly affect charged particle motion in the black hole vicinity for the particle with large charge to mass ratio. Under some circumstances, the charged particle motion can be chaotic, as several authors claimed in [11,12,13,14,15,16,17,18,19]. The chaotic scatter of charged particles in the combined gravitational and magnetic fields leads to charged particle acceleration along the magnetic field lines [20]. Combining the chaotic motion with regular motion in the final part of the motion can also lead to the possibility of extreme accelerations [21].

The detection of the orbital chaotical behavior requires the use of fast and accurate numerical tools that provide reliable results. Because the motion of electrically charged and neutral particles in many curved spacetimes can be described in terms of Hamiltonian systems, the most appropriate solvers in the case of long-term integration are symplectic schemes which preserve the symplectic nature of Hamiltonian dynamics. Such Hamiltonian systems have no separation of variables or two explicitly integrable splitting terms in general. In this case, the construction and application of explicit symplectic methods are somewhat difficult. Implicit symplectic methods are always applicable to these problems. They are, e.g., the Gauss–Legendre Runge–Kutta (GLRK) method [12, 22], and slimplectic integrator [23]. These completely implicit symplectic methods have poor computational efficiency compared with combined implicit and explicit symplectic methods [24,25,26,27,28,29]. In order to further reduce the cost in the computational time, our group have recently developed a class of explicit symplectic integrators for the Hamiltonian systems of many curved spacetimes. Such algorithmic constructions are based on the Hamiltonians or time-transformed versions of the Hamiltonians split into more than two explicitly integrable pieces [30,31,32,33,34].

The detection of the orbital chaotical behavior also relies on efficient methods. The chaos detection methods are the Poincaré map, frequency map analysis of Laskar [35], Lyapunov exponents [36], fast Lyapunov indicators (FLIs) [37], smaller alignment index (SALI) [38], generalized alignment index (GALI) [39], and 0–1 test [40]. The Poincaré map is mainly applied to clearly distinguish between ordered and chaotic motion in conservative Hamiltonian systems with four-dimensional phase space. The other methods are appropriate for Hamiltonian systems with any dimensions. The SALI, GALI and FLI can much rapidly determine the chaotic or regular nature of orbits than the maximum Lyapunov exponents. Unlike the maximal Lyapunov exponent whose computation requires phase space reconstruction, the 0–1 test method can be directly applied to the time series data. The latter method is superior to the former method in the case of underlying quasiperiodic dynamics with amounts of measurement noisy data. The 0–1 test correlation method of Gottwald and Melbourne [41] significantly increases the sensitivity for characterizing the chaotic or regular nature of orbits compared with the 0–1 test regression method of Gottwald and Melbourne [40]. The 0–1 test has been applied successfully for the distinction between regular and chaotic dynamics in some Hamiltonian systems [42,43,44,45,46,47].

In the present work, we focus on the application of the 0–1 test correlation method combined an explicit symplectic integrator to a dynamical system in curved spacetime. This system relates to the motion of electrically neutral and charged particles around the magnetized Kerr–Newman black hole immersed in an external electromagnetic field [5]. For the sake of our purpose, we simply introduce the dynamical model in Sect. 2. Explicit symplectic integrator are designed in Sect. 3. In Sect. 4, we check the validity of the correlation method for testing order and chaos. The 0–1 test is used to investigate effects of the parameters on chaos in Sect. 5. Finally, the main results are concluded in Sect. 6.

2 Magnetized Kerr–Newman black holes

A magnetized Kerr–Newman black hole spacetime is introduced. Then, its corresponding Hamiltonian formulation is provided.

2.1 Black hole metric

Suppose that a rotating black hole has mass m, rotating angular momentum a, electric charge q and magnetic charge p, and is immersed in an external magnetic field B. In the Boyer–Lindquist coordinates \(x^{\alpha }=(t, r, \theta , \phi )\), such a rotating black hole can be described in terms of a Kerr–Newman-like metric [5]:

$$\begin{aligned} ds^2= & {} g_{\alpha \beta }dx^\alpha dx^\beta \nonumber \\= & {} g_{tt}dt^2+g_{rr}dr^2+g_{\theta \theta }d\theta ^2 \nonumber \\{} & {} +g_{\phi \phi }d\phi ^2+2g_{t\phi } dt d\phi , \end{aligned}$$
(1)

where the nonzero covariant metric components are

$$\begin{aligned} g_{tt}= & {} \frac{\omega ^2\varSigma \sin ^2\theta }{{H}{\mathcal {R}} ^2}-f{H}, ~~~~ g_{t\phi } = -\frac{\omega \varSigma \sin ^2\theta }{{H}{\mathcal {R}}^2}, \\ g_{rr}= & {} \frac{{H}{\mathcal {R}} ^2}{\varDelta }, ~~~~ g_{\theta \theta } = {H}{\mathcal {R}}^2, ~~~~ g_{\phi \phi } = \frac{ \varSigma \sin ^2\theta }{{H}{\mathcal {R}}^2}. \end{aligned}$$

The related notations are given as follows:

$$\begin{aligned} {\mathcal {R}}^2= & {} r^2+a^2\cos ^2\theta , \end{aligned}$$
(2)
$$\begin{aligned} \varDelta= & {} (r^2+a^2)-2{m}r+{q}^2+p^2,\end{aligned}$$
(3)
$$\begin{aligned} f= & {} \frac{{\mathcal {R}} ^2 \varDelta }{\varSigma },\end{aligned}$$
(4)
$$\begin{aligned} \varSigma= & {} (r^2+a^2)^2-a^2 \varDelta \sin ^2\theta ,\end{aligned}$$
(5)
$$\begin{aligned} {H}= & {} 1+({H_{(1)}}B+{H_{(2)}}B^2+{H_{(3)}}B^3\nonumber \\{} & {} +{H_{(4)}}B^4)/{\mathcal {R}}^2. \end{aligned}$$
(6)

Functions \({H_{(1)}}\), \({H_{(2)}}\), \({H_{(3)}}\) and \({H_{(4)}}\) are expressed as

$$\begin{aligned} {H_{(1)}}= & {} 2 a {q} r \sin ^2 \theta -2 p\left( r^2+a^2\right) \cos \theta , \end{aligned}$$
(7)
$$\begin{aligned} {H_{(2)}}= & {} \frac{1}{2}\left[ \left( r^2+a^2\right) ^2-a^2 \varDelta \sin ^2 \theta \right] \sin ^2 \theta \nonumber \\{} & {} +\frac{3}{2} \tilde{{q}}^2\left( a^2+r^2 \cos ^2 \theta \right) , \end{aligned}$$
(8)
$$\begin{aligned} {H_{(3)}}= & {} -\frac{p}{2} \left( r^4-a^4\right) \sin ^2 \theta \cos \theta \nonumber \\{} & {} +\frac{a {q}}{2 r}\left( r^2+a^2\right) ^2\left( 1+\cos ^2 \theta \right) \nonumber \\{} & {} +\frac{a{q}}{2 r} \tilde{{q}}^2\left[ \left( 2 r^2+a^2\right) \cos ^2 \theta +a^2\right] -\frac{a{q}\varDelta }{2 r} \nonumber \\{} & {} \times \left[ r^2\left( 3-\cos ^2 \theta \right) \cos ^2 \theta +a^2\left( 1+\cos ^2 \theta \right) \right] \nonumber \\{} & {} -p a^2 \varDelta \sin ^2 \theta \cos \theta \nonumber \\{} & {} -\frac{p}{2}\tilde{{q}}^2\left( r^2+a^2\right) \cos ^3 \theta , \end{aligned}$$
(9)
$$\begin{aligned} {H_{(4)}}= & {} \frac{{\mathcal {R}}^2}{16}(r^2+a^2)^2 \sin ^4 \theta +\frac{{m}r}{4}a^2(r^2+a^2) \nonumber \\{} & {} \times \sin ^6 \theta +\frac{1}{4} {m} a^2 \tilde{{q}}^2 r(\cos ^2 \theta -5) \sin ^2 \theta \cos ^2 \theta \nonumber \\{} & {} +\frac{{m}^2}{4} a^2\left[ r^2(\cos ^2 \theta -3)^2 \cos ^2 \theta +a^2(1+\cos ^2 \theta )^2\right] \nonumber \\{} & {} +\frac{\tilde{{q}}^2}{8} (r^2+a^2)(r^2+a^2+a^2 \sin ^2 \theta ) \sin ^2 \theta \cos ^2 \theta \nonumber \\{} & {} +\frac{\tilde{{q}}^4}{16} \left[ r^2 \cos ^2 \theta +a^2\left( 1+\sin ^2 \theta \right) ^2\right] \cos ^2 \theta , \end{aligned}$$
(10)

where \(\tilde{{q}}\) is given by

$$\begin{aligned} \tilde{{q}}^2 = {q}^2+p^2. \end{aligned}$$
(11)

The geometric unit systems \(C=G=1\) are given to the speed of light C and the gravitational constant G.

There is an external electromagnetic field, which corresponds to the vector potential

$$\begin{aligned} A = \varPhi _0 dt- \varPhi _3(d\phi - \omega d t). \end{aligned}$$
(12)

Functions \(\varPhi _0\), \(\varPhi _3\) and \(\omega \) have complicated expressions. \(\varPhi _0\) reads as

$$\begin{aligned} \omega= & {} \frac{1}{\varSigma }\Bigg [\left( 2 {m} r-\tilde{{q}}^2\right) a+\omega _{1} B\Bigg ] \nonumber \\{} & {} +\frac{ B^2}{\varSigma }[\omega _{2}+\omega _{3} B+\omega _{4} B^2], \end{aligned}$$
(13)

where functions \(\omega _1\), \(\omega _2\), \(\omega _3\) and \(\omega _4\) are

$$\begin{aligned} \omega _{1}= & {} -2 {q} r\left( r^2+a^2\right) +2 a p \varDelta \cos \theta , \end{aligned}$$
(14)
$$\begin{aligned} \omega _{2}= & {} -\frac{3}{2} a \tilde{{q}}^2\left( r^2+a^2+\varDelta \cos ^2 \theta \right) , \end{aligned}$$
(15)
$$\begin{aligned} \omega _{3}= & {} 4 {q} {m}^2 a^2 r+\frac{1}{2} a p \tilde{{q}}^4 \cos ^3 \theta \nonumber \\{} & {} +\frac{1}{2} {q} r\left( r^2+a^2\right) \left[ r^2-a^2+\left( r^2+3 a^2\right) \cos ^2 \theta \right] \nonumber \\{} & {} +\frac{1}{2} a p\left( r^2+a^2\right) \left[ 3 r^2+a^2-\left( r^2-a^2\right) \cos ^2 \theta \right] \cos \theta \nonumber \\{} & {} +\frac{1}{2} {q} \tilde{{q}}^2 r\left[ \left( r^2+3 a^2\right) \cos ^2 \theta -2 a^2\right] \nonumber \\{} & {} +\frac{1}{2} a p \tilde{{q}}^2\left[ 3 r^2+a^2+2 a^2 \cos ^2 \theta \right] \cos \theta \nonumber \\{} & {} -a {m} \tilde{{q}}^2\left( 2 a {q}+p r \cos ^3 \theta \right) \nonumber \\{} & {} +{q} {m}\left[ r^4-a^4+r^2\left( r^2+3 a^2\right) \sin ^2 \theta \right] \nonumber \\{} & {} -a p {m} r\left[ 2 {\mathcal {R}}^2+\left( r^2+a^2\right) \sin ^2 \theta \right] \cos \theta , \end{aligned}$$
(16)
$$\begin{aligned} \omega _{4}= & {} \frac{1}{2} a^3 {m}^3 r\left( 3+\cos ^4 \theta \right) -\frac{1}{16} a \tilde{{q}}^6 \cos ^4 \theta \nonumber \\{} & {} -\frac{1}{8} a \tilde{{q}}^4 r^2\left( 2+\sin ^2 \theta \right) \cos ^2 \theta \nonumber \\{} & {} -\frac{1}{8} a \tilde{{q}}^4a^2\left( 1+\cos ^4 \theta \right) \nonumber \\{} & {} +\frac{1}{16} a \tilde{{q}}^2 r^2 \left( r^2+a^2\right) \left( 1-6 \cos ^2 \theta +3 \cos ^4 \theta \right) \nonumber \\{} & {} -\frac{1}{16} a^3 \tilde{{q}}^2 \left( r^2+a^2\right) \left( 1+\cos ^4 \theta \right) \nonumber \\{} & {} -\frac{1}{4} a^3 {m}^2 \tilde{{q}}^2\left( 3+\cos ^4 \theta \right) +\frac{1}{8} a {m} \tilde{{q}}^4 r \cos ^4 \theta \nonumber \\{} & {} +\frac{1}{4} a {m}^2\left[ r^4\left( 3-6 \cos ^2 \theta +\cos ^4 \theta \right) \right] \nonumber \\{} & {} +\frac{1}{4} a {m}^2\left[ 2 a^2 r^2\left( 3 \sin ^2 \theta -2 \cos ^4 \theta \right) \right] \nonumber \\{} & {} +\frac{1}{4} a {m}^2\left[ -a^4\left( 1+\cos ^4 \theta \right) \right] \nonumber \\{} & {} +\frac{1}{4} a {m} \tilde{{q}}^2 r\left[ 2 r^2\left( 3-\cos ^2 \theta \right) \cos ^2 \theta \right] \nonumber \\{} & {} +\frac{1}{4} a {m} \tilde{{q}}^2 r\left[ -a^2\left( 1-3 \cos ^2 \theta -2 \cos ^4 \theta \right) \right] \nonumber \\{} & {} +\frac{1}{8} a {m} r^3 \left( r^2+a^2\right) \left( 3+6 \cos ^2 \theta -\cos ^4 \theta \right) \nonumber \\{} & {} -\frac{1}{8} a^3 {m} r \left( r^2+a^2\right) (1-6 \cos ^2 \theta \nonumber \\{} & {} -3 \cos ^4 \theta ). \end{aligned}$$
(17)

\(\varPhi _{0}\) is written as

$$\begin{aligned} \varPhi _{0}= & {} ({\varPhi _{0}^{(0)}}+{\varPhi _{0}^{(1)}} B+{\varPhi _{0}^{(2)}} B^2+{\varPhi _{0}^{(3)}} B^3)/(4 \varSigma ), \end{aligned}$$
(18)

where

$$\begin{aligned} {\varPhi _{0}^{(0)}}= & {} 4\left[ -{q} r\left( r^2+a^2\right) +a p \varDelta \cos \theta \right] ,\end{aligned}$$
(19)
$$\begin{aligned} {\varPhi _{0}^{(1)}}= & {} -6 a \tilde{{q}}^2\left( r^2+a^2+\varDelta \cos ^2 \theta \right) ,\end{aligned}$$
(20)
$$\begin{aligned} {\varPhi _{0}^{(2)}}= & {} -3 {q}\left[ (r+2 {m}) a^4-\left( r^2+4 {m} r+\varDelta \cos ^2 \theta \right) r^3\right] \nonumber \\{} & {} +3 {q}a^2\left( 6 {m} r^2+8 {m}^2 r+3 \varDelta r \cos ^2 \theta \right) \nonumber \\{} & {} -6 {q}a^2 \tilde{{q}}^2(r+2 {m}) +3 pa \varDelta \cos \theta \nonumber \\{} & {} \times \left[ 3 r^2+a^2+\left( a^2+\tilde{{q}}^2-r^2\right) \cos ^2 \theta \right] ,\end{aligned}$$
(21)
$$\begin{aligned} {\varPhi _{0}^{(3)}}= & {} -\frac{1}{2} a^3(4 a^2 {m}^2+a^2 \tilde{{q}}^2+12 {m}^2 \tilde{{q}}^2+2 \tilde{{q}}^4) \nonumber \\{} & {} - a^3{m}( a^2 r-12 {m}^2 r+2 \tilde{{q}}^2 r-12 {m} r^2) \nonumber \\{} & {} +\frac{1}{2} a {m} r^3(4 a^2+12 {m} r+\tilde{{q}}^2 r^4+6 r^2) \nonumber \\{} & {} +3 ar \varDelta \left[ 2 {m}\left( r^2+a^2\right) -\tilde{{q}}^2 r\right] \cos ^2 \theta \nonumber \\{} & {} -\frac{1}{2} a\varDelta \left[ \tilde{{q}}^4-3 \tilde{{q}}^2 r^2+2 {m} r^3\right] \cos ^4 \theta \nonumber \\{} & {} -\frac{1}{2} a^3\varDelta \left( 4 {m}^2+\tilde{{q}}^2-6 {m} r\right) \cos ^4 \theta . \end{aligned}$$
(22)

The expression of \(\varPhi _3\) is

$$\begin{aligned} \varPhi _3= & {} ({\chi _{(0)}}+{\chi _{(1)}} B+{\chi _{(2)}} B^2+{\chi _{(3)}} B^3)/({\mathcal {R}}^2 {H}), \end{aligned}$$
(23)

where

$$\begin{aligned} {\chi _{(0)}}= & {} a {q} r \sin ^2 \theta -p\left( r^2+a^2\right) \cos \theta , \end{aligned}$$
(24)
$$\begin{aligned} {\chi _{(1)}}= & {} \frac{1}{2}\left[ \varSigma \sin ^2 \theta +3 \tilde{{q}}^2\left( a^2+r^2 \cos ^2 \theta \right) \right] , \end{aligned}$$
(25)
$$\begin{aligned} {\chi _{(2)}}= & {} \frac{3}{4} a {q} r\left( r^2+a^2\right) \sin ^4 \theta \nonumber \\{} & {} +3 p \sin ^2 \theta \cos \theta \Bigg [\frac{1}{4} \left( r^2+a^2\right) ^2 - a^2 {m} r \Bigg ] \nonumber \\{} & {} +\frac{3}{2} a {q} {m} r^2\left( 3-\cos ^2 \theta \right) \cos ^2 \theta \nonumber \\{} & {} +\frac{3}{2} a^3 {q} {m} \left( 1+\cos ^2 \theta \right) \nonumber \\{} & {} -\frac{3}{4} a {q} \tilde{{q}}^2 r \sin ^2 \theta \cos ^2 \theta \nonumber \\{} & {} -\frac{3}{4} p \tilde{{q}}^2\left[ \left( r^2-a^2\right) \cos ^2 \theta +2 a^2\right] \cos \theta , \\ {\chi _{(3)}}= & {} \frac{1}{8} {\mathcal {R}}^2\left( r^2+a^2\right) ^2 \sin ^4 \theta \nonumber \\{} & {} +\frac{1}{2} a^2 {m} r\left( r^2+a^2\right) \sin ^6 \theta \nonumber \\{} & {} -\frac{1}{2} a^2 \tilde{{q}}^2 {m} r\left( 5-\cos ^2 \theta \right) \sin ^2 \theta \cos ^2 \theta \nonumber \\{} & {} +\frac{1}{2} a^2 {m}^2 r^2\left( 3-\cos ^2 \theta \right) ^2 \cos ^2 \theta \nonumber \\{} & {} +\frac{1}{2} a^4 {m}^2 \left( 1+\cos ^2 \theta \right) ^2 \nonumber \\{} & {} +\frac{1}{4} \tilde{{q}}^2\left( r^2+a^2\right) \left[ r^2+a^2+a^2 \sin ^2 \theta \right] \sin ^2 \theta \cos ^2 \theta \nonumber \\{} & {} +\frac{1}{8} \tilde{{q}}^4\left[ r^2 \cos ^2 \theta +a^2\left( 2-\cos ^2 \theta \right) ^2\right] \cos ^2 \theta . \end{aligned}$$
(26)

In a word, the four-vector potential (12) has two nonzero covariant components

$$\begin{aligned} A_t= \varPhi _0-\omega \varPhi _3, ~~~~~ A_\phi = \varPhi _3. \end{aligned}$$
(27)

If \(B=0\) and \(p=0\), the metric (1) represents the Kerr–Newman black hole. For the case of \(B \ne 0 \), the magnetic field plays an important role in the metric (1). In other words, the Kerr–Newman spacetime geometry is typically changed by the magnetic field. Only when \(q=-amB\), is the metric (1) believed to be asymptotic to the static Melvin metric [48], as was shown in [5].

2.2 Hamiltonian system

The motion of a test particle with electric charge e and mass \({m_{0}}\) around the magnetized Kerr–Newman black hole (1) is governed by the following Hamiltonian

$$\begin{aligned} {{\mathcal {H}}}= & {} \frac{1}{2{m_{0}}}g^{\alpha \beta }(p_\alpha -{e}A_\alpha )(p_\beta -{e}A_\beta ) \nonumber \\= & {} \frac{\varDelta }{2{m_{0}}{H}{\mathcal {R}}^2}p_r^2+\frac{1}{2{m_{0}}{H}{\mathcal {R}}^2}p_\theta ^2 +{{\mathcal {H}}}_1, \end{aligned}$$
(28)

where function \({{\mathcal {H}}}_1\) reads as

$$\begin{aligned} {{\mathcal {H}}}_1= & {} \frac{g^{tt}}{2{m_{0}}}[p_t -{e}(\varPhi _0-\omega \varPhi _3)]^2+\frac{g^{\phi \phi }}{2{m_{0}}}(p_\phi -{e} \varPhi _3)^2 \nonumber \\{} & {} + \frac{g^{t\phi }}{{m_{0}}}[p_t -{e}(\varPhi _0-\omega \varPhi _3)](p_\phi -{e} \varPhi _3). \end{aligned}$$
(29)

The nonzero contravariant components of the metric (1) are

$$\begin{aligned} g^{tt}= & {} \frac{g_{\phi \phi }}{g_{tt}g_{\phi \phi }-g^2_{t\phi }}=-\frac{1}{f{H}},\nonumber \\ g^{\phi \phi }= & {} \frac{g_{tt}}{g_{tt}g_{\phi \phi }-g^2_{t\phi }} =\frac{f{H}^2{\mathcal {R}} ^2-\omega ^2\varSigma \sin ^2\theta }{f{H}\varSigma \sin ^2\theta }, \nonumber \\ g^{t\phi }= & {} \frac{-g_{t\phi }}{g_{tt}g_{\phi \phi }-g^2_{t\phi }}=-\frac{\omega }{f{H}}. \nonumber \end{aligned}$$
(30)

The covariant 4-momentum \(p_{\alpha }=(p_t,p_r,p_\theta ,p_\phi )\) is defined by

$$\begin{aligned} p_{\alpha }=\frac{\partial {\mathcal {L}}}{\partial {\dot{x}}^{\alpha }} +{e}A_\alpha , \end{aligned}$$
(31)

where the 4-velocity \({\dot{x}}^{\alpha }=dx^{\alpha }/d\tau \) is a derivative of the coordinate \(x^{\alpha }\) with respect to the proper time \(\tau \), and the Lagrangian system is

$$\begin{aligned} {\mathcal {L}}=\frac{{m_{0}}}{2}\frac{ds^2}{d\tau ^2}=\frac{{m_{0}}}{2} g_{\alpha \beta }{\dot{x}}^{\alpha }{\dot{x}}^{\beta }. \end{aligned}$$
(32)

This 4-momentum is also determined by a set of canonical equations for the Hamiltonian (29)

$$\begin{aligned} {\dot{x}}^{\alpha }=\frac{\partial {{\mathcal {H}}}}{\partial p_{\alpha }} =\frac{1}{{m_{0}}}g^{\alpha \beta }(p_\beta -{e}A_\beta ). \end{aligned}$$
(33)

Another set of canonical equations for the Hamiltonian (29) are

$$\begin{aligned} {\dot{p}}_{\alpha }=-\frac{\partial {{\mathcal {H}}}}{\partial x^{\alpha }}. \end{aligned}$$
(34)

This shows that \(p_t\) and \(p_\phi \) are constants of motion, which correspond to the energy of the particle \(E=- p_t\) and the angular momentum of the particle \(L=p_\phi \). They are

$$\begin{aligned} {\dot{t}}= & {} -\frac{g^{tt}}{{m_{0}}}[E +{e}(\varPhi _0-\omega \varPhi _3)] \nonumber \\{} & {} + \frac{g^{t\phi }}{{m_{0}}}(L -{e} \varPhi _3),\end{aligned}$$
(35)
$$\begin{aligned} {\dot{\phi }}= & {} \frac{g^{\phi \phi }}{{m_{0}}}(L -{e} \varPhi _3) \nonumber \\{} & {} - \frac{g^{t\phi }}{{m_{0}}}[E +{e}(\varPhi _0-\omega \varPhi _3)]. \end{aligned}$$
(36)

In this case, the Hamiltonian system (29) is axially symmetric, and also stationary. In other words, the existence of the two constants of motion is attributed to these background symmetries. A third constant of motion is the conserved Hamiltonian

$$\begin{aligned} {{\mathcal {H}}}=-\frac{{m_{0}}}{2} \end{aligned}$$
(37)

for a time-like geodesic orbit because the 4-velocity satisfies the relation \(g_{\alpha \beta }{\dot{x}}^{\alpha }{\dot{x}}^{\beta }=-1\). In fact, the third constant is due to the rest mass of the particle. There is no fourth constant of motion in the Hamiltonian system (29) due to the strong external magnetic field changing the Kerr–Newman spacetime structure. This fact was similarly shown by finding chaos of neutral particles in the magnetized Schwarzschild spacetime [6, 7] and magnetized Reissner–Nordström spacetime [10].

For simplicity, the Hamiltonian system (29) uses dimensionless operations. Namely, scale transformations are given to the related variables and parameters: \(r\rightarrow r{m}\), \(t\rightarrow t{m}\), \(\tau \rightarrow \tau {m}\), \({q}\rightarrow {q}{m}\), \(p\rightarrow p{m}\), \(a\rightarrow a{m}\), \({{\mathcal {H}}} \rightarrow {m_{0}}{{\mathcal {H}}}\), \(E \rightarrow {m_{0}}E\), \(p_r \rightarrow {m_{0}}p_r\), \(p_\theta \rightarrow {m_{0}}{m}p_\theta \), \(L \rightarrow {m_{0}}{m}L\), \({e} \rightarrow {m_{0}}{e}\), and \(B \rightarrow B/{m}\). In this case, \({m_{0}}\) and m appear as mass factors in the above equations and can be eliminated.

3 Explicit symplectic integrators

The Hamiltonian system (29) cannot be split into more than two integrable terms with analytical solutions as explicit functions of the proper time. However, its appropriate time transformation Hamiltonian can, as the time transformation Hamiltonians for the Kerr spacetime and some other curved spacetimes mentioned in the papers [10, 33, 34] can. In this way, explicit symplectic integrators are easily available for such time transformation Hamiltonians. In what follows, we introduce how to implement explicit symplectic methods for the Hamiltonian (29).

3.1 Construction of numerical schemes

The phase space \((r,\theta ,p_r,p_\theta )\) of Hamiltonian (29) is extended to a new phase space \((r,\theta ,p_r,p_\theta ,p_0,q_0)\), where \(q_0=\tau \) and \(p_0=-{{\mathcal {H}}}=0.5\) are new coordinate and momentum, respectively. The Hamiltonian in the expanded phase space is

$$\begin{aligned} {\mathcal {H}}^* ={{\mathcal {H}}} +p_0. \end{aligned}$$
(38)

It is clear that \({\mathcal {H}}^*=0\) for any proper time. Taking the time transformation

$$\begin{aligned} d\tau = g(r,\theta )d w \end{aligned}$$
(39)

with the time transformation function

$$\begin{aligned} g(r,\theta )=\frac{F {\mathcal {R}} ^2}{r^2}, \end{aligned}$$
(40)

we have a time transformation Hamiltonian

$$\begin{aligned} {\mathcal {J}} = g {\mathcal {H}}^*. \end{aligned}$$
(41)

Obviously, \({\mathcal {J}} =0\) for any new time w.

The time transformation Hamiltonian has five splitting pieces

$$\begin{aligned} {\mathcal {J}} ={\mathcal {J}}_1+{\mathcal {J}}_2+{\mathcal {J}}_3+{\mathcal {J}}_4+{\mathcal {J}}_5, \end{aligned}$$
(42)

where these sub-Hamiltonians are

$$\begin{aligned} {\mathcal {J}}_1= & {} g(r,\theta )({{\mathcal {H}}}_1+p_0), \end{aligned}$$
(43)
$$\begin{aligned} {\mathcal {J}}_2= & {} \frac{1}{2}p_r^2, \end{aligned}$$
(44)
$$\begin{aligned} {\mathcal {J}}_3= & {} -\frac{1}{r}p_r^2, \end{aligned}$$
(45)
$$\begin{aligned} {\mathcal {J}}_4= & {} \frac{p_\theta ^2}{2r^2}, \end{aligned}$$
(46)
$$\begin{aligned} {\mathcal {J}}_5= & {} \frac{1}{2r^2}(a^2+p^2+{q}^2)p_r^2. \end{aligned}$$
(47)

It is easy to check that each of the sub-Hamiltonians is analytically solvable, and its analytical solutions are all explicit functions of the new time w.

The five sub-Hamiltonians correspond to solvers \({\mathfrak {T}} _1\), \({\mathfrak {T}} _2\), \({\mathfrak {T}} _3\), \({\mathfrak {T}} _4\), and \({\mathfrak {T}} _5\) in sequence. Setting h as a time step, we obtain two first-order operators

$$\begin{aligned} \varXi (h)= & {} {\mathfrak {T}}_1(h)\times {\mathfrak {T}}_2(h)\times {\mathfrak {T}}_3(h)\nonumber \\{} & {} \times {\mathfrak {T}}_4(h)\times {\mathfrak {T}}_5(h), \end{aligned}$$
(48)
$$\begin{aligned} \varXi ^{*} (h)= & {} {\mathfrak {T}}_5(h)\times {\mathfrak {T}}_4(h)\times {\mathfrak {T}}_3(h)\nonumber \\{} & {} \times {\mathfrak {T}}_2(h)\times {\mathfrak {T}}_1(h). \end{aligned}$$
(49)

Symmetrically combining the two operators, we have a second-order explicit symplectic method for solving the Hamiltonian (42)

$$\begin{aligned} S_2(h)=\varXi ^{*}\Bigg (\frac{h}{2}\Bigg )\times \varXi \Bigg (\frac{h}{2}\Bigg ). \end{aligned}$$
(50)

Symmetrically combining three second-order explicit symplectic methods, we obtain a fourth-order method [49]

$$\begin{aligned} S_4(h)=S_2(\gamma h)\times S_2(\delta h)\times S_2(\gamma h), \end{aligned}$$
(51)

where \(\gamma =1/(2-\root 3 \of {2}) \) and \(\delta =1-2\gamma \). The Hamiltonian (42) is suitable for the application of an optimized fourth-order partitioned Runge–Kutta explicit symplectic integrator [50, 51]

$$\begin{aligned} PRK_64(h)= & {} \varXi ^{*} (\alpha _{12} h)\times \varXi (\alpha _{11} h)\times \cdots \nonumber \\{} & {} \times \varXi ^{*} (\alpha _2 h) \times \varXi (\alpha _1 h), \end{aligned}$$
(52)

where the time coefficients are listed in [50, 51] as follows:

$$\begin{aligned} \alpha _1 = \alpha _{12}= & {} 0.079203696431196, \\ \alpha _2 = \alpha _{11}= & {} 0.130311410182166, \\ \alpha _3 = \alpha _{10}= & {} 0.222861495867608, \\ \alpha _4 = \alpha _9= & {} -0.366713269047426, \\ \alpha _5 = \alpha _8= & {} 0.324648188689706, \\ \alpha _6 = \alpha _7= & {} 0.109688477876750. \end{aligned}$$

In short, \(S_2\), \(S_4\) and \(PRK_64\) are the explicit symplectic integrators we have designed for the time transformation Hamiltonian (42). They adopt fixed time steps for the new time w, but seem to employ variable ones for the proper time \(\tau \).

3.2 Numerical tests

The time step \(h=1\) is used in the new time. The parameters are given by the magnetic field strength \(B=4\times 10^{-4}\), black hole electric charge \({q}=0.6\), black hole rotating angular momentum \(a=0.1\), particle electric charge \({e}=0.5\), particle angular momentum \(L=4.6\), and particle energy \(E=0.998\). The initial conditions are the angle \(\theta =\pi /2\), \(p_r=0\), and \(p_{\theta }>0\) determined by Eq. (37). The initial separations are \(r=25\) for Orbit 1, and \(r=85\) for Orbit 2.

In Fig. 1a, b, the second-order method \(S_2\) and fourth-order method \(S_4\) solving the two tested orbits exhibit good long-term performance. There is no secular drift with the new time w in the errors of the time transformation Hamiltonian (41). In this sense, the two methods have one of the advantages which symplectic methods own. However, the method \(PRK_64\) gives secular drift to the Hamiltonian errors due to the rapid accumulation of roundoff errors.

Fig. 1
figure 1

a Errors of the Hamiltonian \({\mathcal {J}}\) for the three symplectic integrators acting on Orbit 1. b Same as a but Orbit 1 replaced with Orbit 2. The time step is \(h=1\). The two orbits have the dynamical parameters, which involve the magnetic field strength \(B=4\times 10^{-4}\), the black hole’s electric charge \({q}=0.6\), magnetic charge \(p=0.05\) and spin \(a=0.1\), and the particle’s electric charge \({e}=0.5\), energy \(E=0.998\) and angular momentum \(L=4.6\). They have the initial conditions \(p_r=0\) and \(\theta =\pi /2\). The initial separations are \(r=25\) for Orbit 1 and \(r=85\) for Orbit 2. The initial values \(p_\theta >0\) are given by Eq. (11). The second-order method \(S_2\) and fourth-order method \(S_4\) show no secular drift in the errors. c Poincaré sections in the \(r-p_r\) plane. Orbit 1 is regular, while Orbit 2 is chaotic

When \(r\gg 2\), \(g(r,\theta )\approx 1\) in Eq. (40). Thus, \(\tau \approx w\) in Eq. (39). This result is also confirmed numerically. In fact, the new time w uses a fixed step size, and the proper time \(\tau \) almost adopts the same fixed step size. In other words, the proper time step is not adaptive if the new time step is fixed.

The phase space structures of Orbits 1 and 2 are plotted in Fig. 1c regarding the Poincaré map in the two-dimensional \(r-p_r\) plane. In fact, the structures consist of many intersections of the particles’ trajectories with the surface of section \(\theta =\pi /2\) and \(p_\theta >0\). The distribution of the points from an orbit in the Poincaré map can show the regularity or chaoticity of the motion. Because Orbit 1 is a closed curve, it is regular nonchaotic. Orbit 2 has many randomly distributed points and therefore is irregular or chaotic. Seen from Fig. 1c, the accuracies in the energy conservation of the algorithms \(S_2\) and \(S_4\) for the regular orbit 1 are almost the same as those for the chaotic orbit 2. This fact shows that the algorithms \(S_2\) and \(S_4\) well conserve the energy irrespective of whether the tested orbit is regular or chaotic.

Although the algorithm \(S_4\) is three orders of magnitude smaller than the method \(S_2\) in the energy accuracy, the former is more computationally demanding than the latter. In addition, the method \(S_2\) reaches an order of \(10^{-6}\) as an acceptable accuracy. Thus, the method \(S_2\) is used in the later computations

4 Correlation method on the 0–1 test for chaos

Apart from the technique of Poincaré map, there are several methods finding chaos, such as the 0–1 test. Considering that the mean square displacements have different growth rates for nonchaotic and chaotic dynamics, Gottwald and Melbourne [40] used a regression method to establish a binary test yielding 0 or 1 for distinguishing between the two cases. The method for testing chaos is superior to tangent space methods for computing maximal Lyapunov exponents [43]. Gottwald and Melbourne proposed computing the correlation coefficient as the correlation of the mean square displacement with time [41]. The correlation method significantly increases its sensitivity for detecting weakly chaotic from regular dynamics, compared with the regression method.

4.1 Description of the correlation method

Let \(\psi (j)\) for \(j=1,2,3,\ldots ,n_1\) be a set of observation data from a deterministic dynamical system. For a given parameter \(c\in (0,\pi )\), two translation variables are defined as

$$\begin{aligned} P_c(n_1)= & {} \sum _{j= 1}^{n_1} \psi (j)\cos (cj), \end{aligned}$$
(53)
$$\begin{aligned} Q_c(n_1)= & {} \sum _{j= 1}^{n_1} \psi (j)\sin (cj), \end{aligned}$$
(54)

where \(n_1=1,2,\ldots ,N_1\). Then, the mean square displacement of the translation variables \(P_c\) and \(Q_c\) is given by

$$\begin{aligned} M_c(n_2)= & {} \lim _{N_2 \rightarrow \infty } \frac{1}{N_2-n_2}\sum _{j = 1}^{N_2-n_2} [P_c(j+n_2)-P_c(j)]^2 \nonumber \\{} & {} +[Q_c(j+n_2)-Q_c(j)]^2. \end{aligned}$$
(55)

In principle, \(n_2\le {\tilde{n}}\ll N_2\) is required, but \({\tilde{n}} \le N_2/10\) is acceptable in practical computations.

The mean square displacement \(M_c(n_2)\) is modified as

$$\begin{aligned} D_c(n_2)= & {} M_c(n_2) -V_{osc}(c,n_2), \end{aligned}$$
(56)

where \(V_{osc}(c,n_2)\) is an oscillatory term with an explicit expression

$$\begin{aligned} V_{osc}(c,n_2)= & {} \varLambda ^2 \frac{1-\cos (cn_2)}{1-\cos (c)}, \end{aligned}$$
(57)
$$\begin{aligned} \varLambda= & {} \lim _{N_2 \rightarrow \infty } \frac{1}{N_2}\sum _{j = 1}^{N_2}\psi (j). \end{aligned}$$
(58)

If \(M_c(n_2)\) has a linear term, then \(D_c(n_2)\) remains the linear term of \(M_c(n_2)\), but eliminates the oscillatory term of \(M_c(n_2)\). In fact, the asymptotic growth rate of \(D_c(n_2)\) with time number \(n_2\) is the same as that of \(M_c(n_2)\).

Suppose that the vectors \(\xi =(1,2,...,{\tilde{n}})\) and \(\varDelta _c =(D_c(1),D_c(2),...,D_c({\tilde{n}}))\). Their mean values are

$$\begin{aligned} {\bar{\xi }}= & {} \frac{1}{{\tilde{n}}}\sum ^{{\tilde{n}}}_{j=1} j=\frac{1}{2}({\tilde{n}}+1), \\ {\bar{\varDelta }}_c= & {} \frac{1}{{\tilde{n}}}\sum ^{{\tilde{n}}}_{j=1}D_c(j). \end{aligned}$$

Variances on the two vectors are

$$\begin{aligned} var(\xi )= & {} \frac{1}{{\tilde{n}}}\sum ^{{\tilde{n}}}_{j=1} (j-{\bar{\xi }})^2, \end{aligned}$$
(59)
$$\begin{aligned} var(\varDelta _c)= & {} \frac{1}{{\tilde{n}}}\sum ^{{\tilde{n}}}_{j=1} (D_c(j)-{\bar{\varDelta }}_c)^2. \end{aligned}$$
(60)

A covariance of \(\xi \) and \(\varDelta _c\) is

$$\begin{aligned} cov(\xi ,\varDelta _c)= \frac{1}{{\tilde{n}}}\sum ^{{\tilde{n}}}_{j=1} (j-{\bar{\xi }})(D_c(j)-{\bar{\varDelta }}_c). \end{aligned}$$
(61)

Now, the correlation coefficient of the two vectors is computed by

$$\begin{aligned} K_c = corr(\xi ,\varDelta _c) =\frac{cov(\xi ,\varDelta _c)}{\sqrt{var(\xi )var(\varDelta _c)}}. \end{aligned}$$
(62)

From a statistical viewpoint, the mean square displacement \(D_c(n_2)\) is bounded for any number of observation data \(n_2\) associated with time in the case of nonchaotic dynamics, whereas grows linearly in the related time number \(n_2\) for chaotic dynamics. Thus, \(K_c = 0\) for regular dynamics and \(K_c = 1\) for chaotic dynamics. In other words, \(K_c = 0\) indicates the presence of regular dynamics, while \(K_c = 1\) indicates the presence of chaotic dynamics.

Fig. 2
figure 2

a, d The visuals of two translation variables \(P_c\) and \(Q_c\) with the values of \(K_c\) for Orbits 1 and 2. b The largest Lyapunov exponents \(\lambda \) for Orbits 1 and 2. e Fast Lyapunov indicators (FLIs) for Orbits 1 and 2. c, f Power spectra for Orbits 1 and 2. The 0–1 binary test correlation method is consistent with the techniques of Lyapunov exponents, FLIs and power spectra in distinguishing between regular and chaotic dynamics of the two orbits

\(K_c\) is the 0–1 chaos test from the correlation method, which was introduced by Gottwald and Melbourne [41]. There is a minor difference between the description of \(K_c\) in Eq. (62) and that in [41]. That is, \(n_1\) and \(n_2\) were taken as n, and \(N_1\) and \(N_2\) were written as N in [41]. In fact, a larger value \(N_2\) can cause \(K_c\) to much accurately determine regular or chaotic dynamics. However, we do not need such many points \((P_c,Q_c)\) when the visual of \(P_c\) and \(Q_c\) is used to underly regular or chaotic dynamics. This is why \(N_1<N_2\) is required. A note is worthwhile on the choice of c. In fact, the value of \(K_c\) depends on the choice of c. Most values of \(c\in (0,\pi )\) can make the values of \(K_c\) yield consistent results in signifying nonchaotic or chaotic dynamics. However, isolated values of c lead to the occurrence of resonances and then the values of \(K_c\) do not signify the actual dynamics. In this case, the authors of [41] suggested that the median of the computed values of \(K_c\) rather than the mean of the computed values of \(K_c\) should be used against outliers associated with resonances. A theoretical justification of the 0–1 test for chaos was given by Gottwald and Melbourne [42].

4.2 Validity of the correlation method for testing order and chaos

In our present computations, an orbit is integrated until the integration time \(w=10^{7}\). For computations of data in a plot on \(P_c\) and \(Q_c\), we take \(c=1.7\), \(N_1=4500\), and \(\psi (j)=r_j\), where j corresponds to the time \(w_j=j\times w/N_1\). When each value of \(K_c\) is computed, we take \(N_2=10{,}000\), and give 100 values to c, i.e. \(c_i=i\times \pi /100\) (\(i=1,2,\ldots ,100)\). For each orbit, the 100 values of c correspond to those of \(K_c\). The median of the 100 values of \(K_c\) is taken as the value of \(K_c\) for this orbit. In this way, the values of \(K_c\) for Orbits 1 and 2 in Fig. 1 can be obtained as follows: \(K_c=0.00804 \approx 0\) for Orbits 1 in Fig. 2a, and \(K_c=0.98801 \approx 1\) for Orbits 2 in Fig. 2d. The two values 0 and 1 of \(K_c\) clearly characterize the regularity of Orbits 1 and the chaoticity of Orbits 2, respectively. The results can also be shown from visual plots on the evolution behavior of \(P_c\) and \(Q_c\). The points (\(P_c\), \(Q_c\)) form a bounded region such as a ring surface for underlying regular dynamics in Fig. 2a, but behave as an asymptotic unbounded Brownian motion for underlying chaotic dynamics in Fig. 2d.

Fig. 3
figure 3

a Poincaré map for a three-island orbit with the parameters \({e}=0\), \(B=5\times 10^{-4}\), \(E=0.9967\), \(L=4.7\), \(a=p=0.1\), \({q}=0.5\), and the initial separation \(r=50\). b Poincaré map for a five-island orbit with the parameters \({e}=0.5\), \(B=5\times 10^{-4}\), \(E=0.998\), \(L=4.5\), \(a=0\), \(p=0.1\), \({q}=0.7\), and the initial separation \(r=60\). c Poincaré map for a seven-island orbit with the parameters \({e}=-0.5\), \(B=4\times 10^{-4}\), \(E=0.998\), \(L=5.7\), \(a=0\), \(p=0.1\), \({q}=0.2\), and the initial separation \(r=60\). df The visuals of \(P_c\) and \(Q_c\) with the values of \(K_c\), which respectively correspond to ac

The regular and chaotic dynamics of Orbits 1 and 2 described by the 0–1 binary test and the visuals of \(P_c\) and \(Q_c\) is consistent with that given by the method of Poincaré map in Fig. 1c. It is also confirmed by the largest Lyapunov exponents in Fig. 2c, fast Lyapunov indicators (FLIs) in Fig. 2e, power spectra in Fig. 2c, f. There are tangent space methods and direct methods for computing the maximal Lyapunov exponents. The direct methods for computing the maximal Lyapunov exponents directly measure the divergence of nearby trajectories with time [52]. They were modified in [53, 54] as

$$\begin{aligned} \lambda =\lim _{w \rightarrow \infty } \frac{1}{w} \ln \frac{d(w)}{d(0)}, \end{aligned}$$
(63)

where d(0) and d(w) represent the proper distances between the nearby trajectories at time w and the initial time, respectively. A bounded orbit is chaotic if \(\lambda >0\), while it is regular if \(\lambda \le 0\). The FLIs, which use completely different time rates of the lengths of deviation vectors to distinguish between the ordered and chaotic two cases, are from modified versions of the Lyapunov exponents. The tangent space methods for the FLIs were introduced by Froeschlé [37] and Froeschlé and Lega [55]. The direct method for computing the FLI was given in [54] by

$$\begin{aligned} FLI=\log _{10} \frac{d(w)}{d(0)}. \end{aligned}$$
(64)

An exponential growth of the FLI with time \(\log _{10}w\) describes chaotic dynamics of a bounded orbit, but an algebraical growth shows regular dynamics. The FLIs are a faster and more sensitive tool to detect chaos from order than the Lyapunov exponents. The power spectrum has discrete peaks at the harmonics and subharmonics for a periodic or quasiperiodic system, while has a broadband nature for a chaotic signal. These characteristics can be used to distinguish periodic, quasiperiodic and chaotic motions.

Besides regular Orbit 1 as a KAM (Kolmogorov–Arnold–Moser) torus in Fig. 1, some regular trajectories consisting of several distinct islands are used to evaluate the performance of \(P_c\), \(Q_c\) and \(K_c\) in Fig. 3. The appearance of such islands in each trajectory means the existence of resonance. The values of \(K_c\) are less than 0.12, and show the regular dynamics of the three resonant orbits. For the three-island orbit and seven-island orbit produced through the Poincaré surface of section in Fig. 3a, c, their corresponding visuals of \(P_c\) and \(Q_c\) in Fig. 3d, f are similar to the visual for the single-torus orbit 1 in Fig. 2a. The visual of \(P_c\) and \(Q_c\) for the five-island orbit in Fig. 3b is a torus surface in Fig. 3e. These results show that the visual shapes of \(P_c\) and \(Q_c\) for such resonant orbits have no typically different characteristics, compared with those for these single-torus orbits.

Fig. 4
figure 4

ac The visuals of \(P_c\) and \(Q_c\) with the values of \(K_c\) for three magnetic field strengths \(B=1.5\times 10^{-4}\), \(B=3\times 10^{-4}\), and \(B=7\times 10^{-4}\). The other parameters are \(E=0.998\), \(L=4.5\), \(a=p=0.1\), \({q}=0.5\) and \(e=0\). The initial separation is \(r=60\). d FLIs for the three values of B. The extent of chaos is typically enhanced with the magnetic field strength increasing

5 Effects of the parameters on chaos

In this section, the impacts of the parameters on a transition from regularity to chaos are considered. At first, we detect chaos from order by tracing the visual shapes of (\(P_c\), \(Q_c\)) and the values of \(K_c\). Then, we find chaos through the dependence of \(K_c\) on varying one or two parameters.

Fig. 5
figure 5

ac Poincaré sections for three energies \(E=0.996\), \(E=0.9967\) and \(E=0.998\). The other parameters are \({e}=0\), \(B=5\times 10^{-4}\), \(L=4.7\), \(a=p=0.1\), \({q}=0.5\), and the initial separation is \(r=65\). df The visuals of \(P_c\) and \(Q_c\) with the values of \(K_c\), which correspond to ac. The extent of chaos typically increases with the energy increasing

5.1 Finding chaos by the evolution behavior of \(P_c\), \(Q_c\) and \(K_c\)

Let us take the parameters \(E=0.998\), \(L=4.5\), \(a=p=0.1\), \({q}=0.5\) and \({e}=0\). The initial separation is \(r=60\). Seen the visuals of \(P_c\) and \(Q_c\) from Fig. 4, the magnetic field strengths \(B=1.5\times 10^{-4}\), \(3\times 10^{-4}\) and \(7\times 10^{-4}\) correspond to order, chaos and chaos, respectively. Their corresponding values of \(K_c=0.13989\), 0.99389 and 0.99598 also show these dynamical behaviors. In the case of the particle without electric charge, chaos can be present because the magnetic field acts as a gravitational effect destroying the integrability of the Kerr–Newman spacetime. In fact, the onset of chaos of neutral particles or photons moving around the magnetized Schwarzschild, Reissner–Nordström, and Kerr black holes was reported in [6,7,8,9,10]. The FLIs with the values of \(K_c\) display that chaos is stronger for \(B=7\times 10^{-4}\) than for \(B=3\times 10^{-4}\). The values of \(K_c\) and the FLIs seem to show that the extent of chaos increases with the magnetic field strength increasing.

Fig. 6
figure 6

ac Poincaré sections for three angular momenta \(L=4.5\), \(E=5.3\) and \(E=6.2\). The other parameters are \({e}=0\), \(E=0.998\), \(a=p=0.1\), \({q}=0.5\) and \(B=4.5\times 10^{-4}\), and the initial separation is \(r=50\). df The visuals of \(P_c\) and \(Q_c\) with the values of \(K_c\), which correspond to ac. An increase of the angular momentum weakens the degree of chaos

Fig. 7
figure 7

ac Poincaré sections for three values of the black hole spins \(a=0.08\), \(a=0.5\) and \(a=0.9\). The other parameters are \({e}=0\), \(B=4\times 10^{-4}\), \(E=0.998\), \(L=5.2\), \(p=0.1\), \({q}=0.5\), and the initial separation is \(r=30\). df The visuals of \(P_c\) and \(Q_c\) with the values of \(K_c\), which correspond to ac. An increase of the black hole spin weakens the degree of chaos

Fig. 8
figure 8

ac The visuals of \(P_c\) and \(Q_c\) with the values of \(K_c\) for three values of the particle charges \({e}=0.2\), \({e}=0.5\), and \({e}=0.9\). The other parameters are \(B=4\times 10^{-4}\), \(E=0.998\), \(L=5.7\) and \(a=p={q}=0.1\). The initial separation is \(r=40\). d FLIs for the three values of e. The extent of chaos is typically enhanced with the particle charge increasing

Fig. 9
figure 9

The visuals of \(P_c\) and \(Q_c\) with the values of \(K_c\) for three values of the black hole charges \({q}=0.2\), \({q}=0.5\) and \({q}=0.8\). The other parameters are \({e}=0\), \(E=0.998\), \(L=4.5\), \(a=p=0.1\), and the initial separation is \(r=30\). The magnetic field strengths are \(B=2\times 10^{-4}\) corresponding to the regular dynamics in panels ac, and \(B=7\times 10^{-4}\) corresponding to the chaotic dynamics in panels df

Fig. 10
figure 10

ac Poincaré sections for three values of the black hole electric charges \({q}=0.2\), \({q}=0.6\) and \({q}=0.9\). The other parameters are \({e}=0.5\), \(B=5\times 10^{-4}\), \(E=0.998\), \(L=4.5\), \(a=p=0.1\), and the initial separation is \(r=30\). df The visuals of \(P_c\) and \(Q_c\) with the values of \(K_c\), which correspond to ac. An increase of the black hole electric charge weakens the degree of chaos

Fig. 11
figure 11

ae The visuals of \(P_c\) and \(Q_c\) with the values of \(K_c\) for three values of the black hole electric charges \({q}=0.2\), \({q}=0.45\) and \({q}=0.8\). The other parameters are \(B=4\times 10^{-4}\), \(E=0.998\), \(L=5.7\), \(a=p=0.1\), and the initial separation is \(r=40\). The particles have negative charges \({e}=-0.8\) in panels ac, \({e}=-0.4\) in panel d, and \({e}=-0.2\) in panel e. f FLIs for the five cases

Fig. 12
figure 12

ad The visuals of \(P_c\) and \(Q_c\) with the values of \(K_c\) and FLIs for three values of the black hole magnetic charges p. The other parameters are \({e}=0\), \(B=4.5\times 10^{-4}\), \(E=0.998\), \(L=6.5\), \(a=0.1\), and the initial separation is \(r=45\). eh Same as ad, but the other parameter values are \({e}=-0.5\), \(B=3.5\times 10^{-4}\), \(E=0.998\), \(L=4.4\), \(a=q=0.1\), and the initial separation is \(r=30\). il Same as eh, but the parameter values are \({e}=0.5\) and \(L=6\)

Fig. 13
figure 13

The dependence of \(K_c\) on varying one parameter. a The parameter is B, and the other parameter values are \({e}=0\), \(E=0.998\), \(L=4.5\), \(a=p=0.1\) and \({q}=0.5\). The initial radius is \(r=35\). b The parameter is a, and the other parameter values are \({e}=0.5\), \(B=4\times 10^{-4}\), \(E=0.998\), \(L=4.5\), \(p=0.1\) and \({q}=0.5\). The initial separation is \(r=30\). c The parameter is e, and the other parameter values are \(B=4\times 10^{-4}\), \(E=0.998\), \(L=5.7\) and \(a=p={q}=0.1\). The initial separation is \(r=40\). d The parameter is p, and the other parameter values are \({e}=0\), \(B=4.5\times 10^{-4}\), \(E=0.998\), \(a=0.1\) and \({q}=0.5\). Two values of \(L=4.0\) and \(L=6.5\) are taken, and the initial separation radius is \(r=45\)

Fig. 14
figure 14

The dependence of \(K_c\) on two varying parameters for the case of electrically neutral particles. The magnetic charge \(p=0.1\) and spin \(a=0.1\) are adopted. a The two parameters relate to the black hole charge q and magnetic field strength B. There are the particle energy \(E=0.998\), angular momentum \(L=4.5\), and initial separation \(r=30\). b The two parameters are the black hole charge q and particle energy E. There are the magnetic field strength \(B=5\times 10^{-4}\), angular momentum \(L=4.7\) and initial separation radius \(r=30\). c The two parameters deal with the black hole charge q and angular momentum L. There are the particle energy \(E=0.998\), magnetic field strength \(B=4.5\times 10^{-4}\), and initial radius \(r=45\)

Fig. 15
figure 15

The dependence of \(K_c\) on two varying parameters for the case of electrically negative or positive particles. a The two parameters relate to q and \({e}<0\). There are \(B=4\times 10^{-4}\), \(E=0.998\), \(L=5.7\), \(a=p=0.1\), and the initial separation \(r=40\). b Same as a but \({e}>0\). There are \(B=3.5\times 10^{-4}\), \(E=0.998\), \(L=5.6\), \(a=p=0.1\), and the initial separation \(r=30\). c The two parameters relate to p and \({e}<0\). There are \(B=3.5\times 10^{-4}\), \(E=0.998\), \(L=4.4\), \(a=0.1\), \({q}=0.1\), and the initial separation \(r=30\). d Same as c but \({e}>0\). There are \(B=3.5\times 10^{-4}\), \(E=0.998\), \(L=6\), \(a=0.1\), \({q}=0.1\), and the initial separation \(r=30\)

Now, we consider three distinct energies \(E=0.996\), 0.9967 and 0.998 in Fig. 5, where the other parameters are \(B=5\times 10^{-4}\), \(L=4.7\), \(a=p=0.1\), \({q}=0.5\) and \({e}=0\), and the initial separation is \(r=65\). The Poincaré surfaces of section describe that the three energies correspond to a regular KAM torus, weak chaos and strong chaos. These regular and chaotic dynamical behaviors can also be seen from the visuals of (\(P_c\), \(Q_c\)). The values of \(K_c=0.1922\), 0.98038, 0.99668 tell us a path for the transition from regularity to weak and strong chaos.

Figure 6 plots the section surfaces, visuals of \((P_c, Q_c)\) and values of \(K_c\) for three different particle angular momenta \(L=4.5\), 5.3 and 6.2. The other parameters are \(B=4.5\times 10^{-4}\), \(E=0.998\), \(a=p=0.1\), \({q}=0.5\) and \({e}=0\), and the initial separation is \(r=50\). When the three values of the angular momentum are changed from small to large, strongly chaotic dynamics, weakly chaotic dynamics and regular dynamics occur, as shown via the section surfaces and values of \(K_c\). The extent of chaos is weakened with the particle angular momentum increasing under some circumstances. This result is also suitable for an increase of the black hole spin a in Fig. 7. However, chaos becomes stronger as the particle positive charge increases in Fig. 8.

To investigate the effects of the black hole electric charges q on the dynamical behavior, we consider three cases of the particle charge e \(=\), >, or < 0. For the case of \({e}=0\) in Fig. 9, the visuals of \((P_c, Q_c)\) and values of \(K_c\) show that the black hole electric charges \({q}=\) 0.2, 0.5 and 0.8 correspond to the regularity in Fig. 9a–c, where \(B=2\times 10^{-4}\) is given. However, the black hole charges \({q}=\) 0.2, 0.5 and 0.8 correspond to the onset of chaos when \(B=7\times 10^{-4}\) in Fig. 9d–f. If \({e}=0.5\) in Fig. 10, the values of \(K_c\) are 0.99661 for \({q}=0.2\), 0.99192 for \({q}=0.6\) and 0.01599 for \({q}=0.9\), and seem to show that an increase of the black hole charges q weakens the extent of chaos. When \({e}=-0.8\) in Fig. 11a–c, the black hole charges \({q}=0.2\), 0.45 and 0.8 correspond to the values of \(K_c=\) 0.00467, 0.97603 and 0.99178. This seems to show that chaos is induced easily as the black hole charge q increases. If \({q}=0.8\) is fixed in Fig. 11c–e, chaos seems to be weakened as the magnitude of the particle negative charge q decreases.

Figure 12 plots the visuals of \((P_c, Q_c)\) and values of \(K_c\), which show how a variation of the black hole magnetic charge p affects the dynamics for the three cases of the particle charge e \(=\), >, or < 0. In the three cases, the transition from regularity to chaos is not very sensitive dependence on the variation of p. When p is enough large, e.g. \(p=0.8\), chaos can exist in the three cases.

5.2 Finding chaos via the dependence of \(K_c\) on varying one or two parameters

In fact, the dependence of \(K_c\) on varying one or two parameters can better provide some insight into the transition from regularity to chaos than the technique of Poincaré map.

Figure 13 plots the dependence of \(K_c\) on varying one parameter. Here, we take \(N_2=10{,}000\). For a given parameter, the value of \(K_c\) is not obtained until the integration time reaches \(10^7\). The values of \(0\le K_c<0.5\) indicate the regularity, whereas those of \(0.5\le K_c\le 1\) correspond to the chaoticity. When the magnetic field B spans \(3.6\times 10^{-4}\) in Fig. 13a, the transition from regularity to chaos occurs. As the black hole spin a is larger than 0.69, chaos disappears in Fig. 13b. The values of \({e}\ge 0.21\) induce chaos almost anywhere in Fig. 13c. These facts show that chaos is easily induced as the magnetic field strength and particle positive charge increase or the black hole spin decreases. On the other hand, chaos is always present for any one of the black hole magnetic charges p when a smaller angular momentum \(L=4.0\) is taken in Fig. 13d. However, only several values of p admit chaos when a larger angular momentum \(L=6.5\) is used.

We can also use the values of \(K_c\) to exhibit the distribution of order and chaos in the space of two parameters. In Fig. 14, the particles are electrically neutral, and the two parameters are q and one of B, E and L. Clearly, the regular and chaotic dynamics of neutral particles is not very sensitive dependence on the variation of q. Under some circumstances, the increase of B and E or the decrease of L can easily induce chaos from the statistical computations. When the particles have negative charges in Fig. 15a, chaos occurs easily as q increases. However, the chaotic motion of positive charge particles occurs easily as q decreases in Fig. 15b. The dependence of chaos on the black hole charge in the magnetized Kerr–Newman spacetime is similar to that in the magnetized RN spacetime [10]. There is no universal rule on the contribution of a variation of p to the transition from order to chaos in Fig. 15c, d.

As a point to be illustrated, the parameters corresponding to regular and chaotic dynamics described by the values of \(K_c\) in Figs. 13, 14 and 15 are completely consistent with those shown by the FLIs.

6 Summary

An external magnetic field which surrounds the Kerr–Newman black hole is so strong that it changes the spacetime geometry. The strong magnetic field in the spacetime acts as a gravitational effect to electrically neutral particles. It leads to the absence of the Carter constant. As a result, such a magnetized Kerr–Newman spacetime is nonintegrable. When test particles moving around the black hole are electrically charged, they are subject to the interaction of an external electromagnetic field as well as the magnetized Kerr–Newman spacetime. In this case, the dynamical model of electrically charged particles becomes more complicated.

The motion of electrically neutral or charged particles around the magnetized Kerr–Newman black hole immersed in the external electromagnetic field is described in terms of a dimensionless Hamiltonian system. The Hamiltonian has several physical parameters, including the external magnetic field strength, the black hole’s rotating angular momentum, electric charge and magnetic charge, and the particle’s charge, angular momentum and energy. It has no separation of variables, and cannot be split into several explicitly integrable terms, either. However, an appropriate time transformation to the Hamiltonian allows for the existence of five explicitly integrable splitting parts. In this way, explicit symplectic integrators are easily available. It is shown numerically that the second- and fourth-order explicit symplectic integrators perform high accuracy in the conserved Hamiltonian quantity and show no secular drift in the Hamiltonian error.

Considering computational efficiency, we select the second-order explicit symplectic method as an integration tool to provide some insight into the dynamics of electrically neutral or charged particles. In addition, the 0–1 binary test correlation method is mainly used to distinguish between regular and chaotic dynamics. The correlation coefficient \(K_c=0\) corresponds to the regular dynamics, while the correlation coefficient \(K_c=1\) represents the chaotic dynamics. A bounded region like a ring surface, as the visual of two translation variables \(P_c\) and \(Q_c\), can characterize the regularity. If the visual of two translation variables \(P_c\) and \(Q_c\) behave as an asymptotic unbounded Brownian motion, it can characterize the chaoticity. The correlation method is effective to detect chaos from order, as the other techniques of Poincaré map, power spectrum, Lyapunov exponents and FLIs are. It is more sensitive to find chaos than the Lyapunov exponents.

From a statistical viewpoint, the transition from regularity to chaos occurs easily under some circumstances as both the external magnetic field strength and the particle charge and energy increase. Chaos is also easily induced when the black hole spin and the particle angular momentum decrease. The effects of the black hole charge on the regular and chaotic dynamics are dependent on the sign of the particle charge. The variation of the black hole charge does not very sensitively affect the dynamics of neutral particles. With the black hole charge increasing, the motions of positively charged particles are not easily chaotic, whereas those of negatively charged particles are. On the other hand, no universal rule can be given to the effect of a small change of the black hole magnetic charge on the dynamical transition from order to chaos.