ABACUS develop
Atomic-orbital Based Ab-initio Computation at UStc
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
ModuleIO::Cal_MLKEDF_Descriptors Class Reference

A class to calculate the descriptors for ML KEDF. Sun, Liang, and Mohan Chen. Physical Review B 109.11 (2024): 115135. Sun, Liang, and Mohan Chen. Electronic Structure 6.4 (2024): 045006. More...

#include <cal_mlkedf_descriptors.h>

Collaboration diagram for ModuleIO::Cal_MLKEDF_Descriptors:

Public Member Functions

 ~Cal_MLKEDF_Descriptors ()
 
void set_para (const int &nx, const double &nelec, const double &tf_weight, const double &vw_weight, const double &chi_p, const double &chi_q, const std::vector< double > &chi_xi, const std::vector< double > &chi_pnl, const std::vector< double > &chi_qnl, const int &nkernel, const std::vector< int > &kernel_type, const std::vector< double > &kernel_scaling, const std::vector< double > &yukawa_alpha, const std::vector< std::string > &kernel_file, const double &omega, ModulePW::PW_Basis *pw_rho)
 
void getGamma (const double *const *prho, std::vector< double > &rgamma)
 
void getP (const double *const *prho, ModulePW::PW_Basis *pw_rho, std::vector< std::vector< double > > &pnablaRho, std::vector< double > &rp)
 
void getQ (const double *const *prho, ModulePW::PW_Basis *pw_rho, std::vector< double > &rq)
 
void getGammanl (const int ikernel, std::vector< double > &pgamma, ModulePW::PW_Basis *pw_rho, std::vector< double > &rgammanl)
 
void getPnl (const int ikernel, std::vector< double > &pp, ModulePW::PW_Basis *pw_rho, std::vector< double > &rpnl)
 
void getQnl (const int ikernel, std::vector< double > &pq, ModulePW::PW_Basis *pw_rho, std::vector< double > &rqnl)
 
void getXi (std::vector< double > &pgamma, std::vector< double > &pgammanl, std::vector< double > &rxi)
 
void getTanhXi (const int ikernel, std::vector< double > &pgamma, std::vector< double > &pgammanl, std::vector< double > &rtanhxi)
 
void getTanhP (std::vector< double > &pp, std::vector< double > &rtanhp)
 
void getTanhQ (std::vector< double > &pq, std::vector< double > &rtanhq)
 
void getTanh_Pnl (const int ikernel, std::vector< double > &ppnl, std::vector< double > &rtanh_pnl)
 
void getTanh_Qnl (const int ikernel, std::vector< double > &pqnl, std::vector< double > &rtanh_qnl)
 
void getTanhP_nl (const int ikernel, std::vector< double > &ptanhp, ModulePW::PW_Basis *pw_rho, std::vector< double > &rtanhp_nl)
 
void getTanhQ_nl (const int ikernel, std::vector< double > &ptanhq, ModulePW::PW_Basis *pw_rho, std::vector< double > &rtanhq_nl)
 
void getTanhXi_nl (const int ikernel, std::vector< double > &ptanhxi, ModulePW::PW_Basis *pw_rho, std::vector< double > &rtanhxi_nl)
 
void getF_KS (psi::Psi< std::complex< double > > *psi, elecstate::ElecState *pelec, ModulePW::PW_Basis_K *pw_psi, ModulePW::PW_Basis *pw_rho, UnitCell &ucell, const std::vector< std::vector< double > > &nablaRho, std::vector< double > &rF, std::vector< double > &rpauli)
 
void getNablaRho (const double *const *prho, ModulePW::PW_Basis *pw_rho, std::vector< std::vector< double > > &rnablaRho)
 
double MLkernel (double eta, double tf_weight, double vw_weight)
 
double MLkernel_yukawa (double eta, double alpha)
 
void read_kernel (const std::string &fileName, const double &scaling, ModulePW::PW_Basis *pw_rho, double *kernel_)
 
void multiKernel (const int ikernel, double *pinput, ModulePW::PW_Basis *pw_rho, double *routput)
 
void Laplacian (double *pinput, ModulePW::PW_Basis *pw_rho, double *routput)
 
void divergence (double **pinput, ModulePW::PW_Basis *pw_rho, double *routput)
 
void tanh (std::vector< double > &pinput, std::vector< double > &routput, double chi=1.)
 
double dtanh (double tanhx, double chi=1.)
 

Public Attributes

std::vector< double > chi_xi = {1.0}
 
double chi_p = 1.
 
double chi_q = 1.
 
std::vector< double > chi_pnl = {1.0}
 
std::vector< double > chi_qnl = {1.0}
 
int nx = 0
 
double dV = 0.
 
double rho0 = 0.
 
double kF = 0.
 
double tkF = 0.
 
const double cTF = 3.0/10.0 * std::pow(3*std::pow(M_PI, 2.0), 2.0/3.0) * 2
 
const double pqcoef = 1.0 / (4.0 * std::pow(3*std::pow(M_PI, 2.0), 2.0/3.0))
 
int nkernel = 1
 
std::vector< int > kernel_type = {1}
 
std::vector< double > kernel_scaling = {1.0}
 
std::vector< double > yukawa_alpha = {1.0}
 
std::vector< std::string > kernel_file = {"none"}
 
std::vector< std::vector< double > > kernel = {}
 

Detailed Description

A class to calculate the descriptors for ML KEDF. Sun, Liang, and Mohan Chen. Physical Review B 109.11 (2024): 115135. Sun, Liang, and Mohan Chen. Electronic Structure 6.4 (2024): 045006.

Author
sunliang on 2025-06-12

Constructor & Destructor Documentation

◆ ~Cal_MLKEDF_Descriptors()

ModuleIO::Cal_MLKEDF_Descriptors::~Cal_MLKEDF_Descriptors ( )
inline

Member Function Documentation

◆ divergence()

void ModuleIO::Cal_MLKEDF_Descriptors::divergence ( double **  pinput,
ModulePW::PW_Basis pw_rho,
double *  routput 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ dtanh()

double ModuleIO::Cal_MLKEDF_Descriptors::dtanh ( double  tanhx,
double  chi = 1. 
)
Here is the caller graph for this function:

◆ getF_KS()

void ModuleIO::Cal_MLKEDF_Descriptors::getF_KS ( psi::Psi< std::complex< double > > *  psi,
elecstate::ElecState pelec,
ModulePW::PW_Basis_K pw_psi,
ModulePW::PW_Basis pw_rho,
UnitCell ucell,
const std::vector< std::vector< double > > &  nablaRho,
std::vector< double > &  rF,
std::vector< double > &  rpauli 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getGamma()

void ModuleIO::Cal_MLKEDF_Descriptors::getGamma ( const double *const *  prho,
std::vector< double > &  rgamma 
)
Here is the caller graph for this function:

◆ getGammanl()

void ModuleIO::Cal_MLKEDF_Descriptors::getGammanl ( const int  ikernel,
std::vector< double > &  pgamma,
ModulePW::PW_Basis pw_rho,
std::vector< double > &  rgammanl 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getNablaRho()

void ModuleIO::Cal_MLKEDF_Descriptors::getNablaRho ( const double *const *  prho,
ModulePW::PW_Basis pw_rho,
std::vector< std::vector< double > > &  rnablaRho 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getP()

void ModuleIO::Cal_MLKEDF_Descriptors::getP ( const double *const *  prho,
ModulePW::PW_Basis pw_rho,
std::vector< std::vector< double > > &  pnablaRho,
std::vector< double > &  rp 
)
Here is the caller graph for this function:

◆ getPnl()

void ModuleIO::Cal_MLKEDF_Descriptors::getPnl ( const int  ikernel,
std::vector< double > &  pp,
ModulePW::PW_Basis pw_rho,
std::vector< double > &  rpnl 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getQ()

void ModuleIO::Cal_MLKEDF_Descriptors::getQ ( const double *const *  prho,
ModulePW::PW_Basis pw_rho,
std::vector< double > &  rq 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getQnl()

void ModuleIO::Cal_MLKEDF_Descriptors::getQnl ( const int  ikernel,
std::vector< double > &  pq,
ModulePW::PW_Basis pw_rho,
std::vector< double > &  rqnl 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getTanh_Pnl()

void ModuleIO::Cal_MLKEDF_Descriptors::getTanh_Pnl ( const int  ikernel,
std::vector< double > &  ppnl,
std::vector< double > &  rtanh_pnl 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getTanh_Qnl()

void ModuleIO::Cal_MLKEDF_Descriptors::getTanh_Qnl ( const int  ikernel,
std::vector< double > &  pqnl,
std::vector< double > &  rtanh_qnl 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getTanhP()

void ModuleIO::Cal_MLKEDF_Descriptors::getTanhP ( std::vector< double > &  pp,
std::vector< double > &  rtanhp 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getTanhP_nl()

void ModuleIO::Cal_MLKEDF_Descriptors::getTanhP_nl ( const int  ikernel,
std::vector< double > &  ptanhp,
ModulePW::PW_Basis pw_rho,
std::vector< double > &  rtanhp_nl 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getTanhQ()

void ModuleIO::Cal_MLKEDF_Descriptors::getTanhQ ( std::vector< double > &  pq,
std::vector< double > &  rtanhq 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getTanhQ_nl()

void ModuleIO::Cal_MLKEDF_Descriptors::getTanhQ_nl ( const int  ikernel,
std::vector< double > &  ptanhq,
ModulePW::PW_Basis pw_rho,
std::vector< double > &  rtanhq_nl 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getTanhXi()

void ModuleIO::Cal_MLKEDF_Descriptors::getTanhXi ( const int  ikernel,
std::vector< double > &  pgamma,
std::vector< double > &  pgammanl,
std::vector< double > &  rtanhxi 
)
Here is the caller graph for this function:

◆ getTanhXi_nl()

void ModuleIO::Cal_MLKEDF_Descriptors::getTanhXi_nl ( const int  ikernel,
std::vector< double > &  ptanhxi,
ModulePW::PW_Basis pw_rho,
std::vector< double > &  rtanhxi_nl 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getXi()

void ModuleIO::Cal_MLKEDF_Descriptors::getXi ( std::vector< double > &  pgamma,
std::vector< double > &  pgammanl,
std::vector< double > &  rxi 
)
Here is the caller graph for this function:

◆ Laplacian()

void ModuleIO::Cal_MLKEDF_Descriptors::Laplacian ( double *  pinput,
ModulePW::PW_Basis pw_rho,
double *  routput 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ MLkernel()

double ModuleIO::Cal_MLKEDF_Descriptors::MLkernel ( double  eta,
double  tf_weight,
double  vw_weight 
)
Here is the caller graph for this function:

◆ MLkernel_yukawa()

double ModuleIO::Cal_MLKEDF_Descriptors::MLkernel_yukawa ( double  eta,
double  alpha 
)
Here is the caller graph for this function:

◆ multiKernel()

void ModuleIO::Cal_MLKEDF_Descriptors::multiKernel ( const int  ikernel,
double *  pinput,
ModulePW::PW_Basis pw_rho,
double *  routput 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ read_kernel()

void ModuleIO::Cal_MLKEDF_Descriptors::read_kernel ( const std::string &  fileName,
const double &  scaling,
ModulePW::PW_Basis pw_rho,
double *  kernel_ 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ set_para()

void ModuleIO::Cal_MLKEDF_Descriptors::set_para ( const int &  nx,
const double &  nelec,
const double &  tf_weight,
const double &  vw_weight,
const double &  chi_p,
const double &  chi_q,
const std::vector< double > &  chi_xi,
const std::vector< double > &  chi_pnl,
const std::vector< double > &  chi_qnl,
const int &  nkernel,
const std::vector< int > &  kernel_type,
const std::vector< double > &  kernel_scaling,
const std::vector< double > &  yukawa_alpha,
const std::vector< std::string > &  kernel_file,
const double &  omega,
ModulePW::PW_Basis pw_rho 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ tanh()

void ModuleIO::Cal_MLKEDF_Descriptors::tanh ( std::vector< double > &  pinput,
std::vector< double > &  routput,
double  chi = 1. 
)
Here is the caller graph for this function:

Member Data Documentation

◆ chi_p

double ModuleIO::Cal_MLKEDF_Descriptors::chi_p = 1.

◆ chi_pnl

std::vector<double> ModuleIO::Cal_MLKEDF_Descriptors::chi_pnl = {1.0}

◆ chi_q

double ModuleIO::Cal_MLKEDF_Descriptors::chi_q = 1.

◆ chi_qnl

std::vector<double> ModuleIO::Cal_MLKEDF_Descriptors::chi_qnl = {1.0}

◆ chi_xi

std::vector<double> ModuleIO::Cal_MLKEDF_Descriptors::chi_xi = {1.0}

◆ cTF

const double ModuleIO::Cal_MLKEDF_Descriptors::cTF = 3.0/10.0 * std::pow(3*std::pow(M_PI, 2.0), 2.0/3.0) * 2

◆ dV

double ModuleIO::Cal_MLKEDF_Descriptors::dV = 0.

◆ kernel

std::vector<std::vector<double> > ModuleIO::Cal_MLKEDF_Descriptors::kernel = {}

◆ kernel_file

std::vector<std::string> ModuleIO::Cal_MLKEDF_Descriptors::kernel_file = {"none"}

◆ kernel_scaling

std::vector<double> ModuleIO::Cal_MLKEDF_Descriptors::kernel_scaling = {1.0}

◆ kernel_type

std::vector<int> ModuleIO::Cal_MLKEDF_Descriptors::kernel_type = {1}

◆ kF

double ModuleIO::Cal_MLKEDF_Descriptors::kF = 0.

◆ nkernel

int ModuleIO::Cal_MLKEDF_Descriptors::nkernel = 1

◆ nx

int ModuleIO::Cal_MLKEDF_Descriptors::nx = 0

◆ pqcoef

const double ModuleIO::Cal_MLKEDF_Descriptors::pqcoef = 1.0 / (4.0 * std::pow(3*std::pow(M_PI, 2.0), 2.0/3.0))

◆ rho0

double ModuleIO::Cal_MLKEDF_Descriptors::rho0 = 0.

◆ tkF

double ModuleIO::Cal_MLKEDF_Descriptors::tkF = 0.

◆ yukawa_alpha

std::vector<double> ModuleIO::Cal_MLKEDF_Descriptors::yukawa_alpha = {1.0}

The documentation for this class was generated from the following files: