Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
113 commits
Select commit Hold shift + click to select a range
c83e361
Use template to reconstruct parse_expression
1041176461 Jan 21, 2023
cdf3c0c
Feature: output R matrix at each MD step
1041176461 Jan 23, 2023
cff6e08
Modify'matrix_HS' to 'matrix' for R matrix output
1041176461 Jan 23, 2023
b9db1f1
Merge branch 'develop' into develop
1041176461 Jan 23, 2023
6c1a77b
Merge branch 'develop' of https://github.com/1041176461/abacus-develo…
1041176461 Jan 31, 2023
cc149a5
Merge branches 'develop' and 'develop' of https://github.com/10411764…
Feb 11, 2023
992ba96
Merge branch 'develop' of https://github.com/1041176461/abacus-develo…
Feb 11, 2023
0c753e2
Merge branch 'deepmodeling:develop' into develop
1041176461 Feb 12, 2023
3fd87f3
Merge branch 'develop' of https://github.com/1041176461/abacus-develo…
Feb 14, 2023
2a81795
Fix: modify index in parse_expression
1041176461 Feb 15, 2023
3523c57
Merge branch 'deepmodeling:develop' into develop
1041176461 Mar 27, 2023
afe397c
Fix: add regfree for parse_expression
May 10, 2023
d7775cf
Merge branch 'develop' into develop
1041176461 May 10, 2023
aad3e5a
Merge branch 'develop' into develop
Qianruipku May 10, 2023
4375864
Merge branch 'deepmodeling:develop' into develop
1041176461 May 21, 2023
d91a9e9
Doc: update phonopy doc
1041176461 Jun 5, 2023
238d73f
Merge branch 'deepmodeling:develop' into develop
1041176461 Jun 5, 2023
cdc685a
Doc: update phonopy doc
1041176461 Jun 5, 2023
47bc26b
Merge branch 'develop' of https://github.com/1041176461/abacus-develo…
1041176461 Jun 5, 2023
2ecdcca
Merge branch 'deepmodeling:develop' into develop
1041176461 Jun 24, 2023
53eeedf
Merge branch 'deepmodeling:develop' into develop
1041176461 Aug 30, 2023
b22769e
Merge branch 'deepmodeling:develop' into develop
1041176461 Sep 4, 2023
89d7394
Merge branch 'deepmodeling:develop' into develop
1041176461 Oct 30, 2023
d09f2d8
Merge branch 'deepmodeling:develop' into develop
1041176461 Apr 8, 2024
2673ecc
fix tdos plot for nspin=2
1041176461 Apr 8, 2024
3d2d8dd
optimize dosplot for nspin=2
1041176461 Apr 8, 2024
d919681
fix legend for dosplot
1041176461 Apr 8, 2024
76defcd
Merge branch 'develop' into develop
1041176461 Apr 8, 2024
560a60c
Merge branch 'deepmodeling:develop' into develop
1041176461 May 8, 2024
47d5cac
Merge branch 'deepmodeling:develop' into develop
1041176461 Jul 3, 2024
8e0c6d8
Merge branch 'deepmodeling:develop' into develop
1041176461 Oct 13, 2024
90e4750
Merge branch 'deepmodeling:develop' into develop
1041176461 Oct 19, 2024
d0bedae
Add files via upload
ESROAMER Nov 2, 2024
25a77b3
Update cal_edm_tddft.cpp
ESROAMER Nov 2, 2024
e21da57
Refactor: modify exx loop for relax/md
1041176461 Nov 2, 2024
74651ac
Update result.ref
ESROAMER Nov 2, 2024
b67c43c
Fix wrong parameters in integrate test
ESROAMER Nov 2, 2024
0cb9cbb
Update result.ref
ESROAMER Nov 2, 2024
2ba948c
Update result.ref
ESROAMER Nov 2, 2024
58cc693
Update result.ref
ESROAMER Nov 2, 2024
6513db5
Update result.ref
ESROAMER Nov 2, 2024
0fc246b
Update result.ref
ESROAMER Nov 2, 2024
0721fbb
Update result.ref
ESROAMER Nov 2, 2024
63e59b5
Update result.ref
ESROAMER Nov 2, 2024
22058e3
Update result.ref
ESROAMER Nov 2, 2024
ced029a
add exx when istep>0
maki49 Nov 2, 2024
7740356
Merge pull request #8 from maki49/new_loop
1041176461 Nov 3, 2024
d15217c
Merge pull request #7 from 1041176461/new_loop
1041176461 Nov 3, 2024
2755221
Merge branch 'develop' into develop
1041176461 Nov 4, 2024
9b7df7d
Update dos.py
1041176461 Nov 4, 2024
a8a9051
Update esolver_sdft_pw.cpp
1041176461 Nov 4, 2024
ba09ba9
Update lcao_before_scf.cpp
1041176461 Nov 4, 2024
f5734d4
Update Exx_LRI_interface.h
1041176461 Nov 4, 2024
cacaf93
Update Exx_LRI_interface.hpp
1041176461 Nov 4, 2024
894cb25
Fix: compile error
1041176461 Nov 4, 2024
7c54ec6
Fix: compile error
1041176461 Nov 4, 2024
8c7c0e6
Fix: change HSE relax/md result.ref for new framework
1041176461 Nov 5, 2024
3df2804
Merge branch 'pr/1041176461/9' into develop
1041176461 Nov 6, 2024
9a820d2
Fix: compile error
1041176461 Nov 6, 2024
ebfdadc
compatible with exx_iter_finish
1041176461 Nov 6, 2024
eca5f43
Merge branch 'deepmodeling:develop' into develop
ESROAMER Nov 7, 2024
bac726b
Add files via upload
ESROAMER Nov 7, 2024
6965e9e
Update esolver_ks_lcao_tddft.h
ESROAMER Nov 8, 2024
09aa1a1
Update esolver_ks_lcao_tddft.cpp
ESROAMER Nov 8, 2024
2373c13
Merge pull request #10 from ESROAMER/no_force
1041176461 Nov 8, 2024
0ca4e04
Merge branch 'deepmodeling-develop' into develop
1041176461 Nov 27, 2024
7e3e147
Merge branch 'develop' of https://github.com/1041176461/abacus-develo…
1041176461 Nov 27, 2024
289036b
Merge branch 'deepmodeling:develop' into develop
1041176461 Jan 6, 2025
db653b7
Fix: support negative value in parse_expression
1041176461 Jan 6, 2025
4b82a10
[pre-commit.ci lite] apply automatic fixes
pre-commit-ci-lite[bot] Jan 6, 2025
7e0c98e
Merge branch 'deepmodeling:develop' into develop
1041176461 Jan 30, 2025
eb353a8
Fix: parse_expression for scientific notation
1041176461 Jan 30, 2025
c1235ac
Update input_conv.h
1041176461 Jan 30, 2025
477c87a
Merge branch 'deepmodeling:develop' into develop
1041176461 Feb 22, 2025
15d4fca
Merge branch 'deepmodeling:develop' into develop
1041176461 May 13, 2025
d7771a8
Merge branch 'deepmodeling:develop' into develop
1041176461 Jun 5, 2025
4ee5b2c
Merge branch 'deepmodeling:develop' into develop
1041176461 Jun 17, 2025
a6d828d
add complex erf function
1041176461 Jun 17, 2025
9cb6230
Merge branch 'develop' of https://github.com/deepmodeling/abacus-deve…
1041176461 Jul 1, 2025
8328df9
refactor ccp framework
1041176461 Jul 1, 2025
0ad01df
fix compile
1041176461 Jul 1, 2025
c2d6085
fix compile
1041176461 Jul 1, 2025
18cc44e
fix compile
1041176461 Jul 1, 2025
29517df
fix compile
1041176461 Jul 1, 2025
a40e993
fix compile
1041176461 Jul 1, 2025
f87ee41
fix compile
1041176461 Jul 1, 2025
9d5b757
fix compile
1041176461 Jul 1, 2025
4cfbc17
fix empty error
1041176461 Jul 2, 2025
4ed708d
add revised spencer
1041176461 Jul 2, 2025
89d8284
add cal_psi_erfc_spencer
1041176461 Jul 2, 2025
0cb8873
add exx_singularity_correction
1041176461 Jul 2, 2025
d6f78a1
add exx_singularity_correction test
1041176461 Jul 2, 2025
eb7204c
add lc-corrected hybrid functionals
1041176461 Jul 2, 2025
abdce6c
fix compile
1041176461 Jul 2, 2025
4b52538
fix compile
1041176461 Jul 2, 2025
3b47cdc
fix compile error
1041176461 Jul 2, 2025
043c9f6
fix libxc error
1041176461 Jul 2, 2025
fa1fe10
fix libxc error
1041176461 Jul 2, 2025
c941284
fix libxc error
1041176461 Jul 2, 2025
eb5c5b4
add klist.h in RI_Util.h
1041176461 Jul 2, 2025
0813999
fix include
1041176461 Jul 2, 2025
9d4e3f6
Merge branch 'develop' into rsh_spencer
1041176461 Jul 3, 2025
82ef3ee
fix ptest for hse
1041176461 Jul 3, 2025
caca763
Merge branch 'rsh_spencer' of https://github.com/1041176461/abacus-de…
1041176461 Jul 3, 2025
f5969ca
fix lc_pbe name for vdw autoset
1041176461 Jul 3, 2025
6a57a04
fix test error
1041176461 Jul 3, 2025
22936b1
fix cam_pbeh test
1041176461 Jul 3, 2025
a78ad6e
fix fock settings
1041176461 Jul 4, 2025
e195da0
support rsh functionals
1041176461 Jul 4, 2025
1532955
fix libxc param
1041176461 Jul 4, 2025
85831ad
Merge branch 'develop' into rsh_spencer
1041176461 Jul 4, 2025
673e842
add input
1041176461 Jul 4, 2025
39bd8d9
fix input
1041176461 Jul 4, 2025
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
49 changes: 31 additions & 18 deletions docs/advanced/input_files/input-main.md
Original file line number Diff line number Diff line change
Expand Up @@ -2769,37 +2769,41 @@ Support for hybrid functionals in the *pw [basis_type](#basis_type)* is under ac

The following parameters apply to *[basis_type](#basis_type)==lcao/lcao_in_pw/pw*. For basis specific parameters, see the sections *[Exact Exchange (LCAO/LCAO in PW)](#exact-exchange-lcaolcao-in-pw)* and *[Exact Exchange (PW)](#exact-exchange-pw)*.

**Availablity**: *[dft_functional](#dft_functional)==hse/hf/pbe0/scan0/opt_orb* or *[rpa](#rpa)==True*.
#### Hybrid Functional Parameters {#hybrid_func_params}
|[dft_functional](#dft_functional)|[exx_fock_alpha](#exx_fock_alpha)|[exx_erfc_alpha](#exx_erfc_alpha)|[exx_erfc_omega](#exx_erfc_omega)|
|:-:|:-:|:-:|:-:|
|hf|1|0|0|
|lc_pbe|1|-1|0.33|
|lc_wpbe|1|-1|0.4|
|lrc_wpbe|1|-1|0.3|
|lrc_wpbeh|1|-0.8|0.2|
|pbe0|0.25|0|0|
|hse|0.0|0.25|0.11|
|scan0|0.25|0|0|
|cam_pbeh|0.2|0.8|0.7|
|b3lyp|0.2|0|0|
|muller|1|0|0|
|power|1|0|0|
|wp22|1|-1|0.11|
|cwp22|0|1|0.11|

### exx_fock_alpha

- **Type**: Real \[Real...\](optional)
- **Description**: Fraction of Fock exchange 1/r in hybrid functionals, so that $E_{X} = \alpha E_{X} + (1-\alpha)E_{X,\text{LDA/GGA}}$
- **Default**:
- 1: if *[dft_functional](#dft_functional)==hf*
- 0.25: if *[dft_functional](#dft_functional)==pbe0*
- 0.2: if *[dft_functional](#dft_functional)==b3lyp*
- 0.25: if *[dft_functional](#dft_functional)==scan0*
- 1: if *[dft_functional](#dft_functional)==muller*
- 1: if *[dft_functional](#dft_functional)==power*
- 1: if *[dft_functional](#dft_functional)==wp22*
- 0: else
- **Description**: Fraction of full-ranged Fock exchange 1/r ($\alpha$) in range-separated hybrid funtionals, so that $E_{X} = \alpha E_{X}^\text{HF-LR}+(\alpha+\beta) E_{X}^\text{HF-SR}+(1-\alpha)E_{X}^\text{KS-LR}+[1-(\alpha+\beta)]E_{X}^\text{KS-SR}$.
- **Default**: see [hybrid_func_params](#hybrid_func_params)

### exx_erfc_alpha

- **Type**: Real \[Real...\](optional)
- **Description**: Fraction of exchange erfc(wr)/r in hybrid functionals, so that $E_{X} = \alpha E_{X}^{\text{SR}} + (1-\alpha)E_{X,\text{LDA/GGA}}^{\text{SR}} + E_{X,\text{LDA/GGA}}^{\text{LR}}$
- **Default**:
- 0.25: if *[dft_functional](#dft_functional)==hse*
- 1: if *[dft_functional](#dft_functional)==cwp22*
- -1: if *[dft_functional](#dft_functional)==wp22*
- 0: else
- **Description**: Fraction of short-ranged Fock exchange erfc(wr)/r ($\beta$) in range-separated hybrid funtionals, so that $E_{X} = \alpha E_{X}^\text{HF-LR}+(\alpha+\beta) E_{X}^\text{HF-SR}+(1-\alpha)E_{X}^\text{KS-LR}+[1-(\alpha+\beta)]E_{X}^\text{KS-SR}$.
- **Default**: see [hybrid_func_params](#hybrid_func_params)

### exx_erfc_omega

- **Type**: Real \[Real...\](optional)
- **Description**: Range-separation parameter in exchange, such that $1/r=\text{erfc}(\omega r)/r+\text{erf}(\omega r)/r$
- **Default**: 0.11
- **Default**: see [hybrid_func_params](#hybrid_func_params)

### exx_separate_loop

Expand Down Expand Up @@ -2934,6 +2938,15 @@ These variables are relevant when using hybrid functionals with *[basis_type](#b
- True: if gamma_only
- False: else

### exx_singularity_correction

- **Type**: String
- **Description**:
- spencer: see Phys. Rev. B 77, 193110 (2008).
- revised_spencer: see Phys. Rev. Mater. 5, 013807 (2021).
Set the scheme of Coulomb singularity correction.
- **Default**: default

### rpa_ccp_rmesh_times

- **Type**: Real
Expand Down
1 change: 1 addition & 0 deletions source/module_parameter/input_parameter.h
Original file line number Diff line number Diff line change
Expand Up @@ -523,6 +523,7 @@ struct Input_para
std::vector<std::string> exx_erfc_omega = {"default"}; ///< range-separation parameter in HSE functional
bool exx_separate_loop = true; ///< if 1, a two-step method is employed, else it will start
///< with a GGA-Loop, and then Hybrid-Loop
std::string exx_singularity_correction = "default"; ///< set the scheme of Coulomb singularity correction
int exx_hybrid_step = 100; ///< the maximal electronic iteration number in
///< the evaluation of Fock exchange
double exx_mixing_beta = 1.0; ///< mixing_beta for outer-loop when exx_separate_loop=1
Expand Down
2 changes: 1 addition & 1 deletion source/source_hamilt/module_vdw/vdwd3_autoset_xcname.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ const std::map<std::string, std::string> xcname_libxc_xc_ = {
{"XC_HYB_GGA_XC_WHPBE0", "whpbe0"},
{"XC_HYB_GGA_XC_LC_BLYP_EA", "lc_blyp_ea"},
{"XC_HYB_GGA_XC_LC_BOP", "lc_bop"},
{"XC_HYB_GGA_XC_LC_PBEOP", "lc_pbeop"},
{"XC_HYB_GGA_XC_LC_PBEOP", "lc_pbe"},
{"XC_HYB_GGA_XC_LC_BLYPR", "lc_blypr"},
{"XC_HYB_GGA_XC_MCAM_B3LYP", "mcam_b3lyp"},
{"XC_MGGA_XC_VCML_RVV10", "vcml_rvv10"},
Expand Down
20 changes: 11 additions & 9 deletions source/source_hamilt/module_xc/exx_info.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,14 @@ struct Exx_Info

// Fock:
// "alpha": "0"
// "Rcut_type": "limits" / "spencer"
// "singularity_correction": "limits" / "spencer" / "revised_spencer"
// "lambda": "0.3"
// //"Rcut"
// "Rcut"
// Erfc:
// "alpha": "0"
// "omega": "0.11"
// "Rcut_type": "limits"
// //"Rcut"
// "singularity_correction": "limits" / "spencer" / "revised_spencer"
// "Rcut"

Conv_Coulomb_Pot_K::Ccp_Type ccp_type;
double hybrid_alpha = 0.25;
Expand All @@ -51,10 +51,7 @@ struct Exx_Info

struct Exx_Info_RI
{
std::map<Conv_Coulomb_Pot_K::Coulomb_Method,
std::pair<bool,
std::map<Conv_Coulomb_Pot_K::Coulomb_Type,
std::vector<std::map<std::string,std::string>>>>> coulomb_settings;
const std::map<Conv_Coulomb_Pot_K::Coulomb_Type, std::vector<std::map<std::string,std::string>>> &coulomb_param;

bool real_number = false;

Expand All @@ -72,10 +69,15 @@ struct Exx_Info
double kmesh_times = 4;

int abfs_Lmax = 0; // tmp

Exx_Info_RI(const Exx_Info::Exx_Info_Global& info_global)
: coulomb_param(info_global.coulomb_param)
{
}
};
Exx_Info_RI info_ri;

Exx_Info() : info_lip(this->info_global)
Exx_Info() : info_lip(this->info_global), info_ri(this->info_global)
{
}
};
Expand Down
43 changes: 38 additions & 5 deletions source/source_hamilt/module_xc/xc_functional.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,10 @@ void XC_Functional::set_xc_first_loop(const UnitCell& ucell)
the first scf iteration only calculate the functional without exact
exchange. but in "nscf" calculation, there is no need of "two-level"
method. */
if (ucell.atoms[0].ncpp.xc_func == "HF"
|| ucell.atoms[0].ncpp.xc_func == "PBE0"
|| ucell.atoms[0].ncpp.xc_func == "HSE") {
if (ucell.atoms[0].ncpp.xc_func == "HF" || ucell.atoms[0].ncpp.xc_func == "HSE"
|| ucell.atoms[0].ncpp.xc_func == "PBE0"|| ucell.atoms[0].ncpp.xc_func == "LC_PBE"
|| ucell.atoms[0].ncpp.xc_func == "LC_WPBE" || ucell.atoms[0].ncpp.xc_func == "LRC_WPBEH"
|| ucell.atoms[0].ncpp.xc_func == "CAM_PBEH") {
XC_Functional::set_xc_type("pbe");
}
else if (ucell.atoms[0].ncpp.xc_func == "SCAN0") {
Expand Down Expand Up @@ -149,6 +150,36 @@ void XC_Functional::set_xc_type(const std::string xc_func_in)
func_type = 5;
use_libxc = true;
}
else if( xc_func == "LC_PBE")
{
func_id.push_back(XC_HYB_GGA_XC_LC_PBEOP);
func_type = 4;
use_libxc = true;
}
else if( xc_func == "LC_WPBE")
{
func_id.push_back(XC_HYB_GGA_XC_LC_WPBE);
func_type = 4;
use_libxc = true;
}
else if( xc_func == "LRC_WPBE")
{
func_id.push_back(XC_HYB_GGA_XC_LRC_WPBE);
func_type = 4;
use_libxc = true;
}
else if( xc_func == "LRC_WPBEH")
{
func_id.push_back(XC_HYB_GGA_XC_LRC_WPBEH);
func_type = 4;
use_libxc = true;
}
else if( xc_func == "CAM_PBEH")
{
func_id.push_back(XC_HYB_GGA_XC_CAM_PBEH);
func_type = 4;
use_libxc = true;
}
#endif
else if( xc_func == "HF")
{
Expand Down Expand Up @@ -271,9 +302,11 @@ void XC_Functional::set_xc_type(const std::string xc_func_in)

#ifndef USE_LIBXC
if(xc_func == "SCAN" || xc_func == "HSE" || xc_func == "SCAN0"
|| xc_func == "MULLER" || xc_func == "POWER" || xc_func == "WP22" || xc_func == "CWP22")
|| xc_func == "MULLER" || xc_func == "POWER" || xc_func == "WP22" || xc_func == "CWP22" ||
xc_func == "LC_PBE" || xc_func == "LC_WPBE" || xc_func == "LRC_WPBE" ||
xc_func == "LRC_PBEH" || xc_func == "CAM_PBEH")
{
ModuleBase::WARNING_QUIT("set_xc_type","to use SCAN, SCAN0, or HSE, LIBXC is required");
ModuleBase::WARNING_QUIT("set_xc_type","to use SCAN, SCAN0, HSE, long-range corrected (LC_PBE, LC_WPBE...) or CAM_PBEH LIBXC is required");
}
use_libxc = false;
#endif
Expand Down
44 changes: 44 additions & 0 deletions source/source_hamilt/module_xc/xc_functional_libxc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,50 @@ const std::vector<double> in_built_xc_func_ext_params(const int id)
case XC_GGA_C_LYPR:
return {0.04918, 0.132, 0.2533, 0.349,
0.35/2.29, 2.0/2.29, GlobalC::exx_info.info_global.hse_omega};
// Long-range corrected functionals:
case XC_HYB_GGA_XC_LC_PBEOP: // LC version of PBE
{
// This is a range-separated hybrid functional with range-separation constant 0.330,
// and 0.0% short-range and 100.0% long-range exact exchange,
// using the error function kernel.
return { GlobalC::exx_info.info_global.hse_omega }; //Range separation constant: 0.33
}
case XC_HYB_GGA_XC_LC_WPBE: // Long-range corrected PBE (LC-wPBE) by Vydrov and Scuseria
{
// This is a range-separated hybrid functional with range-separation constant 0.400,
// and 0.0% short-range and 100.0% long-range exact exchange,
// using the error function kernel.
return { std::stod(PARAM.inp.exx_fock_alpha[0]), //Fraction of Hartree-Fock exchange: 1.0
std::stod(PARAM.inp.exx_erfc_alpha[0]), //Fraction of short-range exact exchange: -1.0
GlobalC::exx_info.info_global.hse_omega }; //Range separation constant: 0.4
}
case XC_HYB_GGA_XC_LRC_WPBE: // Long-range corrected PBE (LRC-wPBE) by by Rohrdanz, Martins and Herbert
{
// This is a range-separated hybrid functional with range-separation constant 0.300,
// and 0.0% short-range and 100.0% long-range exact exchange,
// using the error function kernel.
return { std::stod(PARAM.inp.exx_fock_alpha[0]), //Fraction of Hartree-Fock exchange: 1.0
std::stod(PARAM.inp.exx_erfc_alpha[0]), //Fraction of short-range exact exchange: -1.0
GlobalC::exx_info.info_global.hse_omega }; //Range separation constant: 0.3
}
case XC_HYB_GGA_XC_LRC_WPBEH: // Long-range corrected short-range hybrid PBE (LRC-wPBEh) by Rohrdanz, Martins and Herbert
{
// This is a range-separated hybrid functional with range-separation constant 0.200,
// and 20.0% short-range and 100.0% long-range exact exchange,
// using the error function kernel.
return { std::stod(PARAM.inp.exx_fock_alpha[0]), //Fraction of Hartree-Fock exchange: 1.0
std::stod(PARAM.inp.exx_erfc_alpha[0]), //Fraction of short-range exact exchange: -0.8
GlobalC::exx_info.info_global.hse_omega }; //Range separation constant: 0.2
}
case XC_HYB_GGA_XC_CAM_PBEH: // CAM hybrid screened exchange PBE version
{
// This is a range-separated hybrid functional with range-separation constant 0.700,
// and 100.0% short-range and 20.0% long-range exact exchange,
// using the error function kernel.
return { std::stod(PARAM.inp.exx_fock_alpha[0]), //Fraction of Hartree-Fock exchange: 0.2
std::stod(PARAM.inp.exx_erfc_alpha[0]), //Fraction of short-range exact exchange: 0.8
GlobalC::exx_info.info_global.hse_omega }; //Range separation constant: 0.7
}
#endif
default:
return std::vector<double>{};
Expand Down
36 changes: 21 additions & 15 deletions source/source_io/input_conv.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -297,7 +297,12 @@ void Input_Conv::Convert()
if (dft_functional_lower == "hf" || dft_functional_lower == "pbe0"
|| dft_functional_lower == "hse"
|| dft_functional_lower == "opt_orb"
|| dft_functional_lower == "scan0") {
|| dft_functional_lower == "scan0"
|| dft_functional_lower == "lc_pbe"
|| dft_functional_lower == "lc_wpbe"
|| dft_functional_lower == "lrc_wpbe"
|| dft_functional_lower == "lrc_wpbeh"
|| dft_functional_lower == "cam_pbeh") {
GlobalC::restart.info_load.load_charge = true;
GlobalC::restart.info_load.load_H = true;
}
Expand All @@ -322,10 +327,15 @@ void Input_Conv::Convert()
dft_functional_lower.begin(),
tolower);
if (dft_functional_lower == "hf"
|| dft_functional_lower == "pbe0" || dft_functional_lower == "b3lyp" || dft_functional_lower == "hse"
|| dft_functional_lower == "scan0"
|| dft_functional_lower == "muller" || dft_functional_lower == "power"
|| dft_functional_lower == "cwp22" || dft_functional_lower == "wp22")
|| dft_functional_lower == "pbe0" || dft_functional_lower == "b3lyp" || dft_functional_lower == "hse"
|| dft_functional_lower == "scan0"
|| dft_functional_lower == "muller" || dft_functional_lower == "power"
|| dft_functional_lower == "cwp22" || dft_functional_lower == "wp22"
|| dft_functional_lower == "lc_pbe"
|| dft_functional_lower == "lc_wpbe"
|| dft_functional_lower == "lrc_wpbe"
|| dft_functional_lower == "lrc_wpbeh"
|| dft_functional_lower == "cam_pbeh")
{
GlobalC::exx_info.info_global.cal_exx = true;

Expand All @@ -352,15 +362,13 @@ void Input_Conv::Convert()
{
if(PARAM.inp.basis_type == "lcao")
{
std::map<Conv_Coulomb_Pot_K::Coulomb_Type, std::vector<std::map<std::string,std::string>>> coulomb_param;
coulomb_param[Conv_Coulomb_Pot_K::Coulomb_Type::Fock].resize(fock_alpha.size());
GlobalC::exx_info.info_global.coulomb_param[Conv_Coulomb_Pot_K::Coulomb_Type::Fock].resize(fock_alpha.size());
for(std::size_t i=0; i<fock_alpha.size(); ++i)
{
coulomb_param[Conv_Coulomb_Pot_K::Coulomb_Type::Fock][i] = {{
GlobalC::exx_info.info_global.coulomb_param[Conv_Coulomb_Pot_K::Coulomb_Type::Fock] = {{
{"alpha", ModuleBase::GlobalFunc::TO_STRING(fock_alpha[i])},
{"Rcut_type", "spencer"} }};
{"singularity_correction", PARAM.inp.exx_singularity_correction} }};
}
GlobalC::exx_info.info_ri.coulomb_settings[Conv_Coulomb_Pot_K::Coulomb_Method::Center2] = std::make_pair(true, coulomb_param);
}
else if(PARAM.inp.basis_type == "lcao_in_pw")
{
Expand Down Expand Up @@ -392,16 +400,14 @@ void Input_Conv::Convert()
assert(erfc_alpha.size() == PARAM.inp.exx_erfc_omega.size());
if(PARAM.inp.basis_type == "lcao")
{
std::map<Conv_Coulomb_Pot_K::Coulomb_Type, std::vector<std::map<std::string,std::string>>> coulomb_param;
coulomb_param[Conv_Coulomb_Pot_K::Coulomb_Type::Erfc].resize(erfc_alpha.size());
GlobalC::exx_info.info_global.coulomb_param[Conv_Coulomb_Pot_K::Coulomb_Type::Erfc].resize(erfc_alpha.size());
for(std::size_t i=0; i<erfc_alpha.size(); ++i)
{
coulomb_param[Conv_Coulomb_Pot_K::Coulomb_Type::Erfc] = {{
GlobalC::exx_info.info_global.coulomb_param[Conv_Coulomb_Pot_K::Coulomb_Type::Erfc] = {{
{"alpha", ModuleBase::GlobalFunc::TO_STRING(erfc_alpha[i])},
{"omega", ModuleBase::GlobalFunc::TO_STRING(PARAM.inp.exx_erfc_omega[i])},
{"Rcut_type", "limits"} }};
{"singularity_correction", PARAM.inp.exx_singularity_correction} }};
}
GlobalC::exx_info.info_ri.coulomb_settings[Conv_Coulomb_Pot_K::Coulomb_Method::Center2] = std::make_pair(true, coulomb_param);
}
}
}
Expand Down
Loading
Loading