BALL
1.4.2
|
#include <BALL/MOLMEC/COMMON/snapShot.h>
Public Member Functions | |
Constructors and Destructors | |
SnapShot () | |
SnapShot (const SnapShot &snapshot) | |
Copy constructor. More... | |
virtual | ~SnapShot () |
The destructor. More... | |
Assignment | |
const SnapShot & | operator= (const SnapShot &snapshot) |
Assignment operator. More... | |
virtual void | clear () |
Clear method. More... | |
Predicates | |
bool | operator== (const SnapShot &snapshot) const |
Equality operator. More... | |
bool | isValid () const |
Accessors | |
void | setIndex (Size index) |
Set the index attribute. More... | |
Size | getIndex () const |
Get the index of this instance. More... | |
void | setNumberOfAtoms (Size number_of_atoms) |
Set the number of atoms that are covered by this snapshot. More... | |
Size | getNumberOfAtoms () const |
Get the number of atoms that are covered by this snapshot. More... | |
void | setPotentialEnergy (DoubleReal potential_energy) |
Set the value for the potential energy of this snapshot's system. More... | |
DoubleReal | getPotentialEnergy () const |
Get the value for the potential energy of this snapshot's system. More... | |
void | setKineticEnergy (DoubleReal kinetic_energy) |
Set the value for the kinetic energy of this snapshot's system. More... | |
DoubleReal | getKineticEnergy () const |
Get the value for the kinetic energy of this snapshot's system. More... | |
void | setAtomPositions (const ::std::vector< Vector3 > &atom_postions) |
Specify all atom positions. More... | |
const ::std::vector< Vector3 > & | getAtomPositions () const |
Get the vector containing the atom postions. More... | |
void | setAtomVelocities (const ::std::vector< Vector3 > &atom_velocities) |
Specify all atom velocities. More... | |
const ::std::vector< Vector3 > & | getAtomVelocities () const |
Get the vector containing the atom velocitites. More... | |
void | setAtomForces (const ::std::vector< Vector3 > &atom_forces) |
Specify all atom forces. More... | |
const ::std::vector< Vector3 > & | getAtomForces () const |
Get all atom forces. More... | |
System interaction | |
void | takeSnapShot (const System &system) throw (Exception::OutOfMemory) |
void | applySnapShot (System &system) const |
void | getAtomPositions (const System &system) throw (Exception::OutOfMemory) |
void | setAtomPositions (System &system) const |
void | getAtomVelocities (const System &system) throw (Exception::OutOfMemory) |
void | setAtomVelocitites (System &system) const |
void | getAtomForces (const System &system) throw (Exception::OutOfMemory) |
void | setAtomForces (System &system) const |
Protected Attributes | |
Size | index_ |
Size | number_of_atoms_ |
double | potential_energy_ |
double | kinetic_energy_ |
vector< Vector3 > | atom_positions_ |
vector< Vector3 > | atom_velocities_ |
vector< Vector3 > | atom_forces_ |
SnapShot class, containing the actual data of one single snapshot. It consists of the posistions, velocities and forces for each atom along with kinetic and potential energy of selected atoms. It is used by the SnapShotManager .
Definition at line 31 of file snapShot.h.
BALL::SnapShot::SnapShot | ( | ) |
The default constructor. It creates an empty SnapShot object.
BALL::SnapShot::SnapShot | ( | const SnapShot & | snapshot | ) |
Copy constructor.
|
virtual |
The destructor.
void BALL::SnapShot::applySnapShot | ( | System & | system | ) | const |
Apply the data contained in a SnapShot to a System. Copy all available data to the system. Note that some trajectory file formats do not contain all this information and vectors might be zero or even worse undefined when read SnapShots are read from such a file.
system | the System which will be manipulated |
|
virtual |
Clear method.
const ::std::vector<Vector3>& BALL::SnapShot::getAtomForces | ( | ) | const |
Get all atom forces.
void BALL::SnapShot::getAtomForces | ( | const System & | system | ) | throw (Exception::OutOfMemory) |
const ::std::vector<Vector3>& BALL::SnapShot::getAtomPositions | ( | ) | const |
Get the vector containing the atom postions.
void BALL::SnapShot::getAtomPositions | ( | const System & | system | ) | throw (Exception::OutOfMemory) |
const ::std::vector<Vector3>& BALL::SnapShot::getAtomVelocities | ( | ) | const |
Get the vector containing the atom velocitites.
void BALL::SnapShot::getAtomVelocities | ( | const System & | system | ) | throw (Exception::OutOfMemory) |
Size BALL::SnapShot::getIndex | ( | ) | const |
Get the index of this instance.
DoubleReal BALL::SnapShot::getKineticEnergy | ( | ) | const |
Get the value for the kinetic energy of this snapshot's system.
Size BALL::SnapShot::getNumberOfAtoms | ( | ) | const |
Get the number of atoms that are covered by this snapshot.
DoubleReal BALL::SnapShot::getPotentialEnergy | ( | ) | const |
Get the value for the potential energy of this snapshot's system.
bool BALL::SnapShot::isValid | ( | ) | const |
Indicates validity of the SnapShot
void BALL::SnapShot::setAtomForces | ( | const ::std::vector< Vector3 > & | atom_forces | ) |
Specify all atom forces.
void BALL::SnapShot::setAtomForces | ( | System & | system | ) | const |
void BALL::SnapShot::setAtomPositions | ( | const ::std::vector< Vector3 > & | atom_postions | ) |
Specify all atom positions.
void BALL::SnapShot::setAtomPositions | ( | System & | system | ) | const |
void BALL::SnapShot::setAtomVelocities | ( | const ::std::vector< Vector3 > & | atom_velocities | ) |
Specify all atom velocities.
void BALL::SnapShot::setAtomVelocitites | ( | System & | system | ) | const |
void BALL::SnapShot::setIndex | ( | Size | index | ) |
Set the index attribute.
void BALL::SnapShot::setKineticEnergy | ( | DoubleReal | kinetic_energy | ) |
Set the value for the kinetic energy of this snapshot's system.
void BALL::SnapShot::setNumberOfAtoms | ( | Size | number_of_atoms | ) |
Set the number of atoms that are covered by this snapshot.
void BALL::SnapShot::setPotentialEnergy | ( | DoubleReal | potential_energy | ) |
Set the value for the potential energy of this snapshot's system.
void BALL::SnapShot::takeSnapShot | ( | const System & | system | ) | throw (Exception::OutOfMemory) |
|
protected |
Definition at line 236 of file snapShot.h.
|
protected |
Definition at line 230 of file snapShot.h.
|
protected |
Definition at line 233 of file snapShot.h.
|
protected |
Definition at line 211 of file snapShot.h.
|
protected |
Definition at line 227 of file snapShot.h.
|
protected |
Definition at line 217 of file snapShot.h.
|
protected |
Definition at line 222 of file snapShot.h.