ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/OOPSE_old/src/mdtools/libmdCode/SimInfo.cpp
Revision: 348
Committed: Fri Mar 14 21:33:10 2003 UTC (21 years, 4 months ago) by mmeineke
File size: 947 byte(s)
Log Message:
mostly compiles. interface twixt c and fortran is broken. (c needs to be brought up to date with fortran.)

File Contents

# Content
1 #include <cstdlib>
2 #include <cstring>
3
4
5 #include "SimInfo.hpp"
6 #define __C
7 #include "fSimulation.h"
8 #include "simError.h"
9
10 #include <fortranWrappers.hpp>
11
12 SimInfo* currentInfo;
13
14 SimInfo::SimInfo(){
15 excludes = NULL;
16 n_constraints = 0;
17 n_oriented = 0;
18 n_dipoles = 0;
19 the_integrator = NULL;
20 setTemp = 0;
21 thermalTime = 0.0;
22
23 wrapMeSimInfo( this );
24 }
25
26 void SimInfo::refreshSim(){
27
28 simtype fInfo;
29 int isError;
30
31 fInfo.box[0] = box_x;
32 fInfo.box[1] = box_y;
33 fInfo.box[2] = box_z;
34
35 fInfo.rlist = rList;
36 fInfo.rcut = rCut;
37 fInfo.SIM_uses_PBC = usePBC;
38
39 isError = 0;
40 setFsimulation( &fInfo, &isError );
41
42 if( isError ){
43
44 sprintf( painCave.errMsg,
45 "There was an error setting the simulation information in fortran.\n" );
46 painCave.isFatal = 1;
47 simError();
48 }
49
50 #ifdef IS_MPI
51 sprintf( checkPointMsg,
52 "succesfully sent the simulation information to fortran.\n");
53 MPIcheckPoint();
54 #endif // is_mpi
55 }
56