Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
tsoc
openmm
Commits
856aab50
Commit
856aab50
authored
Nov 02, 2015
by
Robert McGibbon
Browse files
Update docstrings in amd.py and mtsintegrator.py
parent
98d053d4
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
69 additions
and
39 deletions
+69
-39
wrappers/python/simtk/openmm/amd.py
wrappers/python/simtk/openmm/amd.py
+50
-23
wrappers/python/simtk/openmm/mtsintegrator.py
wrappers/python/simtk/openmm/mtsintegrator.py
+19
-16
No files found.
wrappers/python/simtk/openmm/amd.py
View file @
856aab50
...
@@ -49,10 +49,14 @@ class AMDIntegrator(CustomIntegrator):
...
@@ -49,10 +49,14 @@ class AMDIntegrator(CustomIntegrator):
def
__init__
(
self
,
dt
,
alpha
,
E
):
def
__init__
(
self
,
dt
,
alpha
,
E
):
"""Create an AMDIntegrator.
"""Create an AMDIntegrator.
Parameters:
Parameters
- dt (time) The integration time step to use
----------
- alpha (energy) The alpha parameter to use
dt : time
- E (energy) The energy cutoff to use
The integration time step to use
alpha : energy
The alpha parameter to use
E : energy
The energy cutoff to use
"""
"""
CustomIntegrator
.
__init__
(
self
,
dt
)
CustomIntegrator
.
__init__
(
self
,
dt
)
self
.
addGlobalVariable
(
"alpha"
,
alpha
)
self
.
addGlobalVariable
(
"alpha"
,
alpha
)
...
@@ -104,11 +108,16 @@ class AMDForceGroupIntegrator(CustomIntegrator):
...
@@ -104,11 +108,16 @@ class AMDForceGroupIntegrator(CustomIntegrator):
def
__init__
(
self
,
dt
,
group
,
alphaGroup
,
EGroup
):
def
__init__
(
self
,
dt
,
group
,
alphaGroup
,
EGroup
):
"""Create a AMDForceGroupIntegrator.
"""Create a AMDForceGroupIntegrator.
Parameters:
Parameters
- dt (time) The integration time step to use
----------
- group (int) The force group to apply the boost to
dt : time
- alphaGroup (energy) The alpha parameter to use for the boosted force group
The integration time step to use
- EGroup (energy) The energy cutoff to use for the boosted force group
group : int
The force group to apply the boost to
alphaGroup : energy
The alpha parameter to use for the boosted force group
EGroup : energy
The energy cutoff to use for the boosted force group
"""
"""
CustomIntegrator
.
__init__
(
self
,
dt
)
CustomIntegrator
.
__init__
(
self
,
dt
)
self
.
addGlobalVariable
(
"alphaGroup"
,
alphaGroup
)
self
.
addGlobalVariable
(
"alphaGroup"
,
alphaGroup
)
...
@@ -144,9 +153,14 @@ class AMDForceGroupIntegrator(CustomIntegrator):
...
@@ -144,9 +153,14 @@ class AMDForceGroupIntegrator(CustomIntegrator):
def
getEffectiveEnergy
(
self
,
groupEnergy
):
def
getEffectiveEnergy
(
self
,
groupEnergy
):
"""Given the actual group energy of the system, return the value of the effective potential.
"""Given the actual group energy of the system, return the value of the effective potential.
Parameters:
Parameters
- groupEnergy (energy): the actual potential energy of the boosted force group
----------
Returns: the value of the effective potential
groupEnergy : energy
the actual potential energy of the boosted force group
Returns
-------
the value of the effective potential
"""
"""
alphaGroup
=
self
.
getAlphaGroup
()
alphaGroup
=
self
.
getAlphaGroup
()
EGroup
=
self
.
getEGroup
()
EGroup
=
self
.
getEGroup
()
...
@@ -172,13 +186,20 @@ class DualAMDIntegrator(CustomIntegrator):
...
@@ -172,13 +186,20 @@ class DualAMDIntegrator(CustomIntegrator):
def
__init__
(
self
,
dt
,
group
,
alphaTotal
,
ETotal
,
alphaGroup
,
EGroup
):
def
__init__
(
self
,
dt
,
group
,
alphaTotal
,
ETotal
,
alphaGroup
,
EGroup
):
"""Create a DualAMDIntegrator.
"""Create a DualAMDIntegrator.
Parameters:
Parameters
- dt (time) The integration time step to use
----------
- group (int) The force group to apply the second boost to
dt : time
- alphaTotal (energy) The alpha parameter to use for the total energy
The integration time step to use
- ETotal (energy) The energy cutoff to use for the total energy
group : int
- alphaGroup (energy) The alpha parameter to use for the boosted force group
The force group to apply the second boost to
- EGroup (energy) The energy cutoff to use for the boosted force group
alphaTotal : energy
The alpha parameter to use for the total energy
ETotal : energy
The energy cutoff to use for the total energy
alphaGroup : energy
The alpha parameter to use for the boosted force group
EGroup : energy
The energy cutoff to use for the boosted force group
"""
"""
CustomIntegrator
.
__init__
(
self
,
dt
)
CustomIntegrator
.
__init__
(
self
,
dt
)
self
.
addGlobalVariable
(
"alphaTotal"
,
alphaTotal
)
self
.
addGlobalVariable
(
"alphaTotal"
,
alphaTotal
)
...
@@ -237,10 +258,16 @@ class DualAMDIntegrator(CustomIntegrator):
...
@@ -237,10 +258,16 @@ class DualAMDIntegrator(CustomIntegrator):
def
getEffectiveEnergy
(
self
,
totalEnergy
,
groupEnergy
):
def
getEffectiveEnergy
(
self
,
totalEnergy
,
groupEnergy
):
"""Given the actual potential energy of the system, return the value of the effective potential.
"""Given the actual potential energy of the system, return the value of the effective potential.
Parameters:
Parameters
- totalEnergy (energy): the actual potential energy of the whole system
----------
- groupEnergy (energy): the actual potential energy of the boosted force group
totalEnergy : energy
Returns: the value of the effective potential
the actual potential energy of the whole system
groupEnergy : energy
the actual potential energy of the boosted force group
Returns
-------
the value of the effective potential
"""
"""
alphaTotal
=
self
.
getAlphaTotal
()
alphaTotal
=
self
.
getAlphaTotal
()
ETotal
=
self
.
getETotal
()
ETotal
=
self
.
getETotal
()
...
...
wrappers/python/simtk/openmm/mtsintegrator.py
View file @
856aab50
...
@@ -74,11 +74,14 @@ class MTSIntegrator(CustomIntegrator):
...
@@ -74,11 +74,14 @@ class MTSIntegrator(CustomIntegrator):
def
__init__
(
self
,
dt
,
groups
):
def
__init__
(
self
,
dt
,
groups
):
"""Create an MTSIntegrator.
"""Create an MTSIntegrator.
Parameters:
Parameters
- dt (time) The largest (outermost) integration time step to use
----------
- groups (list) A list of tuples defining the force groups. The first element of each
dt : time
tuple is the force group index, and the second element is the number of times that force
The largest (outermost) integration time step to use
group should be evaluated in one time step.
groups : list
A list of tuples defining the force groups. The first element of
each tuple is the force group index, and the second element is the
number of times that force group should be evaluated in one time step.
"""
"""
if
len
(
groups
)
==
0
:
if
len
(
groups
)
==
0
:
raise
ValueError
(
"No force groups specified"
)
raise
ValueError
(
"No force groups specified"
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment