ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/OOPSE_old/src/mdtools/libmdCode/SimInfo.cpp
(Generate patch)

Comparing trunk/OOPSE_old/src/mdtools/libmdCode/SimInfo.cpp (file contents):
Revision 290 by chuckv, Thu Feb 27 21:25:47 2003 UTC vs.
Revision 368 by chuckv, Thu Mar 20 00:02:39 2003 UTC

# Line 7 | Line 7
7   #include "fSimulation.h"
8   #include "simError.h"
9  
10 < extern "C"{
11 <  void wrapsimmod_( void (*wrapFunction)(void (*fSub)( simtype*, int* )));
12 < }
10 > #include <fortranWrappers.hpp>
11  
14 void wrapSimInfo(void (*fSub)( simtype*, int* ));
15
12   SimInfo* currentInfo;
13  
14   SimInfo::SimInfo(){
# Line 24 | Line 20 | SimInfo::SimInfo(){
20    setTemp = 0;
21    thermalTime = 0.0;
22  
23 <  currentInfo = this;
24 <  wrapMe();
25 < }
23 >  usePBC = 0;
24 >  useLJ = 0;
25 >  useSticky = 0;
26 >  useDipole = 0;
27 >  useReactionField = 0;
28 >  useGB = 0;
29 >  useEAM = 0;
30  
31  
32 void SimInfo::wrapMe(){
32  
33 <  wrapsimmod_( wrapSimInfo );
33 >  wrapMeSimInfo( this );
34   }
35  
37
36   void SimInfo::refreshSim(){
37  
38    simtype fInfo;
# Line 46 | Line 44 | void SimInfo::refreshSim(){
44  
45    fInfo.rlist = rList;
46    fInfo.rcut = rCut;
47 <  fInfo.rlistsq = rlist * rlist;
48 <  fInfo.rcutsq = rCut * rCut;
49 <  fInfo.rcut6 = fInfo.rcutsq * fInfo.rcutsq * fInfo.rcutsq;
50 <  fInfo.natoms = n_atoms;
51 <  fInfo.usePBC = usePBC;
52 <  strcpy( fInfo.ensemble, ensemble );
53 <  strcpy( fInfo.mixingRule, mixingRule );
47 >  fInfo.SIM_uses_PBC = usePBC;
48 >  fInfo.SIM_uses_LJ = useLJ;
49 >  fInfo.SIM_uses_sticky = useSticky;
50 >  fInfo.SIM_uses_dipoles = useDipole;
51 >  fInfo.SIM_uses_RF = useReactionField;
52 >  fInfo.SIM_uses_GB = useGB;
53 >  fInfo.SIM_uses_EAM = useEAM;
54  
55 +
56    isError = 0;
58  setFsimulation( &fInfo, &isError );
57  
58 +  fInfo;
59 +  n_atoms;
60 +  identArray;
61 +  n_exclude;
62 +  excludes;
63 +  nGlobalExcludes;
64 +  globalExcludes;
65 +  isError;
66 +
67 +  setFsimulation( &fInfo, &n_atoms, identArray, &n_exclude, excludes, &nGlobalExcludes, globalExcludes, &isError );
68 +
69    if( isError ){
70  
71      sprintf( painCave.errMsg,
# Line 72 | Line 81 | void SimInfo::refreshSim(){
81   #endif // is_mpi
82   }
83  
75 void wrapSimInfo(void (*fSub)( simtype*, int* )){
76  
77  currentInfo->setInternal(fSub);
78 }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines