# AmoebaMultipoleForce Class Reference

This class implements the Amoeba multipole interaction. More...

Inheritance diagram for AmoebaMultipoleForce:

List of all members.

## Public Member Functions

def | getNumMultipoles
| getNumMultipoles(self) -> int
def | getNonbondedMethod
| getNonbondedMethod(self) -> NonbondedMethod
def | setNonbondedMethod
| setNonbondedMethod(self, NonbondedMethod method)
def | getPolarizationType
| getPolarizationType(self) -> PolarizationType
def | setPolarizationType
| setPolarizationType(self, PolarizationType type)
def | getCutoffDistance
| getCutoffDistance(self) -> double
def | setCutoffDistance
| setCutoffDistance(self, double distance)
def | getAEwald
| getAEwald(self) -> double
def | setAEwald
| setAEwald(self, double aewald)
def | getPmeBSplineOrder
| getPmeBSplineOrder(self) -> int
def | getPmeGridDimensions
| getPmeGridDimensions(self)
def | setPmeGridDimensions
| setPmeGridDimensions(self, vectori gridDimension)
def | addMultipole
| addMultipole(self, double charge, vectord molecularDipole, vectord molecularQuadrupole, int axisType, int multipoleAtomZ, int multipoleAtomX, int multipoleAtomY, double thole, double dampingFactor, double polarity) -> int
def | getMultipoleParameters
| getMultipoleParameters(self, int index)
def | setMultipoleParameters
| setMultipoleParameters(self, int index, double charge, vectord molecularDipole, vectord molecularQuadrupole, int axisType, int multipoleAtomZ, int multipoleAtomX, int multipoleAtomY, double thole, double dampingFactor, double polarity)
def | setCovalentMap
| setCovalentMap(self, int index, CovalentType typeId, vectori covalentAtoms)
def | getCovalentMap
| getCovalentMap(self, int index, CovalentType typeId)
def | getCovalentMaps
| getCovalentMaps(self, int index)
def | getMutualInducedMaxIterations
| getMutualInducedMaxIterations(self) -> int
def | setMutualInducedMaxIterations
| setMutualInducedMaxIterations(self, int inputMutualInducedMaxIterations)
def | getMutualInducedTargetEpsilon
| getMutualInducedTargetEpsilon(self) -> double
def | setMutualInducedTargetEpsilon
| setMutualInducedTargetEpsilon(self, double inputMutualInducedTargetEpsilon)
def | getEwaldErrorTolerance
| getEwaldErrorTolerance(self) -> double
def | setEwaldErrorTolerance
| setEwaldErrorTolerance(self, double tol)
def | getInducedDipoles
| getInducedDipoles(self, Context context)
def | getElectrostaticPotential
| getElectrostaticPotential(self, std.vector<(Vec3,std.allocator<(Vec3)>)> inputGrid, Context context)
def | getSystemMultipoleMoments
| getSystemMultipoleMoments(self, Context context)
def | updateParametersInContext
| updateParametersInContext(self, Context context)
def | __init__
| __init__(self) -> AmoebaMultipoleForce __init__(self, AmoebaMultipoleForce other) -> AmoebaMultipoleForce
def | __del__
| __del__(self)

## Public Attributes

| this

## Static Public Attributes

| NoCutoff = _openmm.AmoebaMultipoleForce_NoCutoff
| PME = _openmm.AmoebaMultipoleForce_PME
| Mutual = _openmm.AmoebaMultipoleForce_Mutual
| Direct = _openmm.AmoebaMultipoleForce_Direct
| ZThenX = _openmm.AmoebaMultipoleForce_ZThenX
| Bisector = _openmm.AmoebaMultipoleForce_Bisector
| ZBisect = _openmm.AmoebaMultipoleForce_ZBisect
| ThreeFold = _openmm.AmoebaMultipoleForce_ThreeFold
| ZOnly = _openmm.AmoebaMultipoleForce_ZOnly
| NoAxisType = _openmm.AmoebaMultipoleForce_NoAxisType
| LastAxisTypeIndex = _openmm.AmoebaMultipoleForce_LastAxisTypeIndex
| Covalent12 = _openmm.AmoebaMultipoleForce_Covalent12
| Covalent13 = _openmm.AmoebaMultipoleForce_Covalent13
| Covalent14 = _openmm.AmoebaMultipoleForce_Covalent14
| Covalent15 = _openmm.AmoebaMultipoleForce_Covalent15
| PolarizationCovalent11 = _openmm.AmoebaMultipoleForce_PolarizationCovalent11
| PolarizationCovalent12 = _openmm.AmoebaMultipoleForce_PolarizationCovalent12
| PolarizationCovalent13 = _openmm.AmoebaMultipoleForce_PolarizationCovalent13
| PolarizationCovalent14 = _openmm.AmoebaMultipoleForce_PolarizationCovalent14
| CovalentEnd = _openmm.AmoebaMultipoleForce_CovalentEnd

## Detailed Description

This class implements the Amoeba multipole interaction.

To use it, create an AmoebaMultipoleForce object then call addMultipole() once for each atom. After an entry has been added, you can modify its force field parameters by calling setMultipoleParameters(). This will have no effect on Contexts that already exist unless you call updateParametersInContext().

## Member Function Documentation

def __del__ | ( |  | self | ) |

__del__(self)

Reimplemented from Force.

def __init__ | ( |  | self,
|  |  | args |
| ) |  |  |

__init__(self) -> AmoebaMultipoleForce __init__(self, AmoebaMultipoleForce other) -> AmoebaMultipoleForce

Create an AmoebaMultipoleForce.

def addMultipole | ( |  | self,
|  |  | args |
| ) |  |  |

addMultipole(self, double charge, vectord molecularDipole, vectord molecularQuadrupole, int axisType, int multipoleAtomZ, int multipoleAtomX, int multipoleAtomY, double thole, double dampingFactor, double polarity) -> int

Add multipole-related info for a particle

Parameters:

  | charge | the particle's charge
  | molecularDipole | the particle's molecular dipole (vector of size 3)
  | molecularQuadrupole | the particle's molecular quadrupole (vector of size 9)
  | axisType | the particle's axis type
  | multipoleAtomZ | index of first atom used in constructing lab<->molecular frames
  | multipoleAtomX | index of second atom used in constructing lab<->molecular frames
  | multipoleAtomY | index of second atom used in constructing lab<->molecular frames
  | thole | Thole parameter
  | dampingFactor | dampingFactor parameter
  | polarity | polarity parameter

def getAEwald | ( |  | self | ) |

getAEwald(self) -> double

Get the Ewald alpha parameter. If this is 0 (the default), a value is chosen automatically based on the Ewald error tolerance.

def getCovalentMap | ( |  | self,
|  |  | args |
| ) |  |  |

getCovalentMap(self, int index, CovalentType typeId)

Get the CovalentMap for an atom

Parameters:

  | index | the index of the atom for which to set parameters
  | typeId | CovalentTypes type
  | covalentAtoms | output vector of covalent atoms associated w/ the specfied CovalentType

def getCovalentMaps | ( |  | self,
|  |  | args |
| ) |  |  |

getCovalentMaps(self, int index)

Get the CovalentMap for an atom

Parameters:

  | index | the index of the atom for which to set parameters
  | covalentLists | output vector of covalent lists of atoms

def getCutoffDistance | ( |  | self | ) |

getCutoffDistance(self) -> double

Get the cutoff distance (in nm) being used for nonbonded interactions. If the NonbondedMethod in use is NoCutoff, this value will have no effect.

def getElectrostaticPotential | ( |  | self,
|  |  | args |
| ) |  |  |

getElectrostaticPotential(self, std.vector<(Vec3,std.allocator<(Vec3)>)> inputGrid, Context context)

Get the electrostatic potential.

Parameters:

  | inputGrid | input grid points over which the potential is to be evaluated
  | context | context
  | outputElectrostaticPotential | output potential

def getEwaldErrorTolerance | ( |  | self | ) |

getEwaldErrorTolerance(self) -> double

Get the error tolerance for Ewald summation. This corresponds to the fractional error in the forces which is acceptable. This value is used to select the grid dimensions and separation (alpha) parameter so that the average error level will be less than the tolerance. There is not a rigorous guarantee that all forces on all atoms will be less than the tolerance, however.

This can be overridden by explicitly setting an alpha parameter and grid dimensions to use.

def getInducedDipoles | ( |  | self,
|  |  | args |
| ) |  |  |

getInducedDipoles(self, Context context)

Get the induced dipole moments of all particles.

Parameters:

  | context | the Context for which to get the induced dipoles
  | dipoles | the induced dipole moment of particle i is stored into the i'th element

def getMultipoleParameters | ( |  | self,
|  |  | args |
| ) |  |  |

getMultipoleParameters(self, int index)

Get the multipole parameters for a particle.

Parameters:

  | index | the index of the atom for which to get parameters
  | charge | the particle's charge
  | molecularDipole | the particle's molecular dipole (vector of size 3)
  | molecularQuadrupole | the particle's molecular quadrupole (vector of size 9)
  | axisType | the particle's axis type
  | multipoleAtomZ | index of first atom used in constructing lab<->molecular frames
  | multipoleAtomX | index of second atom used in constructing lab<->molecular frames
  | multipoleAtomY | index of second atom used in constructing lab<->molecular frames
  | thole | Thole parameter
  | dampingFactor | dampingFactor parameter
  | polarity | polarity parameter

def getMutualInducedMaxIterations | ( |  | self | ) |

getMutualInducedMaxIterations(self) -> int

Get the max number of iterations to be used in calculating the mutual induced dipoles

def getMutualInducedTargetEpsilon | ( |  | self | ) |

getMutualInducedTargetEpsilon(self) -> double

Get the target epsilon to be used to test for convergence of iterative method used in calculating the mutual induced dipoles

def getNonbondedMethod | ( |  | self | ) |

getNonbondedMethod(self) -> NonbondedMethod

Get the method used for handling long-range nonbonded interactions.

def getNumMultipoles | ( |  | self | ) |

getNumMultipoles(self) -> int

Get the number of particles in the potential function

def getPmeBSplineOrder | ( |  | self | ) |

getPmeBSplineOrder(self) -> int

Get the B-spline order to use for PME charge spreading

def getPmeGridDimensions | ( |  | self | ) |

getPmeGridDimensions(self)

Get the PME grid dimensions. If Ewald alpha is 0 (the default), this is ignored and grid dimensions are chosen automatically based on the Ewald error tolerance.

def getPolarizationType | ( |  | self | ) |

getPolarizationType(self) -> PolarizationType

Get polarization type

def getSystemMultipoleMoments | ( |  | self,
|  |  | args |
| ) |  |  |

getSystemMultipoleMoments(self, Context context)

Get the system multipole moments.

This method is most useful for non-periodic systems. When called for a periodic system, only the lowest nonvanishing moment has a well defined value. This means that if the system has a net nonzero charge, the dipole and quadrupole moments are not well defined and should be ignored. If the net charge is zero, the dipole moment is well defined (and really represents a dipole density), but the quadrupole moment is still undefined and should be ignored.

Parameters:

  | context | context
  | outputMultipoleMoments | (charge, dipole_x, dipole_y, dipole_z, quadrupole_xx, quadrupole_xy, quadrupole_xz, quadrupole_yx, quadrupole_yy, quadrupole_yz, quadrupole_zx, quadrupole_zy, quadrupole_zz)

def setAEwald | ( |  | self,
|  |  | args |
| ) |  |  |

setAEwald(self, double aewald)

Set the Ewald alpha parameter. If this is 0 (the default), a value is chosen automatically based on the Ewald error tolerance.

Parameters:

  | Ewald | alpha parameter

def setCovalentMap | ( |  | self,
|  |  | args |
| ) |  |  |

setCovalentMap(self, int index, CovalentType typeId, vectori covalentAtoms)

Set the CovalentMap for an atom

Parameters:

  | index | the index of the atom for which to set parameters
  | typeId | CovalentTypes type
  | covalentAtoms | vector of covalent atoms associated w/ the specfied CovalentType

def setCutoffDistance | ( |  | self,
|  |  | args |
| ) |  |  |

setCutoffDistance(self, double distance)

Set the cutoff distance (in nm) being used for nonbonded interactions. If the NonbondedMethod in use is NoCutoff, this value will have no effect.

Parameters:

  | distance | the cutoff distance, measured in nm

def setEwaldErrorTolerance | ( |  | self,
|  |  | args |
| ) |  |  |

setEwaldErrorTolerance(self, double tol)

Get the error tolerance for Ewald summation. This corresponds to the fractional error in the forces which is acceptable. This value is used to select the grid dimensions and separation (alpha) parameter so that the average error level will be less than the tolerance. There is not a rigorous guarantee that all forces on all atoms will be less than the tolerance, however.

This can be overridden by explicitly setting an alpha parameter and grid dimensions to use.

def setMultipoleParameters | ( |  | self,
|  |  | args |
| ) |  |  |

setMultipoleParameters(self, int index, double charge, vectord molecularDipole, vectord molecularQuadrupole, int axisType, int multipoleAtomZ, int multipoleAtomX, int multipoleAtomY, double thole, double dampingFactor, double polarity)

Set the multipole parameters for a particle.

Parameters:

  | index | the index of the atom for which to set parameters
  | charge | the particle's charge
  | molecularDipole | the particle's molecular dipole (vector of size 3)
  | molecularQuadrupole | the particle's molecular quadrupole (vector of size 9)
  | axisType | the particle's axis type
  | multipoleAtomZ | index of first atom used in constructing lab<->molecular frames
  | multipoleAtomX | index of second atom used in constructing lab<->molecular frames
  | multipoleAtomY | index of second atom used in constructing lab<->molecular frames
  | polarity | polarity parameter

def setMutualInducedMaxIterations | ( |  | self,
|  |  | args |
| ) |  |  |

setMutualInducedMaxIterations(self, int inputMutualInducedMaxIterations)

Set the max number of iterations to be used in calculating the mutual induced dipoles

Parameters:

  | max | number of iterations

def setMutualInducedTargetEpsilon | ( |  | self,
|  |  | args |
| ) |  |  |

setMutualInducedTargetEpsilon(self, double inputMutualInducedTargetEpsilon)

Set the target epsilon to be used to test for convergence of iterative method used in calculating the mutual induced dipoles

Parameters:

  | target | epsilon

def setNonbondedMethod | ( |  | self,
|  |  | args |
| ) |  |  |

setNonbondedMethod(self, NonbondedMethod method)

Set the method used for handling long-range nonbonded interactions.

def setPmeGridDimensions | ( |  | self,
|  |  | args |
| ) |  |  |

setPmeGridDimensions(self, vectori gridDimension)

Set the PME grid dimensions. If Ewald alpha is 0 (the default), this is ignored and grid dimensions are chosen automatically based on the Ewald error tolerance.

Parameters:

  | the | PME grid dimensions

def setPolarizationType | ( |  | self,
|  |  | args |
| ) |  |  |

setPolarizationType(self, PolarizationType type)

Set the polarization type

def updateParametersInContext | ( |  | self,
|  |  | args |
| ) |  |  |

updateParametersInContext(self, Context context)

Update the multipole parameters in a Context to match those stored in this Force object. This method provides an efficient method to update certain parameters in an existing Context without needing to reinitialize it. Simply call setMultipoleParameters() to modify this object's parameters, then call updateParametersInState() to copy them over to the Context.

This method has several limitations. The only information it updates is the parameters of multipoles. All other aspects of the Force (the nonbonded method, the cutoff distance, etc.) are unaffected and can only be changed by reinitializing the Context. Furthermore, this method cannot be used to add new multipoles, only to change the parameters of existing ones.

## Member Data Documentation

Bisector = _openmm.AmoebaMultipoleForce_Bisector`[static]`

Covalent12 = _openmm.AmoebaMultipoleForce_Covalent12`[static]`

Covalent13 = _openmm.AmoebaMultipoleForce_Covalent13`[static]`

Covalent14 = _openmm.AmoebaMultipoleForce_Covalent14`[static]`

Covalent15 = _openmm.AmoebaMultipoleForce_Covalent15`[static]`

CovalentEnd = _openmm.AmoebaMultipoleForce_CovalentEnd`[static]`

Direct = _openmm.AmoebaMultipoleForce_Direct`[static]`

LastAxisTypeIndex = _openmm.AmoebaMultipoleForce_LastAxisTypeIndex`[static]`

Mutual = _openmm.AmoebaMultipoleForce_Mutual`[static]`

NoAxisType = _openmm.AmoebaMultipoleForce_NoAxisType`[static]`

NoCutoff = _openmm.AmoebaMultipoleForce_NoCutoff`[static]`

PME = _openmm.AmoebaMultipoleForce_PME`[static]`

PolarizationCovalent11 = _openmm.AmoebaMultipoleForce_PolarizationCovalent11`[static]`

PolarizationCovalent12 = _openmm.AmoebaMultipoleForce_PolarizationCovalent12`[static]`

PolarizationCovalent13 = _openmm.AmoebaMultipoleForce_PolarizationCovalent13`[static]`

PolarizationCovalent14 = _openmm.AmoebaMultipoleForce_PolarizationCovalent14`[static]`

this

ThreeFold = _openmm.AmoebaMultipoleForce_ThreeFold`[static]`

ZBisect = _openmm.AmoebaMultipoleForce_ZBisect`[static]`

ZOnly = _openmm.AmoebaMultipoleForce_ZOnly`[static]`

ZThenX = _openmm.AmoebaMultipoleForce_ZThenX`[static]`

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

- openmm.py