10.28. solvent — Solvent methods

The solvent implements the domain-decomposition COSMO solvent model for mean-field and correlated methods.

To run a mean-field calculation with the implicit solvent model, one can try the following example:

from pyscf import gto, scf, dft
from pyscf import solvent
mol = gto.M(atom='''
C        0.000000    0.000000             -0.542500
O        0.000000    0.000000              0.677500
H        0.000000    0.9353074360871938   -1.082500
H        0.000000   -0.9353074360871938   -1.082500
            ''',
            verbose = 4)
mf = scf.RHF(mol)
solvent.ddCOSMO(mf).run()

10.28.1. Examples

Relevant examples examples/solvent/00-scf_with_ddcosmo.py examples/solvent/01-casscf_with_ddcosmo.py examples/solvent/02-casci_with_ddcosmo.py examples/solvent/03-ccsd_with_ddcosmo.py examples/solvent/20-state_specific_casci.py

10.28.2. Program reference

10.28.2.1. domain decomposition PCM

domain decomposition PCM (In testing)

See also JCP, 144, 054101 JCP, 144, 160901

class pyscf.solvent.ddpcm.DDPCM(mol)[source]
nuc_grad_method(grad_method)[source]

For grad_method in vacuum, add nuclear gradients of solvent

pyscf.solvent.ddpcm.ddpcm_for_casci(mc, solvent_obj=None, dm=None)[source]

Add solvent model to CASCI method.

Kwargs:
dmif given, solvent does not respond to the change of density

matrix. A frozen ddCOSMO potential is added to the results.

pyscf.solvent.ddpcm.ddpcm_for_casscf(mc, solvent_obj=None, dm=None)[source]

Add solvent model to CASSCF method.

Kwargs:
dmif given, solvent does not respond to the change of density

matrix. A frozen ddCOSMO potential is added to the results.

pyscf.solvent.ddpcm.ddpcm_for_post_scf(method, solvent_obj=None, dm=None)[source]

A wrapper of solvent model for post-SCF methods (CC, CI, MP etc.)

NOTE: this implementation often causes (macro iteration) convergence issue

Kwargs:
dmif given, solvent does not respond to the change of density

matrix. A frozen ddCOSMO potential is added to the results.

pyscf.solvent.ddpcm.ddpcm_for_scf(mf, solvent_obj=None, dm=None)[source]

Add solvent model to SCF (HF and DFT) method.

Kwargs:
dmif given, solvent does not respond to the change of density

matrix. A frozen ddCOSMO potential is added to the results.

pyscf.solvent.ddpcm.ddpcm_for_tdscf(method, solvent_obj=None, dm=None)[source]

Add solvent model in TDDFT calculations.

Kwargs:
dmif given, solvent does not respond to the change of density

matrix. A frozen ddCOSMO potential is added to the results.

pyscf.solvent.ddpcm.energy(pcmobj, dm)[source]

ddPCM energy Es = 1/2 f(eps) int rho(r) W(r) dr

10.28.2.2. domain decomposition COSMO

domain decomposition COSMO

See also the code on github

https://github.com/filippolipparini/ddPCM

and the papers

[1] Domain decomposition for implicit solvation models. E. Cances, Y. Maday, B. Stamm J. Chem. Phys., 139, 054111 (2013) http://dx.doi.org/10.1063/1.4816767

[2] Fast Domain Decomposition Algorithm for Continuum Solvation Models: Energy and First Derivatives. F. Lipparini, B. Stamm, E. Cances, Y. Maday, B. Mennucci J. Chem. Theory Comput., 9, 3637-3648 (2013) http://dx.doi.org/10.1021/ct400280b

[3] Quantum, classical, and hybrid QM/MM calculations in solution: General implementation of the ddCOSMO linear scaling strategy. F. Lipparini, G. Scalmani, L. Lagardere, B. Stamm, E. Cances, Y. Maday, J.-P.Piquemal, M. J. Frisch, B. Mennucci J. Chem. Phys., 141, 184108 (2014) http://dx.doi.org/10.1063/1.4901304

– Dielectric constants (from https://gaussian.com/scrf/) – More dataset can be found in Minnesota Solvent Descriptor Database (https://comp.chem.umn.edu/solvation) Water 78.3553 Acetonitrile 35.688 Methanol 32.613 Ethanol 24.852 IsoQuinoline 11.00 Quinoline 9.16 Chloroform 4.7113 DiethylEther 4.2400 Dichloromethane 8.93 DiChloroEthane 10.125 CarbonTetraChloride 2.2280 Benzene 2.2706 Toluene 2.3741 ChloroBenzene 5.6968 NitroMethane 36.562 Heptane 1.9113 CycloHexane 2.0165 Aniline 6.8882 Acetone 20.493 TetraHydroFuran 7.4257 DiMethylSulfoxide 46.826 Argon 1.430 Krypton 1.519 Xenon 1.706 n-Octanol 9.8629 1,1,1-TriChloroEthane 7.0826 1,1,2-TriChloroEthane 7.1937 1,2,4-TriMethylBenzene 2.3653 1,2-DiBromoEthane 4.9313 1,2-EthaneDiol 40.245 1,4-Dioxane 2.2099 1-Bromo-2-MethylPropane 7.7792 1-BromoOctane 5.0244 1-BromoPentane 6.269 1-BromoPropane 8.0496 1-Butanol 17.332 1-ChloroHexane 5.9491 1-ChloroPentane 6.5022 1-ChloroPropane 8.3548 1-Decanol 7.5305 1-FluoroOctane 3.89 1-Heptanol 11.321 1-Hexanol 12.51 1-Hexene 2.0717 1-Hexyne 2.615 1-IodoButane 6.173 1-IodoHexaDecane 3.5338 1-IodoPentane 5.6973 1-IodoPropane 6.9626 1-NitroPropane 23.73 1-Nonanol 8.5991 1-Pentanol 15.13 1-Pentene 1.9905 1-Propanol 20.524 2,2,2-TriFluoroEthanol 26.726 2,2,4-TriMethylPentane 1.9358 2,4-DiMethylPentane 1.8939 2,4-DiMethylPyridine 9.4176 2,6-DiMethylPyridine 7.1735 2-BromoPropane 9.3610 2-Butanol 15.944 2-ChloroButane 8.3930 2-Heptanone 11.658 2-Hexanone 14.136 2-MethoxyEthanol 17.2 2-Methyl-1-Propanol 16.777 2-Methyl-2-Propanol 12.47 2-MethylPentane 1.89 2-MethylPyridine 9.9533 2-NitroPropane 25.654 2-Octanone 9.4678 2-Pentanone 15.200 2-Propanol 19.264 2-Propen-1-ol 19.011 3-MethylPyridine 11.645 3-Pentanone 16.78 4-Heptanone 12.257 4-Methyl-2-Pentanone 12.887 4-MethylPyridine 11.957 5-Nonanone 10.6 AceticAcid 6.2528 AcetoPhenone 17.44 a-ChloroToluene 6.7175 Anisole 4.2247 Benzaldehyde 18.220 BenzoNitrile 25.592 BenzylAlcohol 12.457 BromoBenzene 5.3954 BromoEthane 9.01 Bromoform 4.2488 Butanal 13.45 ButanoicAcid 2.9931 Butanone 18.246 ButanoNitrile 24.291 ButylAmine 4.6178 ButylEthanoate 4.9941 CarbonDiSulfide 2.6105 Cis-1,2-DiMethylCycloHexane 2.06 Cis-Decalin 2.2139 CycloHexanone 15.619 CycloPentane 1.9608 CycloPentanol 16.989 CycloPentanone 13.58 Decalin-mixture 2.196 DiBromomEthane 7.2273 DiButylEther 3.0473 DiEthylAmine 3.5766 DiEthylSulfide 5.723 DiIodoMethane 5.32 DiIsoPropylEther 3.38 DiMethylDiSulfide 9.6 DiPhenylEther 3.73 DiPropylAmine 2.9112 e-1,2-DiChloroEthene 2.14 e-2-Pentene 2.051 EthaneThiol 6.667 EthylBenzene 2.4339 EthylEthanoate 5.9867 EthylMethanoate 8.3310 EthylPhenylEther 4.1797 FluoroBenzene 5.42 Formamide 108.94 FormicAcid 51.1 HexanoicAcid 2.6 IodoBenzene 4.5470 IodoEthane 7.6177 IodoMethane 6.8650 IsoPropylBenzene 2.3712 m-Cresol 12.44 Mesitylene 2.2650 MethylBenzoate 6.7367 MethylButanoate 5.5607 MethylCycloHexane 2.024 MethylEthanoate 6.8615 MethylMethanoate 8.8377 MethylPropanoate 6.0777 m-Xylene 2.3478 n-ButylBenzene 2.36 n-Decane 1.9846 n-Dodecane 2.0060 n-Hexadecane 2.0402 n-Hexane 1.8819 NitroBenzene 34.809 NitroEthane 28.29 n-MethylAniline 5.9600 n-MethylFormamide-mixture 181.56 n,n-DiMethylAcetamide 37.781 n,n-DiMethylFormamide 37.219 n-Nonane 1.9605 n-Octane 1.9406 n-Pentadecane 2.0333 n-Pentane 1.8371 n-Undecane 1.9910 o-ChloroToluene 4.6331 o-Cresol 6.76 o-DiChloroBenzene 9.9949 o-NitroToluene 25.669 o-Xylene 2.5454 Pentanal 10.0 PentanoicAcid 2.6924 PentylAmine 4.2010 PentylEthanoate 4.7297 PerFluoroBenzene 2.029 p-IsoPropylToluene 2.2322 Propanal 18.5 PropanoicAcid 3.44 PropanoNitrile 29.324 PropylAmine 4.9912 PropylEthanoate 5.5205 p-Xylene 2.2705 Pyridine 12.978 sec-ButylBenzene 2.3446 tert-ButylBenzene 2.3447 TetraChloroEthene 2.268 TetraHydroThiophene-s,s-dioxide 43.962 Tetralin 2.771 Thiophene 2.7270 Thiophenol 4.2728 trans-Decalin 2.1781 TriButylPhosphate 8.1781 TriChloroEthene 3.422 TriEthylAmine 2.3832 Xylene-mixture 2.3879 z-1,2-DiChloroEthene 9.2

class pyscf.solvent.ddcosmo.DDCOSMO(mol)[source]
as_solver(verbose=None)

Generate ddcosmo function to compute energy and potential matrix

property dm

Density matrix to generate the frozen ddCOSMO solvent potential.

energy(dm)

ddCOSMO energy Es = 1/2 f(eps) int rho(r) W(r) dr

gen_solver(verbose=None)

Generate ddcosmo function to compute energy and potential matrix

kernel(dm)[source]

A single shot solvent effects for given density matrix.

nuc_grad_method(grad_method)[source]

For grad_method in vacuum, add nuclear gradients of solvent

reset(mol=None)[source]

Reset mol and clean up relevant attributes for scanner mode

pyscf.solvent.ddcosmo.ddcosmo_for_casci(mc, solvent_obj=None, dm=None)[source]

Add solvent model to CASCI method.

Kwargs:
dmif given, solvent does not respond to the change of density

matrix. A frozen ddCOSMO potential is added to the results.

pyscf.solvent.ddcosmo.ddcosmo_for_casscf(mc, solvent_obj=None, dm=None)[source]

Add solvent model to CASSCF method.

Kwargs:
dmif given, solvent does not respond to the change of density

matrix. A frozen ddCOSMO potential is added to the results.

pyscf.solvent.ddcosmo.ddcosmo_for_post_scf(method, solvent_obj=None, dm=None)[source]

A wrapper of solvent model for post-SCF methods (CC, CI, MP etc.)

NOTE: this implementation often causes (macro iteration) convergence issue

Kwargs:
dmif given, solvent does not respond to the change of density

matrix. A frozen ddCOSMO potential is added to the results.

pyscf.solvent.ddcosmo.ddcosmo_for_scf(mf, solvent_obj=None, dm=None)[source]

Add solvent model to SCF (HF and DFT) method.

Kwargs:
dmif given, solvent does not respond to the change of density

matrix. A frozen ddCOSMO potential is added to the results.

pyscf.solvent.ddcosmo.ddcosmo_for_tdscf(method, solvent_obj=None, dm=None)[source]

Add solvent model in TDDFT calculations.

Kwargs:
dmif given, solvent does not respond to the change of density

matrix. A frozen ddCOSMO potential is added to the results.

pyscf.solvent.ddcosmo.energy(pcmobj, dm)[source]

ddCOSMO energy Es = 1/2 f(eps) int rho(r) W(r) dr

pyscf.solvent.ddcosmo.gen_ddcosmo_solver(pcmobj, verbose=None)[source]

Generate ddcosmo function to compute energy and potential matrix

pyscf.solvent.ddcosmo.make_phi(pcmobj, dm, r_vdw, ui, ylm_1sph, with_nuc=True)[source]

Induced potential of ddCOSMO model

Kwargs:
with_nuc (bool): Mute the contribution of nuclear charges when

computing the second order derivatives of energy

pyscf.solvent.ddcosmo.make_psi_vmat(pcmobj, dm, r_vdw, ui, ylm_1sph, cached_pol, Xvec, L, with_nuc=True)[source]

The first order derivative of E_ddCOSMO wrt density matrix

Kwargs:
with_nuc (bool): Mute the contribution of nuclear charges when

computing the second order derivatives of energy.

Analytical nuclear gradients for domain decomposition COSMO

See also

[1] Fast Domain Decomposition Algorithm for Continuum Solvation Models: Energy and First Derivatives. F. Lipparini, B. Stamm, E. Cances, Y. Maday, B. Mennucci J. Chem. Theory Comput., 9, 3637-3648 (2013) http://dx.doi.org/10.1021/ct400280b

[2] Quantum, classical, and hybrid QM/MM calculations in solution: General implementation of the ddCOSMO linear scaling strategy. F. Lipparini, G. Scalmani, L. Lagardere, B. Stamm, E. Cances, Y. Maday, J.-P.Piquemal, M. J. Frisch, B. Mennucci J. Chem. Phys., 141, 184108 (2014) http://dx.doi.org/10.1063/1.4901304

pyscf.solvent.ddcosmo_grad.make_grad_object(grad_method)[source]

For grad_method in vacuum, add nuclear gradients of solvent pcmobj