Package src :: Package factories :: Module PropagatorFactory
[hide private]
[frames] | no frames]

Module PropagatorFactory

source code

Classes [hide private]
  PropagatorFactory
Contains mappings from propagator names to creation functions, their types (object or method) and parameters with default values.
Functions [hide private]
 
setPropagator(prop, phys, forces, obj, levelswitch=False)
Set and initialize a propagator object.
source code
 
executePropagator(prop, phys, forces, io, numsteps)
Run and finish the propagator.
source code
Python module
_get_mod(modulePath)
Given a path to a Python module, return the module itself.
source code
Variables [hide private]
  propFactory = PropagatorFactory()
PropagatorFactory singleton object
Function Details [hide private]

setPropagator(prop, phys, forces, obj, levelswitch=False)

source code 

Set and initialize a propagator object.

Parameters:
  • prop (Propagator) - MDL Propagator object
  • phys (Physical) - The physical system.
  • forces (Forces) - MDL Forces object
  • obj (STS/MTS) - Prototyped propagator object
  • levelswitch (boolean) - True if we are changing levels in the hierarchy. Default false.

executePropagator(prop, phys, forces, io, numsteps)

source code 

Run and finish the propagator.

Parameters:
  • prop (Propagator) - MDL Propagator object
  • phys (Physical) - The physical system.
  • forces (Forces) - MDL Forces object
  • io (IO) - MDL IO object
  • numsteps (int) - Number of steps to run

_get_mod(modulePath)

source code 

Given a path to a Python module, return the module itself. This allows the factory to search for example the propagators/ and modifiers/ packages

Parameters:
  • modulePath (string) - Path to the Python module.
Returns: Python module
The Python module.