ABACUS develop
Atomic-orbital Based Ab-initio Computation at UStc
Loading...
Searching...
No Matches
pseudo.h
Go to the documentation of this file.
1#ifndef PSEUDO_H
2#define PSEUDO_H
3
4#include <cstdint>
8
9//-----------------------------------------
10// read in pseudopotentials
11// mohan update 2021-05-01
12//-----------------------------------------
13class pseudo
14{
15 public:
16 pseudo();
17 ~pseudo();
18
19 //<PP_HEADER>
20 bool has_so = false; // if .true. includes spin-orbit
21 int nv = 0; // UPF file version number
22 std::string psd; // Element label
23 std::string pp_type; // Pseudo type ( NC or US )
24 bool tvanp = false; // .true. if Ultrasoft
25 bool nlcc = false; // Non linear core corrections(bool)
26 std::string xc_func; // Exch-Corr type
27 double zv = 0; // z valence
28 double etotps = 0.0; // total energy
29 double ecutwfc = 0.0; // suggested cut-off for wfc
30 double ecutrho = 0.0; // suggested cut-off for rho
31 int lmax = 0; // maximum angular momentum component
32 int mesh = 0; // number of point in the radial mesh
33 int nchi = 0; // nwfc,number of wavefunctions
34 int nbeta = 0; // number of projectors
35 int nqlc = 0; // number of angular momenta in Q
36 int kkbeta = 0; // kkbeta, point where the beta are zero
37
38 std::vector<std::string> els = {}; // els[nchi]
39 std::vector<int> lchi = {}; // lchi[nchi]
40 std::vector<double> oc = {}; // oc[nchi]
41
42 std::vector<double> jjj = {}; // total angual momentum, jjj[nbeta]
43 std::vector<double> jchi = {}; // jchi(nwfc), added by zhengdy-soc
44 std::vector<int> nn = {};
45
46 // Local pseudopotentials
47 std::vector<double> vloc_at = {}; // [mesh], local potential( = pseudopot_upf.vloc )
48
49 // <PP_MESH>
50 std::vector<double> r = {}; // radial logaritmic mesh, r[0:mesh-1]
51 std::vector<double> rab = {}; // derivative of the radial mesh, rab[0:mesh-1]
52
53 //<PP_NLCC>
54 std::vector<double> rho_atc = {}; // radial core charge density, rho_atc[0:mesh-1]
55
56 //<PP_RHOATOM>
57 std::vector<double> rho_at = {}; // radial atomic charge density, rho_at[0:mesh-1]
58
59 // <PP_PSWFC>
60 ModuleBase::matrix chi; // radial atomic orbitals, chi(nchi, mesh)
61
62 // other
63 int msh = 0; // number of points up to rcut
64 double rcut = 0.0; // cut-off radius
65
66 // <PP_BETA>
67 std::vector<int> lll = {}; // lll(nbeta), angular momentum of the beta function
68
69 // <PP_DIJ>
70 ModuleBase::matrix dion; // dion(nbeta,nbeta)
71 ModuleBase::matrix betar; // (nbeta, mesh), radial beta_{mu} functions
72
73 // other
74 int nh = 0; // number of beta functions per atomic type
75
76 // uspp
77 ModuleBase::realArray qfuncl; // qfuncl(2*lmax+1,nbeta*(nbeta+1)/2,mesh) Q_{mu,nu}(|r|) function for |r|> r_L
78 ModuleBase::matrix qqq; // qqq(nbeta,nbeta) q_{mu,nu}
84 void check_betar();
85
86 void print_pseudo_h(std::ofstream& ofs) const;
87 void print_pseudo_atom(std::ofstream& ofs) const;
88 void print_pseudo_vl(std::ofstream& ofs) const;
89 void print_pseudo(std::ofstream& ofs) const;
90};
91
92#endif // PSEUDO_H
Definition matrix.h:18
double float array
Definition realarray.h:21
Definition pseudo.h:14
int mesh
Definition pseudo.h:32
std::vector< double > rho_atc
Definition pseudo.h:54
void print_pseudo_h(std::ofstream &ofs) const
Definition pseudo.cpp:78
double ecutwfc
Definition pseudo.h:29
~pseudo()
Definition symmetry_test_analysis.cpp:27
std::vector< int > lchi
Definition pseudo.h:39
void print_pseudo(std::ofstream &ofs) const
Definition pseudo.cpp:42
ModuleBase::matrix chi
Definition pseudo.h:60
std::vector< int > nn
Definition pseudo.h:44
std::vector< double > jjj
Definition pseudo.h:42
std::string psd
Definition pseudo.h:22
std::vector< double > vloc_at
Definition pseudo.h:47
std::vector< int > lll
Definition pseudo.h:67
std::vector< double > jchi
Definition pseudo.h:43
double etotps
Definition pseudo.h:28
double zv
Definition pseudo.h:27
bool nlcc
Definition pseudo.h:25
void print_pseudo_vl(std::ofstream &ofs) const
Definition pseudo.cpp:70
int kkbeta
Definition pseudo.h:36
std::vector< std::string > els
Definition pseudo.h:38
void check_betar()
Check the input data for non-normal numbers in the betar. Subsequent values following non-normal numb...
Definition pseudo.cpp:14
int lmax
Definition pseudo.h:31
int msh
Definition pseudo.h:63
void print_pseudo_atom(std::ofstream &ofs) const
Definition pseudo.cpp:54
bool has_so
Definition pseudo.h:20
std::vector< double > oc
Definition pseudo.h:40
double ecutrho
Definition pseudo.h:30
int nbeta
Definition pseudo.h:34
double rcut
Definition pseudo.h:64
std::string pp_type
Definition pseudo.h:23
int nv
Definition pseudo.h:21
int nqlc
Definition pseudo.h:35
std::vector< double > rab
Definition pseudo.h:51
pseudo()
Definition symmetry_test_analysis.cpp:24
int nh
Definition pseudo.h:74
ModuleBase::realArray qfuncl
Definition pseudo.h:77
std::vector< double > r
Definition pseudo.h:50
int nchi
Definition pseudo.h:33
ModuleBase::matrix betar
Definition pseudo.h:71
bool tvanp
Definition pseudo.h:24
ModuleBase::matrix dion
Definition pseudo.h:70
std::vector< double > rho_at
Definition pseudo.h:57
std::string xc_func
Definition pseudo.h:26
ModuleBase::matrix qqq
Definition pseudo.h:78