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