| 90 |
|
#endif // is_mpi |
| 91 |
|
|
| 92 |
|
void SimSetup::createSim(void){ |
| 93 |
– |
int i, j, k, globalAtomIndex; |
| 93 |
|
|
| 94 |
|
// gather all of the information from the Bass file |
| 95 |
|
|
| 107 |
|
|
| 108 |
|
if (!isInfoArray){ |
| 109 |
|
initSystemCoords(); |
| 110 |
+ |
|
| 111 |
+ |
if( !(globals->getUseInitTime()) ) |
| 112 |
+ |
info[0].currentTime = 0.0; |
| 113 |
|
} |
| 114 |
|
|
| 115 |
|
// make the output filenames |
| 131 |
|
|
| 132 |
|
|
| 133 |
|
void SimSetup::makeMolecules(void){ |
| 134 |
< |
int k, l; |
| 134 |
> |
int k; |
| 135 |
|
int i, j, exI, exJ, tempEx, stampID, atomOffset, excludeOffset; |
| 136 |
|
molInit molInfo; |
| 137 |
|
DirectionalAtom* dAtom; |
| 553 |
|
|
| 554 |
|
|
| 555 |
|
void SimSetup::gatherInfo(void){ |
| 556 |
< |
int i, j, k; |
| 556 |
> |
int i; |
| 557 |
|
|
| 558 |
|
ensembleCase = -1; |
| 559 |
|
ffCase = -1; |
| 916 |
|
if (worldRank == 0){ |
| 917 |
|
#endif //is_mpi |
| 918 |
|
inName = globals->getInitialConfig(); |
| 917 |
– |
double* tempDouble = new double[1000000]; |
| 919 |
|
fileInit = new InitializeFromFile(inName); |
| 920 |
|
#ifdef IS_MPI |
| 921 |
|
} |
| 933 |
|
|
| 934 |
|
sprintf(painCave.errMsg, |
| 935 |
|
"Cannot intialize a parallel simulation without an initial configuration file.\n"); |
| 936 |
< |
painCave.isFatal; |
| 936 |
> |
painCave.isFatal = 1;; |
| 937 |
|
simError(); |
| 938 |
|
|
| 939 |
|
#else |
| 1159 |
|
} |
| 1160 |
|
|
| 1161 |
|
void SimSetup::calcSysValues(void){ |
| 1162 |
< |
int i, j, k; |
| 1162 |
> |
int i; |
| 1163 |
|
|
| 1164 |
|
int* molMembershipArray; |
| 1165 |
|
|
| 1258 |
|
|
| 1259 |
|
|
| 1260 |
|
void SimSetup::makeSysArrays(void){ |
| 1261 |
< |
int i, j, k, l; |
| 1261 |
> |
|
| 1262 |
> |
#ifndef IS_MPI |
| 1263 |
> |
int k, j; |
| 1264 |
> |
#endif // is_mpi |
| 1265 |
> |
int i, l; |
| 1266 |
|
|
| 1267 |
|
Atom** the_atoms; |
| 1268 |
|
Molecule* the_molecules; |
| 1345 |
|
void SimSetup::makeIntegrator(void){ |
| 1346 |
|
int k; |
| 1347 |
|
|
| 1348 |
+ |
NVE<RealIntegrator>* myNVE = NULL; |
| 1349 |
|
NVT<RealIntegrator>* myNVT = NULL; |
| 1350 |
|
NPTi<NPT<RealIntegrator> >* myNPTi = NULL; |
| 1351 |
|
NPTf<NPT<RealIntegrator> >* myNPTf = NULL; |
| 1355 |
|
case NVE_ENS: |
| 1356 |
|
if (globals->haveZconstraints()){ |
| 1357 |
|
setupZConstraint(info[k]); |
| 1358 |
< |
new ZConstraint<NVE<RealIntegrator> >(&(info[k]), the_ff); |
| 1358 |
> |
myNVE = new ZConstraint<NVE<RealIntegrator> >(&(info[k]), the_ff); |
| 1359 |
|
} |
| 1360 |
< |
else |
| 1361 |
< |
new NVE<RealIntegrator>(&(info[k]), the_ff); |
| 1360 |
> |
else{ |
| 1361 |
> |
myNVE = new NVE<RealIntegrator>(&(info[k]), the_ff); |
| 1362 |
> |
} |
| 1363 |
> |
|
| 1364 |
> |
info->the_integrator = myNVE; |
| 1365 |
|
break; |
| 1366 |
|
|
| 1367 |
|
case NVT_ENS: |
| 1383 |
|
painCave.isFatal = 1; |
| 1384 |
|
simError(); |
| 1385 |
|
} |
| 1386 |
+ |
|
| 1387 |
+ |
info->the_integrator = myNVT; |
| 1388 |
|
break; |
| 1389 |
|
|
| 1390 |
|
case NPTi_ENS: |
| 1426 |
|
painCave.isFatal = 1; |
| 1427 |
|
simError(); |
| 1428 |
|
} |
| 1429 |
+ |
|
| 1430 |
+ |
info->the_integrator = myNPTi; |
| 1431 |
|
break; |
| 1432 |
|
|
| 1433 |
|
case NPTf_ENS: |
| 1469 |
|
painCave.isFatal = 1; |
| 1470 |
|
simError(); |
| 1471 |
|
} |
| 1472 |
+ |
|
| 1473 |
+ |
info->the_integrator = myNPTf; |
| 1474 |
|
break; |
| 1475 |
|
|
| 1476 |
|
default: |