ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/OOPSE/libmdtools/AbstractClasses.hpp
Revision: 837
Committed: Wed Oct 29 00:19:10 2003 UTC (20 years, 8 months ago) by tim
File size: 1234 byte(s)
Log Message:
add chi and eta to the comment line of dump file.

File Contents

# User Rev Content
1 mmeineke 377 #ifndef _ABSTRACT_CLASSES_H_
2     #define _ABSTRACT_CLASSES_H_
3    
4 tim 837 #include <string>
5 mmeineke 377 #include "Atom.hpp"
6     #ifdef IS_MPI
7    
8     #include "mpi.h"
9     #endif
10 tim 837
11     using namespace std;
12    
13 mmeineke 377 class Constraint{
14    
15 tim 837 public:
16 mmeineke 377 Constraint(){}
17     ~Constraint(){}
18 tim 837
19 mmeineke 377 int get_a() {return a;}
20     void set_a(int index) {a = index;}
21     int get_b() {return b;}
22     void set_b(int index) {b = index;}
23 mmeineke 424 double get_dsqr() {return dsqr;}
24 mmeineke 377 void set_dsqr(double ds) {dsqr = ds;}
25    
26     private:
27     int a; /* index of constrained atom a */
28     int b; /* index of constrained atom b */
29     double dsqr; /* the square of the constraint distance */
30     };
31    
32     class SRI{
33    
34     public:
35     SRI(){ c_potential_E = 0.0; }
36     virtual ~SRI() {}
37    
38     virtual void calc_forces() = 0;
39    
40     double get_potential(){ return c_potential_E; }
41     virtual int is_constrained() = 0;
42     virtual Constraint *get_constraint() = 0;
43     virtual void constrain(double bond_distance) = 0;
44    
45     virtual void printMe( void ) = 0;
46    
47     protected:
48     double c_potential_E;
49     };
50    
51    
52 mmeineke 540 class BaseIntegrator{
53 tim 837
54 mmeineke 377 public:
55 mmeineke 540 BaseIntegrator(){}
56     virtual ~BaseIntegrator(){}
57 tim 837
58 mmeineke 377 virtual void integrate( void ) = 0;
59 tim 837 virtual double getConservedQuantity(void) = 0;
60     virtual string getAdditionalParameters(void) = 0;
61 mmeineke 377 };
62     #endif