You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Browse filesBrowse the repository at this point in the historyBrowse files
dyzheng
committed
Fix(dftu-pw): fix DFT+U for PW basis (nspin=1/2/4) and occupation matrix mixing
- Relax DFT+U nspin validation to support nspin=1/2/4 for PW basis
- Encapsulate Plus_U with typed accessors (get/set_locale, get_orbital_corr, get_hubbard_u, is_locale_initialized, mark_locale_dirty, enable_mixing)
- Rewrite cal_occ_pw for nspin=1/2/4 with correct becp indexing
- Add DFT+U occupation matrix mixing via Broyden method in Charge_Mixing
- Fix DFT+U locale double-counting when kpar>1
- Fix spin-channel selection: use isk[ik] instead of ik>=nk/2 in cal_occ_pw
- Extract setup_pw_dftu_indices() from cal_ps_dftu
- Propagate ld_psi for correct GEMM strides when ngk[ik] < npwx
- Restructure eff_pot_pw layout: nspin=2 uses split spin_up|spin_down
- Add get_eff_pot_pw_spin(isk) for nspin-aware access
- Add becp_ready caching in OnsiteProjector
- Update dftu_lcao.cpp for new Plus_U accessor interface
- Add unit tests for PW DFT+U (dftu_pw_test.cpp)
- Update dftu_io.cpp to use new accessors and onsite.dm format
0 commit comments