1 #ifndef OPENMM_CUSTOMANGLEFORCE_H_
2 #define OPENMM_CUSTOMANGLEFORCE_H_
38 #include "internal/windowsExport.h"
92 return parameters.size();
98 return globalParameters.size();
103 const std::string& getEnergyFunction()
const;
107 void setEnergyFunction(
const std::string& energy);
114 int addPerAngleParameter(
const std::string& name);
121 const std::string& getPerAngleParameterName(
int index)
const;
128 void setPerAngleParameterName(
int index,
const std::string& name);
136 int addGlobalParameter(
const std::string& name,
double defaultValue);
143 const std::string& getGlobalParameterName(
int index)
const;
150 void setGlobalParameterName(
int index,
const std::string& name);
157 double getGlobalParameterDefaultValue(
int index)
const;
164 void setGlobalParameterDefaultValue(
int index,
double defaultValue);
174 int addAngle(
int particle1,
int particle2,
int particle3,
const std::vector<double>& parameters);
184 void getAngleParameters(
int index,
int& particle1,
int& particle2,
int& particle3, std::vector<double>& parameters)
const;
194 void setAngleParameters(
int index,
int particle1,
int particle2,
int particle3,
const std::vector<double>& parameters);
205 void updateParametersInContext(
Context& context);
216 ForceImpl* createImpl()
const;
219 class AngleParameterInfo;
220 class GlobalParameterInfo;
221 std::string energyExpression;
222 std::vector<AngleParameterInfo> parameters;
223 std::vector<GlobalParameterInfo> globalParameters;
224 std::vector<AngleInfo> angles;
231 class CustomAngleForce::AngleInfo {
233 int particle1, particle2, particle3;
234 std::vector<double> parameters;
235 AngleInfo() : particle1(-1), particle2(-1), particle3(-1) {
237 AngleInfo(
int particle1,
int particle2,
int particle3,
const std::vector<double>& parameters) :
238 particle1(particle1), particle2(particle2), particle3(particle3), parameters(parameters) {
246 class CustomAngleForce::AngleParameterInfo {
249 AngleParameterInfo() {
251 AngleParameterInfo(
const std::string& name) : name(name) {
259 class CustomAngleForce::GlobalParameterInfo {
263 GlobalParameterInfo() {
265 GlobalParameterInfo(
const std::string& name,
double defaultValue) : name(name), defaultValue(defaultValue) {
int getNumPerAngleParameters() const
Get the number of per-angle parameters that the interaction depends on.
Definition: CustomAngleForce.h:91
A Context stores the complete state of a simulation.
Definition: Context.h:67
int getNumGlobalParameters() const
Get the number of global parameters that the interaction depends on.
Definition: CustomAngleForce.h:97
Force objects apply forces to the particles in a System, or alter their behavior in other ways...
Definition: Force.h:65
int getNumAngles() const
Get the number of angles for which force field parameters have been defined.
Definition: CustomAngleForce.h:85
bool usesPeriodicBoundaryConditions() const
Returns whether or not this force makes use of periodic boundary conditions.
Definition: CustomAngleForce.h:212
This class implements interactions between sets of three particles that depend on the angle between t...
Definition: CustomAngleForce.h:73
Definition: AndersenThermostat.h:40