A simulator engine is used to compute the displacements of all atoms of the model. More...
#include <Simulator.h>
Public Member Functions | |
virtual void | createPml (const char *inputFile, const char *pmlFile)=0 |
Create a pml file from a simulator specific imput file. More... | |
virtual void | end ()=0 |
end simultor More... | |
virtual void | getForce (int index, double force[3])=0 |
get current force for one atom More... | |
virtual void | getPosition (int index, double position[3])=0 |
get current position for one atom More... | |
virtual void | init ()=0 |
initialize the simulator More... | |
Simulator (MonitoringManager *monitoringManager) | |
default constructor build a simulation from context provided by monitoringManager More... | |
Simulator (MonitoringManager *monitoringManager, const char *file) | |
constructor with simulator file build a simulation from context provided by monitoringManager and physical model provided by a simulator specific input file More... | |
void | updatePositions () |
update all current positions and store last positions More... | |
virtual | ~Simulator ()=default |
destructor More... | |
Protected Attributes | |
MonitoringManager * | monitoringManager |
monitoring manager More... | |
A simulator engine is used to compute the displacements of all atoms of the model.
Simulator::Simulator | ( | MonitoringManager * | monitoringManager | ) |
default constructor build a simulation from context provided by monitoringManager
monitoringManager | manager provinding context of simulation |
References monitoringManager.
Simulator::Simulator | ( | MonitoringManager * | monitoringManager, |
const char * | file | ||
) |
constructor with simulator file build a simulation from context provided by monitoringManager and physical model provided by a simulator specific input file
monitoringManager | manager provinding context of simulation |
file | path to simulator specific file |
References monitoringManager.
|
virtualdefault |
destructor
|
pure virtual |
Create a pml file from a simulator specific imput file.
Implemented in NonInteractiveSimulator, InteractiveSimulator, SofaSimulator, ArtisynthSimulator, and AnsysSimulator.
|
pure virtual |
end simultor
Implemented in NonInteractiveSimulator, InteractiveSimulator, SofaSimulator, ArtisynthSimulator, and AnsysSimulator.
|
pure virtual |
get current force for one atom
Implemented in SofaSimulator, ArtisynthSimulator, and AnsysSimulator.
Referenced by MonitorForce::calculate().
|
pure virtual |
get current position for one atom
Implemented in NonInteractiveSimulator, InteractiveSimulator, SofaSimulator, ArtisynthSimulator, and AnsysSimulator.
Referenced by updatePositions().
|
pure virtual |
initialize the simulator
Implemented in NonInteractiveSimulator, InteractiveSimulator, SofaSimulator, ArtisynthSimulator, and AnsysSimulator.
void Simulator::updatePositions | ( | ) |
update all current positions and store last positions
References PhysicalModel::getAtom(), PhysicalModel::getAtoms(), Structure::getIndex(), MonitoringManager::getPml(), getPosition(), StructuralComponent::getStructure(), monitoringManager, Atom::setPosition(), and MonitoringManager::storeOldPositions().
Referenced by InteractiveMonitoringManager::doMove(), NonInteractiveMonitoringManager::doMove(), InteractiveMonitoringManager::init(), and NonInteractiveMonitoringManager::init().
|
protected |
monitoring manager
Referenced by AnsysSimulator::getPosition(), ArtisynthSimulator::getPosition(), SofaSimulator::init(), Simulator(), and updatePositions().