1 INTRODUCTION

Numerical methods for obtaining a bound-state solution of the one-dimensional Schrödinger equation can be broadly classified into two types: numerical integration (shooting methods) and matrix methods [1]. The techniques to be described here belong to the matrix method category. Most of the Schrödinger equations we find in physics cannot be solved analytically [2]. Analytical solutions of the Quantum Harmonic Oscillator and the Radial Schrödinger equations for a Hydrogen atom are well-known that allow us to study the numerical techniques and test the accuracy of the suggested methods. The Numerov method gives high accuracy results which are in good agreement with analytical solutions and other methods [34]. Generally, the Shooting method in combination with Numerov approximation and the R matrix is used to solve a boundary value problem. None of these methods is sufficiently stable. If we use the Shooting method directly then one of the solutions grows exponentially and becomes unstable due to the rounding-off errors. On the other hand, when we use a band matrix technique, the solutions are always stable. And the number of multiplications (or complexity of the algorithm) is of the same order \( \sim {{n}^{2}}\) as in the R matrix solution. The stability is high when we use routines from the LINPACK package. The transmission of waves through a potential barrier or well is a fundamental problem in quantum mechanics and has applications in a wide range of practical problems [5]. Using the Numerov method we obtain a stable, accurate method for calculating the transmission and the reflection coefficients of the potential barrier. The method is applicable to the potentials of arbitrary shapes.

2 NUMERICAL METHODS

The Numerov method (named after Russian astronomer Boris Vasilyevich Numerov) which is a specialized integration formula for numerically integrating differential equations to transform it into a new representation of matrix form on a discrete lattice depends only on the displacement of grid \(h\) and the number of grid \(N\). The method is fourth-order (\(O({{h}^{4}})\)) accurate method of the form Eq. (1),

$$\begin{gathered} y{\kern 1pt} {''}(x) + f(x,y) = 0, \\ {{y}_{{n + 1}}} - 2{{y}_{n}} + {{y}_{{n - 1}}} = \frac{{{{h}^{2}}}}{{12}}\left( {{{f}_{{n + 1}}} + 10{{f}_{n}} + {{f}_{{n - 1}}}} \right), \\ \end{gathered} $$
(1)

here \({{f}_{n}} = f({{x}_{n}},{{y}_{n}})\) and \({{y}_{n}} = y({{x}_{n}})\) are value of the function \(f(x,y)\) and the solution \(y(x)\) at the nodes of the grid points \(\left( {{{x}_{0}},...{{x}_{n}}....,{{x}_{N}}} \right)\) and \(h = {{x}_{n}} - {{x}_{{n - 1}}}\) is the distance between the nodes of the grid.

We use the following modified subroutines from the LINPACK collections: dgbsl.f, dgbfa.f. Our main program includes the following crucial methods: Gaussian elimination, LU factorization, Inverse iteration. Gaussian elimination and other aspects of matrix computation are studied in detail in the book by Forthsythe and Moler (1977) [6] and Stewart (1973) [7]. Our calculations were made on the main server of BLTP (2x 8-core Xeon E5-2690 2.9 GHz, 256 GB RAM). In our case, the Schrödinger equation is reduced to the generalized eigenvalue problem of the form

$$Ax = \lambda Bx.$$
(2)

If matrix \(B\) is symmetric, then we can decompose Eq. (2) into \(L\), \(U\) decomposition, then the generalized eigenvalue problem is reduced to the standart eigenvalue problem of the form

$$\begin{gathered} A{\kern 1pt} 'y = \lambda y,\,\,\,\,{\text{here}}\,\,\,B = L{{L}^{T}}, \\ A{\kern 1pt} ' = {{L}^{{ - 1}}}A{{L}^{{ - T}}},\,\,\,y = {{L}^{T}}x. \\ \end{gathered} $$

However, this method is too laborious (\( \sim 20{{N}^{2}}\) multiplication operations) and is less resistant to calculation errors. If only a single eigenvalue (eigenvector) is needed, the solution may be obtained efficiently (\({{ \sim {\kern 1pt} {{N}^{2}}} \mathord{\left/ {\vphantom {{ \sim {\kern 1pt} {{N}^{2}}} 6}} \right. \kern-0em} 6}\) multiplication operations) with the help of the inverse iteration method:

$$\left( {A{\kern 1pt} '\,\, - \mu B} \right)y_{k}^{{(n + 1)}} = {{s}^{{(n)}}}By_{k}^{{(n)}},$$

where scalar factor \({{s}^{{(n)}}}\) is chosen in such a way that \(\left\| {y_{k}^{{(n + 1)}}} \right\| = 1\). If \(\mu \) is close to exact eigenvalue \({{\lambda }_{k}}\), the vector sequence \(y_{k}^{{(n)}}\) converges rapidly to the exact eigenvector \({{y}_{k}}\), and \(\lambda _{k}^{{(n)}} = \left( {y_{k}^{{(n)}},Ay_{k}^{{(n)}}} \right)\) converges rapidly to the exact value \({{\lambda }_{k}}\). In order to illustrate this, one may assume, without a loss of generality, that matrix \(A\) is a diagonal one. The solution may then be written down in the explicit form:

$$y_{k}^{{(n)}} = {{c}_{n}}{{\left[ {{{{\left( {\frac{{{{\lambda }_{k}} - \mu }}{{{{\lambda }_{1}} - \mu }}} \right)}}^{n}}{{u}_{1}},...,{{u}_{k}},...,{{{\left( {\frac{{{{\lambda }_{k}} - \mu }}{{{{\lambda }_{n}} - \mu }}} \right)}}^{n}}{{u}_{n}}} \right]}^{T}},$$
(3)

where \({{c}_{n}}\) is a coefficient that normalizes the vector from the right. It can be seen from Eq. (3) that all components of vector \(y_{k}^{{(n)}}\) (except for \({{u}_{k}}\), which remains equal to unity tend to zero under the given normalization conditions (for more details [8, 9]). Practical calculations demonstrate that this method is also the most resistant to rounding errors (calculation errors).

3 THE QUANTUM HARMONIC OSCILLATOR

The Schrödinger equation is a linear partial differential equation that describes the wave function or state function of a quantum-mechanical system. The stationary Schrödinger equation for the one-dimensional quantum harmonic oscillator takes the following form:

$$\begin{gathered} \left[ { - \frac{\hbar }{{2m}}\frac{{{{d}^{2}}}}{{d{{x}^{2}}}} + V(x)} \right]{{\Psi }_{n}}(x) = {{E}_{n}}{{\Psi }_{n}}(x), \\ {\text{for}}\,\,\,V(x) = \frac{{{{\omega }^{2}}{{x}^{2}}}}{2}. \\ \end{gathered} $$
(4)

Equation (4) has three constants including \(\hbar ,m,\omega \), we take them equal to unity in numerical calculations. Here boundary conditions are defined as follows:

$$\left\{ \begin{gathered} \Psi ( - \infty ) = 0, \hfill \\ \Psi (\infty ) = 0. \hfill \\ \end{gathered} \right.$$
(5)

In a practical case, we do not take boundary conditions at infinite points or at infinity as defined in Eq. (5). Instead, we find solutions at finite points \([ - R,R]\), then we get \({{E}_{n}}\) which depends on \(h\). Then using different steps, we can extrapolate to \(h \to 0\).

3.1 Analytical Solution

There are at least two approaches for analytically solving the Schrödinger equation for the quantum harmonic oscillator. The first method is to decompose in a series that is suitable for solving some differential equations which allow analytical solutions. The second method is the Algebraic method which is fast and convenient to generate the solutions. Here we use the second method to obtain the wave functions of the first bound state and use the creation (or ladder) operator explicitly and which listed here the general formula for obtaining the arbitrary level of wave functions.

$${{\psi }_{0}}(x) = {{\left( {\frac{{m\omega }}{{\pi \hbar }}} \right)}^{{\frac{1}{4}}}}{{e}^{{ - \tfrac{{m\omega }}{{2\hbar }}{{x}^{2}}}}},\,\,\,{{\psi }_{1}}(x) = {{\left( {\frac{{m\omega }}{{\pi \hbar }}} \right)}^{{\frac{1}{4}}}}\sqrt {\frac{{2m\omega }}{\hbar }} x{{e}^{{ - \tfrac{{m\omega }}{{2\hbar }}{{x}^{2}}}}},$$
$$\begin{gathered} {{\Psi }_{n}}(x) = \frac{1}{{\sqrt {n!} }}{{({{{\hat {a}}}^{\dag }})}^{n}}{{\Psi }_{0}}(x), \\ {\text{here}}\,\,\,\,{{{\hat {a}}}^{\dag }} = \frac{1}{{\sqrt {2\hbar m\omega } }} \\ \times \,\,\left( { - i\hat {p} + m\omega x} \right)\,\,{\text{is}}\,\,{\text{a}}\,\,{\text{raising}}\,\,{\text{operator}}. \\ \end{gathered} $$

We use these analytical formulas to plot the first 5 wavefunctions of a quantum harmonic oscillator. Origin 2019b is used to make the plot out as figured in the below.

3.2 Numerical Solution

In order to numerically solve the Schrödinger equation defined by the Eq. (4), the equation can be reduced to the following form

$$ - \frac{1}{2}\frac{{{{d}^{2}}}}{{d{{x}^{2}}}}{{\Psi }_{n}}(x) = \left( {{{E}_{n}} - V(x)} \right){{\Psi }_{n}}(x).$$

Here to be more concrete, let us denote some indexes as follows: \(n\) is nth eigenvalue, \(i\) is grid point number, \(h\) is a step of discretization, then

$$\begin{gathered} {{f}_{{i + 1}}} = \left( {{{E}_{n}} - V({{x}_{{i + 1}}})} \right){{\Psi }_{n}}({{x}_{{i + 1}}}), \\ {{f}_{i}} = \left( {{{E}_{n}} - V({{x}_{i}})} \right){{\Psi }_{n}}({{x}_{i}}), \\ {{f}_{{i - 1}}} = \left( {{{E}_{n}} - V({{x}_{{i - 1}}})} \right){{\Psi }_{n}}({{x}_{{i - 1}}}). \\ \end{gathered} $$

Here if we use the Numerov method Eq. (1), then Eq. (4) takes the following form.

$$\begin{gathered} - \frac{1}{{2{{h}^{2}}}}({{\Psi }_{n}}({{x}_{{i + 1}}}) - 2{{\Psi }_{n}}({{x}_{i}}) + {{\Psi }_{n}}({{x}_{{i - 1}}})) \\ = \frac{1}{{12}}({{E}_{n}}{{\Psi }_{n}}({{x}_{{i + 1}}}) - V({{x}_{{i + 1}}}){{\Psi }_{n}}({{x}_{{i + 1}}}) + 10{{E}_{n}}{{\Psi }_{n}}({{x}_{i}}) \\ - \,\,10V({{x}_{i}}){{\Psi }_{n}}({{x}_{i}}) + {{E}_{n}}{{\Psi }_{n}}({{x}_{{i - 1}}}) - V({{x}_{{i - 1}}}){{\Psi }_{n}}({{x}_{{i - 1}}})), \\ - \frac{1}{{2{{h}^{2}}}}({{\Psi }_{n}}({{x}_{{i + 1}}}) - 2{{\Psi }_{n}}({{x}_{i}}) + {{\Psi }_{n}}({{x}_{{i - 1}}})) \\ + \,\,\left( {\frac{{V({{x}_{{i + 1}}}){{\Psi }_{n}}({{x}_{{i + 1}}}) + 10V({{x}_{i}}){{\Psi }_{n}}({{x}_{i}}) + V({{x}_{{i - 1}}}){{\Psi }_{n}}({{x}_{{i - 1}}})}}{{12}}} \right) \\ = {{E}_{n}}\left( {\frac{{{{\Psi }_{n}}({{x}_{{i + 1}}}) + 10{{\Psi }_{n}}({{x}_{i}}) + {{\Psi }_{n}}({{x}_{{i - 1}}})}}{{12}}} \right), \\ \end{gathered} $$

which is in the form of

$$(A + V)\Psi = EB\Psi .$$

Where

$$A = - \frac{1}{{2{{h}^{2}}}}\left( {\begin{array}{*{20}{c}} { - 2}&1&0& \cdots \\ 1&{ - 2}&1& \cdots \\ 0&1&{ - 2}& \cdots \\ \vdots & \vdots & \vdots & \ddots \end{array}} \right),\,\,\,B = \frac{1}{{12}}\left( {\begin{array}{*{20}{c}} {10}&1&0& \cdots \\ 1&{10}&1& \cdots \\ 0&1&{10}& \cdots \\ \vdots & \vdots & \vdots & \ddots \end{array}} \right),$$
$$V = \frac{1}{{12}}\left( \begin{gathered} \begin{array}{*{20}{c}} {10V({{x}_{i}})}&{V({{x}_{{i + 1}}})}&0& \cdots \\ {V({{x}_{{i - 1}}})}&{10V({{x}_{i}})}&{V({{x}_{{i + 1}}})}& \cdots \\ 0&{V({{x}_{{i - 1}}})}&{10V({{x}_{i}})}& \cdots \\ \vdots & \vdots & \vdots & \ddots \end{array} \hfill \\ \end{gathered} \right),\,\,\,{{\Psi }_{n}} = \left( \begin{gathered} \begin{array}{*{20}{c}} {{{\Psi }_{1}}} \\ {{{\Psi }_{2}}} \\ \vdots \\ {{{\Psi }_{n}}} \end{array} \hfill \\ \end{gathered} \right).$$

The dimension of this matrix corresponds to the number of discretization points and different steps of discretization were used. The integration was carried out in the interval \([ - 5,5]\). Table 1 shows the numerical results.

Table 1. These numerical calculations clearly show that the order of the Numerov method is \({{h}^{4}}\). More precisely, we see that (say, for the third state) the ratio of the errors is  \(\tfrac{{(3.5 - 3.4999984608)}}{{(3.5 - 3.4999999039)}} = 16.0166 \approx {{2}^{4}}\). So, decreasing the step \(h\), we get the energy value rapidly convergent

4 RADIAL SCHRÖDINGER EQUATION FOR A HYDROGEN ATOM

The radial stationary Schrödinger equation for an electron in a spherically symmetric potential takes the following form:

$$\begin{gathered} \left[ { - \frac{{{{\hbar }^{2}}}}{{2m}}\left( {\frac{{{{d}^{2}}}}{{d{{r}^{2}}}} - \frac{{\ell (\ell + 1)}}{{{{r}^{2}}}}} \right) + V(r)} \right]U(r) = EU(r), \\ {\text{for}}\,\,\,V(r) = - \frac{{{{e}^{2}}}}{{4\pi {{\varepsilon }_{0}}r}}. \\ \end{gathered} $$
(6)

In our calculations, the mass of an electron \(m\) and Planck’s constant \(\hbar \) are taken equal to unity. The boundary conditions for the related states are:

$$\left\{ {\begin{array}{*{20}{c}} {U(0) = 0,} \\ {U(\infty ) = 0.} \end{array}} \right.$$
(7)

In practical calculations, we use \(U(R) = 0\) for some large \(R\). Then we find solutions at interval \([0,R]\), then we get \({{E}_{n}}\) which depends on \(h\). Then using different steps, we can extrapolate to \(h \to 0\).

Fig. 1.
figure 1

Normalized wavefunctions of a quantum harmonic oscillator for the five lowest eigenstates n from 0 to 5. The horizontal axis shows the position of \(x\). Note that the wavefunctions for higher \(n\) have more nodes within the potential, \(V(x) = \frac{{{{x}^{2}}}}{2}\). This corresponds to a shorter wavelength and therefore by the de Broglie relationship they may be seen to have a higher momentum and therefore higher energy.

4.1 Analytical Solution

We present a stationary one-dimensional Schrödinger equation which is a problem almost identical to solve the radial wave in three dimensions. Here we list the main formula for the radial wave functions and for the total wave functions of the Hydrogen atom:

$$\begin{gathered} {{R}_{{10}}}(r) = \frac{2}{{\sqrt {a_{0}^{3}} }}{{e}^{{ - \tfrac{r}{{{{a}_{0}}}}}}}, \\ {{R}_{{n\ell }}}(r) = \sqrt {\frac{{(n - l - 1)!}}{{2n{{{[(n + \ell )!]}}^{3}}}}{{{\left( {\frac{2}{{na}}} \right)}}^{3}}} {{\left( {\frac{{2r}}{{na}}} \right)}^{\ell }}L_{{n - \ell - 1}}^{{2\ell + 1}}\left( {\frac{{2r}}{{na}}} \right){{e}^{{ - \tfrac{r}{{na}}}}}, \\ \end{gathered} $$
$$\begin{gathered} {{\Psi }_{{100}}}(r,\theta ,\phi ) = \frac{1}{{\sqrt \pi }}{{\left( {\frac{1}{{{{a}_{0}}}}} \right)}^{{\frac{3}{2}}}}{{e}^{{ - \tfrac{r}{{{{a}_{0}}}}}}}, \\ {{\Psi }_{{n,\ell ,m}}}(r,\theta ,\varphi ) = {{R}_{{n\ell }}}(r)\Upsilon _{\ell }^{m}(\theta ,\varphi ). \\ \end{gathered} $$

We use these analytical formulas to plot the first 3 states of the Radial wavefunction for a Hydrogen atom. Origin 2019b is used to make the plot out in Fig. 2.

Fig. 2.
figure 2

Radial wave functions of the hydrogen atom. Here we use spectroscopic notation to represent quantum numbers \(\ell ,m\). Note that as the energy decreases, the spatial extent of the wavefunction increases, that is to say, the electron is more delocalized.

Table 2. The numerical solution of the Radial Schrödinger equation for a Hydrogen atom. Here we see that the convergence is different in each state and we used different steps of discretization. Because under the given boundary condition we have a singularity at 0. In this case, the order of the Numerov method \({{h}^{4}}\) is seen only for the \(3d\) state. From our analysis it follows that the order of the Numerov method for the \(s\) state is \({{h}^{2}}\), for the \(p\) state is \({{h}^{3}}\), for the \(d\) state is \({{h}^{4}}\). In addition, we compared our results with the work (J.F. Van der Maelen Uría et al., 1996), in which they used Richardson’s extrapolation. It can be seen that our calculation leads to more accurate results

4.2 Numerical Solution

In order to obtain the necessary form for the application of the Numerov method, Eq. (6) can be reduced in the following form:

$$\begin{gathered} - \frac{1}{2}\frac{{{{d}^{2}}}}{{d{{r}^{2}}}}U(r) = (E - {{V}_{{{\text{eff}}}}})U(r), \\ {{V}_{{{\text{eff}}}}} = \frac{1}{2}\frac{{\ell (\ell + 1)}}{{{{r}^{2}}}} + V(r). \\ \end{gathered} $$

Here to be more concrete let us denote some indexes as follows: \(n\) is \(n\)th eigenvalue, \(i\) is grid point number, \(h\) is the step of discretization. Then we get

$$\begin{gathered} {{f}_{{i + 1}}} = \left( {{{E}_{n}} - {{V}_{{{\text{eff}}}}}({{x}_{{i + 1}}})} \right){{U}_{n}}({{x}_{{i + 1}}}), \\ {{f}_{i}}\left( {{{E}_{n}} - {{V}_{{{\text{eff}}}}}({{x}_{i}})} \right){{U}_{n}}({{x}_{i}}), \\ {{f}_{{i - 1}}} = \left( {{{E}_{n}} - {{V}_{{{\text{eff}}}}}({{x}_{{i - 1}}})} \right){{U}_{n}}({{x}_{{i - 1}}}). \\ \end{gathered} $$

Now, if we use the Numerov method Eq. (1), then Eq. (6) takes the following form.

$$\begin{gathered} - \frac{1}{{2{{h}^{2}}}}({{U}_{n}}({{x}_{{i + 1}}}) - 2{{U}_{n}}({{x}_{i}}) + {{U}_{n}}({{x}_{{i - 1}}})) = \frac{1}{{12}}({{E}_{n}}{{U}_{n}}({{x}_{{i + 1}}}) - {{V}_{{{\text{eff}}}}}({{x}_{{i + 1}}}){{U}_{n}}({{x}_{{i + 1}}}) + 10{{E}_{n}}{{U}_{n}}({{x}_{i}}) \\ - \,\,10{{V}_{{{\text{eff}}}}}({{x}_{i}}){{U}_{n}}({{x}_{i}}) + {{E}_{n}}{{U}_{n}}({{x}_{{i - 1}}}) - {{V}_{{{\text{eff}}}}}({{x}_{{i - 1}}}){{U}_{n}}({{x}_{{i - 1}}})), \\ - \,\,\frac{1}{{2{{h}^{2}}}}({{U}_{n}}({{x}_{{i + 1}}}) - 2{{U}_{n}}({{x}_{i}}) + {{U}_{n}}({{x}_{{i - 1}}})) + \left( {\frac{{{{V}_{{{\text{eff}}}}}({{x}_{{i + 1}}}){{U}_{n}}({{x}_{{i + 1}}}) + 10{{V}_{{{\text{eff}}}}}({{x}_{i}}){{U}_{n}}({{x}_{i}}) + {{V}_{{{\text{eff}}}}}({{x}_{{i - 1}}}){{U}_{n}}({{x}_{{i - 1}}})}}{{12}}} \right) \\ = {{E}_{n}}\left( {\frac{{{{U}_{n}}({{x}_{{i + 1}}}) + 10{{U}_{n}}({{x}_{i}}) + {{U}_{n}}({{x}_{{i - 1}}})}}{{12}}} \right), \\ \end{gathered} $$

which is in the form of

$$(A + V)U = EBU.$$

Where

$$A = - \frac{1}{{2{{h}^{2}}}}\left( {\begin{array}{*{20}{c}} { - 2}&1&0& \cdots \\ 1&{ - 2}&1& \cdots \\ 0&1&{ - 2}& \cdots \\ \vdots & \vdots & \vdots & \ddots \end{array}} \right),\,\,\,B = \frac{1}{{12}}\left( {\begin{array}{*{20}{c}} {10}&1&0& \cdots \\ 1&{10}&1& \cdots \\ 0&1&{10}& \cdots \\ \vdots & \vdots & \vdots & \ddots \end{array}} \right),$$
$$\begin{gathered} {{V}_{{{\text{eff}}}}} = \frac{1}{{12}}\left( \begin{gathered} \begin{array}{*{20}{c}} {10{{V}_{{{\text{eff}}}}}({{x}_{i}})}&{{{V}_{{{\text{eff}}}}}({{x}_{{i + 1}}})}&0& \cdots \\ {{{V}_{{{\text{eff}}}}}({{x}_{{i - 1}}})}&{10{{V}_{{{\text{eff}}}}}({{x}_{i}})}&{{{V}_{{{\text{eff}}}}}({{x}_{{i + 1}}})}& \cdots \\ 0&{{{V}_{{{\text{eff}}}}}({{x}_{{i - 1}}})}&{10{{V}_{{{\text{eff}}}}}({{x}_{i}})}& \cdots \\ \vdots & \vdots & \vdots & \ddots \end{array} \hfill \\ \end{gathered} \right), \\ {{U}_{n}} = \left( \begin{gathered} \begin{array}{*{20}{c}} {{{U}_{1}}} \\ {{{U}_{2}}} \\ \vdots \\ {{{U}_{n}}} \end{array} \hfill \\ \end{gathered} \right). \\ \end{gathered} $$

5 QUANTUM TUNNELING

Here we consider numerical the Numerov method for the accurate calculation of reflection and transmission coefficient. If a particle pass through the potential barrier, one of two things happen: it can bounce back, or it can penetrate the barrier. The stationary Schrödinger equation has the following form

$$\left[ { - \frac{{{{\hbar }^{2}}}}{{2m}}\frac{{{{d}^{2}}}}{{d{{x}^{2}}}} + V(x)} \right]\psi (x) = E\psi (x),$$
(8)

where potential \(V(x) = {{e}^{{ - {{x}^{2}}}}}\) is taken for our numerical studies. In our calculations, the mass of a particle \(m\) and Planck’s constant \(\hbar \) are taken equal unity. The boundary conditions are:

$$\left\{ \begin{gathered} {{\psi }_{ - }}(x) = {{e}^{{ikx}}} + {{A}_{ - }}{{e}^{{ - ikx}}},\,\,\,\,{\text{when}}\,\,x \to - \infty . \hfill \\ {{\psi }_{ + }}(x) = {{A}_{ + }}{{e}^{{ikx}}},\,\,\,{\text{when}}\,\,x \to + \infty . \hfill \\ \end{gathered} \right.$$
(9)

Here \({{A}_{ - }}\) corresponds to a coefficient of reflection, and \({{A}_{ + }}\) corresponds to a coefficient of transmission. In the case of a free particle (no force acting on it), the momentum value \(p\) corresponding to function Eq. (9) and the angular wavenumber corresponds to \(k\) are \(p = \hbar k,\) \(k = \tfrac{{\sqrt {2mE} }}{\hbar }.\)Here we assume that the momentum \(p\) corresponds to \(k\) in Eq. (9)

$$p = \sqrt {2mE} .$$

General solution of Eq. (8) can be represented as: \(\psi (x) = U{{\psi }_{1}}(x) + W{{\psi }_{2}}(x)\), where the functions \({{\psi }_{1}}\) and ψ2 satisfy the following simple boundary conditions respectively:

$$\left\{ {\begin{array}{*{20}{c}} {{{\psi }_{1}}( - R) = 1,\,\,\,\,{{\psi }_{1}}(R) = 0,} \\ {{{\psi }_{2}}( - R) = 0,\,\,\,\,{{\psi }_{2}}(R) = 1.} \end{array}} \right.$$

In order to obtain a solution determined by the boundary conditions of Eq. (9), it is necessary to match the solution at 4 points (by the number of unknowns: \(U,W,{{A}_{ - }},\,\,{\text{and}}\,\,{{A}_{ + }}\)).

$$\left\{ \begin{gathered} {{e}^{{ - ikR}}} + {{A}_{ - }}{{e}^{{ikR}}} = U{{\psi }_{1}}( - R) + W{{\psi }_{2}}( - R),\,\,\,\psi ( - R) \hfill \\ {{e}^{{ - ik(R - h)}}} + {{A}_{ - }}{{e}^{{ik(R - h)}}} = U{{\psi }_{1}}( - R + h) \hfill \\ + \,\,W{{\psi }_{2}}( - R + h),\,\,\,\,\psi ( - R + h) \hfill \\ {{A}_{ + }}{{e}^{{ikR}}} = U{{\psi }_{1}}(R) + W{{\psi }_{2}}(R),\,\,\,\,\psi (R) \hfill \\ {{A}_{ + }}{{e}^{{ik(R - h)}}} = U{{\psi }_{1}}(R - h) + W{{\psi }_{2}}(R - h),\,\,\,\,\psi (R - h) \hfill \\ \end{gathered} \right.$$

or in the matrix form:

$$\begin{gathered} \left( {\begin{array}{*{20}{c}} 1&0&{ - {{e}^{{ikR}}}}&0 \\ 0&1&0&{ - {{e}^{{ikR}}}} \\ {{{\psi }_{1}}( - R + h)}&{{{\psi }_{2}}( - R + h)}&{ - {{e}^{{ik(R - h)}}}}&0 \\ {{{\psi }_{1}}(R - h)}&{{{\psi }_{2}}(R - h)}&0&{ - {{e}^{{ik(R - h)}}}} \end{array}} \right) \\ \times \,\,\left( {\begin{array}{*{20}{c}} U \\ W \\ {{{A}_{ - }}} \\ {{{A}_{ + }}} \end{array}} \right) = \left( {\begin{array}{*{20}{c}} {{{e}^{{ - ikR}}}} \\ 0 \\ {{{e}^{{ - ik(R - h)}}}} \\ 0 \end{array}} \right). \\ \end{gathered} $$

The numerical results Table 3 shows the penetration of a particle passing from the left to right through the potential barrier. The transmission coefficient represents the probability flux of the transmitted wave relative to that of the incident wave, the reflection coefficient determines the ratio of the reflected wave amplitude to the incident wave amplitude. From the results of Table 3, we can say that the incident energy increases the transmitted wave decreases and the reflected wave increases. Or the incident energy decreases the transmitted wave increases and the reflected wave decreases. The numerical values of the amplitude are used to plot the figure (Fig. 3). Origin 2019b is used to draw wavefunctions.

Table 3.   The transmission and reflection coefficients for various incident energies. For boundary conditions \(R\) is taken finite: \(R = 5\). We show the ratio of \({{A}_{ - }}\) and \({{A}_{ + }}\) using \(({{A}_{h}} - {{A}_{{h/2}}}) - ({{A}_{{h/2}}} - {{A}_{{h/4}}})\)
Fig. 3.
figure 3

The real part of the wavefunctions on both sides and within the potential barrier \(V(x) = {{e}^{{ - {{x}^{2}}}}}\). The left side plot represents the reflected wavefunction, the right side plot represents the transmitted wave function.

6 CONCLUSIONS

In conclusion, we do our calculations using double-precision arithmetic and analyze the dependence of precision of the Numerov method on the discretization step. We can state that the Numerov method based on the band matrix decomposition allows obtaining accurate, stable solutions of the one-dimensional Schrödinger equation for various problems of the Quantum Mechanics. Comparing analytical and numerical solutions to the Schrödinger equation, we demonstrate that our realization of the Numerov method is an efficient tool to solve Schrödinger equations numerically with high accuracy.