JDFTx  1.2.0
FluidSolverParams.h
Go to the documentation of this file.
1 /*-------------------------------------------------------------------
2 Copyright 2013 Ravishankar Sundararaman, Kendra Letchworth Weaver, Deniz Gunceler
3 
4 This file is part of JDFTx.
5 
6 JDFTx is free software: you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation, either version 3 of the License, or
9 (at your option) any later version.
10 
11 JDFTx is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
15 
16 You should have received a copy of the GNU General Public License
17 along with JDFTx. If not, see <http://www.gnu.org/licenses/>.
18 -------------------------------------------------------------------*/
19 
20 #ifndef JDFTX_ELECTRONIC_FLUIDSOLVERPARAMS_H
21 #define JDFTX_ELECTRONIC_FLUIDSOLVERPARAMS_H
22 
25 
26 #include <electronic/ExCorr.h>
27 #include <fluid/FluidComponent.h>
28 #include <core/PulayParams.h>
29 
31 {
37 };
38 
40 {
44 };
45 
48 {
52 };
53 
55 struct FmixParams
56 {
57  std::shared_ptr<FluidComponent> fluid1,fluid2;
59  double energyScale,lengthScale;
60 };
61 
77 };
78 
80 #define case_PCM_SCCS_any \
81  case PCM_SCCS_g09: \
82  case PCM_SCCS_g03: \
83  case PCM_SCCS_g03p: \
84  case PCM_SCCS_g09beta: \
85  case PCM_SCCS_g03beta: \
86  case PCM_SCCS_g03pbeta: \
87  case PCM_SCCS_cation: \
88  case PCM_SCCS_anion
89 inline bool isPCM_SCCS(PCMVariant pcmVariant) { switch(pcmVariant) { case_PCM_SCCS_any: return true; default: return false; } }
90 
91 
94 {
95  FluidType fluidType;
96  PCMVariant pcmVariant;
97 
98  double T;
99  double P;
100  double epsBulkOverride, epsInfOverride;
101  bool verboseLog;
102  FluidSolveFrequency solveFrequency;
103 
104  const std::vector< std::shared_ptr<FluidComponent> >& components;
105  const std::vector< std::shared_ptr<FluidComponent> >& solvents;
106  const std::vector< std::shared_ptr<FluidComponent> >& cations;
107  const std::vector< std::shared_ptr<FluidComponent> >& anions;
108 
109  void addComponent(const std::shared_ptr<FluidComponent>& component);
110 
111  //Fit parameters:
112  double nc;
113  double sigma;
114  double cavityTension;
115  double vdwScale;
116 
117  //For CANDLE alone:
118  double Ztot;
119  double eta_wDiel;
120  double sqrtC6eff;
121  double pCavity;
122 
123  //For SCCS alone:
124  double rhoMin, rhoMax;
125  double rhoDelta;
126  double cavityPressure;
127 
128  //For SaLSA alone:
129  int lMax;
130 
131  //Debug parameters for Nonlinear PCM's:
135  double screenOverride;
137 
138  //For Explicit Fluid JDFT alone:
140  std::vector<FmixParams> FmixList;
141 
142  string initWarnings;
143 
145  void setPCMparams();
146  void setCDFTparams();
147  bool needsVDW() const;
148  bool ionicScreening() const;
149 private:
150  std::vector< std::shared_ptr<FluidComponent> > components_, solvents_, cations_, anions_; //internal mutable versions of the public component lists
151 };
152 
153 #endif // JDFTX_ELECTRONIC_FLUIDSOLVERPARAMS_H
Decide based on fluid type (Inner for linear fluids, Gummel for rest)
Definition: FluidSolverParams.h:43
Linear local-response dielectric fluid [S.A. Petrosyan SA, A.A. Rigos and T.A. Arias, J Phys Chem B. 109, 15436 (2005)].
Definition: FluidSolverParams.h:68
double Ztot
number of valence electrons
Definition: FluidSolverParams.h:118
Classical density functional description of fluid (EXPERIMENTAL)
Definition: FluidSolverParams.h:36
double rhoMax
start and end of transition
Definition: FluidSolverParams.h:124
FMixFunctional FmixType
Type of Fmix to be used (GaussianKernel or LJPotential)
Definition: FluidSolverParams.h:58
bool linearScreening
If true, work in the linearized Poisson-Boltzman limit for the ions.
Definition: FluidSolverParams.h:133
double sqrtC6eff
(effective C6 parameter in J-nm^6/mol)^(1/2) for the entire molecule (fit parameter) (vdwScale unnece...
Definition: FluidSolverParams.h:120
Solve fluid every electronic step.
Definition: FluidSolverParams.h:41
double pCavity
sensitivity of cavity to surface electric field to emulate charge asymmetry [e-a0/Eh] (fit parameter)...
Definition: FluidSolverParams.h:121
std::vector< FmixParams > FmixList
Tabulates which components interact through an additional Fmix.
Definition: FluidSolverParams.h:140
No fluid.
Definition: FluidSolverParams.h:32
Parameters needed to mix fluids.
Definition: FluidSolverParams.h:55
PulayParams scfParams
overrides screening factor with this value
Definition: FluidSolverParams.h:136
g03&#39;+beta parametrization of SCCS local linear model for water [Andreussi et al. J. Chem. Phys. 136, 064102 (2012)]
Definition: FluidSolverParams.h:74
double sigma
smoothing factor for the PCM cavity shape function
Definition: FluidSolverParams.h:113
FluidSolveFrequency
Definition: FluidSolverParams.h:39
Use a Gummel iteration.
Definition: FluidSolverParams.h:42
const std::vector< std::shared_ptr< FluidComponent > > & anions
list of anionic components
Definition: FluidSolverParams.h:107
Parameters to control Pulay mixing.
Definition: PulayParams.h:26
double rhoDelta
Delta used for "quantum surface".
Definition: FluidSolverParams.h:125
double nc
critical density for the PCM cavity shape function
Definition: FluidSolverParams.h:112
double lengthScale
Energy scale (eps for LJ potential) and range parameter (sigma for LJ potential)
Definition: FluidSolverParams.h:59
double T
temperature
Definition: FluidSolverParams.h:98
double eta_wDiel
control electrostatic weight function (gaussian convolved by delta(r-eta) at l=1) (fit parameter) ...
Definition: FluidSolverParams.h:119
ExCorr exCorr
Fluid exchange-correlation and kinetic energy functional.
Definition: FluidSolverParams.h:139
double cavityTension
effective surface tension (including dispersion etc.) of the cavity (hartree per bohr^2) ...
Definition: FluidSolverParams.h:114
PCMVariant
Definition: FluidSolverParams.h:62
Spherically-averaged liquid susceptibility ansatz (nonlocal PCM)
Definition: FluidSolverParams.h:35
cations-only parametrization of SCCS local linear model for water [Dupont et al., J...
Definition: FluidSolverParams.h:75
string initWarnings
warnings emitted during parameter initialization, if any
Definition: FluidSolverParams.h:142
const std::vector< std::shared_ptr< FluidComponent > > & cations
list of cationic components
Definition: FluidSolverParams.h:106
Definition: ExCorr.h:72
Charge-asymmetric nonlocally-determined local-electric (CANDLE) solvation model [R. Sundararaman and W.A. Goddard III, JCP 142, 064107 (2015)].
Definition: FluidSolverParams.h:64
Interaction with attractive part of Lennard Jones with sigma/eps potential only.
Definition: FluidSolverParams.h:50
Nonlinear local-dielectric fluid including non-electrostatic terms.
Definition: FluidSolverParams.h:34
g03&#39; parametrization of SCCS local linear model for water [Andreussi et al. J. Chem. Phys. 136, 064102 (2012)]
Definition: FluidSolverParams.h:71
Local-response dielectric fluid or electrolyte with weighted-density cavitation and dispersion [R...
Definition: FluidSolverParams.h:65
double cavityPressure
volume term (used in some parametrizations)
Definition: FluidSolverParams.h:126
Interaction with gaussian kernel with Rsolv/Esolv.
Definition: FluidSolverParams.h:51
double vdwScale
overall scale factor for Grimme pair potentials (or damping range scale factor for vdw-TS when implem...
Definition: FluidSolverParams.h:115
double P
pressure
Definition: FluidSolverParams.h:99
Use only with fluid type SaLSA [R. Sundararaman, K. Schwarz, K. Letchworth-Weaver, and T.A. Arias, JCP 142, 054102 (2015)].
Definition: FluidSolverParams.h:63
g09 parametrization of SCCS local linear model for water [Andreussi et al. J. Chem. Phys. 136, 064102 (2012)]
Definition: FluidSolverParams.h:69
g03 parametrization of SCCS local linear model for water [Andreussi et al. J. Chem. Phys. 136, 064102 (2012)]
Definition: FluidSolverParams.h:70
bool verboseLog
whether iteration progress is printed for Linear PCM&#39;s, and whether sub-iteration progress is printed...
Definition: FluidSolverParams.h:101
g03+beta parametrization of SCCS local linear model for water [Andreussi et al. J. Chem. Phys. 136, 064102 (2012)]
Definition: FluidSolverParams.h:73
Local-response dielectric fluid or electrolyte with empirical cavity tension [D. Gunceler, K. Letchworth-Weaver, R. Sundararaman, K.A. Schwarz and T.A. Arias, MSMSE 21, 074005 (2013)].
Definition: FluidSolverParams.h:66
FMixFunctional
Mixing functional choices.
Definition: FluidSolverParams.h:47
double epsInfOverride
Override default dielectric constants if non-zero.
Definition: FluidSolverParams.h:100
g09+beta parametrization of SCCS local linear model for water [Andreussi et al. J. Chem. Phys. 136, 064102 (2012)]
Definition: FluidSolverParams.h:72
Linear local-dielectric fluid, optionally including non-electrostatic terms.
Definition: FluidSolverParams.h:33
bool nonlinearSCF
whether to use an SCF method for nonlinear PCMs
Definition: FluidSolverParams.h:134
Extra parameters for fluids:
Definition: FluidSolverParams.h:93
No Interaction.
Definition: FluidSolverParams.h:49
#define case_PCM_SCCS_any
Check for any of the SCCS cases:
Definition: FluidSolverParams.h:80
anions-only parametrization of SCCS local linear model for water [Dupont et al., J. Chem. Phys. 139, 214110 (2013)]
Definition: FluidSolverParams.h:76
const std::vector< std::shared_ptr< FluidComponent > > & solvents
list of solvent components
Definition: FluidSolverParams.h:105
Linear local-response electrolyte [K. Letchworth-Weaver and T.A. Arias, Phys. Rev. B 86, 075140 (2012)].
Definition: FluidSolverParams.h:67
FluidType
Definition: FluidSolverParams.h:30
const std::vector< std::shared_ptr< FluidComponent > > & components
list of all fluid components
Definition: FluidSolverParams.h:104
bool linearDielectric
If true, work in the linear dielectric response limit.
Definition: FluidSolverParams.h:132