{'fraction_non_alphanumeric': 0.03793035414817007, 'fraction_numerical': 0.01099930946039262, 'mean_word_length': 4.533569868995633, 'pattern_counts': {'":': 0, '<': 1, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
High-Performance Algorithm for Calculating Non-Spurious Spin- and Parity-Dependent Nuclear Level Densities

A new high-performance algorithm for calculating the spin- and parity-dependent shell model nuclear level densities using methods of statistical spectroscopy in the proton-neutron formalism was recently proposed. When used in valence spaces that cover more than one major harmonic oscillator shell, this algorithm mixes the genuine intrinsic states with spurious center-of-mass excitations. In this paper we present an advanced algorithm, based on the recently proposed statistical moments method, that eliminates the spurious states. Results for unnatural parity states of several sd-shell nuclei are presented and compared with those of exact shell model calculations and experimental data.


I. INTRODUCTION
In this article we make a next step towards a reliable practical algorithm for calculating the level density in a finite many-body system with strong interaction between the constituents. Our primary object of applications is the atomic nucleus but the same techniques can be applied to other mesoscopic systems, such as atoms in traps [1] and quantum dots [2]. Being a key element in the description of nuclear reactions and quantum transport in general, the many-body level densities are also interesting from the fundamental viewpoint since, at not very high excitation energy, the growth of the level density reflects the interplay of interactions inside the system. The energy dependence of the level density may indicate the phase transformations smoothed out in finite systems: pairing quenching in nuclei [3,4] and small metallic particles [5], or magnetic effects in small quantum dots [6]. The correct reproduction of the level density serves as the first step to recognizing the regular or chaotic nature of spectral statistics in nuclei [3,7,8], complex atoms [9] and quantum dots [10].
The information on spin-and parity-dependent nuclear level densities (SPNLD) represents a critical ingredient for the theory of nuclear reactions, including those of astrophysical interest. For example, the routinely used Hauser-Feschbach approach [11] requires the knowledge of nuclear level densities for certain quantum numbers J π of spin and parity in the window of excitation energy around the particle threshold [12,13]. The nuclear technology requires the level density in the region of compound resonances close to the neutron separation energy. Therefore, a lot of effort has been invested in finding the accurate SPNLD, starting with the classical Fermi-gas approximations [14][15][16] and progressing to the sophisticated mean-field combinatorics [8,17,18] and various shell model approaches with residual interactions in large valence spaces [19][20][21][22][23][24][25][26][27].
Earlier we developed a strategy [19,[26][27][28][29] of calculating the shell model SPNLD using methods of statistical spectroscopy [30,31]. In the basic version of this approach, all basis states that can be built within a selected spherical single-particle valence space are taken into account. However, when the valence space spans more than one harmonic oscillator major shell, the shell model states include spurious excitations of the centerof-mass (CM). Apart from the level density problem, the correct separation of the spurious states is important for finding the physical response of the system to external fields, for example in the case of the excitation of isoscalar giant resonances. Over the years, shell model practitioners developed techniques [32] that allow one to push these unwanted states to energies higher than those of interest for low-energy phenomena. These techniques involve (i) separation of basis states in the so-called Nhω subspaces that can exactly factorize in the CM-excited and intrinsic states, and (ii) the addition to the nuclear Hamiltonian of a CM-part multiplied by a properly chosen positive constant. Unfortunately, the second ingredient leads to a multimodal distribution of levels and it is not appropriate for the methods of statistical spectroscopy.
In a recent letter [33], we proposed a shell-model algorithm for removing the spurious CM contributions from the SPNLD that works if one knows the SPNLD for each Nhω subspace. These contributions are unimodal and can be described using methods of statistical spectroscopy, provided that one can calculate the necessary moments of the Hamiltonian in Nhω subspaces. In the present paper we formulate and utilize a highperformance algorithm that can calculate the configuration centroids and the widths of the Hamiltonian in Nhω subspaces. This algorithm will be used for calculating the non-spurious level density for unnatural parity states of several sd-shell nuclei. Comparison with the exact shell model results and/or experimental data will be also presented.

II. SPIN-AND PARITY-DEPENDENT CONFIGURATION MOMENTS METHOD
We start closely following the approach proposed in Refs. [19,26,27]. For reader's convenience, we repeat first the main equations of the moments method. According to this approach, one can calculate the level density ρ as a function of excitation energy E in the following way: where α = {n, J, T z , π} is a set of quantum numbers, the total number of particles, n, total spin, J, isospin projection, T z , and parity, π; for the level density, in contrast to the state density, the spin degeneracy 2J + 1 is excluded. The sum over configurations κ in Eq. (1) spans all possible (for the certain values of n, T z , and π) ways of distributing n particles over q spherical singleparticle orbitals. Each configuration κ is presented by a set of occupation numbers κ = {n 1 , n 2 , ... , n q }, where n j is the number of particles occupying the spherical singleparticle level j, j n j = n. The energy dependence of the density ρ is expressed by finite-range Gaussian functions, G ακ , defined as in Ref. [26]: where the parameters E ακ and σ ακ will be defined later, E g.s. is the ground state energy, η is the cut-off parameter, and C is the normalization factor corresponding to the condition +∞ −∞ G(x, σ)dx = 1. Although η can be treated as a free parameter, we know from the previous works (see for example [19,28,29]) that its optimal value is η ∼ 3, which allows us to get a finite-range distribution for the density and, practically, do not change each Gaussian contribution. Finally, the dimension D ακ in Eq. (1) gives the correct normalization for each finiterange Gaussian being equal to the number of many-body states with given set of quantum numbers α that can be built for a given configuration κ.
The density distribution ρ(E), especially its low-energy part, is very sensitive to the choice of the ground state energy E gs . This origin of the energy scale is an external parameter for the moments method. To calculate it we need to use supplementary methods, such as the shell model.
The parameters E ακ and σ ακ in Eq. (2) are the fixed-J configuration centroids and widths. They essentially present the average energy and the standard deviation for the set of many-body states with a given set of quantum numbers α within a given configuration κ. For a Hamiltonian containing one-and (antisymmetrized) two-body parts of interaction, the fixed-J centroids and widths can be expressed in terms of the traces of the first and second power of this Hamiltonian [19], Tr[H] and Tr[H 2 ], for each configuration κ: where Every trace, such as Tr (ακ) [· · ·], contains the sum of all diagonal matrix elements, ν, J| · · · |ν, J , over all manybody states |ν, J within given configuration κ and with certain set of quantum numbers α.
As in our previous work [19] we derive these traces for the fixed total spin projection J z , rather than for fixed J. Technically, it is much more easier to construct manybody states with a given total spin projection. The Jtraces can be easily expressed through the J z -traces using the standard relation In Eq. (9) we omitted all quantum numbers, except for the projection J z and the total spin J.
We will use the same label α to denote a set of quantum numbers that includes either the fixed J z or the fixed J, keeping in mind that Eq. (9) can always connect them. In every important case we will point out which set of quantum numbers was used. The expressions for the traces can be found in Ref. [34], see also [19] and references there.

III. NEW FEATURES OF THE ALGORITHM
To remove the center-of-mass spurious states from the level density we follow the approach suggested in [33]. This approach assumes the knowledge of the level density within a restricted basis, and one needs to calculate partial densities ρ(E, α, N ) for a given number N of excitationshω, where the classification of states in terms of the harmonic oscillator Nhω excitations is applied. It has to be mentioned that such a splitting is clearly an approximation since it refers to the harmonic oscillator potential and the level scheme. The harmonic oscillator frequency ω, being an auxiliary parameter has no strict a-priori definition. Nevertheless, as we will demonstrate, the suggested method results are independent ofhω.
According to this method a pure (without admixture of spurious states) level density ρ (0) (E, J, N ) can be expressed through the total (all states included) level density ρ(E, J, N ) for the same values of arguments and through the pure densities of lower N , Ref. [33]: Here, for simplicity, we omitted all quantum numbers indicatting only total spin J representing the set α. In order to make these recursive equations complete we need a boundary condition that can be obtained from the 0hω case which is free of spurious admixtures, For example, if we are interested in the 1hω level density, we come to the following relation: To calculate these partial level densities with the restricted values of excitation numbers N we need to slightly change the previous algorithm. By construction, each configuration κ in Eq. (1) has a certain excitation number N κ that can be defined as where the sum runs over all n nucleons, ν a is the excitation number of the single-particle level occupied by the nucleon a, and, for our convenience, we shift the result by the lowest value of the sum, N 0 , so that N κ starts with zero: N κ = 0, 1, 2, · · ·. Knowing N κ we can restrict the sum in Eq. (1) by including only those configurations κ which correspond to the desirable values of excitation numbers.
For each configuration κ we need to calculate the Jfixed width and centroid, σ ακ , E ακ , defined by Eqs. (5) and (6). There is no problem with the centroid calculation, E ακ ∼ Tr (ακ) [H], since it remains unchanged, we just need to select the configurations κ of our interest. The width calculation requires more attention. The problem is that the widths depend on the trace of the second power of the Hamiltonian, Tr (ακ) [H 2 ], and if we want to restrict the basis we have to take care of the intermediate states − they also have to be restricted, Here the sum over λ includes all many-body states within the given configuration κ and with certain set of quantum numbers α. In contrast to this, the sum over µ includes all possible intermediate states regardless to configurations and quantum numbers, but only restricted by the desirable excitation numbers N . In Eq. (14), R represents the set of all such many-body states defined by the allowed N . In our previous algorithm, we could remove the intermediate sum using the completeness relation, µ |µ µ| = 1, and express the width in terms of the traces over single-particle excitations (D−structures, as in Eq. (11) of Ref. [19]). Now that is impossible, and we need to treat the situation differently.
One possible way to proceed here is still to follow the approach suggested in Ref. [27], where the "restricted" D−structures were introduced, see Eqs. (11,12) in this reference. Here we propose an alternative solution, which may be easier to implement as an efficient computer algorithm. The single-particle part of the Hamiltonian (4) does not create any problems. Indeed the one-body operators of the a † i a i type do not change the excitation number N , so that all states |µ in Eq. (14) have the same N µ as the states |λ all of which have the same excitation number defined by the configuration κ, N λ = N κ . The two-body part of the Hamiltonian has the matrix elements where ν i is the excitation number of the single-particle level i. It is important that ∆N ijkl reflects the internal property of the interaction operator a † i a † j a l a k and does not depend on the many-body states. To deal with the sum over µ in Eq. (14), we notice that N µ = N λ +∆N ijkl , and therefore the restriction on N µ can be reformulated in terms of the equivalent restriction on the singleparticle levels, where R ∆ means that the sum inside the parentheses is restricted by N λ + ∆N ijkl ∈ R.
In order to satisfy the condition of Eq. (17) we just need to keep those sets of the single-particle levels i, j, l, and k in (15) for which the excitation quanta of the |λ state plus the shift ∆N , caused by the corresponding operator a † i a † j a l a k , satisfy this restriction condition. For example, if we want to take into account only 0hω and 2hω classes of states, and the |λ states belong to the, let's say, 0hω class, then the allowed shifts of excitation quantum numbers will be ∆N = 0, 2. All other terms in Eq. (15) must be ignored. Thus, we can use the old expressions for the D-structures without changes (see Eq. (12) of Ref. [19]), which is an essential advantage, but it is necessary to enforce the appropriate restrictions on the sums over single-particle quantum numbers.
The final result can be written as where R 1 means that the sums inside the associated square bracket are restricted by (N κ + ν i + ν j − ν q − ν l ) ∈ R, and R 2 means that the sums in corresponding square bracket are restricted by (N κ + ν l − ν q ) ∈ R. The trace D can be interpreted as a number of many-body states with fixed projection J z (if we consider J z -traces) and the single-particle state i occupied, which can be constructed for the configuration κ; the notations for more complex traces are D , and so on. These Dstructures were called propagation functions in Refs. [19,34]. The detailed procedure for calculating these functions can be found in Ref. [19].
In some applications, the restriction of the level density to one class of excitations described by the excitation number N , Eq. (10), might not be sufficient. For example, one could be interested in considering the class of (0 + 2)hω excitations. In those cases we select the maximum value N max of allowed excitations, and all the states, including intermediate ones, are restricted accord- Such a restriction allows us to fully take into account the interference between the states of different Nhω in Eq. (14). For example, if N max = 2, there are two possible classes of states, 0hω and 2hω, contributing to the width (1hω does not contribute because of opposite parity). The cross terms in Eq. (14), which are proportional to | 2hω|H|0hω | 2 , are equally important along with the diagonal contributions | 2hω|H|2hω | 2 and | 0hω|H|0hω | 2 . If one is interested in the density of unnatural parity states, one could consider only the 1hω excitations. In these cases there are no cross terms, since the 0hω states have opposite parity, thus one can directly use Eqs. (10) and (12). Finally, one should mention that the present algorithm was integrated in our highly scalable moments code that was described in Ref. [19].

IV. RESULTS
As a first example we consider 20 Ne in the s − p − sd − pf -shell model space. For this space we use the Warburton-Brown (WBT) interaction [35]. All calculations were done for 1hω subspace and for negative parity. Fig. 1 presents the comparison of the exact shell model level densities (stair-dashed and stair-solid lines) with the densities calculated using the moments methods (straight-dashed and straight-solid lines). The all dashed lines present the total densities including spurious states. The solid lines present the pure non-spurious densities. For the shell model calculations the spurious states were removed with the help of the Lawson method [32] that adds to the actual Hamiltonian a shifted center-of-mass Hamiltonian, H CM , multiplied by a constant β, The additional term pushes the all spurious states up and leaves the non-spurious density at low-lying excitation energy. In our calculations we used β = 5. However, as it was mentioned in the introduction, the Lawson recipe can not filter spurious states for the moments method. To get the straight-solid lines on Fig. 1 we use the recursive method introduced in Eqs. (10)(11)(12). Finally, the dotted lines present the spurious densities itself calculated according to the second part of the right-hand side of Eqs. (10,12). To calculate the level density with the moments method we need to know the ground state energy and the cut-off parameter η.   Figures 4 and 5 show comparisons of the level density calculated with the moments method, that is presented by straight lines, with experimental level densities presented by stair lines. There are two stair-like lines on each figure: the solid stair lines present an "optimistic" approach, when all experimental levels with uncertain parity were counted; oppositely, the dashed stair lines present a "pessimistic" approach, when only experimental levels with defined parity were counted.
It is needed to be mentioned that the real level densities must be greater than those presented by the stair-like lines since it is possible that many levels were missed in experiment. In spite of the fact that the WBT interaction was not really tested in such big model spaces (it was specifically designed for A < 20), the agreement between the calculations using the moments method and experimental data is quite remarkable.

V. CONCLUSIONS AND OUTLOOK
In conclusion, we developed a new high-performance algorithm to calculate the configuration centroids and widths of the nuclear Hamiltonian in Nhω subspaces built in a valence space. These first two moments can be used to calculate the SPNLD in the associated Nhω subspaces, which can be further mixed according to a recently proposed algorithm [33] for extracting the nonspurious SPNLD. This strategy can be used to calculate the non-spurious shell-model level density for unnatural parity, a long-standing problem in nuclear structure.
We tested our techniques by calculating the negative parity level density for several even-even sd-nuclei, where the exact 1hω shell model diagonalization can be done and compared with the results of the newly proposed al- gorithm. In all cases the SPNLD results of our moments method describe very well the results of the full shell model calculations. We also compared the results of our moments method with the available experimental data for 26 Al and 28 Si. For the states of positive parity, the effective interaction is well suited and our level density compares successfully with the experimental data. For the negative parity states, there is no well-adjusted 1hω effective interaction for the middle of the sd-shell. Using the WBT interaction that was tested up to about mass 20 [35] we obtain a reasonable description of the experimental data.
Certainly, there is a need of refined effective interactions for the unnatural parity states for the sd nuclei, and our techniques could help improving their quality. The algorithm suggested in this article can be used to reliably predict for the first time the SPNLD for a large number of unstable nuclei relevant for the rp-process. The next steps could be directed to the more complicated cases, where the Nhω space is incomplete. This will allow us to reformulate the approach for the realistic mean-field potentials when it will be possible to exclude the standard reference to harmonic oscillator and open the broad field of problems related to the cross sections and reaction rates. In parallel, the deep question should be addressed of the influence of continuum effects [36] on the density of levels which are in fact resonance quasistationary states.