Skip to content

Commit 71410f5

Browse files
authored
Update to_wannier90_lcao.h (#7266)
1 parent 71ee1d7 commit 71410f5

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

source/source_io/module_wannier/to_wannier90_lcao.h

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
#include "source_base/parallel_reduce.h"
1111
#include "source_base/sph_bessel_recursive.h"
1212
#include "source_base/timer.h"
13+
#include "source_base/tool_quit.h"
1314
#include "source_base/vector3.h"
1415
#include "source_base/ylm.h"
1516
#include "source_basis/module_ao/ORB_atomic_lm.h"
@@ -90,7 +91,10 @@ class toWannier90_LCAO : public toWannier90
9091
const psi::Psi<double>& psi,
9192
const Parallel_Orbitals* pv)
9293
{
93-
throw std::logic_error("The wave function of toWannier90_LCAO_IN_PW is generally a std::complex<double> type.");
94+
ModuleBase::WARNING_QUIT("toWannier90_LCAO::calculate",
95+
"The wave function is real (double type), indicating 'gamma_only = 1'. "
96+
"The Wannier90 interface does not support Gamma-only calculations. "
97+
"Please set 'gamma_only 0' in your INPUT file.");
9498
}
9599

96100
void cal_Amn(const UnitCell& ucell, const K_Vectors& kv, const psi::Psi<std::complex<double>>& psi);

0 commit comments

Comments
 (0)