ls1-MarDyn
ls1-MarDyn molecular dynamics code
Integrator.h
1#ifndef INTEGRATOR_H_
2#define INTEGRATOR_H_
3
5class Domain;
6class XMLfileUnits;
7
33public:
36 Integrator(double timestepLength) : _timestepLength(timestepLength) {}
37
39 virtual ~Integrator() {}
40
41 virtual void readXML(XMLfileUnits& xmlconfig) = 0;
42
44 virtual void init() = 0;
45
54 virtual void eventForcesCalculated(ParticleContainer* moleculeContainer, Domain* domain) = 0;
55
66 virtual void eventNewTimestep(ParticleContainer* moleculeContainer, Domain* domain) = 0;
67
69 void setTimestepLength(double dt) {
70 _timestepLength = dt;
71 }
72
75 return _timestepLength;
76 }
77
78protected:
79
82
83};
84#endif /* INTEGRATOR_H_ */
This class is used to read in the phasespace and to handle macroscopic values.
Definition: Domain.h:47
Update velocities and positions.
Definition: Integrator.h:32
virtual void eventForcesCalculated(ParticleContainer *moleculeContainer, Domain *domain)=0
informs the integrator about available forces, who then continues integration
virtual void eventNewTimestep(ParticleContainer *moleculeContainer, Domain *domain)=0
inform the integrator that the integration should continue
Integrator()
The constructor.
Definition: Integrator.h:35
double _timestepLength
time between time step n and time step (n+1)
Definition: Integrator.h:81
virtual void init()=0
void setTimestepLength(double dt)
set the time between two time steps
Definition: Integrator.h:69
double getTimestepLength()
get the time between two time steps
Definition: Integrator.h:74
virtual ~Integrator()
The destructor.
Definition: Integrator.h:39
This Interface is used to get access to particles and pairs of particles.
Definition: ParticleContainer.h:69
XML file with unit attributes abstraction.
Definition: xmlfileUnits.h:25