Keywords

1 Introduction

The adiabatic representation is widely applied for solving multichannel scattering and bound-state problems for systems of several quantum particles in molecular, atomic and nuclear physics [6, 7, 11, 14].

Such problems are described by elliptic boundary value problems (BVPs) in a multidimensional domain of the configuration space, solved using the Kantorovich method, i.e., the reduction to a system of self-adjoint ordinary differential equations (SODEs) using the basis of surface functions of an auxiliary BVP depending on the independent variable of the SODEs parametrically [10, 16]. The elements of matrices of variable coefficients of these SODEs including the matrix of the first derivatives are determined by the integrals of products of surface eigenfunctions and/or their first derivatives with respect to the parameter [4].

Thus, the key problem of such a method is to develop effective algorithms and programs for calculating with given accuracy the surface eigenfunctions and the corresponding eigenvalues of the auxiliary BVP, together with their derivatives with respect to the parameter, and the corresponding integrals that present the matrix elements of the effective potentials in the SODEs [9].

In this paper, we propose new calculation schemes and symbolic-numerical algorithms implemented in Maple-Fortran environment for the solution of the parametric 2D elliptic boundary-value problem using high-accuracy finite element method (FEM) with triangular elements. For the integration, the new high-order fully symmetric high-order Gaussian quadratures on a triangle are performed. We used the symbolic algorithms to generate Fortran routines that allow the solution of the algebraic eigenvalue problem with high-dimension matrices. The algorithms were implemented in a package of programs that calculate with the given accuracy eigenvalues, eigenfunctions, and their first derivatives with respect to the parameter of the parametric self-adjoint elliptic differential equations with the boundary conditions of the Dirichlet and/or Neumann type in the 2D finite domain and the integrals of products of the surface eigenfunctions and their first derivatives with respect to the parameters that express the matrix elements of the effective potentials in the SODEs. Efficiency of the FEM scheme is demonstrated by benchmark calculations of Helium atom ground state.

The structure of the paper is the following. In Sect. 2, the 2D FEM schemes and algorithms for solving the parametric 2D BVP are presented. In Sect. 3, fully symmetric high-order Gaussian quadratures are constructed. In Sect. 4, the algorithm for calculating the parametric derivatives of eigenfunctions and effective potentials is presented. In Sect. 5, the benchmark calculations of 2D FEM algorithms and programs are analyzed. In the Conclusion we discuss the results and perspectives.

2 FEM Algorithm for Solving the Parametric 2D BVP

Let us consider a BVP for the parametric self-adjoint 2D PDE in the domain \(\varOmega _{x}\), \(x=(x_1,x_2)\) with the piecewise continuous boundary \(S=\partial \varOmega _x\),

$$\begin{aligned}&\left( {D}(x;z) {-}\varepsilon _i(z)\right) \varPhi _i(x;z)=0,\end{aligned}$$
(1)
$$\begin{aligned}&{D}{\equiv }{D}(x;z) = {-}\frac{1}{g_0(x)} \left( \sum _{ij=1}^2\frac{\partial }{\partial x_i}g_{ij}(x) \frac{\partial }{\partial x_j}\right) +U(x;z), \ \end{aligned}$$
(2)

with the mixed Dirichlet/Neumann boundary conditions

$$\begin{aligned} (I):&\varPhi (x;z)|_{S}=0, \end{aligned}$$
(3)
$$\begin{aligned} (II):&\frac{\partial \varPhi (x;z)}{\partial n_{D}}\Bigl |_{S}=0, \quad \frac{\partial \varPhi (x;z)}{\partial n_{D}}=\sum _{ij=1}^2(\hat{n}, \hat{e}_i) g_{ij}(x)\frac{\partial \varPhi (x;z)}{\partial x_j}. \end{aligned}$$
(4)

Here \(z\in \varOmega _z=[z_{\min },z_{\max }]\) is a parameter, the functions \(g_0(x)>0\), \(g_{ij}(x)>0\), and \(\partial _{x_k} g_{ij}(x)\), U(xz), \(\partial _z U(x;z)\) and \(\partial _z \varPhi _i(x;z)\) are continuous and bounded for \(x\in \varOmega _{x}\); \(g_{12}(x)=g_{21}(x)\), \(g_{11}(x)g_{22}(x)-g_{12}^2(x)>0\). Also assume that the BVP (1), (3) has only the discrete spectrum, so that \(\varepsilon (z):\varepsilon _1 (z)< \ldots<\varepsilon _{j_{\max } }(z) <\ldots \) is the desired set of real eigenvalues. The eigenfunctions satisfy the orthonormality conditions

$$\begin{aligned} \left\langle \varPhi _i\vert \varPhi _j \right\rangle {=} \int _\varOmega g_0(x)\varPhi _i (x;z ) \varPhi _j (x;z)d x {=}\delta _{ij},\quad dx=d x_1 d x_2. \end{aligned}$$
(5)

The FEM solution of the boundary-value problems (1), (3) is reduced to the determination of stationary points of the variational functional [1, 2]

$$\begin{aligned} \varXi (\varPhi _m,\varepsilon _m(z)) \equiv \int \limits _{\varOmega } dx g_0(x){\varPhi }_m(x;z) \left( {D}-\varepsilon _m(z) \right) \varPhi (x;z) =\varPi (\varPhi _m,\varepsilon _m(z)), \end{aligned}$$
(6)

where \(\varPi \equiv \varPi (\varPhi _m,\varepsilon _m(z))\), \(\varPhi _m\equiv \varPhi _m(x;z)\) is the symmetric quadratic functional

$$\begin{aligned} \varPi {=} \int \limits _{\varOmega }dx \biggl [ \sum _{ij{=}1}^2g_{ij}(x)\frac{\partial {\varPhi }_m}{\partial x_i} \frac{\partial \varPhi _m }{\partial x_j} {+} g_0(x){\varPhi }_m ({U}(x;z) {-}\varepsilon _m(z) ) \varPhi _m \biggr ]. \end{aligned}$$

The domain \(\varOmega (x,y)=\bigcup _{q=1}^Q\varDelta _{q}\), specified as a polygon in the plane \((x_1, x_2)\in \mathcal{R}^2\), is covered with finite elements, the triangles \(\varDelta _{q}\) with the vertices \((x_{11},x_{21})\), \((x_{12},x_{22})\), \((x_{13},x_{23})\) (here \(x_{ik}\equiv x_{ik;q}\), \(i=\overline{1,2}\), \(k=\overline{1,3}\), \(q=\overline{1,Q}\)). On each of the triangles \(\varDelta _{q}\) (the boundary is considered to belong to the triangle), the shape functions \(\varphi _l^p(x_1,x_2)\) are introduced. For this purpose we divide the sides of the triangle into p equal parts and draw three families of parallel straight lines through the partition points. The straight lines of each family are numbered from 0 to p, so that the line passing through the side of the triangle has the number 0, and the line passing through the opposite vertex of the triangle has the number p.

Three straight lines from different families intersect at one point \(A_l\in \varDelta _{q}\), which will be numbered by the triplet \((n_1,n_2,n_3)\), \(n_i\ge 0\), \(n_1+n_2+n_3=p\), where \(n_1\), \(n_2\), and \(n_3\) are the numbers of the straight lines passing parallel to the side of the triangle that does not contain the vertex \((x_{11},x_{21})\), \((x_{12},x_{22})\), and \((x_{13},x_{23})\), respectively. The coordinates of this point \(x_{l}=(x_{1l},x_{2l})\) are determined by the expression \((x_{1l},x_{2l})=(x_{11},x_{21})n_1/p+(x_{12},x_{22})n_2/p+(x_{13},x_{23})n_3/p.\)

As shape functions we use the Lagrange triangular polynomials \(\varphi _l^p(x)\) of the order p that satisfy the condition \(\varphi _l^p(x_{1l'},x_{2l'})=\delta _{ll'}\), i.e., equal 1 at one of the points \(A_l\) and zero at the other points.

In this method, the piecewise polynomial functions \(N_l^p(x)\) in the domain \(\varOmega \) are constructed by joining the shape functions \(\varphi _l^p(x)\) in the triangle \(\varDelta _{q}\):

$$N_l^p(x)=\{\varphi _l^p(x), A_l\in \varDelta _{q};0, A_l\not \in \varDelta _{q}\}$$

and possess the following properties: the functions \(N_l^p(x)\) are continuous in the domain \(\varOmega \); the functions \(N_l^p(x)\) equal 1 at one of the points \(A_l\) and zero at the rest points; \(N_l^p(x_{1l'},x_{2l'})=\delta _{ll'}\) in the entire domain \(\varOmega \). Here l takes the values \(l=\overline{1,N}\).

The functions \(N_l^p(x)\) form a basis in the space of polynomials of the pth order. Now, the function \(\varPhi (x; z)\in \mathcal{F}_{z}^h\sim \mathcal{H}^1(\varOmega _x)\) is approximated by a finite sum of piecewise basis functions \(N_l^p(x)\)

$$\begin{aligned} \varPhi ^h(x; z)=\sum _{l=1}^{N} \varPhi _{l}^h(z) N_l^p(x). \end{aligned}$$
(7)

The vector function \({\varvec{\varPhi }}^h=\{\varPhi _{l}^h(z)\}_{l=1}^{N}\) has a generalized first-order partial derivative and belongs to the Sobolev space \(\mathcal{H}^1(\varOmega _x)\) [13]. After substituting expansion (7) into the variational functional and minimizing it [1, 13], we obtain the generalized eigenvalue problem

$$\begin{aligned} \mathbf{A}^p\varvec{{\varPhi }}^h=\varepsilon ^h\mathbf {B}^p{\varvec{\varPhi }}^h. \end{aligned}$$
(8)

Here \(\mathbf{A}^p\) is the stiffness matrix; \(\mathbf {B}^p\) is the positive definite mass matrix; \({\varvec{\varPhi }}^h\) is the vector approximating the solution on the finite-element grid; and \(\varepsilon ^h\equiv \varepsilon ^h(z)\) is the corresponding eigenvalue. The matrices \({\mathbf A}^p\) and \({\mathbf B}^p\) have the form:

$$\begin{aligned} {\mathbf A}^p{=}\{ a_{ll'}^p\}_{ll'=1}^N, \,\, {\mathbf B}^p{=}\{ b_{ll'}^p\}_{ll'=1}^N,\end{aligned}$$
(9)

where the matrix elements \({a}_{ll'}^p\) and \({b}_{ll'}^p\) are calculated for triangular elements as

$$\begin{aligned}&a_{ll'}^p =\int _{\varDelta _q}g_0(x)\varphi _{l}^p(x;z)\varphi _{l'}^p(x;z)U(x;z)\,d x{+}\sum _{i,j=1}^2\!\int _{\varDelta _q}\!g_{ij}\frac{\partial \varphi _{l}^p(x;z)}{\partial x_i } \frac{\partial \varphi _{l'}^p(x;z )}{\partial x_j }\,dx , \\&b_{ll'}^p =\int _{\varDelta _q}g_0(x)\varphi _{l}^p(x;z)\varphi _{l'}^p(x;z)d x. \end{aligned}$$

Let us construct the LIP on a triangle \(\varDelta _{q}\) with the vertices \({\hat{x}}_i=( x_{i1}, x_{i2}, x_{3d})\). For this purpose we introduce the local coordinate system \({x}'=(x_{1}',x_{2}')\in \mathcal{R}^2\), in which the coordinates of the simplex vertices are the following: \({\hat{x}}_i'=( x_{ik}'=\delta _{ik}, k=1,2)\). The relation between the coordinates and derivatives is given by the formula:

$$\begin{aligned}&x_i= x_{0i}+\sum _{j=1}^2\hat{J}_{ij}x_j', \quad x_i'=\sum _{j=1}^2(\hat{J}^{-1})_{ij}(x_j- x_{0j}), \quad i=1,2, \end{aligned}$$
(10)
$$\begin{aligned}&\frac{\partial }{\partial x_i'} {=}\sum _{j=1}^2\hat{J}_{ji}\frac{\partial }{\partial x_j}, \quad \frac{\partial }{\partial x_i} {=}\sum _{j=1}^2(\hat{J}^{-1})_{ji} \frac{\partial }{\partial x'_j}, \end{aligned}$$
(11)

where \(\hat{J}_{ij}=\hat{x}_{ji}-\hat{x}_{0i}\). When constructing the LIP in the local coordinates \(x'\) one has to recalculate the fixed derivatives at the nodes \(\varPhi _{r'}\) of the element \(\varDelta _q\) to the nodes \(\varPhi '_{r'}\) of the element \(\varDelta \), using the matrices \(\hat{J}^{-1}\), given by cumbersome expressions. Therefore, the required recalculation is executed based on the relations (10) and (11) for each finite element \(\varDelta _q\) at the stage of the formation of the LIP basis \(\{\varphi _{r}^p(x')\}_{r=1}^N\) on the finite element \(\varDelta \), implemented numerically using the analytical formulas

$$\begin{aligned}&\int \limits _{\varDelta _q} dx g_0(x)\varphi _{r}^p\varphi _{r'}^pU(x;z) = J\int \limits _{\varDelta }dx'g_0(x') \varphi _{r}^p(x';z)\varphi _{r'}^p(x';z)U(x';z), \\&\int \limits _{\varDelta _q}\! \! dx g_{s_1s_2}(x)\frac{\partial \varphi _{r}^p}{\partial x_{s_1}}\frac{\partial \varphi _{r'}^p}{\partial x_{s_2}}{=} J\!\!\!\sum _{t_1,t_2=1}^2 \!\!\!\hat{J}_{s_1s_2;t_1t_2}^{-1} \int \limits _{\varDelta } \! \!dx'g_{s_1s_2}(x')\frac{\partial \varphi _{r}^p(x';z)}{\partial x_{t_1}'}\frac{\partial \varphi _{r'}^p(x';z)}{\partial x_{t_2}'}, \end{aligned}$$

where \(\varphi ^p_{r}\equiv \varphi _{r}(x;z)\), \(J=\det \hat{J}>0\) is the determinant of the matrix \(\hat{J}\) from Eq. (10), \(\hat{J}_{s_1s_2;t_1t_2}^{-1}=(\hat{J}^{-1})_{t_1 s_1}(\hat{J}^{-1})_{t_2s_2}\), \(dx'=dx_1'dx_2'\). In this case, we have explicit expression for shape functions \(\varphi _l^p(z_1',z_2')\):

$$\begin{aligned} \varphi _l^p(x')= \prod _{n_1'=0}^{n_1-1}\frac{1-x_1'-x_2'-n_1'/p}{n_1/p-n_1'/p} \prod _{n_2'=0}^{n_2-1}\frac{x_1'-n_2'/p}{n_2/p-n_2'/p} \prod _{n_3'=0}^{n_3-1}\frac{x_2'-n_3'/p}{n_3/p-n_3'/p}. \end{aligned}$$
(12)

The integrals (10) are evaluated using the 2p-order 2D Gaussian quadrature.

In order to solve the generalized eigenvalue problem (8), the subspace iteration method [1, 13] elaborated by Bathe [1] for the solution of large symmetric banded-matrix eigenvalue problems has been chosen. This method uses the skyline storage mode which stores the components of the matrix column vectors within the banded region of the matrix, and is ideally suited for banded finite-element matrices. The procedure chooses a vector subspace of the full solution space and iterates upon the successive solutions in the subspace (for details, see [1]). The iterations continue until the desired set of solutions in the iteration subspace converges to within the specified tolerance on the Rayleigh quotients for the eigenpairs. If the matrix \({\mathbf A}^p\) in Eq. (8) is not positively defined, the problem (8) is replaced with the following problem:

$$\begin{aligned} \tilde{\mathbf A}^p\> {\varvec{\varPhi }}^h = \tilde{\varepsilon }^h\> {\mathbf B}^p \> {\varvec{\varPhi }}^h,\quad \tilde{\mathbf A}^p={\mathbf A}^p-\alpha {\mathbf B}^p. \end{aligned}$$
(13)

The number \(\alpha \) (the shift of the energy spectrum) is chosen such that the matrix \(\tilde{\mathbf A}^p\) is positive defined. The eigenvector of problem (13) is the same, and \(\varepsilon ^h=\tilde{\varepsilon }^h+\alpha \).

3 Fully Symmetric High-Order Gaussian Quadratures

Let consider the two-dimensional integral on triangular domain \(\triangle _{xy}\) with vertices \((x_1,y_1)\), \((x_2,y_2)\), \((x_3,y_3)\):

$$\begin{aligned}&I=\frac{1}{S_{\triangle _{xy}}}\int _{\triangle _{xy}}f(x,y)dy dx \end{aligned}$$
(14)

where \(S_{\triangle _{xy}}\) is a square of triangular domain \(\triangle _{xy}\). Using change of variables

$$\begin{aligned}&x=x_1\gamma +x_2\alpha +x_3\beta ,\quad y=y_1\gamma +y_2\alpha +y_3\beta , \quad \gamma =1-\alpha -\beta , \end{aligned}$$
(15)

we obtain

$$\begin{aligned}&I=\frac{|J|}{S_{\triangle _{xy}}}\int _{\triangle _{\alpha \beta }}f(\alpha ,\beta )d\beta d\alpha =2\int _{0}^1\int _0^{1-\alpha }f(\alpha ,\beta )d\beta d\alpha , \end{aligned}$$
(16)

where J is a Jacobian and \(|J|=2S_{\triangle _{xy}}\), and domain \(\triangle _{\alpha \beta }\) is an isosceles right triangle with vertices (0, 0), (0, 1), (1, 0). The pth ordered fully symmetrical Gaussian quadrature rules for this integral may be written as

$$\begin{aligned}&I\approx \sum _{i=1}^{n_p}w_if(\alpha _i,\beta _i). \end{aligned}$$
(17)

We consider fully symmetric rules, where if a point with areal coordinates \((\!\alpha ,\beta ,\gamma \!)\) is used in the quadrature, then all points resulting from the \(N^w_i\) permutation of the areal coordinates are also used, with the same weight \(w_i\). Integration points in a fully symmetric rule can thus belong to one of three different types of point sets, or orbits, depending on the number of areal coordinates which are equal. The number of points for such a rule is \( n_p=n_0+3n_1+6n_2\). Here \(n_0\) is the number of points which three areal coordinates are equal, i.e., \(n_0=0\) or 1. \(n_1\) is the number of points which two areal coordinates are equal, i.e., we get three points which lie on the medians of the triangle. \(n_2\) is the number of points which three areal coordinates are different, i.e., we get six points.

Table 1. The quadrature rule for \(p=15\) with \(n_p=52\), \([n_0,n_1,n_2]=[1,5,6]\), \(N^w_i\) is the number of different permutations of the areal coordinates ( \(\alpha _i\), \(\beta _i\), \(\gamma _i\)).
Table 2. The quadrature rule for \(p=16\), \(n_p=58\), type \([n_0,n_1,n_2]=[1, 7, 6]\)
Table 3. The quadrature rule for \(p=18\), \(n_p=76\), type \([n_0,n_1,n_2]=[1,9,8]\)

In paper [5], the weights and coordinates of the fully symmetric rules were presented up to order \(p=20\) with minimal number of points using the moment equations. Calculation was performed with double precision accuracy. However, some rules have the points outside the triangle and/or negative weights. We need to use Gaussian quadrature rules with positive weights, and no points are outside the triangle (so-called PI type).

The above Gaussian quadrature rules are constructed with Algorithm:

Step 1. Transfer the isosceles right triangular domain \(\triangle _{\alpha \beta }\) to the equilateral triangular domain with vertices \((-1,0)\), \((1/2,-\sqrt{3}/2)\), \((1/2,\sqrt{3}/2)\), which centroid of triangle located at the origin of the coordinate system.

Step 2. Write the moment equations in polar coordinates [5].

Step 3. Minimize nonlinear moment equation for solving \(n_0 + 2n_1 +3n_2\) unknowns using the Levenberg–Marquardt algorithm.

Step 4. Transformation of the calculated areal coordinates to the isosceles right triangular domain \(\triangle _{\alpha \beta }\).

A new high ordered PI type rules that are not listed in the Encyclopedia of Quadrature Formulas [3, 12] are presented in Tables 1, 2, 3 and 4 calculated by the above algorithm implemented in Maple. In the considered problems, the maximal number of the nonlinear moment equations equals 44, and the number of unknowns equals 47 at \(p=20\). The explicit expressions for Gauss quadratures weights and areal coordinates with 32 significant digits were calculated, but are not presented here because of the paper size limitations. Note, the alternative equilateral triangle quadrature formulas were calculated in [17].

Table 4. The quadrature rule for \(p=20\), \(n_p=85\), type \([n_0,n_1,n_2]=[1,8,10]\)

4 The Algorithm for Calculating the Parametric Derivatives of Eigenfunctions and Effective Potentials

Taking a derivative of the boundary-value problem (1)–(5) with respect to the parameter z, we find that \(\partial _z \varPhi _i(x;z)\) is a solution of the following boundary-value problem with the mixed boundary conditions

$$\begin{aligned}&\left( {D}(x;z){-}\varepsilon _i(z) \right) \frac{\partial \varPhi _{i}(x; z)}{\partial z} {=}{-}\left[ \frac{\partial }{\partial z} \left( U(x;z){-}\varepsilon _i(z) \right) \right] \varPhi _{i}(x; z), \nonumber \\&\frac{\partial \varPhi (x;z)}{\partial z}\bigg |_{S}=0 \text{ or } \frac{\partial ^2\varPhi (x;z)}{\partial n_{D}\partial z}\Bigl |_{S}=0. \end{aligned}$$
(18)

The parametric BVP (18) has a unique solution, if and only if it satisfies the conditions

$$\begin{aligned}&\frac{\partial \varepsilon _i(z)}{\partial z}{=} \int _{\varOmega }dx g_0(x) \left( \varPhi _{i}(x; z)\right) \frac{\partial U(x; z)}{\partial z} \varPhi _{i}(x;z), \end{aligned}$$
(19)
$$\begin{aligned}&\int _{\varOmega } d x g_0(x) \varPhi _{i}(x; z) \frac{\partial \varPhi _{i}(x; z)}{\partial z}=0. \end{aligned}$$
(20)

Below we present an efficient numerical method that allows the calculation of \({\partial _z \varPhi _i(x;z)}\) with the same accuracy as achieved for the eigenfunctions of the BVP (1)–(5) and the use of it for computing the matrices of the effective potentials defined as

$$\begin{aligned} \ H_{ij}(z){=}H_{ji}(z){=}\int _{\varOmega }dx g_0(x) \frac{\partial \varPhi _i(x;z)}{\partial z} \frac{\partial \varPhi _j(x;z)}{\partial z}, \end{aligned}$$
(21)
$$\begin{aligned} Q_{ij}(z){=}{-}Q_{ji}(z){=}{-}\int _{\varOmega }dx g_0(x) \varPhi _i(x;z) \frac{\partial \varPhi _j(x;z)}{\partial z}. \ \end{aligned}$$
(22)

The boundary-value problem (18)–(20) is reduced to the linear system of inhomogeneous algebraic equations with respect to the unknown \( {\partial \varvec{\varPhi }^h}/{\partial z}\):

$$\begin{aligned} \ \mathbf {L}\frac{\partial \varvec{\varPhi }^h}{\partial z}\equiv (\mathbf{A}^p-\varepsilon ^h\mathbf {B}^p)\frac{\partial \varvec{\varPhi }^h}{\partial z}=b,\quad b=-\left( \frac{\partial \mathbf{A}^p}{\partial z}-\frac{\partial \varepsilon ^h}{\partial z}\mathbf {B}^p\right) \varvec{\varPhi }^h. \ \end{aligned}$$
(23)

The normalization condition (5), the condition of orthogonality between the function and its parametric derivative (20), and the additional conditions (19) for the solution of (23) read as

$$\begin{aligned} \left( \varvec{\varPhi }^h\right) ^T\mathbf {B}^p \varvec{\varPhi }^h=1,\quad \left( \frac{\partial \varvec{\varPhi }^h}{\partial z}\right) ^T\mathbf {B}^p \varvec{\varPhi }^h=0,\quad \frac{\partial \varepsilon ^h}{\partial z}=\left( \varvec{\varPhi }^h\right) ^T \frac{\partial \mathbf{A}^p}{\partial z}\varvec{\varPhi }^h. \end{aligned}$$
(24)

Then the potential matrix elements \(H_{ij}^h(z)\) and \(Q_{ij}^h(z)\) (21) can be calculated using the formulas

$$\begin{aligned} H_{ij}^h(z)=\left( \frac{\partial \varvec{\varPhi }^h_i}{\partial z}\right) ^T\mathbf {B}^p \frac{\partial \varvec{\varPhi }^h_j}{\partial z}, \quad Q_{ij}^h(z)=-\left( \varvec{\varPhi }^h_i\right) ^T\mathbf {B}^p \frac{\partial \varvec{\varPhi }^h_j}{\partial z}. \end{aligned}$$
(25)

Since \(\varepsilon ^h\) is an eigenvalue of (8), the matrix \(\mathbf {L}\) in Eq. (23) is degenerate. In this case, the algorithm for solving Eq. (23) can be written in three steps as follows:

Step k1. Calculate the solutions \(\mathbf{v}\) and \(\mathbf{w}\) of the auxiliary inhomogeneous systems of algebraic equations

$$\begin{aligned} \mathbf{\bar{L}} \mathbf{v}=\mathbf{\bar{b}}, \quad \mathbf{\bar{L}} \mathbf{w}= \mathbf{d}, \end{aligned}$$
(26)

with the non-degenerate matrix \(\mathbf{\bar{L}}\) and the right-hand sides \(\mathbf{\bar{b}}\) and \( \mathbf{d}\)

$$\begin{aligned} \bar{L}_{ss'}=\left\{ \begin{array}{ll} L_{ss'},&{} (s-S)(s'-S)\ne 0,\\ \delta _{ss'},&{}(s-S)(s'-S)=0,\end{array}\right. \end{aligned}$$
(27)
$$\begin{aligned} \bar{b}_{s}=\left\{ \begin{array}{ll} b_{s},&{} s\ne S,\\ 0,&{}s=S,\end{array}\right. \quad d_{s}=\left\{ \begin{array}{ll} L_{sS},&{} s\ne S,\\ 0,&{}s=S,\end{array}\right. \end{aligned}$$
(28)

where S is the number of the element of the vector \(\mathbf {B}^p\varvec{\varPhi }^h\) having the greatest absolute value.

Step k2. Evaluate the coefficient \(\gamma \)

$$\begin{aligned} \gamma =-\frac{\gamma _1}{(\mathbf {D}_S-\gamma _2)},\quad \gamma _1={\mathbf{v}}^T\mathbf {B}^p\varvec{\varPhi }^h,\quad \gamma _2=\mathbf{w}^T\mathbf {B}^p\varvec{\varPhi }^h,\quad \mathbf {D}_S=(\mathbf {B}^p\varvec{\varPhi }^h)_S. \end{aligned}$$
(29)

Step k3. Evaluate the vector \({\partial _z \varvec{\varPhi }^h}\)

$$\begin{aligned} \frac{\partial \varPhi ^h_s}{\partial z}=\left\{ \begin{array}{ll} v_s-\gamma w_s,&{} s\ne S,\\ \gamma ,&{}s=S.\end{array}\right. \end{aligned}$$
(30)

From the above consideration, it is evident that the computed derivative has the same accuracy as the calculated eigenfunction.

Let D(xz) in Eq. (1) be a continuous and bounded positive definite operator on the space \(\mathcal{H}^1\) with the energy norm, \(\varepsilon _i(z)\), \(\varPhi _i(x,z)\in \mathcal{H}^2\) being the exact solutions of Eqs. (1)–(5), and \(\varepsilon _i^h(z)\), \(\varPhi _i^h(x; z)\in \mathcal{H}^1\) being the corresponding numerical solutions. Then the following estimates are valid [13]

$$\begin{aligned}&\left| \varepsilon _i(z)-\varepsilon _i^h(z)\right| \le c_1h^{2p}, \quad \left\| \varPhi _i(x;z)-\varPhi _i^h(x; z)\right\| _0 \le c_2h^{p+1},\end{aligned}$$
(31)
$$\begin{aligned}&\Vert \varPhi _i(x;z)\Vert _0^2=\int _{\varOmega _x} dx g_0(x)\varPhi _i(x;z)\varPhi _i(x;z), \end{aligned}$$
(32)

where h is the largest distance between any two points in \(\varDelta _q\), p is the order of the finite elements, i is the number of the corresponding solutions, and the constants \(c_1\) and \(c_2\) are independent of the step h.

The following theorem can be formulated.

Theorem. Let D(xz) in Eq. (1) be a continuous and bounded positive definite operator on the space \(\mathcal{H}^1\) with the energy norm. Also let \(\partial _z U(x;z)\) be continuous and bounded for each value of the parameter z. Then for the exact values of the solutions \(\partial _z \varepsilon _i(z)\), \(\partial _z \varPhi _i(x;z)\in \mathcal{H}^2\), \(H_{ij}(z)\), \(Q_{ij}(z)\) from (18)–(21) and the corresponding numerical values \(\partial _z \varepsilon _i^h(z)\), \(\partial _z \varPhi _i^h(x;z)\in \mathcal{H}^1\), \(H_{ij}^h(z)\), \(Q_{ij}^h(z)\) from (23)–(25), the following estimates are valid:

$$\begin{aligned}&\left| \frac{\partial \varepsilon _i(z)}{\partial z}- \frac{\partial \varepsilon _i^h(z)}{\partial z}\right| \le c_3h^{2p}, \quad \left\| \frac{\partial \varPhi _i(x;z)}{\partial z} -\frac{\partial \varPhi _i^h(x;z)}{\partial z}\right\| _0 \le c_4h^{p+1}, \nonumber \\&\left| Q_{ij}(z)-Q_{ij}^h(z)\right| \le c_5h^{2p},\quad \left| H_{ij}(z)-H_{ij}^h(z)\right| \le c_6h^{2p}, \end{aligned}$$
(33)

where h is the largest distance between any two points of the finite element \(\varDelta _q\), p is the order of finite elements, i, j are the numbers of the corresponding solutions, and the constants \(c_3\), \(c_4\), \(c_5\), and \(c_6\) are independent of the step h.

The proof is straightforward following the scheme in accordance with [13].

5 Benchmark Calculations of Helium Atom Ground State

In the hyperspheroidal coordinates \(0\le R<\infty \), \(1\le \xi <\infty \), \(-1\le \eta \le 1\)

$$\begin{aligned}&r_{12}=\frac{\sqrt{2}R}{\sqrt{\xi ^2+\eta ^2}},\quad r_1=\frac{R(\xi +\eta )}{\sqrt{2}\sqrt{\xi ^2+\eta ^2}},\quad r_2=\frac{R(\xi -\eta )}{\sqrt{2}\sqrt{\xi ^2+\eta ^2}} \end{aligned}$$
(34)

the equation for the wave functions \(\varPsi (R,\xi ,\eta )=\sqrt{\xi ^2+\eta ^2}\varPhi (R,\xi ,\eta )\) for S-states of the Helium atom reads as [15]

$$\begin{aligned}&\Bigg [-\frac{1}{R^5}\frac{\partial }{\partial R}R^5\frac{\partial }{\partial R}-\frac{3}{R^2}-\frac{1}{R^2}\frac{(\xi ^2+\eta ^2)^2}{\xi ^2-\eta ^2}\left( \frac{\partial }{\partial \xi }(\xi ^2-1)\frac{\partial }{\partial \xi }+\frac{\partial }{\partial \eta }(1-\eta ^2)\frac{\partial }{\partial \eta }\right) \nonumber \\&\qquad +\sqrt{2}\frac{\sqrt{\xi ^2+\eta ^2}}{R}\left( 1-\frac{8\xi }{\xi ^2-\eta ^2}\right) -2E\Bigg ]\varPhi (R,\xi ,\eta )=0. \end{aligned}$$
(35)

The function \(\varPhi (R,\xi ,\eta )\) satisfies the boundary conditions

$$\begin{aligned}&\lim _{R\rightarrow 0}R^5\frac{\partial \varPhi (R,\xi ,\eta )}{\partial R}=0 , \quad \lim _{R\rightarrow \infty }R^5 \varPhi (R,\xi ,\eta )=0,\nonumber \\&\lim _{\xi \rightarrow 1}(\xi ^2-1)\frac{\partial \varPhi (R,\xi ,\eta )}{\partial \xi }=0, \quad \lim _{\xi \rightarrow \infty }\varPhi (R,\xi ,\eta )=0,\nonumber \\&\lim _{\eta \rightarrow \pm 1}(1-\eta ^2)\frac{\partial \varPhi (R,\xi ,\eta )}{\partial \eta }=0, \end{aligned}$$
(36)

and is normalized by the condition

$$\begin{aligned} 8\pi ^2\int _0^\infty dR R^5\int _1^\infty d\xi \int _{-1}^{1} d\eta \frac{\xi ^2-\eta ^2}{(\xi ^2+\eta ^2)^2} \varPhi ^2(R,\xi ,\eta )=1. \end{aligned}$$
(37)

The parametric function \(\phi _i\equiv \phi _i(\xi ,\eta ;R)\) and the corresponding potential curves \(\varepsilon _i(R)\) are eigensolutions of the 2D BVP having a purely discrete spectrum

$$\begin{aligned} \!\!\! \!\!\!\Bigg [{-}\frac{\partial }{\partial \xi }(\xi ^2{-}1)\frac{\partial }{\partial \xi }{-}\frac{\partial }{\partial \eta }(1{-}\eta ^2)\frac{\partial }{\partial \eta }{+}\frac{\sqrt{2}R\left( \xi ^2{-}\eta ^2{-}8\xi \right) }{\sqrt{\xi ^2{+}\eta ^2}^3}{-} \varepsilon _i(R)\frac{\xi ^2{-}\eta ^2}{(\xi ^2{+}\eta ^2)^2}\Bigg ]\phi _i=0\ \end{aligned}$$
(38)

subject to the following boundary conditions

$$\begin{aligned} \lim _{\xi \rightarrow 1}(\xi ^2{-}1)\frac{\partial \phi _i(\xi ,\eta ;R)}{\partial \xi }=0, \quad \lim _{\xi \rightarrow \infty }\phi _i(\xi ,\eta ;R)=0, \quad \lim _{\eta \rightarrow \pm 1}(1{-}\eta ^2)\frac{\partial \phi _i(\xi ,\eta ;R)}{\partial \eta }=0, \end{aligned}$$

and the normalization condition

$$\begin{aligned} \int _1^\infty d\xi \int _{-1}^{1} d\eta \frac{\xi ^2-\eta ^2}{(\xi ^2+\eta ^2)^2} \phi _i^2(\xi ,\eta ;R)=1. \end{aligned}$$
(39)

In terms of scaled variable and parametric surface functions

$$\begin{aligned} \xi =\frac{1+\lambda }{1-\lambda },\quad 0\le \lambda <1, \quad \phi _i(\xi ,\eta ;R)=\frac{p_i(\xi ,\eta ;R)}{\xi +1}\equiv \frac{p_i(\lambda ,\eta ;R)}{\xi +1}, \end{aligned}$$
(40)

we rewrite the 2D BVP (38)–(39) in the form

$$\begin{aligned}&\Bigg [{-}\frac{\partial }{\partial \lambda }\lambda (1{-}\lambda )^2\frac{\partial }{\partial \lambda }{-}\frac{\partial }{\partial \eta }(1{-}\eta ^2)\frac{\partial }{\partial \eta } {+}\sqrt{2}R(1{-}\lambda )\frac{(1{+}\lambda )^2{-}(1{-}\lambda )^2\eta ^2{-}8(1{-}\lambda ^2)}{\sqrt{(1{+}\lambda )^2{+}(1{-}\lambda )^2\eta ^2}^3}\nonumber \\&{+}1{-}\lambda {-} \varepsilon _i(R)(1{-}\lambda )^2\frac{(1{+}\lambda )^2{-}(1{-}\lambda )^2\eta ^2}{((1{+}\lambda )^2{+}(1{-}\lambda )^2\eta ^2)^2}\Bigg ]p_i(\lambda ,\eta ;R)=0. \end{aligned}$$
(41)

The surface functions \(p_i(\lambda ,\eta ;R)\) satisfy the following boundary and normalization conditions

$$\begin{aligned}&\lim _{\lambda \rightarrow 0,1}\lambda (1{-}\lambda )\frac{\partial p_i(\lambda ,\eta ;R)}{\partial \lambda }=0, \quad \lim _{\eta \rightarrow \pm 1}(1{-}\eta ^2)\frac{\partial p_i(\lambda ,\eta ;R)}{\partial \eta }=0,\quad \end{aligned}$$
(42)
$$\begin{aligned}&\frac{1}{2}\int _0^1 \!\!\!d\lambda \int _{-1}^{1} d\eta (1{-}\lambda )^2\frac{(1{+}\lambda )^2{-}(1{-}\lambda )^2\eta ^2}{((1{+}\lambda )^2{+}(1{-}\lambda )^2\eta ^2)^2} p_i^2(\lambda ,\eta ;R)=1. \end{aligned}$$
(43)

The numerical experiments in the finite-element grids have shown a strict correspondence with the theoretical estimations (31) and (33) for the eigenvalues, eigenfunctions, and the matrix elements. In particular, we calculated the values of the Runge coefficients

$$\begin{aligned} \beta _l=\log _2\left| (\sigma ^h_l-\sigma ^{h/2}_l)/(\sigma ^{h/2}_l-\sigma ^{h/4}_l)\right| , \quad l=1,2, \end{aligned}$$
(44)

with absolute errors on three twice condensed grids for their eigenvalues and eigenfunctions, respectively

$$\begin{aligned}&\sigma ^h_1=|E_m^{2h}(z)-E_m^h(z)|,\quad \sigma ^h_2=\Vert \varPhi _m^{2h}(x;z)-\varPhi ^h_m(x;z)\Vert _0. \end{aligned}$$
(45)
Table 5. Comparison of the transformed potential curves \(E_j(R)=(\varepsilon _j(R)-3)/4\) and their first derivative with respect to parameter R with results [9] at \(j_{\max }=12\). The mesh points are \(\lambda =\{0(L)1\}\) and \(\eta =\{0(L)1\}\), and \(R=7.65\) a.u.
Table 6. Matrix elements \(H_{ji}(R)\), \(i,j=1,...,6\) at \(R=7.65\).
Table 7. Matrix elements \(Q_{ji}(R)\), \(i,j=1,...,6\) at \(R=7.65\).
Fig. 1.
figure 1

The eigenfunction \(p_1(\lambda ,\eta ;R)\) and its parametric derivative \(\partial _R p_1(\lambda ,\eta ;R)\) at \(R=7.65\).

Fig. 2.
figure 2

The eigenfunction \(p_4(\lambda ,\eta ;R)\) and its parametric derivative \(\partial _R p_4(\lambda ,\eta ;R)\) at \(R=7.65\).

The Runge coefficients for six eigenvalues presented in Table 5 equal \(7.52\ \div \ 8.19\) and for their parametric derivatives equal \(7.46\ \div \ 7.76\) are nearly similar and correspond to the theoretical estimates (31) and (33) for the fourth-order scheme (\(2p\approx 8\)).

The calculations were carried out using the server 2\(\,\times \,\)4 kernels i7k (i7-3770K 4.5 GHz, 32 GB RAM, GPU GTX680), and the Intel Fortran compiler 17.0. The computing time for the considered examples with \(10^{-12}\) accuracy on the uniform grids \(\lambda =\{0(L)1\}\), \(\eta =\{0(L)1\}\) at \(L=10,20,40\) is 0.38, 5.08, and 41.21 s, respectively. The matrix elements \(Q_{ij}(R)\) and \(H_{ij}(R)\) are presented in Tables 6 and 7. As an example eigenfunctions and their parametric derivatives are shown in Figs. 1 and 2.

We seek for the solution of the BVP (35)–(37) by Kantorovich expansion

$$\begin{aligned} \varPhi (R,\xi ,\eta )=\sum _{j=1}^{j_{\max }}\phi _j(\xi ,\eta ;R)\chi _j(R) \end{aligned}$$
(46)

over the eigenfunctions \(\phi _j(\xi ,\eta ;R)\) of the parametric 2D BVP having a purely discrete spectrum \(E_{j}(R)=(\varepsilon _j(R)-3)/R^2, j=1,2,...\). Substituting expansion (46) into the 3D BVP Eqs. (35)–(37), we get the 1D BVP for a finite set of \(j_{\max }\) coupled SOODEs for \(\varvec{\chi }(R)=\{\chi _1(R),...,\chi _N(R)\}^T\)

$$\begin{aligned}&\left( {-} \frac{1}{R^5}\mathrm{\mathbf{I}}\frac{d}{d{ R}}R^5 \frac{d}{d{ R}} {+}{} \mathbf{V^{}}({ R}) {+} \mathbf{Q}({ R})\frac{d}{d R}{+} \frac{1}{R^5} \frac{d R^5\mathbf{Q}({ R})}{dR}{-}2E\, \mathbf{I}\right) \varvec{\chi }^{}(R)=0, \end{aligned}$$

with the boundary and normalization conditions

$$\begin{aligned}& \lim _{R\rightarrow 0}R^5\frac{d \varvec{\chi }^{}(R)}{d R}=0, \quad \lim _{R\rightarrow \infty }R^5 \varvec{\chi }^{}(R)=0,\quad 8\pi ^2\int _0^\infty dR R^5(\varvec{\chi }^{}(R))^T\varvec{\chi }^{}(R)=1. \end{aligned}$$

The solution of this BVP with the help of KANTBP program [8] on the non-uniform grids \(R=\{0(50),5,(75),20\}\) using calculated \(E_j(R)\), \(V_{ij}(R)=H_{ij}(R)\), \(V_{jj}(R)=H_{jj}(R)+E_j(R)\), \(Q_{ij}(R)\), \(i,j=1,...,12\) gives us the energy of Helium atom ground state \(E_1=-2.90372430\) a.u. with 8 significant digits.

6 Conclusion

We have elaborated new calculation schemes, algorithms, and the program for solving the parametric 2D elliptic BVP using the high-accuracy FEM with triangular elements. The program calculates the potential matrix elements, the integrals of the eigenfunctions multiplied by their first derivatives with respect to the parameter. The parametric eigenvalues (potential curves) and the matrix elements computed by the program can be used for solving the bound-state and multi-channel scattering problems for a system of the coupled second-order ODES with using the Kantorovich method. We demonstrated the efficiency of the proposed finite element schemes, algorithms, and codes by benchmark calculations of BVPs of helium atom ground state.

The work was partially supported by the Russian Foundation for Basic Research (grants Nos. 16-01-00080 and 17-51-44003 Mong_a) and the Bogoliubov-Infeld program. The reported study was funded by the Agreement N 02.03.21.0008 dated 24.04.2016 between the MES of the RF and RUDN University.