ABACUS develop
Atomic-orbital Based Ab-initio Computation at UStc
Loading...
Searching...
No Matches
chg_symm.h
Go to the documentation of this file.
1#ifndef CHG_SYMM_H
2#define CHG_SYMM_H
3
4// TODO: make cal_rhog_symm / cal_rhog_symm_soc internal (detail or anonymous
5// namespace) so that external callers only use symmetrize_rho. Blocked by:
6// 1. get_pchg_lcao/pw call the double** overload — need a symmetrize_rho
7// overload that accepts raw arrays (with nspin=4 branch).
8// 2. write_mlkedf_desc symmetrizes a single component of a temporary array
9// — symmetrize_rho cannot express that yet.
10// 3. setup_pot, ctrl_output_fp, read_wf2rho, update_state_rdmft already use
11// the Charge& overload and can be migrated directly.
12
13#include <complex>
14
17
18class Charge;
19
27namespace module_charge
28{
29
41void symmetrize_rho(const int nspin,
42 const Charge& chr,
43 const ModulePW::PW_Basis* pw,
44 ModuleSymmetry::Symmetry& symm);
45
52void cal_rhog_symm(const int& spin_now,
53 const Charge& CHR,
54 const ModulePW::PW_Basis* pw,
55 ModuleSymmetry::Symmetry& symm);
56
60void cal_rhog_symm(const int& spin_now,
61 double** rho,
62 std::complex<double>** rhog,
63 int ngmc,
64 double** kin_r,
65 const ModulePW::PW_Basis* pw,
66 ModuleSymmetry::Symmetry& symm);
67
76void cal_rhog_symm_soc(double** rho,
77 std::complex<double>** rhog,
78 const ModulePW::PW_Basis* pw,
79 ModuleSymmetry::Symmetry& symm);
80
81} // namespace module_charge
82
83#endif
Definition charge.h:24
Charge-density symmetrization free functions.
Definition charge.h:18
void cal_rhog_symm_soc(double **rho, std::complex< double > **rhog, const ModulePW::PW_Basis *rho_basis, ModuleSymmetry::Symmetry &symm)
Symmetrize raw nspin=4 spin-density arrays with coupled spin rotations.
Definition chg_symm.cpp:105
void symmetrize_rho(const int nspin, const Charge &chr, const ModulePW::PW_Basis *pw, ModuleSymmetry::Symmetry &symm)
Symmetrize charge density for all spin channels.
Definition chg_symm.cpp:15
void cal_rhog_symm(const int &spin_now, const Charge &chr, const ModulePW::PW_Basis *rho_basis, ModuleSymmetry::Symmetry &symm)
Symmetrize one spin channel of the charge density.
Definition chg_symm.cpp:35
Symmetry analysis class.