This class is an abstract class for processing the velocity and position update of each particle. More...
#include <position_and_velocity_updater.h>
Public Member Functions | |
virtual | ~PositionAndVelocityUpdater () |
virtual std::string | GetName ()=0 |
Returns a string representation of this object. More... | |
virtual void | LoadData (std::ifstream *input_stream, ProgramVersion *version_of_stored_data) |
Loads data to reset the state of the position and velocity updater to the state which was stored. More... | |
virtual void | StoreData (std::ofstream *output_stream) |
Stores the current state of this position and velocity updater such that it can completely restore the current state with this data. More... | |
virtual void | Update (Particle *p)=0 |
This method initializes the velocity and position update of the specified particle. More... | |
Detailed Description
This class is an abstract class for processing the velocity and position update of each particle.
Constructor & Destructor Documentation
|
inlinevirtual |
The destructor.
Member Function Documentation
|
pure virtual |
Returns a string representation of this object.
- Returns
- The name of the object.
Implemented in highprecisionpso::DeltaUpdaterTCS, highprecisionpso::DimensionIndependentUpdater, highprecisionpso::DeltaUpdater, highprecisionpso::OrientationChangeUpdater, highprecisionpso::TestingUpdater, and highprecisionpso::DefaultUpdater.
|
virtual |
Loads data to reset the state of the position and velocity updater to the state which was stored.
- Parameters
-
input_stream The stream which contains the data about the state of the position and velocity updater. version_of_stored_data The version of the program when the backup was created.
Reimplemented in highprecisionpso::DeltaUpdater, and highprecisionpso::OrientationChangeUpdater.
|
virtual |
Stores the current state of this position and velocity updater such that it can completely restore the current state with this data.
- Parameters
-
output_stream The output stream where the state should be stored.
Reimplemented in highprecisionpso::DeltaUpdater, and highprecisionpso::OrientationChangeUpdater.
|
pure virtual |
This method initializes the velocity and position update of the specified particle.
The new velocity is directly calculated in this method. After the new velocity is calculated the bound handling strategy determines the new position.
- Warning
- Do not forget to call the method of the bound handling specified in configuration section for setting the new position.
- Parameters
-
p The particle, which should be updated.
Implemented in highprecisionpso::DimensionIndependentUpdater, highprecisionpso::DeltaUpdater, highprecisionpso::OrientationChangeUpdater, highprecisionpso::TestingUpdater, and highprecisionpso::DefaultUpdater.
The documentation for this class was generated from the following file:
- src/position_and_velocity_updater/position_and_velocity_updater.h