Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: bug of cal_ux #5165

Merged
merged 4 commits into from
Sep 24, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion source/module_esolver/esolver_ks_pw.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ void ESolver_KS_PW<T, Device>::before_scf(const int istep)

//! cal_ux should be called before init_scf because
//! the direction of ux is used in noncoline_rho
if (PARAM.inp.nspin == 4 && PARAM.globalv.domag)
if (PARAM.inp.nspin == 4)
{
GlobalC::ucell.cal_ux();
}
Expand Down
2 changes: 1 addition & 1 deletion source/module_esolver/lcao_before_scf.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ void ESolver_KS_LCAO<TK, TR>::beforesolver(const int istep)
// cal_ux should be called before init_scf because
// the direction of ux is used in noncoline_rho
//=========================================================
if (PARAM.inp.nspin == 4 && PARAM.globalv.domag)
if (PARAM.inp.nspin == 4)
{
GlobalC::ucell.cal_ux();
}
Expand Down
6 changes: 3 additions & 3 deletions tests/integrate/140_PW_15_SO/result.ref
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
etotref -1668.616835067548
etotperatomref -834.3084175338
totaltimeref 6.35
etotref -1668.616833271131
etotperatomref -834.3084166356
totaltimeref 5.15
Loading