## A neural network approach to running high-precision atomic computations

Pavlo Bilous, 1, ∗ Charles Cheung, 2 and Marianna Safronova 2

1 Max Planck Institute for the Science of Light, Staudtstr. 2, 91058 Erlangen, Germany

2 Department of Physics and Astronomy, University of Delaware, Delaware 19716, USA (Dated: August 2, 2024)

Modern applications of atomic physics, including the determination of frequency standards, and the analysis of astrophysical spectra, require prediction of atomic properties with exquisite accuracy. For complex atomic systems, high-precision calculations are a major challenge due to the exponential scaling of the involved electronic configuration sets. This exacerbates the problem of required computational resources for these computations, and makes indispensable the development of approaches to select the most important configurations out of otherwise intractably huge sets. We have developed a neural network (NN) tool for running high-precision atomic configuration interaction (CI) computations with iterative selection of the most important configurations. Integrated with the established pCI atomic codes, our approach results in computations with significantly reduced computational requirements in comparison with those without NN support. We showcase a number of NN-supported computations for the energy levels of Fe 16+ and Ni 12+ , and demonstrate that our approach can be reliably used and automated for solving specific computational problems for a wide variety of systems.

## I. INTRODUCTION

Accurate modeling of electronic correlations in atoms and ions is a ubiquitous problem in modern atomic physics. It is typically addressed using the configuration interaction (CI) approach [1], which consists in expanding the wave function of the searched electronic states | Ψ ⟩ = ∑ α c α | Φ α ⟩ in a fixed basis | Φ α ⟩ (usually Slater determinants or configuration state functions). The unknown coefficients c α for each state and the state energies E α are then obtained as solutions to the eigenvalue problem for the Hamiltonian matrix H αβ = Φ ⟨ α | ˆ Φ H | β ⟩ . For accurate computations, the required basis set | Φ α ⟩ can become huge, posing high demands both on the hardware and the atomic codes, which need to be highly efficient and parallelized. Even then, the required precision remains often beyond the computational feasibility.

Re and Os atoms were performed. The results were compared with Ref. [4], where the CI problem was simplified down to a tractable scale using experimental data for electronic transition and excitation energies. The comparison showed a good agreement leading to the conclusion that the NN-supported algorithm yielded reliable results.

In a recent work [2], an algorithm using a neural network (NN) was demonstrated to tackle big CI computations for the GRASP2018 general relativistic atomic structure package [3]. In this approach, one large CI computation is replaced by a number of smaller ones on a subsequently growing sub-basis. The basis growth is managed by a NN classifier that receives the basis state quantum numbers as input. In each iteration, it predicts the important basis states from the full set, i.e. those with weights w α = | c α | 2 exceeding a specified cutoff x . They are then included in the CI computation that yields the energy and the coefficients c α . The latter are used to give the NN feedback on its prediction and retrain it. The 'importance' cutoff x is decreased from iteration to iteration, leading to convergence of the energy to its 'true' value on the full set. In Ref. [2], otherwise unfeasible computations for the ground state energy of the

∗ pavlo.bilous@mpl.mpg.de

Unfortunately, in many cases, there are no experimental data to carry out such benchmarks as in Ref. [2]. This is especially the case in the domain of highly charged ions, which has yet to be thoroughly explored, but has recently been of great interest, due to its promising applications [5]. Therefore, it is necessary to have at hand an independent systematic ab initio approach, which would ensure the validity of the NN-supported computations. Further analysis of the computations in Ref. [2] suggests that the required NN-related part was itself computationally demanding. The usual dense NN architectures failed, and only switching to a deep convolutional architecture tailored specifically to the structure of the input data (in Ref. [2], configuration state functions) led to a stable behavior. Even on a GPU, the training of such NN took time comparable with the atomic computation in each iteration.

Here, we introduce significant algorithmic improvements and simplifications to the approach from Ref. [2], making the computational overhead beyond the actual CI computations negligible. Instead of using the GRASP package [3] to implement CI, we use the pCI code package developed in Ref. [6] to carry out extremely large-scale parallel CI computations. This package can be also used in combination with the coupled-cluster method and has demonstrated exceptional accuracy for a wide variety of many-electron systems, including neutral atoms, highlycharged ions, and negative ions [7-13]. With the new implementation, the NN part needs only tens of minutes on a single CPU, which is negligible in comparison to the large-scale CI computation. We also generalize

the method from computations for only one electronic level (e.g. the ground state as in Ref. [2]) to many levels at once, i.e., yielding the electronic transition energies. The latter are undoubtedly of superior relevance in atomic physics and its applications. The computations performed in this work contained up to 17 levels at once. Importantly, we show how the obtained results can be verified using an alternative approach to perform large CI computations 'by parts' without the NN. The developments in this work promote the NN-supported algorithm to a generic practical tool for high precision atomic computations.

As demonstration, we perform calculations of the energy levels on particularly large basis sets for the highly charged Fe 16+ and Ni 12+ ions. While Fe 16+ is directly relevant for understanding the astrophysical spectra, the Ni 12+ ion possesses a clock transition between its ground and second excited state, and thus has potential in metrology. These ambitious applications require high precision of a few cm -1 , which we achieve in our computations using the two complementary algorithms, with and without a NN. In these cases, obtaining a high level of accuracy requires the use of very large basis sets, with both large number of partial waves and large principal quantum numbers. The procedure to increase the basis set to numerical completeness at the required precision level is usually extremely costly in terms of computational resources. It also requires submission of a large number of multiple runs that limits such computations to a few exceptional cases. In the present work, we show that the NN-supported algorithm can solve the problem of the basis set increase with complete NN automation, as well as drastic reduction of the computer resource requirements, enabling future automated basis set upscaling for increased accuracy of computations.

The article is structured as follows. In Section II, we present the details of our CI computations and, in particular, the alternative approach to perform large CI computations by parts, without NN support. In Section III, we describe in detail our NN-supported algorithm and highlight the improvements with respect to Ref. [2]. Section IV contains the demonstration computations for the Ni 12+ and Fe 16+ ions. We finish the article by summarizing our conclusions in Section V.

## II. CI COMPUTATIONS

All calculations are carried out using the CI method to correlate all valence electrons. We construct one-electron orbitals from solutions of the Hartree-Fock-Dirac (HFD) equations in the central field approximation. The basis set is designated by the highest principal quantum number for each included partial wave. For example, 17 g means that all orbitals up to n = 17 are included for the spd fg partial waves.

The CI many-electron wave function is obtained as a linear combination constructed from all distinct states and possessing a given total angular momentum and parity:

$$| \Psi ^ { k } \rangle = \sum _ { \alpha } c _ { \alpha } ^ { k } \left | \Phi _ { \alpha } \right \rangle \,. \quad \quad \quad ( 1 )$$

Here the index α labels the involved Slater determinants | Φ α ⟩ , whereas k enumerates the many-electron states. The energies and wave functions are determined from the time-independent many-electron Schr¨dinger equation o

$$\hat { H } \left | \Psi ^ { k } \right \rangle = E ^ { k } \left | \Psi ^ { k } \right \rangle \,.$$

We construct one-electron basis orbitals from solutions of the HFD equations in the central field approximation. In general, we start by building core orbitals for the ground state configuration. Then we freeze those orbitals and construct valence orbitals for a few excited states. Virtual orbitals are then built from the HFD orbitals. A list of configurations defining the CI space is then obtained from all possible single (S) and double (D) excitations to any orbital in our basis set from a few selected reference configurations (typically the ground state and a few excited states). The Hamiltonian is then constructed and diagonalized to obtain the desired eigenvalues and eigenvectors.

This procedure is completed for increasing basis sets (increasing principal quantum number n or partial wave l ) to identify the convergence pattern towards the most accurate results. This process is repeated until (1) either the energies have converged, or (2) the computation becomes too large for the available computational resources. Once the energies have converged as in (1), we consider our computations to be completed; otherwise, we treat (2) via a method optimizing and reducing the size of the CI space.

## A. Upscaling the basis set

For computations of basis sets that cannot be run directly on currently available computational resources, we opt to reduce the size of the CI space by selecting only the most important configurations for subsequent calculations via some cutoff x . From a previously completed direct CI calculation, a configuration subspace corresponding to only the most important configurations can be generated. The importance of a configuration is determined by its weight w α = | c α | 2 . An optimal cutoff x is determined by balancing the number of configurations obtained from the cut, and the subsequent energy difference between the direct run and the cut run. This cutoff x is typically chosen such that the resulting energy difference is minimized for any resulting energy level. This energy difference is then subtracted from the results of the subsequent CI calculation involving an increased principal quantum number n or increased partial wave l . We refer to this procedure of systematically increasing the basis set from a selected list of important configurations as upscaling the basis set .

As an example, we describe the process of upscaling the 17 h basis set to the 20 h basis set. In this case, we have completed the CI calculation for the 17 h basis set, but 20 h was not possible. Here, a cut log 10 x = -10 is used to reduce the size of the 17 h basis set, with the resulting subspace consisting of only the most important configurations (we will denote it as 17 h cut). This cut reduces the size of the CI space from 242 924 relativistic configurations (41 071 940 Slater determinants) to 89 861 (13 345 491). We then construct a list of configurations obtained from increasing 17 h to 20 h and merge this list to the 17 h cut list. The resulting configuration list contains 17 h cut + (20 h -17 h ). The CI procedure is then executed using this basis set to obtain the desired energies from the 20 h basis set. However, it is important then to also subtract the energy difference due to the cut that was made to the 17 h basis. So the final energy in the 20 h calculation is E 20 h = E 17 h cut+(20 h -17 h ) -E 17 h cut -17 h . In this way, we are able to approximate the exact CI results of the 20 h basis by performing much smaller computations. We note that this procedure is still very time consuming and still requires both large memory and CPU allocations.

## III. NN-SUPPORTED ALGORITHM

In this section, we discuss a powerful alternative to the direct CI described above. We introduce our NNsupported iterative algorithm illustrated schematically in Fig. 1, and highlight the improvements with respect to Ref. [2]. Here, we work not with the basis Slater determinants, but instead with relativistic configurations, which are constructed from the determinants. The weight of each configuration Γ is obtained from the individual basis coefficients as w k Γ = ∑ α ∈ Γ | c k α | 2 , where, as before, k labels the considered energy level. We perform our computations for all levels of interest at once, and aggregate their weights in one weight as w Γ = max k w k Γ . Given a large 'full' set of configurations not tractable with the direct CI, the algorithm aims at forming an approximative CI subset of the most relevant configurations in the sense of their weight w Γ . This approximative set (the 'current' CI expansion) is improved with iterations by including further configurations from the remaining 'pool', consisting of configurations from the full set which are currently not included in the CI expansion.

## A. 'Starting' stage

At the beginning, we need to form an initial CI expansion, which serves as data for the initial NN training. We assume that before our algorithm starts, a computation on a smaller sub-basis of the full basis has already been performed. For instance, a computation for a smaller number of virtual orbitals can serve this purpose. Alternatively, the results of another NN-supported computa- tion can be employed.

We construct the 'starting' CI space by combining the initial CI space with a number of configurations chosen randomly from the remainder of the full basis. This set of randomly chosen configurations is needed for (a) the NN to explore the data not represented in the preceding computation, and for (b) mitigation of possible bias towards the 'important' class of the training data. Note that the CI coefficients for the random selection are not yet known, and therefore a CI computation is performed at this step to calculate them. In case the obtained set is too big, a part of the sub-basis from the previous computation with weights below some cutoff y can be omitted at this stage. We stress that this omission is done only for this particular CI computation step, since the aim is only evaluation of the CI coefficients for the random selection. The CI expansion obtained at the described 'starting' stage is schematically shown to the left in Fig. 1.

## B. Iterations

We now enter the NN-supported iterations shown in Fig. 1 in the box to the right. At step (A), we assume that the CI expansion contains configurations from the 'starting' stage described above or from the previous iteration [finished at (F)]. In the latter case, we distinguish between the configurations added directly in the previous iteration and the ones present in the CI expansion before (the latter are denoted as 'old'). Each iteration is characterized by its own importance cutoff x , which is decreased during the computation. At step (B), the newly added configurations in the CI expansion are distributed into the two importance classes with respect to the current cutoff x . At the next step (C), the NN is retrained on the obtained data and predicts new important configurations from the pool.

At step (D), we randomly select a number of configurations discarded by the NN, since the NN needs some feedback on them at the next iteration. This 'balancing' is characterized by the ratio r bal between the number of the randomly included configurations and the number of configurations classified by the NN as important. For larger r bal values, the NN performs better in the next iteration, but the current CI expansion includes randomly selected and thus mostly irrelevant configurations, making the computational overhead larger. For small r bal values, the computational overhead in the current iteration decreases, but in the next iteration, the NN may perform poorly, suggesting many irrelevant configurations. In Ref. [2], the value r bal = 1 was used, whereas in the present work, the choice r bal = 0 5 is sufficient. . We note that in the very last iteration, r bal = 0 can be chosen since no NN retraining follows.

At step (E), the current CI expansion is 'cleaned up' by removing the configurations belonging to the 'unimportant' class from step (D). We note that since the cutoff x is iteratively decreased, and the NN state evolves

![image](https://ac.marcodsn.me/arxiv-markdown-images/2408.00477v1-figure-ad7d6209-1702-45f8-89ee-7f4c96a1c994.jpg)

FIG. 1. Schematic representation of the iterative NN-supported algorithm described in the text. The thin big ellipse denotes the full set of configurations (potentially intractable with a direct CI approach). The subsets shown with thick ellipses are all included in the current CI expansion. The blue color denotes configurations for which the CI expansion coefficients have been already evaluated. The green (red) color depicts the important (unimportant) configurations with respect to the current cutoff x - this is established either directly (if the CI coefficients are known) or using the NN. Note that the different shades of red are irrelevant. The algorithm begins with the 'starting' stage (shown to the left) which assumes that a direct or NNsupported computation has been previously performed on a partial subset of the full set. A number of random configurations is additionally included, and a CI computation is performed yielding the coefficients for the included configurations. The algorithm then enters stage (A) of the NN-supported iterations (shown in the box to the right). The CI expansion contains some configurations either from the 'starting' stage or the previous iteration [finished at stage (F)]. In the latter case, we distinguish between the configurations added directly in the previous iteration and the ones present in the CI expansion before - the latter are denoted as 'Old'. At stage (B), we split the set of the 'newly added' configurations into the important and unimportant classes with respect to the current cutoff x , and thus form a training set for the NN. The NN is trained and applied to classification of configurations from the pool at stage (C). At stage (D), a number of additional 'balancing' configurations is randomly selected. At stage (E), the unimportant configurations are removed from the current CI expansion, whereas the NN-predicted and the 'balancing' ones are included. At stage (F), the CI computation on the formed CI set is performed, finishing the iteration. The energy obtained at (F) is monitored to terminate the algorithm once convergence is achieved.

![image](https://ac.marcodsn.me/arxiv-markdown-images/2408.00477v1-figure-0434c37f-1028-4358-a2ec-6d21308eaa83.jpg)

with further training, these removed configurations may be classified by the NN as important and re-included in future iterations. The CI expansion is now enriched with the new configurations, and the CI computation is performed at step (F), yielding the energy levels and the CI expansion coefficients. The convergence of the energies is monitored and the algorithm is stopped once the targeted precision is achieved.

## C. NN architecture and training

For each relativistic configuration, the input data consist of populations of the electronic orbitals. We convert this discrete input to a binary format by directly transforming the integer orbital populations to their binary code. Each binary digit is then treated as a feature in the transformed data. After this transformation, some of the resulting features may turn out to be trivial, i.e. constant (0 or 1) across the whole dataset, and are deleted. The NN output consists of 2 numbers interpreted as the probabilities of the input configuration to be important or unimportant. The probabilities are guaranteed to sum up to 1 by using the softmax activation function in the NN output layer.

With fixed input and output structure, there remains freedom in choice of the internal NN architecture. In contrast to Ref. [2], where convolutional NNs were used, here, we employ the usual dense NNs [14]. In all computations, we include 4 hidden layers, each with a few tens to a few hundreds of neurons, resulting in a number of trainable parameters of the order of 10 5 (concrete sizes of the input and the NN layers will be specified for each example separately). The NN is trained to minimize the categorical cross-entropy loss using the Adam optimization algorithm [15]. The training is stopped based on the NN performance monitored on 20% of the data held out randomly from the training set. The described functionality is leveraged using the Python library TensorFlow [16].

## D. Algorithm improvements

Here, we explicitly highlight the main improvements with respect to the algorithm developed in Ref. [2].

A crucial change with respect to Ref. [2] consists in treating the basis states in groups of Slater determinants corresponding to relativistic configurations instead of considering them individually. The weight of a configuration Γ is the sum of the individual weights of the participating basis states w k Γ = ∑ α ∈ Γ | c k α | 2 . In this case, all information distinguishing the basis states within a single relativistic configuration is discarded. This has two major advantages. This significantly simplifies the input structure and reduces the number of features (the dataset 'width') without harming the quality of the results, and this strongly reduces the amount of data (the dataset 'length') and is advantageous for large computations. The resulting data are well compatible with the commonplace dense NN architecture. This leads to a stable and well reproducible computation flow and results, without the need of introducing a deep convolutional block as in Ref. [2].

Another advantage of switching to relativistic configurations is a unification of computations performed in the basis of Slater determinants (used in the present work) and configuration state functions (used in Ref. [2]). Specifically for our atomic code package [6], this choice also corresponds to the standard input/output mechanism.

## 2. Multilevel optimization

In this work, we obtain all energy levels of interest in one computation, rather than optimizing them one by one, as described in Ref. [2]. We achieve this by switching from individual weights w k Γ for each k -th energy level to an 'aggregated' weight w Γ = max k w k Γ for each relativistic configuration Γ. With this choice, a configuration becomes important if it is important for at least one energy level. We note that other aggregation approaches tailored to a specific computation can be employed here.

A special challenging situation occurs in computations for the Ni 12+ ion due to an extreme closeness of its 1st and 2nd excited states, lying approximately 600 cm -1 apart. Optimization for each level separately in an independent computation based on the algorithm from Ref. [2] led to a wrong ordering of the levels and difficulties in their identification. In our improved algorithm, all levels are optimized, preventing such mixing due to poor quality energies. This makes our approach practical also in such peculiar situations.

## 3. Starting from a prior computation (direct or NN-supported)

In our algorithm, each iterative computation starts not from scratch as in Ref. [2], but from the output of a prior (direct or NN-supported) computation. This approach is compatible with the standard basis expansion procedures in atomic computations, e.g. increasing the highest principal quantum number n for the included virtual orbitals. More importantly, the information from the previous computation is reused for the starting training of the NN classifier. This resolves the issue of the 'starting' iteration, in which the NN is not yet trained, and thus unable to predict important basis states. In Ref. [2], random basis states were drawn from the full set and included in the computation as the initial training dataset. A great disadvantage of such approach is strongly unbalanced data due to the lack of important basis states in the random selection. This severely contributes to instabilities, which had to be tackled in Ref. [2] at a high computational cost, but are circumvented in this work. With this improvement, there is also no need to manually select a so-called 'primary set' to be explicitly included in each iteration as in Ref. [2].

## IV. DEMONSTRATION COMPUTATIONS

In this section, we demonstrate our approach by performing computations on particular basis sets for:

- A) 5 lowest Ni 12+ levels (belonging to the ground state fine structure);
- B) 5 lowest even states of the Fe 16+ ion;
- C) 17 lowest odd states of the Fe 16+ ion.

These examples cover the most relevant aspects of the NN-supported computations. We concentrate here on obtaining high precision results using the improved version of the algorithm, and refer to Ref. [2] for further demonstration and discussions of the basic procedure.

## A. Numerical results

## 1. Five lowest states of Ni 12+

We start with a demonstration of our NN-supported approach for computations of the five lowest energy levels of Ni 12+ , which all belong to the ground state fine structure. Such ions with optical narrow transitions are of particular importance to the development of highlycharged-ion clocks [5]. We consider Ni 12+ with a closed core [1 s 2 2 s 2 2 p 6 ] and ground state configuration 3 s 2 3 p 4 with 6 valence electrons. The core can be accounted for using the coupled-cluster approach as in e.g. Ref [17], so here we focus on making the 6-electron CI computation complete with respect to the basis set convergence.

The full basis is constructed by SD excitations from the reference electronic configurations 3 s 2 3 p 4 , 3 s 3 p 4 3 d and 3 s 2 3 p 2 3 d 2 to the orbitals up to 22 spd fgh 20 ikl , resulting in 862 788 relativistic configurations (208 827 180 Slater

determinants). For this set of orbitals, the number of features after the binary transformation of the input data (see Section III C) is 575. We use 4 hidden NN layers of sizes 150, 75, 45, 20, resulting in 102 107 trainable NN parameters. We perform a full CI computation on a restricted subset of 171 644 configurations (24 064 676 Slater determinants) obtained by limiting the basis set to 17 spd fg , and use it as the starting point for the NNsupported computation.

In Table I, we compare the energies of the lowest 5 levels evaluated using the direct CI computation (performed using the basis upscaling technique described in Section II A) and obtained for iterations of the NNsupported approach. The latter are labeled by their cutoff value x ; the 'starting' stage is also presented. The final energy value in the NN-supported algorithm is obtained by exponential extrapolation of the values in the iterations (discussed in more detail later in the text). The energies E k direct from the direct CI computation are shown in Hartree units, whereas the energies obtained in the NN-supported algorithm are counted from the corresponding E k direct values and are measured in cm -1 . It is seen that in the subsequent iterations with decreasing importance cutoff x , the energies E k i are refined and converge eventually to the values E k direct with the targeted precision of a few cm -1 . The resulting basis set from the NN consists of 145 490 configurations, a factor of approximately 6 times less than that of the full basis set. Note that the energy differences between the levels obtained using the two computation methods agree within an error of 1 cm -1 smaller than for the individual levels. We attribute this cancellation effect to the similarity of the considered levels, since they all belong to the fine structure of the same electronic state.

## 2. Five even energy levels of Fe 16+

Next, we compute the 5 lowest even-parity energy levels of the highly charged Fe 16+ ion. Here, we consider all 10 electrons to be active, and allow SD excitations to vacancies in all orbitals up to 24 h starting from 3 reference configurations 1 s 2 2 s 2 2 p 6 , 1 s 2 2 s 2 2 p 5 3 p , and 1 s 2 2 s 2 p 6 3 . s This leads to 649 195 relativistic configurations, corresponding to 48 174 193 Slater determinants, which is beyond our computational capabilities for a direct CI computation on the full set. The number of data features is in this case 469, and 4 hidden NN layers of size 469, 469, 234 and 117, respectively, were used, resulting in 578 571 trainable NN parameters. The 'starting' set is constructed as follows. We begin with a subset of 204 487 relativistic configurations obtained from the full basis by restricting the virtual orbitals by 17 g . We perform a full CI computation on this set, and then omit all nonrelativistic configurations with weights below 10 -11 . The resulting subset consists of 133 276 relativistic configurations, corresponding to 9 148 479 Slater determinants. In Table II, we summarize the results of our computations in the same manner as in the previous section. The final approximative CI expansion contains 207 604 relativistic configurations.

## 3. 17 odd energy levels of Fe 16+

We proceed now to the lowest 17 odd states of the Fe 16+ ion, and target a challenging number of energy levels computed at the same time. As in the preceding section, we construct the full basis by allowing SD excitations for all 10 electrons to higher orbitals up to 24 h . The reference configurations are now 1 s 2 2 s 2 2 p 5 3 , s 1 s 2 2 s 2 2 p 5 3 d , and 1 s 2 2 s 2 p 6 3 p . This gives 947 766 relativistic configurations (94 527 257 Slater determinants) in the full basis set. The same number of features is present in the NN input data and the same NN structure was used here as in the computations for the even Fe 16+ levels described in the previous section. We perform a prior full CI computation on a sub-basis of 296 993 relativistic configurations (24 115 133 Slater determinants) constructed in the same way as for the even Fe 16+ levels. The results are shown in Table III. The final approximative CI expansion consists of 351 452 relativistic configurations.

## B. Extrapolation of energies

In the cases described above, and shown in Tables IIII, the final level energies are obtained via exponential extrapolation of the values yielded in each NNsupported iteration. This procedure is based on the observation that after a few first iterations, the energy change ∆ E i [ ] = E i -E i +1 between adjacent iterations starts decreasing by a factor

$$\frac { \Delta E [ i ] } { \Delta E [ i + 1 ] } = \kappa \,,$$

which is approximately constant. Once κ is obtained numerically from linear fitting of log (∆ E i [ ]) as shown in Fig. 2, this allows us to formally sum up all energy changes ∆ E i [ ] beyond our iterations and obtain the final result. From Fig. 2, it is seen that in the few first iterations, the described pattern is not yet established. These apparent outliers are not included in the extrapolation procedure. Though the assumption given by Eq. (3) is satisfied not at all precisely, our demonstrations show that it is sufficient to improve the energy precision and avoid further costly iterations on a larger CI expansion. This is especially the case for the Ni 12+ example, since all energy levels belong to the fine structure of the same electronic (ground) state and behave similarly in the NNsupported computation. We stress that the extrapolation approach is applicable only to the energies and does not influence the CI expansion, e.g. the wave function, itself.

| Level k   | Configuration     | E k direct , Hartree   | E k i - E k direct , cm - 1   |   E k i - E k direct , cm - 1 |   E k i - E k direct , cm - 1 |   E k i - E k direct , cm - 1 |   E k i - E k direct , cm - 1 |   E k i - E k direct , cm - 1 | E k i - E k direct , cm - 1   |
|-----------|-------------------|------------------------|-------------------------------|-------------------------------|-------------------------------|-------------------------------|-------------------------------|-------------------------------|-------------------------------|
|           |                   |                        | Start                         |                         -10   |                         -10.5 |                         -11   |                         -11.5 |                         -12   | Final                         |
| 0         | 3 s 2 3 p 4 3 P 2 | -1457.78467907         | 1294.4                        |                         257.3 |                          88.8 |                          35.5 |                          18.4 |                           9.3 | 3.8                           |
| 1         | 3 s 2 3 p 4 3 P 1 | -1457.69624247         | 1266.1                        |                         195.4 |                          73.5 |                          30.6 |                          16.4 |                           8.2 | 2.7                           |
| 2         | 3 s 2 3 p 4 3 P 0 | -1457.69337789         | 1309.3                        |                         256.3 |                          91.6 |                          37   |                          20.1 |                           9.9 | 3.6                           |
| 3         | 3 s 2 3 p 4 1 D 2 | -1457.56972999         | 1458.1                        |                         238.1 |                          88.1 |                          35.8 |                          19.2 |                           9.7 | 3.6                           |
| 4         | 3 s 2 3 p 4 1 S 0 | -1457.33747811         | 1506.4                        |                         248.6 |                          94.4 |                          39.5 |                          21.8 |                          11.1 | 3.8                           |

TABLE I. Comparison of the 5 lowest energy levels of Ni 12+ between completed direct CI computation (performed on basis parts using the basis upscaling technique) and iterations of the NN-supported algorithm. The final approximative CI expansion has a size of 145 490 relativistic configurations.

TABLE II. Comparison of the 5 lowest even energy levels of Fe 16+ between completed direct CI computation (performed on basis parts using the basis upscaling technique) and iterations of the NN-supported algorithm. The final approximative CI expansion has a size of 207 604 relativistic configurations.

| Level k   | Configuration   | E k direct , Hartree   | E k i - E k direct , cm - 1   |   E k i - E k direct , cm - 1 |   E k i - E k direct , cm - 1 |   E k i - E k direct , cm - 1 |   E k i - E k direct , cm - 1 |   E k i - E k direct , cm - 1 |   E k i - E k direct , cm - 1 | E k i - E k direct , cm - 1   |
|-----------|-----------------|------------------------|-------------------------------|-------------------------------|-------------------------------|-------------------------------|-------------------------------|-------------------------------|-------------------------------|-------------------------------|
| Level k   | Configuration   | E k direct , Hartree   | Start                         |                          -9.5 |                         -10   |                         -10.5 |                         -11   |                         -11.5 |                         -12   | Final                         |
| 0         | 2 p 6 1 S 0     | -1148.40541049         | 2074.8                        |                         523.6 |                         294.5 |                         133.1 |                          31   |                           5   |                           1.5 | 0.2                           |
| 1         | 2 p 5 3 p 3 S 1 | -1120.64481897         | 1829.3                        |                         672.7 |                         453   |                         196.5 |                          48.8 |                          11.4 |                           5   | 2.4                           |
| 2         | 2 p 5 3 p 3 D 2 | -1120.51593721         | 1800.5                        |                         523.6 |                         330.7 |                         141.5 |                          33   |                           6.1 |                           2.3 | 0.9                           |
| 3         | 2 p 5 3 p 3 D 3 | -1120.45669580         | 1798.6                        |                         522.9 |                         298.6 |                         129.1 |                          28.5 |                           5.3 |                           1.9 | 0.6                           |
| 4         | 2 p 5 3 p 1 P 1 | -1120.41525162         | 1827.4                        |                         581.6 |                         361.9 |                         157.6 |                          36.9 |                           7.1 |                           3   | 1.5                           |

TABLE III. Comparison of the 17 lowest odd energy levels of Fe 16+ between completed direct CI computation (performed on basis parts using the basis upscaling technique) and iterations of the NN-supported algorithm. The final approximative CI expansion has a size of 351 452 relativistic configurations.

| Level k   | Configuration         | E k direct , Hartree   | E k i - E k direct , cm - 1   |   E k i - E k direct , cm - 1 |   E k i - E k direct , cm - 1 |   E k i - E k direct , cm - 1 |   E k i - E k direct , cm - 1 |   E k i - E k direct , cm - 1 |   E k i - E k direct , cm - 1 | E k i - E k direct , cm - 1   |
|-----------|-----------------------|------------------------|-------------------------------|-------------------------------|-------------------------------|-------------------------------|-------------------------------|-------------------------------|-------------------------------|-------------------------------|
| Level k   | Configuration         | E k direct , Hartree   | Start                         |                          -9.5 |                         -10   |                         -10.5 |                         -11   |                         -11.5 |                         -12   | Final                         |
| 0         | 2 s 2 2 p 5 3 s 2     | -1121.76048561         | 2263.9                        |                         866.8 |                         658   |                         252.9 |                          71.6 |                          17.3 |                           7.2 | 3.0                           |
| 1         | 2 s 2 2 p 5 3 s 3 P 1 | -1121.69077098         | 2282.1                        |                         877   |                         667.8 |                         255.5 |                          72.6 |                          17.7 |                           7.3 | 3.0                           |
| 2         | 2 s 2 2 p 5 3 s 1 P 1 | -1121.25287031         | 2175.6                        |                         877.2 |                         661.8 |                         264.7 |                          74.2 |                          18.7 |                           8   | 3.4                           |
| 3         | 2 s 2 2 p 5 3 d 3 P 1 | -1118.92128256         | 2286.3                        |                         829.2 |                         594.5 |                         245.5 |                          70.2 |                          14.4 |                           5   | 0.9                           |
| 4         | 2 s 2 2 p 5 3 d 3 P 2 | -1118.85451593         | 2299.9                        |                         837.6 |                         591.5 |                         253.3 |                          67.5 |                          15   |                           4.8 | 0.2                           |
| 5         | 2 s 2 2 p 5 3 d 3 F 4 | -1118.85179744         | 2329.5                        |                         853   |                         599.7 |                         260.1 |                          68.1 |                          16.2 |                           5.1 | -0.0                          |
| 6         | 2 s 2 2 p 5 3 d 3 F 3 | -1118.82459374         | 2362.7                        |                         859.1 |                         621.7 |                         254.6 |                          74.2 |                          15.6 |                           5.7 | 1.5                           |
| 7         | 2 s 2 2 p 5 3 d 1 D 2 | -1118.76136360         | 2363.2                        |                         858.6 |                         618.1 |                         255.5 |                          72.7 |                          15.5 |                           5.5 | 1.1                           |
| 8         | 2 s 2 2 p 5 3 d 3 D 3 | -1118.72173088         | 2375.2                        |                         857.8 |                         605   |                         260.3 |                          67.9 |                          16   |                           4.9 | -0.1                          |
| 9         | 2 s 2 2 p 5 3 d 3 D 1 | -1118.55136331         | 2371.3                        |                         855.5 |                         608.8 |                         259.8 |                          71   |                          15.9 |                           5.1 | 0.2                           |
| 10        | 2 s 2 2 p 5 3 d 3 F 2 | -1118.36202727         | 2308.3                        |                         838.7 |                         598.3 |                         267.1 |                          77.5 |                          17   |                           5.5 | 0.0                           |
| 11        | 2 s 2 2 p 5 3 d 3 D 2 | -1118.33212227         | 2296.9                        |                         855.9 |                         587   |                         264.7 |                          72.7 |                          16.3 |                           5.6 | 0.6                           |
| 12        | 2 s 2 2 p 5 3 d 1 F 3 | -1118.31283417         | 2317.1                        |                         866.8 |                         596.1 |                         271.4 |                          76.5 |                          17.5 |                           6.2 | 0.7                           |
| 13        | 2 s 2 2 p 5 3 d 1 P 1 | -1118.05785037         | 2373.0                        |                         859.3 |                         607.3 |                         267.8 |                          76.2 |                          17.2 |                           5.5 | -0.1                          |
| 14        | 2 s 2 p 6 3 p 3 P 1   | -1115.59428826         | 2317.9                        |                         971.2 |                         731.6 |                         306.2 |                          89.5 |                          24.7 |                           8.3 | 0.0                           |
| 15        | 2 s 2 p 6 3 p 3 P 2   | -1115.50892176         | 2275.1                        |                         939.9 |                         712.2 |                         286.2 |                          88.2 |                          23.1 |                           8.1 | 0.8                           |
| 16        | 2 s 2 p 6 3 p 1 P 1   | -1115.43721159         | 2309.4                        |                         964.9 |                         730.6 |                         293.6 |                          90.6 |                          24.3 |                           8.8 | 1.2                           |

## C. NN training

Here we discuss the evolution of the NN performance with the training epochs. The three panels in Fig. 3 rep- resent the NN training process for the three computations described in the previous section. For each case, we show the iterations of the NN-supported algorithm separated

FIG. 2. Extrapolation procedure for energies obtained in the iterations of the NN-supported algorithm for the three computations described in Section IV A is shown in the corresponding panels. Here, ∆ E i [ ] = E i -E i +1 is the change of the level energies obtained in adjacent iterations indexed as i and i +1. The first iterations in which the pattern given by Eq. (3) is not yet established, are marked with a black cross and omitted in extrapolation. As shown in color, each energy level k has its own value ∆ E k [ i ], which all behave very similarly in the context of the extrapolation procedure.

![image](https://ac.marcodsn.me/arxiv-markdown-images/2408.00477v1-figure-fc210690-fe7e-4535-8ac1-e173c78bcd9b.jpg)

by vertical dashed lines and labelled by the importance cutoff log 10 x at the top of each panel. The NN performance is measured by the classification accuracy, i.e. the fraction of the configurations classified correctly. It is evaluated prior to the training on the whole training data, and after each epoch on 20% configurations held out from the training set. This accuracy is monitored to early-stop the NN training for the current iteration of the NN-supported algorithm if no progress is achieved. In this work, we use 'early stopping with patience' and terminate the training not immediately after the epoch with the lower accuracy, but in case 5 further epochs have not led to an improvement. The NN is then reset back to its state immediately after the epoch in which the best accuracy was achieved.

The plots in Fig. 3 show the typical patterns of the NN training in our algorithm. In each iteration, the starting accuracy prior to training (shown by the points lying directly on the vertical dashed lines) is lower since the NN is either yet untrained (in the very first iteration) or has switched from an iteration with a different importance cutoff x . The accuracy then grows strongly already after the first training epoch and is refined in further epochs until the best NN performance is achieved. The slight accuracy decline in the last 5 epochs is attributed to the early stopping method used with patience=5. Although these epochs are shown in Fig. 3, they do not participate in the NN evolution, since it is reset to its best state achieved in the iteration. We note that in the first iteration, higher accuracy is typically achieved due to training on the data obtained in an independent (direct or NN-supported) CI computation. This contrasts with the training procedure in Ref. [2], where the first NN training was performed on a random selection from the pool, leading to unstable NN performance and necessity to switch to the convolutional architecture.

## D. Computational resources

We now shift attention to the amount of used computational resources, as well as the total execution time of the calculations. Since both our NN-supported algorithm and the basis upscaling approach without NN involve many internal iterations, we stick to the representative case of Ni 12+ for comparison of the required computational effort. In Table IV, we list the number of processors and required amount of memory per processor, as well as the runtime for each calculation for the respective basis sets. All computations are done with the maximum amount of available computational resources at the time. We find a total speedup of about 4 times of the NN-supported approach with respect to the direct CI with basis upscaling. Note that this only takes into account the runtime of the actual calculations with the CI atomic code, excluding any time to prepare basis sets and construct configuration lists (both with and without NN). The total time it takes to prepare the calculations is much lower in the case of the NN-supported approach, since here much fewer CI runs are performed in total, whereas the NN operation introduces no significant computational overhead.

## V. CONCLUSIONS

We have built upon the NN-based approach developed in Ref [2] and introduced significant developments and

FIG. 3. Evolution of the NN classification accuracy with the training epochs for the three computations described in Section IV A is shown in the corresponding panels. For each case, iterations of the NN-supported algorithm are shown separated by the vertical dashed lines and labelled by their importance cutoff x at the top.

![image](https://ac.marcodsn.me/arxiv-markdown-images/2408.00477v1-figure-88295509-f0a9-4081-9fec-425b2771d93b.jpg)

![image](https://ac.marcodsn.me/arxiv-markdown-images/2408.00477v1-figure-3d306173-99a2-48e2-a4fb-21056ddb98e5.jpg)

![image](https://ac.marcodsn.me/arxiv-markdown-images/2408.00477v1-figure-d18498a7-f6e5-4129-ab02-4efc7a258aac.jpg)

simplifications for its use with the pCI code package [6]. The improved algorithm operates on groups of Slater determinants corresponding to relativistic electronic configurations. The computation is performed for many levels at once, and starts from another (direct or NNsupported) computation. These improvements allow us to refrain from a computationally demanding convolutional architecture, as in Ref. [2], and use a simple dense NN. We have successfully demonstrated the validity and accuracy of the results obtained using our NN-supported algorithm compared to the direct large-scale CI calculations for energy levels of the highly charged Ni 12+ and Fe 16+ ions. For the cases considered in this work, a direct CI computation on the full basis is not feasible. Instead, all direct CI calculations (i.e. without NN) were performed on partial sets using the basis upscaling technique. It has been shown that the NN-supported computation can be completed with significantly reduced execution time in comparison with basis upscaling. The demonstrated NN-supported basis set convergence pro-

- [1] I. P. Grant, Relativistic Quantum Theory of Atoms and Molecules: Theory and Computation (Springer New York, New York, NY, 2007).
- [2] P. Bilous, A. P´lffy, a and F. Marquardt, Phys. Rev. Lett. 131 , 133002 (2023).
- [3] C. Froese Fischer, G. Gaigalas, P. J¨ onsson, and J. Biero´, Computer Physics Communications n 237 , 184 (2019).
- [4] P. Filianin, C. Lyu, M. Door, K. Blaum, W. J. Huang, M. Haverkort, P. Indelicato, C. H. Keitel, K. Kromer, D. Lange, Y. N. Novikov, A. Rischka, R. X. Sch¨ssler, u C. Schweiger, S. Sturm, S. Ulmer, Z. Harman, and S. Eliseev, Phys. Rev. Lett. 127 , 072502 (2021).

cedure can now be automated to provide accurate results for a wide variety of systems for astrophysics and the development of atomic clocks.

## ACKNOWLEDGEMENTS

We thank Florian Marquardt, Ian Grant, Per J¨nsson, o Adriana P´ alffy and Chunhai Liu for helpful discussions. This work was supported by the US NSF Grant No. PHY-2309254 and US Office of Naval Research Grant No. N00014-20-1-2513. The calculations in this work were done through the use of Information Technologies resources at the University of Delaware, specifically the high-performance Caviness and DARWIN computer clusters.

## REFERENCES

- [5] M. G. Kozlov, M. S. Safronova, J. R. Crespo L´ opezUrrutia, and P. O. Schmidt, Rev. Mod. Phys. 90 , 045005 (2018).
- [6] C. Cheung, M. Safronova, and S. Porsev, Symmetry 13 (2021), 10.3390/sym13040621.
- [7] C. Shah, M. Togawa, M. Botz, J. Danisch, J. J. Goes, S. Bernitt, M. Maxton, K. K¨ obnick, J. Buck, J. Seltmann, M. Hoesch, M. F. Gu, F. S. Porter, T. Pfeifer, M. A. Leutenegger, C. Cheung, M. S. Safronova, and J. R. Crespo L´pez-Urrutia, The Astrophysical Journal o 969 , 52 (2024).
- [8] C. Shah, S. K¨hn, S. Bernitt, R. Steinbr¨gge, M. Togawa, u u L. Berger, J. Buck, M. Hoesch, J. Seltmann, M. G. Ko-

| Direct CI   | Direct CI   | Direct CI    | Direct CI   |
|-------------|-------------|--------------|-------------|
| Basis       | num procs   | mem per core | time (hr)   |
| 17 g        | 1124        | 8.3          | 4           |
| 22 g        | 1124        | 17.7         | 13          |
| 17 h        | 1124        | 15.1         | 9.5         |
| 20 h        | 704         | 14.4         | 10.5        |
| 22 h        | 850         | 13.1         | 10          |
| 17 i        | 840         | 29.4         | 27          |
| 20 i        | 704         | 25.2         | 25          |
| 17 k        | 840         | 17.8         | 19          |
| 20 k        | 810         | 28.3         | 34          |
| 17 l        | 640         | 29.7         | 47          |
| 18 l        | 1350        | 15.4         | 10.5        |
| 19 l        | 1056        | 20.4         | 15.5        |
| 20 l        | 1000        | 25.3         | 24          |
| 17 h a      | 800         | 3.7          | 2.5         |
| 20 h a      | 640         | 5.9          | 2           |
| 17 i a      | 900         | 5.9          | 4           |
| 20 i a      | 950         | 9.3          | 4.5         |
| 20 i b      | 900         | 7            | 2           |
| 17 k a      | 950         | 8.8          | 6.5         |
| 17 l b      | 1350        | 8            | 2           |
| 18 l b      | 576         | 11.5         | 5.5         |
| 19 l b      | 660         | 13.9         | 5.5         |
| Total       | -           | -            | 283.5       |

## NN-supported CI

| Iteration   | num procs   | mem per core   |   time (hr) |
|-------------|-------------|----------------|-------------|
| Start       | 640         | 21.7           |         2.5 |
| -10         | 640         | 21.1           |         2.2 |
| -10.5       | 640         | 22.4           |         5.3 |
| -11         | 640         | 24.7           |        11.1 |
| -11.5       | 640         | 27.8           |        19.7 |
| -12         | 640         | 31.5           |        30.5 |
| Total       | -           | -              |        71.2 |

TABLE IV. Computational resources and execution time for each computation required to obtain the final energies for Ni 12+ . For each computation, the 'num procs' column lists the number of CPU cores, and the 'mem per core' column lists the total amount of required memory in GiB. The superscripts ' a ' and ' ' indicate b runs done with a cutoff log 10 x = -10 and log 10 x = -9, respectively.

- zlov, S. G. Porsev, M. F. Gu, F. S. Porter, T. Pfeifer, M. A. Leutenegger, C. Cheung, M. S. Safronova, and J. R. Crespo L´ opez-Urrutia, Physical Review A 109 (2024), 10.1103/physreva.109.063108.
- [9] S. Eustice, D. Filin, J. Schrott, S. Porsev, C. Cheung, D. Novoa, D. M. Stamper-Kurn, and M. S. Safronova, Physical Review A 107 (2023), 10.1103/physreva.107.l051102.
- [10] C. C. . M. S. S. David R. Leibrandt, Sergey G. Porsev, Nature Communications 15 , 5663 (2024).
- [11] S. K¨ uhn, C. Cheung, N. S. Oreshkina, R. Steinbr¨gge, u M. Togawa, S. Bernitt, L. Berger, J. Buck, M. Hoesch, J. Seltmann, F. Trinter, C. H. Keitel, M. G. Kozlov, S. G. Porsev, M. F. Gu, F. S. Porter, T. Pfeifer, M. A. Leutenegger, Z. Harman, M. S. Safronova, J. R. C. L´ opez-Urrutia, and C. Shah, Physical Review Letters 129 (2022), 10.1103/physrevlett.129.245001.
- [12] E. B. Norrgard, D. S. Barker, S. P. Eckel, S. G. Porsev, C. Cheung, M. G. Kozlov, I. I. Tupitsyn, and M. S. Safronova, Physical Review A 105 (2022), 10.1103/physreva.105.032812.
- [13] C. Walter, S. Spielman, R. Ponce, N. Gibson, J. Yukich, C. Cheung, and M. Safronova, Physical Review Letters 126 (2021), 10.1103/physrevlett.126.083001.
- [14] I. Goodfellow, Y. Bengio, and A. Courville, Deep Learning (MIT Press, 2016) http://www.deeplearningbook. org .
- [15] D. P. Kingma and J. Ba, 'Adam: A method for stochastic optimization,' (2017), arXiv:1412.6980 [cs.LG].
- [16] M. Abadi, A. Agarwal, P. Barham, E. Brevdo, Z. Chen, C. Citro, G. S. Corrado, A. Davis, J. Dean, M. Devin, S. Ghemawat, I. Goodfellow, A. Harp, G. Irving, M. Isard, Y. Jia, R. Jozefowicz, L. Kaiser, M. Kudlur, J. Levenberg, D. Man´ e, R. Monga, S. Moore, D. Murray, C. Olah, M. Schuster, J. Shlens, B. Steiner, I. Sutskever, K. Talwar, P. Tucker, V. Vanhoucke, V. Vasudevan, F. Vi´ egas, O. Vinyals, P. Warden, M. Wattenberg, M. Wicke, Y. Yu, and X. Zheng, 'TensorFlow: Largescale machine learning on heterogeneous systems,' (2015), software available from tensorflow.org.
- [17] S. G. Porsev, U. I. Safronova, M. S. Safronova, P. O. Schmidt, A. I. Bondarev, M. G. Kozlov, I. I. Tupitsyn, and C. Cheung, Phys. Rev. A 102 , 012802 (2020).
Pavlo Bilous Charles Cheung Marianna Safronova
A neural network approach to running high-precision atomic computations
Modern applications of atomic physics, including the determination of
frequency standards, and the analysis of astrophysical spectra, require
prediction of atomic properties with exquisite accuracy. For complex atomic
systems, high-precision calculations are a major challenge due to the
exponential scaling of the involved electronic configuration sets. This
exacerbates the problem of required computational resources for these
computations, and makes indispensable the development of approaches to select
the most important configurations out of otherwise intractably huge sets. We
have developed a neural network (NN) tool for running high-precision atomic
configuration interaction (CI) computations with iterative selection of the
most important configurations. Integrated with the established pCI atomic
codes, our approach results in computations with significantly reduced
computational requirements in comparison with those without NN support. We
showcase a number of NN-supported computations for the energy levels of
Fe$^{16+}$ and Ni$^{12+}$, and demonstrate that our approach can be reliably
used and automated for solving specific computational problems for a wide
variety of systems.