41 std::ifstream original_file(filename.c_str());
42 std::string buffer((std::istreambuf_iterator<char>(original_file)),
43 std::istreambuf_iterator<char>());
44 std::replace(buffer.begin(), buffer.end(),
'D',
'E');
45 std::replace(buffer.begin(), buffer.end(),
'd',
'e');
47 std::istringstream
file(buffer);
52 file.seekg(0, std::ios::beg);
54 file.seekg(0, std::ios::end);
58 file.seekg(0, std::ios::beg);
98 file >> extension_switch;
107 if (extension_switch > 2)
130 for (
int iproj = 0; iproj <
nprojl_[
l]; iproj++) {
139 file >> read_ip >> grid_point;
141 assert(read_ip == ip + 1);
143 for (
int iproj = 0; iproj <
nprojl_[
l]; iproj++)
161 assert(read_ip == ip + 1);
166 if (extension_switch == 1) {
174 assert(read_ip == ip + 1);
321 assert(function_.size() >= 4);
326 double f1 = function_[1];
327 double f2 = function_[2];
328 double f3 = function_[3];
333 function_[0] = f1 * x2 * x3 * (x2 - x3) + f2 * x1 * x3 * (x3 - x1) +
334 f3 * x1 * x2 * (x1 - x2);
335 function_[0] /= (x1 - x2) * (x1 - x3) * (x2 - x3);
344 assert(
llocal_ == read_llocal);
352 assert(read_ip == ip + 1);
373 std::vector<std::vector<double>>
ekb_;
std::string filename_
Definition: base.hpp:175
pseudopotential::type type_
Definition: base.hpp:185
int lmax_
Definition: base.hpp:186
Definition: element.hpp:34
double mass() const
Definition: element.hpp:73
const std::string & symbol() const
Definition: element.hpp:69
double d_ij(int l, int i, int j) const
Definition: psp8.hpp:280
int atomic_number_
Definition: psp8.hpp:363
bool has_radial_function(int l) const
Definition: psp8.hpp:288
bool has_nlcc() const
Definition: psp8.hpp:298
bool has_soc_
Definition: psp8.hpp:379
std::vector< double > nlcc_density_
Definition: psp8.hpp:376
int llocal() const
Definition: psp8.hpp:238
int nchannels() const
Definition: psp8.hpp:244
pseudopotential::format format() const
Definition: psp8.hpp:180
int llocal_
Definition: psp8.hpp:366
bool has_density_
Definition: psp8.hpp:377
int atomic_number() const
Definition: psp8.hpp:193
double valence_charge_
Definition: psp8.hpp:364
void radial_function(int l, std::vector< double > &function) const
Definition: psp8.hpp:290
int nchannels_
Definition: psp8.hpp:368
int mesh_size() const
Definition: psp8.hpp:248
void read_local_potential(std::istream &file)
Definition: psp8.hpp:338
std::vector< double > local_potential_
Definition: psp8.hpp:374
bool has_total_angular_momentum() const
Definition: psp8.hpp:300
std::string description() const
Definition: psp8.hpp:186
size_t file_size_
Definition: psp8.hpp:361
pseudopotential::exchange exchange() const
Definition: psp8.hpp:202
double mass() const
Definition: psp8.hpp:195
void nlcc_density(std::vector< double > &density) const
Definition: psp8.hpp:302
void local_potential(std::vector< double > &potential) const
Definition: psp8.hpp:250
double mesh_spacing() const
Definition: psp8.hpp:246
int nprojectors_
Definition: psp8.hpp:371
int mesh_size_
Definition: psp8.hpp:367
double mesh_spacing_
Definition: psp8.hpp:369
psp8(const std::string &filename)
Definition: psp8.hpp:37
std::vector< int > nprojl_
Definition: psp8.hpp:370
std::vector< std::vector< double > > ekb_
Definition: psp8.hpp:373
int nprojectors_per_l(int l) const
Definition: psp8.hpp:259
pseudopotential::correlation correlation() const
Definition: psp8.hpp:217
std::vector< std::vector< std::vector< double > > > projectors_
Definition: psp8.hpp:372
int ixc_
Definition: psp8.hpp:365
std::string description_
Definition: psp8.hpp:362
bool has_density() const
Definition: psp8.hpp:309
std::string symbol() const
Definition: psp8.hpp:188
int size() const
Definition: psp8.hpp:184
bool nlcc_
Definition: psp8.hpp:375
void projector(int l, int i, std::vector< double > &proj) const
Definition: psp8.hpp:263
void extrapolate_first_point(std::vector< double > &function_) const
Definition: psp8.hpp:319
void density(std::vector< double > &density) const
Definition: psp8.hpp:311
void radial_potential(int l, std::vector< double > &function) const
Definition: psp8.hpp:294
double valence_charge() const
Definition: psp8.hpp:200
int nprojectors() const
Definition: psp8.hpp:257
std::vector< double > density_
Definition: psp8.hpp:378
!The assertions are ignored if the code is compiled in not debug when !prints out the assertion the file
Definition: global.h:58
!The assertions are ignored if the code is compiled in not debug when !prints out the assertion string
Definition: global.h:58
void const fint const fint * val
Definition: iihash_low.cc:41
Definition: anygrid.hpp:27
correlation
Definition: base.hpp:74
format
Definition: base.hpp:49
exchange
Definition: base.hpp:64
ptrdiff_t l
Definition: operate_inc.c:51
ptrdiff_t j
Definition: operate_inc.c:51
void const fint * i
Definition: write_iter_low.cc:126