JDFTx  1.4.2
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PCM Class Reference

Base class for all PCMs. More...

#include <PCM.h>

Inheritance diagram for PCM:
FluidSolver LinearPCM NonlinearPCM SaLSA

Public Member Functions

 PCM (const Everything &e, const FluidSolverParams &fsp)
 
void dumpDensities (const char *filenamePattern) const
 dump cavity shape functions
 
void dumpDebug (const char *filenamePattern) const
 generate fluidDebug text file with common info to all PCMs
 
- Public Member Functions inherited from FluidSolver
 FluidSolver (const Everything &e, const FluidSolverParams &fsp)
 Any non-electrostatic contributions to A_rhoExplicitTilde (removed from dumped d_fluid / d_tot) More...
 
double ionWidthMuCorrection () const
 correction to electron chemical potential due to finite ion width in fluid interaction
 
bool useGummel () const
 
void set (const ScalarFieldTilde &rhoExplicitTilde, const ScalarFieldTilde &nCavityTilde)
 
double get_Adiel_and_grad (ScalarFieldTilde *Adiel_rhoExplicitTilde=0, ScalarFieldTilde *Adiel_nCavityTilde=0, IonicGradient *extraForces=0) const
 
virtual double bulkPotential ()
 
virtual bool prefersGummel () const =0
 Specify whether fluid prefers a gummel loop (true) or is minimized each time (false)
 
virtual void loadState (const char *filename)=0
 Initialize fluid state from a file.
 
virtual void saveState (const char *filename) const =0
 Save fluid state to a file.
 
virtual void minimizeFluid ()=0
 Minimize fluid side (holding explicit electronic system fixed)
 

Protected Member Functions

virtual void printDebug (FILE *fp) const
 over-ride to get extra PCM-specific output in fluidDebug text file
 
void updateCavity ()
 update shape function(s) from nCavity, and energies dependent upon shape alone
 
void propagateCavityGradients (const ScalarFieldArray &A_shape, ScalarField &A_nCavity, ScalarFieldTilde &A_rhoExplicitTilde, IonicGradient *forces) const
 
void accumExtraForces (IonicGradient *forces, const ScalarFieldTilde &A_nCavityTilde) const
 Accumulate extra fluid forces (vdw and full-core forces, when applicable)
 
ScalarFieldTilde getFullCore () const
 get full core correction for PCM variants that need them
 
- Protected Member Functions inherited from FluidSolver
virtual void set_internal (const ScalarFieldTilde &rhoExplicitTilde, const ScalarFieldTilde &nCavityTilde)=0
 Fluid-dependent implementation of set()
 
virtual double get_Adiel_and_grad_internal (ScalarFieldTilde &Adiel_rhoExplicitTilde, ScalarFieldTilde &Adiel_nCavityTilde, IonicGradient *extraForces) const =0
 Fluid-dependent implementation of get_Adiel_and_grad()
 

Static Protected Member Functions

static ScalarFieldTilde coulomb (const ScalarFieldTilde &rho)
 

Protected Attributes

EnergyComponents Adiel
 PCM energy components.
 
ScalarFieldTilde rhoExplicitTilde
 Charge density of explicit (electronic) system.
 
ScalarField nCavity
 
ScalarField tauCavity
 
ScalarField nCavityEx [2]
 Cavity determining electron density (or product for SaLSA, or KE density for SG14tauVW, and expanded electron densities for the SGA13 variant)
 
ScalarFieldArray shape
 Electrostatic cavity shape function. Second component, if any, is separate ionic cavity.
 
ScalarField shapeVdw
 Separate cavitation/dispersion shape function for the SGA13 variant.
 
std::vector< RadialFunctionGSf
 spherically-averaged structure factors for each solvent site
 
std::vector< int > atomicNumbers
 atomic number for each solvent site (for dispersion interactions)
 

Friends

struct ChargedDefect
 

Additional Inherited Members

- Public Attributes inherited from FluidSolver
const Everythinge
 
const GridInfogInfo
 
const FluidSolverParamsfsp
 
double epsBulk
 
double epsInf
 bulk dielectric constants of fluid
 
double k2factor
 prefactor to screening term (0 => no ionic screening)
 
std::vector< std::vector
< vector3<> > > 
atpos
 
ScalarFieldTilde A_rhoNonES
 atomic positions per species in the relevant coordinate system (depending on embedding option)
 

Detailed Description

Base class for all PCMs.

Member Function Documentation

void PCM::propagateCavityGradients ( const ScalarFieldArray A_shape,
ScalarField A_nCavity,
ScalarFieldTilde A_rhoExplicitTilde,
IonicGradient forces 
) const
protected

Propagate A_shape (+ cached Acavity_shape) and accumulate to gradients w.r.t nCavity and rhoExplicitTilde. Set fluid force contributions (for atom-sphere cavities) if non-null.


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