ABACUS develop
Atomic-orbital Based Ab-initio Computation at UStc
Loading...
Searching...
No Matches
dftu_nao_fs_r.h File Reference

Unified entry for DFT+U force and stress in real space (r-space). More...

#include "source_base/matrix.h"
#include <vector>
Include dependency graph for dftu_nao_fs_r.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  hamilt
namespace  DFTU_LCAO

Functions

void DFTU_LCAO::reduce_force_impl (ModuleBase::matrix &force, int nspin)
 Post-process force: MPI Allreduce and spin-degeneracy scaling.
void DFTU_LCAO::reduce_stress_impl (const UnitCell *ucell, const std::vector< double > &stress_tmp, ModuleBase::matrix &stress)
 Post-process stress: MPI Allreduce and renormalization to full 3x3 tensor from Voigt-like 6-component form.
void DFTU_LCAO::cal_fs_nao_r_impl (const UnitCell *ucell, Plus_U_Base *dftu, const TwoCenterIntegrator *intor, int nspin, const std::vector< AdjacentAtomInfo > &adjs_all, const std::vector< const hamilt::HContainer< double > * > &dmR, bool cal_force, bool cal_stress, ModuleBase::matrix &force, ModuleBase::matrix &stress)
 Non-template core of DFT+U force/stress in real space.
void DFTU_LCAO::cal_fs_nao_r (const UnitCell *ucell, Plus_U_Base *dftu, const TwoCenterIntegrator *intor, int nspin, const std::vector< AdjacentAtomInfo > &adjs_all, const std::vector< const hamilt::HContainer< double > * > &dmR, bool cal_force, bool cal_stress, ModuleBase::matrix &force, ModuleBase::matrix &stress)
 Calculate DFT+U force and stress in real space from explicit environment arguments (non-template overload).

Detailed Description

Unified entry for DFT+U force and stress in real space (r-space).

Loops over atom pairs (I,J,R) and dispatches to the per-pair kernels cal_for_IJR_nao_r / cal_str_IJR_nao_r. Independent of k-point sampling because the real-space density matrix (DMR) already contains the Brillouin-zone integration.

Naming convention: _r suffix denotes the real-space implementation, corresponding to _k for the k-space (legacy) one.

The DFT+U force on atom J is derived from the Hubbard correction energy:

E_U = (U_eff/2) * sum_{I,m,m',sigma} [ n^sigma_{mm'}(I) * (delta_{mm'} - n^sigma_{m'm}(I)) ]

where n^sigma_{mm'}(I) is the on-site occupation matrix for correlated orbital l on atom I.

The force on atom J is:

F_J = -dE_U/d tau_J = -sum_{I,R} sum_{m,m'} V_U_{mm'}(I) * [ sum_{mu,nu} DMR_{mu,nu}(I,R) * d<phi_{mu,0}|chi_m(I)>/d tau_J * <chi_m'(I)|phi_{nu,R}> ]

For stress, the derivative is with respect to strain tensor epsilon_{alpha,beta}:

sigma_{alpha,beta} = -(1/Omega) * dE_U/d epsilon_{alpha,beta} = -(1/Omega) * sum_{I,R} sum_{m,m'} V_U_{mm'}(I) * [ sum_{mu,nu} DMR_{mu,nu}(I,R) * ( d<phi_{mu,0}|chi_m(I)>/d epsilon_{alpha,beta} * <chi_m'(I)|phi_{nu,R}> * R_beta

  • <phi_{mu,0}|chi_m(I)> * d<chi_m'(I)|phi_{nu,R}>/d epsilon_{alpha,beta} * R_beta ) ]