OpenMM

- Main Page
- Related Pages
- Classes

All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Pages
AmoebaGeneralizedKirkwoodForce.h
1 #ifndef AMOEBA_OPENMM_GK_FORCE_FIELD_H_
2 #define AMOEBA_OPENMM_GK_FORCE_FIELD_H_
3
4 /* -------------------------------------------------------------------------- *
5 * OpenMM *
6 * -------------------------------------------------------------------------- *
7 * This is part of the OpenMM molecular simulation toolkit originating from *
8 * Simbios, the NIH National Center for Physics-Based Simulation of *
9 * Biological Structures at Stanford, funded under the NIH Roadmap for *
10 * Medical Research, grant U54 GM072970. See https://simtk.org. *
11 * *
12 * Portions copyright (c) 2008-2012 Stanford University and the Authors. *
13 * Authors: Mark Friedrichs, Peter Eastman *
14 * Contributors: *
15 * *
16 * Permission is hereby granted, free of charge, to any person obtaining a *
17 * copy of this software and associated documentation files (the "Software"), *
18 * to deal in the Software without restriction, including without limitation *
19 * the rights to use, copy, modify, merge, publish, distribute, sublicense, *
20 * and/or sell copies of the Software, and to permit persons to whom the *
21 * Software is furnished to do so, subject to the following conditions: *
22 * *
23 * The above copyright notice and this permission notice shall be included in *
24 * all copies or substantial portions of the Software. *
25 * *
26 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR *
27 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, *
28 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL *
29 * THE AUTHORS, CONTRIBUTORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, *
30 * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR *
31 * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE *
32 * USE OR OTHER DEALINGS IN THE SOFTWARE. *
33 * -------------------------------------------------------------------------- */
34
35 #include "openmm/Force.h"
36 #include "internal/windowsExportAmoeba.h"
37 #include <vector>
38
39 namespace OpenMM {
40
52 class OPENMM_EXPORT_AMOEBA AmoebaGeneralizedKirkwoodForce : public Force {
53
54 public:
55
56 /*
57 * Create an AmoebaGeneralizedKirkwoodForce.
58 */
59 AmoebaGeneralizedKirkwoodForce();
60
64 int getNumParticles() const {
65 return particles.size();
66 }
67
77 int addParticle(double charge, double radius, double scalingFactor);
78
87 void getParticleParameters(int index, double& charge, double& radius, double& scalingFactor) const;
88
97 void setParticleParameters(int index, double charge, double radius, double scalingFactor);
98
102 double getSolventDielectric() const {
103 return solventDielectric;
104 }
105
109 void setSolventDielectric(double dielectric) {
110 solventDielectric = dielectric;
111 }
112
116 double getSoluteDielectric() const {
117 return soluteDielectric;
118 }
119
123 void setSoluteDielectric(double dielectric) {
124 soluteDielectric = dielectric;
125 }
126
130 int getIncludeCavityTerm() const;
131
135 void setIncludeCavityTerm(int includeCavityTerm);
136
140 double getProbeRadius() const;
141
145 void setProbeRadius(double probeRadius);
146
150 double getSurfaceAreaFactor() const;
151
155 void setSurfaceAreaFactor(double surfaceAreaFactor);
165 void updateParametersInContext(Context& context);
172 bool usesPeriodicBoundaryConditions() const {
173 return false;
174 }
175 protected:
176 ForceImpl* createImpl() const;
177 private:
178 class ParticleInfo;
179 int includeCavityTerm;
180 double solventDielectric, soluteDielectric, dielectricOffset,
181 probeRadius, surfaceAreaFactor;
182 std::vector<ParticleInfo> particles;
183 };
184
189 class AmoebaGeneralizedKirkwoodForce::ParticleInfo {
190 public:
191 double charge, radius, scalingFactor;
192 ParticleInfo() {
193 charge = radius = scalingFactor = 0.0;
194 }
195 ParticleInfo(double charge, double radius, double scalingFactor) :
196 charge(charge), radius(radius), scalingFactor(scalingFactor) {
197 }
198 };
199
200 } // namespace OpenMM
201
202 #endif /*AMOEBA_OPENMM_GK_FORCE_FIELD_H_*/
OpenMM::AmoebaGeneralizedKirkwoodForce::usesPeriodicBoundaryConditions
bool usesPeriodicBoundaryConditions() const
Returns whether or not this force makes use of periodic boundary conditions.
Definition: AmoebaGeneralizedKirkwoodForce.h:172
OpenMM::Context
A Context stores the complete state of a simulation.
Definition: Context.h:67
OpenMM::AmoebaGeneralizedKirkwoodForce::setSoluteDielectric
void setSoluteDielectric(double dielectric)
Set the dielectric constant for the solute.
Definition: AmoebaGeneralizedKirkwoodForce.h:123
OpenMM::AmoebaGeneralizedKirkwoodForce::setSolventDielectric
void setSolventDielectric(double dielectric)
Set the dielectric constant for the solvent.
Definition: AmoebaGeneralizedKirkwoodForce.h:109
OpenMM::Force
Force objects apply forces to the particles in a System, or alter their behavior in other ways...
Definition: Force.h:65
OpenMM::AmoebaGeneralizedKirkwoodForce::getSolventDielectric
double getSolventDielectric() const
Get the dielectric constant for the solvent.
Definition: AmoebaGeneralizedKirkwoodForce.h:102
OpenMM::AmoebaGeneralizedKirkwoodForce
This class implements an implicit solvation force using the generalized Kirkwood/Grycuk model...
Definition: AmoebaGeneralizedKirkwoodForce.h:52
OpenMM::AmoebaGeneralizedKirkwoodForce::getSoluteDielectric
double getSoluteDielectric() const
Get the dielectric constant for the solute.
Definition: AmoebaGeneralizedKirkwoodForce.h:116
OpenMM::AmoebaGeneralizedKirkwoodForce::getNumParticles
int getNumParticles() const
Get the number of particles in the system.
Definition: AmoebaGeneralizedKirkwoodForce.h:64
OpenMM
Definition: AndersenThermostat.h:40