Density-fitted Coupled Cluster methods
ElemCo.DFCoupledCluster — Module
DFCoupledCluster
Density-fitted coupled-cluster methods.
Exported functions
ElemCo.DFCoupledCluster.calc_df_lt_sos_mp2 — Method
calc_df_lt_sos_mp2(EC::ECInfo)Perform density-fitted Laplace-transformed SOS MP2 calculation.
Args: EC: ECInfo object
Returns: OutDict with keys "E", "ESS", "EOS", "EO" for MP2 correlation energy, SS, OS, and O contributions.
ElemCo.DFCoupledCluster.calc_dfmp2 — Method
calc_dfmp2(EC::ECInfo)Perform density-fitted MP2 calculation. If save is set in CcOptions.save, save T2 amplitudes to save*"_2" file.
Args: EC: ECInfo object
Returns: OutDict with keys "E", "ESS", "EOS", "EO" for MP2 correlation energy, SS, OS, and O contributions.
ElemCo.DFCoupledCluster.calc_dressed_3idx — Method
calc_dressed_3idx(EC::ECInfo, T1)Calculate dressed integrals for 3-index integrals from file mmL.
ElemCo.DFCoupledCluster.calc_svd_dc — Method
calc_svd_dc(EC::ECInfo, method::AbstractString)Calculate decomposed closed-shell DCSD or DCD with $T^{ij}_{ab}=U^{iX}_a U^{jY}_b T_{XY}$.
ElemCo.DFCoupledCluster.calc_svd_dc — Method
calc_svd_dc(EC::ECInfo, method::ECMethod)Calculate decomposed closed-shell DCSD or DCD with $T^{ij}_{ab}=U^{iX}_a U^{jY}_b T_{XY}$.
Currently only DC methods are supported. DF integrals are used (have to be calculated before). The starting guess for SVD-coefficients is calculated without doubles, see calc_doubles_decomposition_without_doubles.
ElemCo.DFCoupledCluster.save_pseudodressed_3idx — Method
save_pseudodressed_3idx(EC::ECInfo)Save non-dressed 3-index integrals from file mmL to dressed files.
Internal functions
ElemCo.DFCoupledCluster.calc_3idx_svd_decomposition — Method
calc_3idx_svd_decomposition(EC::ECInfo, voL::AbstractArray, tol2)Calculate $U^{iX}_a$ from $v_a^{iL}$ using SVD.
Version without holding all $v_a^{iL}$ integrals in memory. voL is the full 3-index integral $v_a^{iL}$ (can be mmaped).
ElemCo.DFCoupledCluster.calc_MP2_amplitudes_from_3idx — Method
calc_MP2_amplitudes_from_3idx(EC::ECInfo, voL::AbstractArray, ishift)Calculate MP2 amplitudes from $v_a^{iL}$.
The imaginary shift ishift is used in the denominator in the calculation of the MP2 amplitudes.
ElemCo.DFCoupledCluster.calc_MP2_from_3idx — Method
calc_MP2_from_3idx(EC::ECInfo, voL::AbstractArray, ishift)Calculate MP2 energy from $v_a^{iL}$.
The imaginary shift ishift is used in the denominator in the calculation of the MP2 amplitudes. Returns total energy, SS, OS and Openshell (0.0) contributions as OutDict with keys (E,ESS,EOS,EO).
ElemCo.DFCoupledCluster.calc_deco_doubles_energy — Method
calc_deco_doubles_energy(EC::ECInfo, T2)Calculate closed-shell doubles energy using decomposed doubles amplitudes T2=$T_{XY}$ or T2=$T^{ij}_{ab}$ using density-fitted integrals.
Returns total energy, SS, OS and Openshell (0.0) contributions as OutDict with keys (E,ESS,EOS,EO).
ElemCo.DFCoupledCluster.calc_deco_hylleraas — Method
calc_deco_hylleraas(EC::ECInfo, T1, T2, R1, R2)Calculate closed-shell singles and doubles Hylleraas energy using contravariant decomposed doubles amplitudes T2=$T_{XY}$ or full contravariant doubles amplitude T2=$T^{ij}_{ab}$.
Returns total energy, SS, OS and Openshell (0.0) contributions as OutDict with keys (E,ESS,EOS,EO).
ElemCo.DFCoupledCluster.calc_df_doubles_energy — Method
calc_df_doubles_energy(EC::ECInfo, T2)Calculate closed-shell doubles energy using DF integrals and T2[a,b,i,j] = $T^{ij}_{ab}$.
Returns total energy, SS, OS and Openshell (0.0) contributions as OutDict with keys (E,ESS,EOS,EO).
ElemCo.DFCoupledCluster.calc_doubles_decomposition — Method
calc_doubles_decomposition(EC::ECInfo)Decompose $T^{ij}_{ab}=U^{iX}_a U^{jY}_b T_{XY}$
ElemCo.DFCoupledCluster.calc_doubles_decomposition_with_doubles — Method
calc_doubles_decomposition_with_doubles(EC::ECInfo)Decompose $T^{ij}_{ab}=U^{iX}_a U^{jY}_b T_{XY}$ using explicit doubles amplitudes $T^{ij}_{ab}$.
ElemCo.DFCoupledCluster.calc_doubles_decomposition_without_doubles — Method
calc_doubles_decomposition_without_doubles(EC::ECInfo)Decompose $T^{ij}_{ab}=U^{iX}_a U^{jY}_b T_{XY}$ without explicit calculation of $T^{ij}_{ab}$.
The decomposition is done in two steps:
- $\bar U^{i\bar X}_a$ is calculated from $v_a^{iL}$ using SVD (with threshold
CcOptions.ampsvdtol×CcOptions.ampsvdfac); - MP2 doubles $T^{i}_{aX}$ are calculated from $v_a^{iL}$ and $U^{iX}_a$ and again decomposed using SVD and threshold
CcOptions.ampsvdtol.
The SVD-basis is rotated to pseudocanonical basis to diagonalize orbital-energy differences, $ϵ_X = U^{iX}_{a}(ϵ_a-ϵ_i)U^{iX}_a$. The imaginary shift CcOptions.deco_ishiftp is used in the denominator in the calculation of the MP2 amplitudes. The orbital energy differences are saved in file e_X. The SVD-coefficients $U^{iX}_a$ are saved in file C_voX. The starting guess for doubles $T_{XY}$ is saved in file T_XX. Return full MP2 correlation energy, SS, OS, and Openshell(0.0) (using the imaginary shift) as OutDict with keys (E,ESS,EOS,EO).
ElemCo.DFCoupledCluster.calc_svd_dcsd_residual — Method
calc_svd_dcsd_residual(EC::ECInfo, T1, T2)Calculate decomposed closed-shell DCSD residual with $T^{ij}_{ab}=U^{iX}_a U^{jY}_b T_{XY}$ and $R_{XY}=U^{iX†}_a U^{jY†}_b R^{ij}_{ab}$. T2 contains decomposed amplitudes $T_{XY}$ or full amplitudes $T^{ij}_{ab}$.
If T2 is $T^{ij}_{ab}$, the residual is also returned in full form.
ElemCo.DFCoupledCluster.calc_voX — Method
calc_voX(EC::ECInfo; calc_vᵥᵒˣ=false, calc_vᵛₒₓ=false)Calculate $\hat v_a^{iX} = \hat v_{ak}^{ci} U^{kX}_c$ and/or $\hat v^c_{kX} = \hat v_{ak}^{ci} U^{†a}_{kX}$ with $\hat v_{ak}^{ci} = \hat v_a^{cL} \hat v_k^{iL}$ and $U^{kX}_c$ from file C_voX.
Return a tuple (vᵥᵒˣ, vᵛₒₓ) (not calculated intermediates are empty arrays).
ElemCo.DFCoupledCluster.contravariant_deco_doubles — Function
contravariant_deco_doubles(EC::ECInfo, T2, projx=false)Calculate contravariant doubles amplitudes $T̃^{ij}_{ab} = 2T^{ij}_{ab} - T^{ij}_{ba}$ with $T^{ij}_{ab} = U^{iX}_a U^{jY}_b T_{XY}$. If projx is true, the projected exchange is returned: $T̃_{XY} = U^{†a}_{iX} U^{†b}_{jY} T̃^{ij}_{ab}$
ElemCo.DFCoupledCluster.dress_df_fock — Method
dress_df_fock(EC::ECInfo, T1)Dress DF fock matrix with DF 3-index integrals.
The dress-contribution is added to the original fock matrix from file f_mm. The dressed fock matrix is stored in file df_mm. Additionally, the coulomb and exchange dressing contributions to $\hat f_k^c$ are stored in files dfc_ov and dfe_ov.
ElemCo.DFCoupledCluster.gen_vₓˣᴸ — Method
gen_vₓˣᴸ(EC::ECInfo)Generate $v_X^{X'L} = v_a^{cL} U^{†a}_{kX} U^{kX'}_c$ using bare integrals.
The integrals and the SVD-coefficients are read from files mmL and C_voX, and the result is stored in file X^XL.
ElemCo.DFCoupledCluster.get_ssv_osvˣˣ — Method
get_ssv_osvˣˣ(EC::ECInfo)Return $ssv^{XY} = U^{kX}_c U^{lX}_d (v_{kl}^{cd} - v_{lk}^{cd} )$ and $osv^{XY} = U^{kX}_c U^{lX}_d v_{kl}^{cd}$ with $v_{kl}^{cd} = v_k^{cL} v_l^{dL'}δ_{LL'}$.
The integrals will be read from files ssd_^XX and osd_^XX. If the files do not exist, the integrals will be calculated and stored in files ssd_^XX and osd_^XX. vk^{cL} and U^{kX}c are read from files d_ovL and C_voX.
ElemCo.DFCoupledCluster.save_pseudo_dress_df_fock — Method
save_pseudo_dress_df_fock(EC::ECInfo)Save non-dressed DF fock matrix from file f_mm to dressed file df_mm.