Line data Source code
1 : // Copyright (C) 2015 Technische Universitaet Muenchen
2 : // This file is part of the Mamico project. For conditions of distribution
3 : // and use, please see the copyright notice in Mamico's main folder, or at
4 : // www5.in.tum.de/mamico
5 : #ifndef _MOLECULARDYNAMICS_SERVICES_EXTERNALFORCESERVICE_H_
6 : #define _MOLECULARDYNAMICS_SERVICES_EXTERNALFORCESERVICE_H_
7 :
8 : #include "simplemd/MolecularDynamicsDefinitions.h"
9 : #include "simplemd/Molecule.h"
10 : #include "simplemd/configurations/ExternalForceConfiguration.h"
11 : #include <cstdlib>
12 : #include <iostream>
13 : #include <vector>
14 :
15 : namespace simplemd {
16 : namespace services {
17 : class ExternalForceService;
18 : }
19 : } // namespace simplemd
20 :
21 : /** adds external forces to the molecules
22 : * @author Philipp Neumann
23 : */
24 : class simplemd::services::ExternalForceService {
25 : public:
26 : /** initialises the properties */
27 : ExternalForceService(const std::vector<simplemd::configurations::ExternalForceConfiguration>& configs);
28 :
29 : void addExternalForce(tarch::la::Vector<MD_DIM, double>& force);
30 :
31 12 : ~ExternalForceService() {}
32 :
33 : private:
34 : const std::vector<simplemd::configurations::ExternalForceConfiguration>& _configurations;
35 : };
36 : #endif // _MOLECULARDYNAMICS_SERVICES_EXTERNALFORCESERVICE_H_
|