SIRIUS 7.5.0
Electronic structure library and applications
atom_type.hpp
Go to the documentation of this file.
1// Copyright (c) 2013-2020 Anton Kozhevnikov, Thomas Schulthess
2// All rights reserved.
3//
4// Redistribution and use in source and binary forms, with or without modification, are permitted provided that
5// the following conditions are met:
6//
7// 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the
8// following disclaimer.
9// 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions
10// and the following disclaimer in the documentation and/or other materials provided with the distribution.
11//
12// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED
13// WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
14// PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
15// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
16// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
17// CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
18// OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
19
20/** \file atom_type.hpp
21 *
22 * \brief Contains declaration and implementation of sirius::Atom_type class.
23 */
24
25#ifndef __ATOM_TYPE_HPP__
26#define __ATOM_TYPE_HPP__
27
28#include "atomic_data.hpp"
34#include "core/sht/sht.hpp"
35#include "core/sht/gaunt.hpp"
36#include "core/r3/r3.hpp"
37#include "core/profiler.hpp"
38#include "core/packed_index.hpp"
39
40namespace sirius {
41
42/// Descriptor of a local orbital radial function.
44{
45 /// Orbital quantum number \f$ \ell \f$.
47
48 /// Set of radial solution descriptors.
49 /** Local orbital is constructed from at least two radial functions in order to make it zero at the
50 * muffin-tin sphere boundary. */
52
54 : am(am__)
55 {
56 }
57};
58
59/// Store basic information about radial pseudo wave-functions.
61{
62 /// Constructor.
64 : n(n__)
65 , am(am__)
66 , occ(occ__)
67 , f(std::move(f__))
68 {
69 }
70 /// Principal quantum number.
71 int n;
72 /// Angular momentum quantum number.
74 /// Shell occupancy
75 double occ;
76 /// Radial wave-function.
78};
79
80inline std::ostream& operator<<(std::ostream& out, ps_atomic_wf_descriptor const& wfd)
81{
82 if (wfd.am.s() == 0) {
83 out << "{n: " << wfd.n << ", l: " << wfd.am.l() << "}";
84 } else {
85 out << "{n: " << wfd.n << ", l: " << wfd.am.l() << ", j: " << wfd.am.j() << "}";
86 }
87 return out;
88}
89
90/// Defines the properties of atom type.
91/** Atoms wth the same properties are grouped by type. */
93{
94 private:
95 /// Basic parameters.
97
98 /// Unique id of atom type in the range [0, \f$ N_{types} \f$).
99 int id_{-1};
100
101 /// Unique string label for the atom type.
102 std::string label_;
103
104 /// Chemical element symbol.
105 std::string symbol_;
106
107 /// Chemical element name.
108 std::string name_;
109
110 /// Nucleus charge or pseudocharge, treated as positive(!) integer.
111 int zn_{0};
112
113 /// Atom mass.
114 double mass_{0};
115
116 /// List of atomic levels.
117 /** Low-energy levels are core states. Information about core states is defined in the species file. */
118 std::vector<atomic_level_descriptor> atomic_levels_;
119
120 /// Number of core electrons.
122
123 /// Number of valence electrons.
125
126 /// Default augmented wave configuration.
128
129 /// Augmented wave configuration for specific l.
130 std::vector<radial_solution_descriptor_set> aw_specific_l_;
131
132 /// List of radial descriptor sets used to construct augmented waves.
133 std::vector<radial_solution_descriptor_set> aw_descriptors_;
134
135 /// List of radial descriptor sets used to construct local orbitals.
136 /** In case of LAPW this list defines all local orbitals for a given atom type. In case of PP-PW this is
137 a list of all beta-projectors. */
138 std::vector<local_orbital_descriptor> lo_descriptors_;
139
140 /// Maximum number of AW radial functions across angular momentums.
142
143 /// Index of radial basis functions.
144 /** In LAPW this index is used to iterate over combined set of APW and local-orbital radial functions.
145 * In pseudo_potential case this index is used to iterate over radial part of beta-projectors. */
147
148 /// Index of atomic basis functions (radial function * spherical harmonic).
149 /** This index is used in LAPW to combine APW and local-orbital muffin-tin functions */
151
152 /// Index for the radial atomic functions.
154
155 /// Index of atomic wavefunctions (radial function * spherical harmonic).
157
158 /// List of Hubbard orbital descriptors.
159 /** List of sirius::hubbard_orbital_descriptor for each orbital. Each element of the list contains
160 * information about radial function and U and J parameters for the Hubbard correction. The list is
161 * compatible with the indexr_hub_ radial index. */
162 std::vector<hubbard_orbital_descriptor> lo_descriptors_hub_;
163
164 /// Index of radial functions for hubbard orbitals.
166
167 /// Index of basis functions for hubbard orbitals.
169
170 /// Radial functions of beta-projectors.
171 /** This are the beta-function in the USPP file. Pairs of [l, beta_l(r)] are stored. In case of spin-orbit
172 coupling orbital quantum numbers in this list can be positive and negative. This is used to derive the
173 total angular momentum of the orbitals:
174 \f[
175 j = \left\{ \begin{array}{ll}
176 |\ell| - 0.5 & \ell < 0 \\
177 \ell + 0.5 & \ell > 0
178 \end{array} \right.
179 \f]
180 */
181 std::vector<std::pair<angular_momentum, Spline<double>>> beta_radial_functions_;
182
183 /// Atomic wave-functions used to setup the initial subspace and to apply U-correction.
184 /** This are the chi wave-function in the USPP file. Lists of [n, j, occ, chi_l(r)] are stored. In case of
185 * spin-orbit coupling orbital angular quantum number j is equal to l +/- 1/2. Otherwise it is just l. */
186 std::vector<ps_atomic_wf_descriptor> ps_atomic_wfs_;
187
188 /// Radial functions of the Q-operator.
189 /** The dimension of this array is fully determined by the number and lmax of beta-projectors.
190 Beta-projectors must be loaded before loading the Q radial functions. */
192
193 /// True if the pseudopotential is soft and charge augmentation is required.
194 bool augment_{false};
195
196 /// Local part of pseudopotential.
197 std::vector<double> local_potential_;
198
199 /// Pseudo-core charge density (used by PP-PW method in non-linear core correction).
200 std::vector<double> ps_core_charge_density_;
201
202 /// Total pseudo-charge density (used by PP-PW method to setup initial density).
203 std::vector<double> ps_total_charge_density_;
204
205 /// Ionic part of D-operator matrix.
207
208 /// True if the pseudopotential is used for PAW.
209 bool is_paw_{false};
210
211 /// Core energy of PAW.
213
214 /// List of all-electron wave functions of the PAW method.
215 std::vector<std::vector<double>> ae_paw_wfs_;
216
217 /// All-electron wave functions of the PAW method packed in a single array.
218 /** The number of wave functions is equal to the number of beta-projectors. */
220
221 /// List of pseudo wave functions of the PAW method.
222 std::vector<std::vector<double>> ps_paw_wfs_;
223
224 /// Pseudo wave functions of the PAW method packed in a single array.
225 /** The number of wave functions is equal to the number of beta-projectors. */
227
228 /// Occupations of PAW wave-functions.
229 /** Length of vector is the same as the number of beta projectors. This is used for the initial guess of
230 * oribtal occupancies. */
231 std::vector<double> paw_wf_occ_;
232
233 /// Core electron contribution to all electron charge density in PAW method.
234 std::vector<double> paw_ae_core_charge_density_;
235
236 /// True if the pseudo potential includes spin orbit coupling.
238
239 /// Hubbard correction.
241
242 /// Inverse of (Q_{\xi \xi'j}^{-1} + beta_pw^{H}_{\xi} * beta_pw_{xi'})
243 /** Used in Chebyshev iterative solver as a block-diagonal preconditioner */
245
246 /// f_coefficients defined in doi:10.1103/PhysRevB.71.115106 Eq.9 only
247 /// valid when SO interactions are on
249
250 /// List of atom indices (global) for a given type.
251 std::vector<int> atom_id_;
252
253 /// Name of the input file for this atom type.
254 std::string file_name_;
255
256 sddk::mdarray<int, 2> idx_radial_integrals_;
257
258 mutable sddk::mdarray<double, 3> rf_coef_;
259 mutable sddk::mdarray<double, 3> vrf_coef_;
260
261 /// Non-zero Gaunt coefficients.
262 std::unique_ptr<Gaunt_coefficients<std::complex<double>>> gaunt_coefs_{nullptr};
263
264 /// Maximul orbital quantum number of LAPW basis functions.
265 int lmax_apw_{-1};
266
267 /// True if the atom type was initialized.
268 /** After initialization it is forbidden to modify the parameters of the atom type. */
269 bool initialized_{false};
270
271 /// Pass information from the hubbard input section (parsed in input.hpp) to the atom type.
272 void read_hubbard_input();
273
274 /// Generate coefficients used in spin-orbit case.
276
277 inline void read_input_core(nlohmann::json const& parser);
278
279 inline void read_input_aw(nlohmann::json const& parser);
280
281 inline void read_input_lo(nlohmann::json const& parser);
282
283 inline void read_pseudo_uspp(nlohmann::json const& parser);
284
285 inline void read_pseudo_paw(nlohmann::json const& parser);
286
287 /// Read atomic parameters from json file or string.
288 inline void read_input(std::string const& str__);
289
290 /// Initialize descriptors of the augmented-wave radial functions.
292 {
293 RTE_ASSERT(this->lmax_apw() >= -1);
294
295 if (this->lmax_apw() >= 0 && aw_default_l_.size() == 0) {
296 RTE_THROW("default AW descriptor is empty");
297 }
298
299 aw_descriptors_.clear();
300 for (int l = 0; l <= this->lmax_apw(); l++) {
302 for (size_t ord = 0; ord < aw_descriptors_[l].size(); ord++) {
303 aw_descriptors_[l][ord].n = l + 1;
304 aw_descriptors_[l][ord].l = l;
305 }
306 }
307
308 for (size_t i = 0; i < aw_specific_l_.size(); i++) {
309 int l = aw_specific_l_[i][0].l;
310 if (l < this->lmax_apw()) {
312 }
313 }
314 }
315
316 /* forbid copy constructor */
317 Atom_type(Atom_type const& src) = delete;
318
319 /* forbid assignment operator */
320 Atom_type& operator=(Atom_type const& src) = delete;
321
322 protected:
323 /// Radial grid of the muffin-tin sphere.
325
326 /// Density of a free atom.
328
329 /// Density of a free atom as read from the input file.
330 /** Does not contain 4 Pi and r^2 prefactors. */
331 std::vector<double> free_atom_density_;
332
333 /// Radial grid of a free atom.
335
336 public:
337 /// Constructor.
338 /** Basic parameters of atom type are passed as constructor arguments. */
339 Atom_type(Simulation_parameters const& parameters__, std::string symbol__, std::string name__, int zn__,
340 double mass__, std::vector<atomic_level_descriptor> const& levels__)
341 : parameters_(parameters__)
342 , symbol_(symbol__)
343 , name_(name__)
344 , zn_(zn__)
345 , mass_(mass__)
346 , atomic_levels_(levels__)
347 {
348 }
349
350 /// Constructor.
351 /** ID of atom type and label are passed as arguments. The rest of parameters are obtained from the
352 species input file. */
353 Atom_type(Simulation_parameters const& parameters__, int id__, std::string label__, std::string file_name__)
354 : parameters_(parameters__)
355 , id_(id__)
356 , label_(label__)
357 , file_name_(file_name__)
358 {
359 }
360
361 /// Move constructor.
362 Atom_type(Atom_type&& src) = default;
363
364 /// Initialize the atom type.
365 /** Once the unit cell is populated with all atom types and atoms, each atom type can be initialized. */
366 void init();
367
368 /// Initialize the free atom density (smooth or true).
369 void init_free_atom_density(bool smooth);
370
371 /// Add a hubbard orbital to a list.
372 /** All atomic functions must already be loaded prior to callinig this function. Atomic wave-functions
373 (chi in the uspp file) are used as a definition of "localized orbitals" to which U-correction is applied.
374 Full treatment of spin is not considered. In case of spinor wave-functions the are averaged between
375 l+1/2 and l-1/2 states. */
376 void add_hubbard_orbital(int n__, int l__, double occ__, double U, double J, const double* hub_coef__,
377 double alpha__, double beta__, double J0__, std::vector<double> initial_occupancy__,
378 const bool use_for_calculations__);
379
380 /// Print basic info to standard output.
381 void print_info(std::ostream& out__) const;
382
383 /// Set the radial grid of the given type.
384 inline void set_radial_grid(radial_grid_t grid_type__, int num_points__, double rmin__, double rmax__, double p__)
385 {
386 radial_grid_ = Radial_grid_factory<double>(grid_type__, num_points__, rmin__, rmax__, p__);
387 if (parameters_.processing_unit() == sddk::device_t::GPU) {
388 radial_grid_.copy_to_device();
389 }
390 }
391
392 /// Set external radial grid.
393 inline void set_radial_grid(int num_points__, double const* points__)
394 {
395 radial_grid_ = Radial_grid_ext<double>(num_points__, points__);
396 if (parameters_.processing_unit() == sddk::device_t::GPU) {
397 radial_grid_.copy_to_device();
398 }
399 }
400
401 /// Set radial grid of the free atom.
402 /** The grid is extended to effective infinity (usually > 100 a.u.) */
403 inline void set_free_atom_radial_grid(int num_points__, double const* points__)
404 {
405 if (num_points__ <= 0) {
406 RTE_THROW("wrong number of radial points");
407 }
408 free_atom_radial_grid_ = Radial_grid_ext<double>(num_points__, points__);
409 }
410
412 {
413 free_atom_radial_grid_ = std::move(rgrid__);
414 }
415
416 /// Add augmented-wave descriptor.
417 inline void add_aw_descriptor(int n, int l, double enu, int dme, int auto_enu)
418 {
419 if (static_cast<int>(aw_descriptors_.size()) < (l + 1)) {
421 }
422
424
425 rsd.n = n;
426 if (n == -1) {
427 /* default principal quantum number value for any l */
428 rsd.n = l + 1;
429 for (int ist = 0; ist < num_atomic_levels(); ist++) {
430 /* take next level after the core */
431 if (atomic_level(ist).core && atomic_level(ist).l == l) {
432 rsd.n = atomic_level(ist).n + 1;
433 }
434 }
435 }
436
437 rsd.l = l;
438 rsd.dme = dme;
439 rsd.enu = enu;
440 rsd.auto_enu = auto_enu;
441 aw_descriptors_[l].push_back(rsd);
442 }
443
444 /// Add local orbital descriptor
445 inline void add_lo_descriptor(int ilo, int n, int l, double enu, int dme, int auto_enu)
446 {
447 if ((int)lo_descriptors_.size() == ilo) {
448 angular_momentum am(l);
450 } else {
451 if (l != lo_descriptors_[ilo].am.l()) {
452 std::stringstream s;
453 s << "wrong angular quantum number" << std::endl
454 << "atom type id: " << id() << " (" << symbol_ << ")" << std::endl
455 << "idxlo: " << ilo << std::endl
456 << "n: " << l << std::endl
457 << "l: " << n << std::endl
458 << "expected l: " << lo_descriptors_[ilo].am.l() << std::endl;
459 RTE_THROW(s);
460 }
461 }
462
464
465 rsd.n = n;
466 if (n == -1) {
467 /* default value for any l */
468 rsd.n = l + 1;
469 for (int ist = 0; ist < num_atomic_levels(); ist++) {
470 if (atomic_level(ist).core && atomic_level(ist).l == l) {
471 /* take next level after the core */
472 rsd.n = atomic_level(ist).n + 1;
473 }
474 }
475 }
476
477 rsd.l = l;
478 rsd.dme = dme;
479 rsd.enu = enu;
480 rsd.auto_enu = auto_enu;
481 lo_descriptors_[ilo].rsd_set.push_back(rsd);
482 }
483
484 /// Add the entire local orbital descriptor.
486 {
487 lo_descriptors_.push_back(lod__);
488 }
489
490 /// Add atomic radial function to the list.
491 inline void add_ps_atomic_wf(int n__, angular_momentum am__, std::vector<double> f__, double occ__ = 0.0)
492 {
494 auto d = std::sqrt(inner(rwf, rwf, 0, radial_grid_.num_points()));
495 if (d < 1e-4) {
496 std::stringstream s;
497 s << "small norm (" << d << ") of radial atomic pseudo wave-function for n=" << n__
498 << " and j=" << am__.j();
499 RTE_THROW(s);
500 }
501
502 ps_atomic_wfs_.emplace_back(n__, am__, occ__, std::move(rwf));
503 }
504
505 /// Return a tuple describing a given atomic radial function
506 auto const& ps_atomic_wf(int idx__) const
507 {
508 return ps_atomic_wfs_[idx__];
509 }
510
511 /// Add a radial function of beta-projector to a list of functions.
512 /** This is the only allowed way to add beta projectors. */
513 inline void add_beta_radial_function(angular_momentum am__, std::vector<double> beta__)
514 {
515 if (augment_) {
516 RTE_THROW("can't add more beta projectors");
517 }
518 Spline<double> s(radial_grid_, beta__);
519 beta_radial_functions_.push_back(std::make_pair(am__, std::move(s)));
520 }
521
522 /// Number of beta-radial functions.
523 inline int num_beta_radial_functions() const
524 {
525 return beta_radial_functions_.size();
526 }
527
528 /// Return a radial beta function.
529 inline auto const& beta_radial_function(rf_index idxrf__) const
530 {
531 return beta_radial_functions_[idxrf__];
532 }
533
534 /// Add radial function of the augmentation charge.
535 /** Radial functions of beta projectors must be added already. Their total number will be used to
536 deterimine the storage size for the radial functions of the augmented charge. */
537 inline void add_q_radial_function(int idxrf1__, int idxrf2__, int l__, std::vector<double> qrf__)
538 {
539 /* sanity check */
540 if (l__ > 2 * lmax_beta()) {
541 std::stringstream s;
542 s << "wrong l for Q radial functions of atom type " << label_ << std::endl
543 << "current l: " << l__ << std::endl
544 << "lmax_beta: " << lmax_beta() << std::endl
545 << "maximum allowed l: " << 2 * lmax_beta();
546
547 RTE_THROW(s);
548 }
549
550 if (!augment_) {
551 /* once we add a Q-radial function, we need to augment the charge */
552 augment_ = true;
553 /* number of radial beta-functions */
554 int nbrf = num_beta_radial_functions();
555 q_radial_functions_l_ = sddk::mdarray<Spline<double>, 2>(nbrf * (nbrf + 1) / 2, 2 * lmax_beta() + 1);
556
557 for (int l = 0; l <= 2 * lmax_beta(); l++) {
558 for (int idx = 0; idx < nbrf * (nbrf + 1) / 2; idx++) {
560 }
561 }
562 }
563
564 int ijv = packed_index(idxrf1__, idxrf2__);
566 }
567
568 /// Return true if this atom type has an augementation charge.
569 inline bool augment() const
570 {
571 return augment_;
572 }
573
574 /// Set the radial function of the local potential.
575 inline std::vector<double>& local_potential(std::vector<double> vloc__)
576 {
577 local_potential_ = vloc__;
578 return local_potential_;
579 }
580
581 /// Get the radial function of the local potential.
582 inline std::vector<double> const& local_potential() const
583 {
584 return local_potential_;
585 }
586
587 inline std::vector<double>& ps_core_charge_density(std::vector<double> ps_core__)
588 {
589 ps_core_charge_density_ = ps_core__;
591 }
592
593 inline std::vector<double> const& ps_core_charge_density() const
594 {
596 }
597
598 inline std::vector<double>& ps_total_charge_density(std::vector<double> ps_dens__)
599 {
600 ps_total_charge_density_ = ps_dens__;
602 }
603
604 inline std::vector<double> const& ps_total_charge_density() const
605 {
607 }
608
609 /// Add all-electron PAW wave-function.
610 inline void add_ae_paw_wf(std::vector<double> f__)
611 {
612 ae_paw_wfs_.push_back(f__);
613 }
614
615 /// Get all-electron PAW wave-function.
616 inline std::vector<double> const& ae_paw_wf(int i__) const
617 {
618 return ae_paw_wfs_[i__];
619 }
620
621 /// Get the number of all-electron PAW wave-functions.
622 inline int num_ae_paw_wf() const
623 {
624 return static_cast<int>(ae_paw_wfs_.size());
625 }
626
627 inline void add_ps_paw_wf(std::vector<double> f__)
628 {
629 ps_paw_wfs_.push_back(f__);
630 }
631
632 inline std::vector<double> const& ps_paw_wf(int i__) const
633 {
634 return ps_paw_wfs_[i__];
635 }
636
637 inline int num_ps_paw_wf() const
638 {
639 return static_cast<int>(ps_paw_wfs_.size());
640 }
641
642 inline auto const& ae_paw_wfs_array() const
643 {
644 return ae_paw_wfs_array_;
645 }
646
647 inline auto const& ps_paw_wfs_array() const
648 {
649 return ps_paw_wfs_array_;
650 }
651
652 inline auto const& paw_ae_core_charge_density() const
653 {
655 }
656
657 inline auto& paw_ae_core_charge_density(std::vector<double> inp__)
658 {
661 }
662
663 inline auto const& paw_wf_occ() const
664 {
665 return paw_wf_occ_;
666 }
667
668 inline auto& paw_wf_occ(std::vector<double> inp__)
669 {
670 paw_wf_occ_ = inp__;
671 return paw_wf_occ_;
672 }
673
674 /// Return atom type id.
675 inline int id() const
676 {
677 return id_;
678 }
679
680 /// Return ionic charge (as positive integer).
681 inline int zn() const
682 {
683 RTE_ASSERT(zn_ > 0);
684 return zn_;
685 }
686
687 /// Set ionic charge.
688 inline int zn(int zn__)
689 {
690 zn_ = zn__;
691 return zn_;
692 }
693
694 inline std::string const& symbol() const
695 {
696 return symbol_;
697 }
698
699 inline std::string const& name() const
700 {
701 return name_;
702 }
703
704 /// Return atomic mass.
705 inline double mass() const
706 {
707 return mass_;
708 }
709
710 /// Return muffin-tin radius.
711 /** This is the last point of the radial grid. */
712 inline double mt_radius() const
713 {
714 return radial_grid_.last();
715 }
716
717 /// Return number of muffin-tin radial grid points.
718 inline int num_mt_points() const
719 {
720 RTE_ASSERT(radial_grid_.num_points() > 0);
721 return radial_grid_.num_points();
722 }
723
724 inline Radial_grid<double> const& radial_grid() const
725 {
726 RTE_ASSERT(radial_grid_.num_points() > 0);
727 return radial_grid_;
728 }
729
730 inline Radial_grid<double> const& free_atom_radial_grid() const
731 {
733 }
734
735 inline double radial_grid(int ir) const
736 {
737 return radial_grid_[ir];
738 }
739
740 inline double free_atom_radial_grid(int ir) const
741 {
742 return free_atom_radial_grid_[ir];
743 }
744
745 inline int num_atomic_levels() const
746 {
747 return static_cast<int>(atomic_levels_.size());
748 }
749
750 inline atomic_level_descriptor const& atomic_level(int idx) const
751 {
752 return atomic_levels_[idx];
753 }
754
755 inline double num_core_electrons() const
756 {
757 return num_core_electrons_;
758 }
759
760 inline double num_valence_electrons() const
761 {
763 }
764
765 /// Get free atom density at i-th point of radial grid.
766 inline double free_atom_density(const int idx) const
767 {
768 return free_atom_density_spline_(idx);
769 }
770
771 /// Get free atom density at point x.
772 inline double free_atom_density(double x) const
773 {
775 }
776
777 /// Set the free atom all-electron density.
778 inline void free_atom_density(std::vector<double> rho__)
779 {
780 free_atom_density_ = rho__;
781 }
782
783 inline int num_aw_descriptors() const
784 {
785 return static_cast<int>(aw_descriptors_.size());
786 }
787
788 inline auto const& aw_descriptor(int l) const
789 {
790 RTE_ASSERT(l < (int)aw_descriptors_.size());
791 return aw_descriptors_[l];
792 }
793
794 inline int num_lo_descriptors() const
795 {
796 return (int)lo_descriptors_.size();
797 }
798
799 inline auto const& lo_descriptor(int idx) const
800 {
801 return lo_descriptors_[idx];
802 }
803
804 inline int max_aw_order() const
805 {
806 return max_aw_order_;
807 }
808
809 /// Order of augmented wave radial functions for a given l.
810 inline int aw_order(int l__) const
811 {
812 return static_cast<int>(aw_descriptor(l__).size());
813 }
814
815 /// Return const reference to the index of radial functions.
816 /** The index can be used to determine the total number of radial functions */
817 inline auto const& indexr() const
818 {
819 return indexr_;
820 }
821
822 inline auto const& indexr_wfs() const
823 {
824 return indexr_wfs_;
825 }
826
827 inline auto const& indexr_hub() const
828 {
829 return indexr_hub_;
830 }
831
832 inline auto const& indexr(int i) const
833 {
834 //RTE_ASSERT(i >= 0 && i < (int)indexr_.size());
835 return indexr_[rf_index(i)];
836 }
837
838 inline int indexr_by_l_order(int l, int order) const
839 {
840 return indexr_.index_of(angular_momentum(l), order);
841 }
842
843 inline int indexr_by_idxlo(int idxlo) const
844 {
845 return indexr_.index_of(rf_lo_index(idxlo));
846 }
847
848 inline auto const& indexb() const
849 {
850 return indexb_;
851 }
852
853 inline auto const& indexb(int i) const
854 {
855 //RTE_ASSERT(i >= 0 && i < (int)indexb_.size());
856 return indexb_[i];
857 }
858
859 inline int indexb_by_l_m_order(int l, int m, int order) const
860 {
861 return indexb_.index_by_l_m_order(l, m, order);
862 }
863
864 inline int indexb_by_lm_order(int lm, int order) const
865 {
866 return indexb_.index_by_lm_order(lm, order);
867 }
868
869 inline int mt_aw_basis_size() const
870 {
871 return indexb_.size_aw();
872 }
873
874 inline int mt_lo_basis_size() const
875 {
876 return indexb_.size_lo();
877 }
878
879 /// Total number of muffin-tin basis functions (APW + LO).
880 inline int mt_basis_size() const
881 {
882 return indexb_.size();
883 }
884
885 /// Total number of radial basis functions.
886 inline int mt_radial_basis_size() const
887 {
888 return indexr_.size();
889 }
890
891 inline auto const& indexb_wfs() const
892 {
893 return indexb_wfs_;
894 }
895
896 /// Return whole index of hubbard basis functions.
897 inline auto const& indexb_hub() const
898 {
899 return indexb_hub_;
900 }
901
902 inline auto const& hubbard_radial_function(int i) const
903 {
904 return lo_descriptors_hub_[i].f();
905 }
906
907 inline void set_symbol(const std::string symbol__)
908 {
909 symbol_ = symbol__;
910 }
911
912 inline void set_zn(int zn__)
913 {
914 zn_ = zn__;
915 }
916
917 inline void set_mass(double mass__)
918 {
919 mass_ = mass__;
920 }
921
922 inline void set_configuration(int n, int l, int k, double occupancy, bool core)
923 {
925 level.n = n;
926 level.l = l;
927 level.k = k;
928 level.occupancy = occupancy;
929 level.core = core;
930 atomic_levels_.push_back(level);
931 }
932
933 /// Return number of atoms of a given type.
934 inline int num_atoms() const
935 {
936 return static_cast<int>(atom_id_.size());
937 }
938
939 /// Return atom ID (global index) by the index of atom within a given type.
940 inline int atom_id(int idx) const
941 {
942 return atom_id_[idx];
943 }
944
945 /// Add global index of atom to this atom type.
946 inline void add_atom_id(int atom_id__)
947 {
948 atom_id_.push_back(atom_id__);
949 }
950
951 inline bool initialized() const
952 {
953 return initialized_;
954 }
955
956 inline std::string const& label() const
957 {
958 return label_;
959 }
960
961 inline std::string const& file_name() const
962 {
963 return file_name_;
964 }
965
966 inline void d_mtrx_ion(sddk::matrix<double> const& d_mtrx_ion__)
967 {
969 sddk::memory_t::host, "Atom_type::d_mtrx_ion_");
970 sddk::copy(d_mtrx_ion__, d_mtrx_ion_);
971 }
972
973 inline auto const& d_mtrx_ion() const
974 {
975 return d_mtrx_ion_;
976 }
977
978 inline bool is_paw() const
979 {
980 return is_paw_;
981 }
982
983 inline bool is_paw(bool is_paw__)
984 {
985 is_paw_ = is_paw__;
986 return is_paw_;
987 }
988
989 double paw_core_energy() const
990 {
991 return paw_core_energy_;
992 }
993
994 double paw_core_energy(double paw_core_energy__)
995 {
996 paw_core_energy_ = paw_core_energy__;
997 return paw_core_energy_;
998 }
999
1000 inline auto const& idx_radial_integrals() const
1001 {
1002 return idx_radial_integrals_;
1003 }
1004
1005 inline auto& rf_coef() const
1006 {
1007 return rf_coef_;
1008 }
1009
1010 inline auto& vrf_coef() const
1011 {
1012 return vrf_coef_;
1013 }
1014
1015 inline auto const& parameters() const
1016 {
1017 return parameters_;
1018 }
1019
1020 inline auto f_coefficients(int xi1, int xi2, int s1, int s2) const
1021 {
1022 return f_coefficients_(xi1, xi2, s1, s2);
1023 }
1024
1025 inline auto const& q_radial_function(int idxrf1__, int idxrf2__, int l__) const
1026 {
1027 if (idxrf1__ > idxrf2__) {
1028 std::swap(idxrf1__, idxrf2__);
1029 }
1030 /* combined index */
1031 int ijv = idxrf2__ * (idxrf2__ + 1) / 2 + idxrf1__;
1032
1033 return q_radial_functions_l_(ijv, l__);
1034 }
1035
1036 inline bool spin_orbit_coupling() const
1037 {
1038 return spin_orbit_coupling_;
1039 }
1040
1041 inline bool spin_orbit_coupling(bool so__)
1042 {
1043 this->spin_orbit_coupling_ = so__;
1044 return this->spin_orbit_coupling_;
1045 }
1046
1047 /// Get the Hubbard correction switch.
1048 inline bool hubbard_correction() const
1049 {
1050 return hubbard_correction_;
1051 }
1052
1053 /// Set the Hubbard correction switch.
1054 inline bool hubbard_correction(bool ldapu__)
1055 {
1056 this->hubbard_correction_ = ldapu__;
1057 return this->hubbard_correction_;
1058 }
1059
1060 /// Compare indices of beta projectors.
1061 /** Compare the angular, total angular momentum and radial part of the beta projectors,
1062 * leaving the m index free. Only useful when spin orbit coupling is included. */
1063 inline bool compare_index_beta_functions(const int xi, const int xj) const
1064 {
1065 return ((indexb(xi).am == indexb(xj).am) && (indexb(xi).idxrf == indexb(xj).idxrf));
1066 }
1067
1068 /// Return a vector containing all information about the localized atomic
1069 /// orbitals used to generate the Hubbard subspace.
1070 inline const auto& lo_descriptor_hub() const
1071 {
1072 return lo_descriptors_hub_;
1073 }
1074
1075 inline auto const& lo_descriptor_hub(int idx__) const
1076 {
1077 return lo_descriptors_hub_[idx__];
1078 }
1079
1080 inline int lmax_apw() const
1081 {
1082 if (this->lmax_apw_ == -1) {
1083 return parameters_.cfg().parameters().lmax_apw();
1084 } else {
1085 return this->lmax_apw_;
1086 }
1087 }
1088
1089 inline int lmmax_apw() const
1090 {
1091 return sf::lmmax(this->lmax_apw());
1092 }
1093
1094 inline int lmax_lo() const
1095 {
1096 int lmax{-1};
1097 for (auto& e: lo_descriptors_) {
1098 lmax = std::max(lmax, e.am.l());
1099 }
1100 return lmax;
1101 }
1102
1103 /// Return maximum orbital quantum number for the atomic wave-functions.
1104 inline int lmax_ps_atomic_wf() const
1105 {
1106 int lmax{-1};
1107 for (auto& e: ps_atomic_wfs_) {
1108 auto l = e.am.l();
1109 lmax = std::max(lmax, l);
1110 }
1111 return lmax;
1112 }
1113
1114 /// Maximum orbital quantum number between all beta-projector radial functions.
1115 inline int lmax_beta() const
1116 {
1117 int lmax{-1};
1118
1119 for (auto& e: beta_radial_functions_) {
1120 lmax = std::max(lmax, e.first.l());
1121 }
1122 return lmax;
1123 }
1124
1125 auto const& gaunt_coefs() const
1126 {
1127 return *gaunt_coefs_;
1128 }
1129};
1130
1131} // namespace sirius
1132
1133#endif // __ATOM_TYPE_HPP__
Basic atomic data information.
Contains definitiona and implementation of sirius::basis_functions_index class.
Defines the properties of atom type.
Definition: atom_type.hpp:93
void add_q_radial_function(int idxrf1__, int idxrf2__, int l__, std::vector< double > qrf__)
Add radial function of the augmentation charge.
Definition: atom_type.hpp:537
Radial_grid< double > radial_grid_
Radial grid of the muffin-tin sphere.
Definition: atom_type.hpp:324
int mt_basis_size() const
Total number of muffin-tin basis functions (APW + LO).
Definition: atom_type.hpp:880
std::vector< atomic_level_descriptor > atomic_levels_
List of atomic levels.
Definition: atom_type.hpp:118
std::vector< double > & local_potential(std::vector< double > vloc__)
Set the radial function of the local potential.
Definition: atom_type.hpp:575
std::vector< double > local_potential_
Local part of pseudopotential.
Definition: atom_type.hpp:197
int num_beta_radial_functions() const
Number of beta-radial functions.
Definition: atom_type.hpp:523
void add_lo_descriptor(int ilo, int n, int l, double enu, int dme, int auto_enu)
Add local orbital descriptor.
Definition: atom_type.hpp:445
int lmax_ps_atomic_wf() const
Return maximum orbital quantum number for the atomic wave-functions.
Definition: atom_type.hpp:1104
radial_functions_index indexr_wfs_
Index for the radial atomic functions.
Definition: atom_type.hpp:153
void add_atom_id(int atom_id__)
Add global index of atom to this atom type.
Definition: atom_type.hpp:946
int id_
Unique id of atom type in the range [0, ).
Definition: atom_type.hpp:99
std::unique_ptr< Gaunt_coefficients< std::complex< double > > > gaunt_coefs_
Non-zero Gaunt coefficients.
Definition: atom_type.hpp:262
std::vector< double > free_atom_density_
Density of a free atom as read from the input file.
Definition: atom_type.hpp:331
void add_lo_descriptor(local_orbital_descriptor const &lod__)
Add the entire local orbital descriptor.
Definition: atom_type.hpp:485
std::vector< local_orbital_descriptor > lo_descriptors_
List of radial descriptor sets used to construct local orbitals.
Definition: atom_type.hpp:138
bool hubbard_correction() const
Get the Hubbard correction switch.
Definition: atom_type.hpp:1048
Simulation_parameters const & parameters_
Basic parameters.
Definition: atom_type.hpp:96
int lmax_beta() const
Maximum orbital quantum number between all beta-projector radial functions.
Definition: atom_type.hpp:1115
Radial_grid< double > free_atom_radial_grid_
Radial grid of a free atom.
Definition: atom_type.hpp:334
auto const & beta_radial_function(rf_index idxrf__) const
Return a radial beta function.
Definition: atom_type.hpp:529
int atom_id(int idx) const
Return atom ID (global index) by the index of atom within a given type.
Definition: atom_type.hpp:940
int num_mt_points() const
Return number of muffin-tin radial grid points.
Definition: atom_type.hpp:718
bool augment_
True if the pseudopotential is soft and charge augmentation is required.
Definition: atom_type.hpp:194
void free_atom_density(std::vector< double > rho__)
Set the free atom all-electron density.
Definition: atom_type.hpp:778
std::vector< ps_atomic_wf_descriptor > ps_atomic_wfs_
Atomic wave-functions used to setup the initial subspace and to apply U-correction.
Definition: atom_type.hpp:186
void set_free_atom_radial_grid(int num_points__, double const *points__)
Set radial grid of the free atom.
Definition: atom_type.hpp:403
void read_hubbard_input()
Pass information from the hubbard input section (parsed in input.hpp) to the atom type.
Definition: atom_type.cpp:803
auto const & indexr() const
Return const reference to the index of radial functions.
Definition: atom_type.hpp:817
double free_atom_density(double x) const
Get free atom density at point x.
Definition: atom_type.hpp:772
int zn() const
Return ionic charge (as positive integer).
Definition: atom_type.hpp:681
basis_functions_index indexb_hub_
Index of basis functions for hubbard orbitals.
Definition: atom_type.hpp:168
std::vector< double > const & local_potential() const
Get the radial function of the local potential.
Definition: atom_type.hpp:582
Atom_type(Atom_type &&src)=default
Move constructor.
sddk::mdarray< Spline< double >, 2 > q_radial_functions_l_
Radial functions of the Q-operator.
Definition: atom_type.hpp:191
double mt_radius() const
Return muffin-tin radius.
Definition: atom_type.hpp:712
Atom_type(Simulation_parameters const &parameters__, std::string symbol__, std::string name__, int zn__, double mass__, std::vector< atomic_level_descriptor > const &levels__)
Constructor.
Definition: atom_type.hpp:339
auto const & ps_atomic_wf(int idx__) const
Return a tuple describing a given atomic radial function.
Definition: atom_type.hpp:506
int zn(int zn__)
Set ionic charge.
Definition: atom_type.hpp:688
void print_info(std::ostream &out__) const
Print basic info to standard output.
Definition: atom_type.cpp:277
void init_free_atom_density(bool smooth)
Initialize the free atom density (smooth or true).
Definition: atom_type.cpp:241
bool spin_orbit_coupling_
True if the pseudo potential includes spin orbit coupling.
Definition: atom_type.hpp:237
Spline< double > free_atom_density_spline_
Density of a free atom.
Definition: atom_type.hpp:327
double free_atom_density(const int idx) const
Get free atom density at i-th point of radial grid.
Definition: atom_type.hpp:766
Atom_type(Simulation_parameters const &parameters__, int id__, std::string label__, std::string file_name__)
Constructor.
Definition: atom_type.hpp:353
int lmax_apw_
Maximul orbital quantum number of LAPW basis functions.
Definition: atom_type.hpp:265
const auto & lo_descriptor_hub() const
Definition: atom_type.hpp:1070
void init()
Initialize the atom type.
Definition: atom_type.cpp:31
bool compare_index_beta_functions(const int xi, const int xj) const
Compare indices of beta projectors.
Definition: atom_type.hpp:1063
std::vector< double > const & ae_paw_wf(int i__) const
Get all-electron PAW wave-function.
Definition: atom_type.hpp:616
std::vector< std::vector< double > > ae_paw_wfs_
List of all-electron wave functions of the PAW method.
Definition: atom_type.hpp:215
void set_radial_grid(int num_points__, double const *points__)
Set external radial grid.
Definition: atom_type.hpp:393
int mt_radial_basis_size() const
Total number of radial basis functions.
Definition: atom_type.hpp:886
double num_core_electrons_
Number of core electrons.
Definition: atom_type.hpp:121
bool hubbard_correction_
Hubbard correction.
Definition: atom_type.hpp:240
std::vector< double > ps_core_charge_density_
Pseudo-core charge density (used by PP-PW method in non-linear core correction).
Definition: atom_type.hpp:200
std::vector< radial_solution_descriptor_set > aw_descriptors_
List of radial descriptor sets used to construct augmented waves.
Definition: atom_type.hpp:133
basis_functions_index indexb_wfs_
Index of atomic wavefunctions (radial function * spherical harmonic).
Definition: atom_type.hpp:156
int zn_
Nucleus charge or pseudocharge, treated as positive(!) integer.
Definition: atom_type.hpp:111
basis_functions_index indexb_
Index of atomic basis functions (radial function * spherical harmonic).
Definition: atom_type.hpp:150
radial_functions_index indexr_hub_
Index of radial functions for hubbard orbitals.
Definition: atom_type.hpp:165
sddk::mdarray< double, 2 > ps_paw_wfs_array_
Pseudo wave functions of the PAW method packed in a single array.
Definition: atom_type.hpp:226
std::string symbol_
Chemical element symbol.
Definition: atom_type.hpp:105
void generate_f_coefficients()
Generate coefficients used in spin-orbit case.
Definition: atom_type.cpp:749
std::vector< int > atom_id_
List of atom indices (global) for a given type.
Definition: atom_type.hpp:251
bool hubbard_correction(bool ldapu__)
Set the Hubbard correction switch.
Definition: atom_type.hpp:1054
std::string name_
Chemical element name.
Definition: atom_type.hpp:108
bool initialized_
True if the atom type was initialized.
Definition: atom_type.hpp:269
void add_aw_descriptor(int n, int l, double enu, int dme, int auto_enu)
Add augmented-wave descriptor.
Definition: atom_type.hpp:417
std::vector< std::pair< angular_momentum, Spline< double > > > beta_radial_functions_
Radial functions of beta-projectors.
Definition: atom_type.hpp:181
std::vector< radial_solution_descriptor_set > aw_specific_l_
Augmented wave configuration for specific l.
Definition: atom_type.hpp:130
int num_atoms() const
Return number of atoms of a given type.
Definition: atom_type.hpp:934
std::vector< double > ps_total_charge_density_
Total pseudo-charge density (used by PP-PW method to setup initial density).
Definition: atom_type.hpp:203
std::vector< hubbard_orbital_descriptor > lo_descriptors_hub_
List of Hubbard orbital descriptors.
Definition: atom_type.hpp:162
std::string file_name_
Name of the input file for this atom type.
Definition: atom_type.hpp:254
int id() const
Return atom type id.
Definition: atom_type.hpp:675
std::vector< double > paw_ae_core_charge_density_
Core electron contribution to all electron charge density in PAW method.
Definition: atom_type.hpp:234
void add_hubbard_orbital(int n__, int l__, double occ__, double U, double J, const double *hub_coef__, double alpha__, double beta__, double J0__, std::vector< double > initial_occupancy__, const bool use_for_calculations__)
Add a hubbard orbital to a list.
Definition: atom_type.cpp:889
bool paw_core_energy_
Core energy of PAW.
Definition: atom_type.hpp:212
radial_functions_index indexr_
Index of radial basis functions.
Definition: atom_type.hpp:146
radial_solution_descriptor_set aw_default_l_
Default augmented wave configuration.
Definition: atom_type.hpp:127
int num_ae_paw_wf() const
Get the number of all-electron PAW wave-functions.
Definition: atom_type.hpp:622
void init_aw_descriptors()
Initialize descriptors of the augmented-wave radial functions.
Definition: atom_type.hpp:291
std::string label_
Unique string label for the atom type.
Definition: atom_type.hpp:102
void set_radial_grid(radial_grid_t grid_type__, int num_points__, double rmin__, double rmax__, double p__)
Set the radial grid of the given type.
Definition: atom_type.hpp:384
int max_aw_order_
Maximum number of AW radial functions across angular momentums.
Definition: atom_type.hpp:141
bool augment() const
Return true if this atom type has an augementation charge.
Definition: atom_type.hpp:569
std::vector< std::vector< double > > ps_paw_wfs_
List of pseudo wave functions of the PAW method.
Definition: atom_type.hpp:222
sddk::mdarray< std::complex< double >, 4 > f_coefficients_
Definition: atom_type.hpp:248
void add_ps_atomic_wf(int n__, angular_momentum am__, std::vector< double > f__, double occ__=0.0)
Add atomic radial function to the list.
Definition: atom_type.hpp:491
void read_input(std::string const &str__)
Read atomic parameters from json file or string.
Definition: atom_type.cpp:701
double mass() const
Return atomic mass.
Definition: atom_type.hpp:705
sddk::matrix< std::complex< double > > p_mtrx_
Inverse of (Q_{\xi \xi'j}^{-1} + beta_pw^{H}_{\xi} * beta_pw_{xi'})
Definition: atom_type.hpp:244
sddk::mdarray< double, 2 > ae_paw_wfs_array_
All-electron wave functions of the PAW method packed in a single array.
Definition: atom_type.hpp:219
std::vector< double > paw_wf_occ_
Occupations of PAW wave-functions.
Definition: atom_type.hpp:231
int aw_order(int l__) const
Order of augmented wave radial functions for a given l.
Definition: atom_type.hpp:810
double mass_
Atom mass.
Definition: atom_type.hpp:114
void add_ae_paw_wf(std::vector< double > f__)
Add all-electron PAW wave-function.
Definition: atom_type.hpp:610
sddk::mdarray< double, 2 > d_mtrx_ion_
Ionic part of D-operator matrix.
Definition: atom_type.hpp:206
bool is_paw_
True if the pseudopotential is used for PAW.
Definition: atom_type.hpp:209
auto const & indexb_hub() const
Return whole index of hubbard basis functions.
Definition: atom_type.hpp:897
double num_valence_electrons_
Number of valence electrons.
Definition: atom_type.hpp:124
void add_beta_radial_function(angular_momentum am__, std::vector< double > beta__)
Add a radial function of beta-projector to a list of functions.
Definition: atom_type.hpp:513
External radial grid provided as a list of points.
T last() const
Last point of the grid.
int num_points() const
Number of grid points.
Set of basic parameters of a simulation.
T at_point(U x) const
Compute value at any point.
Definition: spline.hpp:216
Angular momentum quantum number.
auto l() const
Get orbital quantum number l.
auto s() const
Get spin quantum number s.
auto j() const
Get total angular momentum j = l +/- 1/2.
A helper class to establish various index mappings for the atomic basis functions.
int size() const
Return total number of MT basis functions.
auto size_aw() const
Return size of AW part of basis functions in case of LAPW.
auto size_lo() const
Return size of local-orbital part of basis functions in case of LAPW.
Radial basis function index.
auto index_of(angular_momentum am__, int order__) const
Return index of radial function.
int size() const
Return total number of radial functions.
Multidimensional array with the column-major (Fortran) order.
Definition: memory.hpp:660
Contains definition and implementation of sirius::Gaunt class.
Contains a descriptor class for Hubbard orbitals.
void copy(T *target__, T const *source__, size_t n__)
Copy memory inside a device.
Definition: acc.hpp:320
int lmax(int lmmax__)
Get maximum orbital quantum number by the maximum lm index.
Definition: specfunc.hpp:56
int lmmax(int lmax)
Maximum number of combinations for a given .
Definition: specfunc.hpp:44
int lm(int l, int m)
Get composite lm index by angular index l and azimuthal index m.
Definition: specfunc.hpp:50
std::enable_if_t< std::is_same< T, real_type< F > >::value, void > inner(::spla::Context &spla_ctx__, sddk::memory_t mem__, spin_range spins__, W const &wf_i__, band_range br_i__, Wave_functions< T > const &wf_j__, band_range br_j__, la::dmatrix< F > &result__, int irow0__, int jcol0__)
Compute inner product between the two sets of wave-functions.
Namespace of the SIRIUS library.
Definition: sirius.f90:5
std::ostream & operator<<(std::ostream &out, hbar &&b)
Inject horisontal bar to ostream.
radial_grid_t
Types of radial grid.
Definition: radial_grid.hpp:35
strong_type< int, struct __rf_lo_index_tag > rf_lo_index
Local orbital radial function index.
std::vector< radial_solution_descriptor > radial_solution_descriptor_set
Set of radial solution descriptors, used to construct augmented waves or local orbitals.
Definition: typedefs.hpp:155
strong_type< int, struct __rf_index_tag > rf_index
Radial function index.
int packed_index(int i__, int j__)
Pack two indices into one for symmetric matrices.
Packed index for symmetric matrices.
A time-based profiler.
Simple classes and functions to work with vectors and matrices of the R^3 space.
Contains definition and implementation of sirius::radial_functions_index class.
Contains declaration and partial implementation of sirius::Radial_solver class.
Contains declaration and particular implementation of sirius::SHT class.
Contains definition and implementation of sirius::Simulation_parameters class.
Describes single atomic level.
Definition: atomic_data.hpp:15
bool core
True if this is a core level.
Definition: atomic_data.hpp:29
int k
Quantum number k.
Definition: atomic_data.hpp:23
int n
Principal quantum number.
Definition: atomic_data.hpp:17
double occupancy
Level occupancy.
Definition: atomic_data.hpp:26
int l
Angular momentum quantum number.
Definition: atomic_data.hpp:20
Descriptor of a local orbital radial function.
Definition: atom_type.hpp:44
radial_solution_descriptor_set rsd_set
Set of radial solution descriptors.
Definition: atom_type.hpp:51
angular_momentum am
Orbital quantum number .
Definition: atom_type.hpp:46
Store basic information about radial pseudo wave-functions.
Definition: atom_type.hpp:61
double occ
Shell occupancy.
Definition: atom_type.hpp:75
Spline< double > f
Radial wave-function.
Definition: atom_type.hpp:77
ps_atomic_wf_descriptor(int n__, angular_momentum am__, double occ__, Spline< double > f__)
Constructor.
Definition: atom_type.hpp:63
angular_momentum am
Angular momentum quantum number.
Definition: atom_type.hpp:73
int n
Principal quantum number.
Definition: atom_type.hpp:71
Describes radial solution.
Definition: typedefs.hpp:128
double enu
Energy of the solution.
Definition: typedefs.hpp:139
int auto_enu
Automatically determine energy.
Definition: typedefs.hpp:142
int n
Principal quantum number.
Definition: typedefs.hpp:130
int l
Angular momentum quantum number.
Definition: typedefs.hpp:133
int dme
Order of energy derivative.
Definition: typedefs.hpp:136