|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectchemaxon.marvin.plugin.CalculatorPlugin
chemaxon.marvin.calculations.MolecularDynamicsPlugin
public class MolecularDynamicsPlugin
Molecular Dynamics plugin.
API usage example:
// create plugin
MolecularDynamicsPlugin plugin = new MolecularDynamicsPlugin();
// set parameters
plugin.setStepNumber(10000);
plugin.setStepTime(1);
plugin.setSamplingInterval(10);
// read the input molecule
MolImporter mi = new MolImporter("mol.sdf");
Molecule mol = mi.read();
// set the input molecule
plugin.setMolecule(mol);
// run the calculation
plugin.run();
// get the results
int structureCount = plugin.getStructureCount();
for (int i = 0; i < structureCount; i++) {
Molecule mdMol = plugin.getStructure(i);
// do something with results
}
mi.close();
For concurrent plugin example applications using ChemAxon's concurrent framework, refer to the Concurrent plugin examples.
| Field Summary |
|---|
| Fields inherited from class chemaxon.marvin.plugin.CalculatorPlugin |
|---|
ATOM, BLUE, CALCRGB_OFF, COVALENT_HYDRATION_ERROR_REMARK, CRITICAL_ERROR_MSG, EPSILON, INCORRECT_AROMATIC_NITROGEN_REMARK, INSTABLE_TAUTOMERIC_FORM_REMARK, licenseEnvironment, MOLECULE, MOLECULES, NAN, PLUGIN_CLASS_KEY, PLUGIN_DIR, RED |
| Constructor Summary | |
|---|---|
MolecularDynamicsPlugin()
Creates a new instance of MolecularDynamicsPlugin |
|
| Method Summary | |
|---|---|
void |
checkMolecule(Molecule mol)
Checks the input molecule. |
java.lang.String |
getProductName()
Returns the product identifier of the plugin as given by LicenseManager. |
java.lang.Object |
getResult(java.lang.Object type,
int index)
Returns the result item for the specified key and index. |
java.lang.String |
getResultAsString(java.lang.Object type,
int index,
java.lang.Object result)
Returns the specified result in String format. |
int |
getResultCount(java.lang.Object type)
Returns the number of result items for the given result key. |
int |
getResultDomain(java.lang.Object type)
Returns the calculation domain. |
chemaxon.marvin.plugin.PluginMDocSource |
getResultSource()
Returns the result as a document source object. |
java.lang.Object[] |
getResultTypes()
Returns the result types. |
Molecule |
getStructure(int index)
Returns a structure. |
int |
getStructureCount()
Returns the number of different structures. |
Molecule[] |
getStructures()
Returns all structures. |
boolean |
handlesMultiFragmentMolecules()
Returns true if the plugin handles multifragment
molecules, false otherwise. |
boolean |
run()
Runs the tool. |
void |
setCenterMolecule(boolean centerMolecule)
Center the molecule before MD calculation (It is not set by default.) |
void |
setForceField(java.lang.String forcefield)
Sets the force field type. |
void |
setInitialTemperature(double temperature)
Sets the initial temperature. |
protected void |
setInputMolecule(Molecule mol)
Sets the input molecule. |
void |
setIntegrator(java.lang.String integrator)
Sets the integrator used for calculations. |
void |
setParameters(java.util.Properties params)
Sets the input parameters for the plugin. |
void |
setProgressMonitor(chemaxon.common.util.MProgressMonitor pmon)
Sets a progress observer to be used in run() to display progress
status. |
void |
setSamplingInterval(double sampinterval)
Number of trajectory frames to be stored from the sampling start time to the end of calculation. |
void |
setSamplingStart(double sampstart)
Sets the beginning of trajectory sampling. |
void |
setStepNumber(int stepno)
Sets the number of simulation steps. |
void |
setStepTime(double timestep)
Sets the simulation timestep. |
void |
standardize(Molecule mol)
Expands sgroups. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MolecularDynamicsPlugin()
| Method Detail |
|---|
public void setForceField(java.lang.String forcefield)
forcefield - force field type
possible values: "dreiding", (default: "dreiding")public void setIntegrator(java.lang.String integrator)
integrator - integrator type
possible values: "positionverlet","velocityverlet","leapfrog","projectedvelocityverlet"
(default: "velocityverlet")public void setStepNumber(int stepno)
stepno - number of simulation steps (default: 1000)public void setStepTime(double timestep)
timestep - duration of one simulation step in femtoseconds (default: 0.1fs)public void setInitialTemperature(double temperature)
temperature - temperature in Kelvinspublic void setSamplingStart(double sampstart)
sampstart - number of first trajectory frame to be savedpublic void setSamplingInterval(double sampinterval)
sampinterval - trajectory sampling interval in femtosecondspublic void setCenterMolecule(boolean centerMolecule)
centerMolecule - is the molecule will be centeredpublic void setProgressMonitor(chemaxon.common.util.MProgressMonitor pmon)
run() to display progress
status. Short calculations may ignore the observer object. The default
implementation does nothing.
setProgressMonitor in class CalculatorPluginpmon - is the progress monitor, may be nullpublic java.lang.String getProductName()
LicenseManager.
getProductName in class CalculatorPluginLicenseManager.CONFORMATION_PLUGIN_GROUP
public void setParameters(java.util.Properties params)
throws PluginException
setParameters in class CalculatorPluginparams - is the parameter table
PluginException - on errorpublic boolean handlesMultiFragmentMolecules()
true if the plugin handles multifragment
molecules, false otherwise. In the latter case the plugin
takes the fragment with more atoms if a multifragment molecule is given
as input. Returns true if parameter "single" is set to
"false", false otherwise (default: false).
handlesMultiFragmentMolecules in class CalculatorPlugin
public void checkMolecule(Molecule mol)
throws PluginException
RxnMolecule or if the molecule contains
R-groups.
checkMolecule in class CalculatorPluginmol - is the input molecule
PluginException - with error message for the user if the
molecule is refused
protected void setInputMolecule(Molecule mol)
throws PluginException
setInputMolecule in class CalculatorPluginmol - is the input molecule
PluginException - on error
public boolean run()
throws PluginException
run in class CalculatorPluginPluginException - on errorCalculatorPlugin.getErrorMessage()
public chemaxon.marvin.plugin.PluginMDocSource getResultSource()
throws PluginException
getResultSource in class CalculatorPluginPluginException - on errorpublic int getStructureCount()
public Molecule getStructure(int index)
throws PluginException
index - is the structure index
PluginException
public Molecule[] getStructures()
throws PluginException
PluginExceptionpublic java.lang.Object[] getResultTypes()
getResultTypes in class CalculatorPluginpublic int getResultDomain(java.lang.Object type)
getResultDomain in class CalculatorPlugintype - is the result type
getResultTypes()public int getResultCount(java.lang.Object type)
getResultCount in class CalculatorPlugintype - is the result type
getResultTypes()
public java.lang.Object getResult(java.lang.Object type,
int index)
throws PluginException
getResult in class CalculatorPlugintype - is the result typeindex - is the result index
PluginException - if the result cannot be returnedCalculatorPlugin.getResultTypes()
public java.lang.String getResultAsString(java.lang.Object type,
int index,
java.lang.Object result)
throws PluginException
getResultAsString in class CalculatorPlugintype - is the result typeindex - is the result indexresult - is the result item
PluginException - if an invalid result item is givenpublic void standardize(Molecule mol)
standardize in class CalculatorPluginmol - is the molecule to be standardized
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||