183 |
|
BendStamp* currentBend; |
184 |
|
TorsionStamp* currentTorsion; |
185 |
|
RigidBodyStamp* currentRigidBody; |
186 |
< |
|
186 |
> |
CutoffGroupStamp* currentCutoffGroup; |
187 |
> |
CutoffGroup* myCutoffGroup; |
188 |
> |
|
189 |
|
bond_pair* theBonds; |
190 |
|
bend_set* theBends; |
191 |
|
torsion_set* theTorsions; |
218 |
|
molInfo.nBends = comp_stamps[stampID]->getNBends(); |
219 |
|
molInfo.nTorsions = comp_stamps[stampID]->getNTorsions(); |
220 |
|
molInfo.nRigidBodies = comp_stamps[stampID]->getNRigidBodies(); |
221 |
+ |
molInfo.nCutoffGroups = comp_stamps[stampID]->getNCutoffGroups(); |
222 |
|
|
223 |
|
molInfo.myAtoms = &(info[k].atoms[atomOffset]); |
224 |
|
|
483 |
|
info[k].rigidBodies.push_back(myRB); |
484 |
|
} |
485 |
|
|
486 |
+ |
|
487 |
+ |
//creat cutoff group for molecule |
488 |
+ |
molInfo.myCutoffGroups.clear(); |
489 |
+ |
for (j = 0; j < molInfo.nCutoffGroups; j++){ |
490 |
+ |
|
491 |
+ |
currentCutoffGroup = comp_stamps[stampID]->getCutoffGroup(j); |
492 |
+ |
nMembers = currentCutoffGroup->getNMembers(); |
493 |
|
|
494 |
+ |
myCutoffGroup = new CutoffGroup(); |
495 |
+ |
|
496 |
+ |
for (int cg = 0; cg < nMembers; cg++) { |
497 |
+ |
|
498 |
+ |
// molI is atom numbering inside this molecule |
499 |
+ |
molI = currentCutoffGroup->getMember(cg); |
500 |
+ |
|
501 |
+ |
// tempI is atom numbering on local processor |
502 |
+ |
tempI = molI + atomOffset; |
503 |
+ |
|
504 |
+ |
myCutoffGroup->addAtom(info[k].atoms[tempI]); |
505 |
+ |
} |
506 |
+ |
|
507 |
+ |
molInfo.myCutoffGroups.push_back(myCutoffGroup); |
508 |
+ |
}//end for (j = 0; j < molInfo.nCutoffGroups; j++) |
509 |
+ |
|
510 |
+ |
|
511 |
+ |
|
512 |
|
// After this is all set up, scan through the atoms to |
513 |
|
// see if they can be added to the integrableObjects: |
514 |
|
|
1310 |
|
LinkedMolStamp* headStamp = new LinkedMolStamp(); |
1311 |
|
LinkedMolStamp* currentStamp = NULL; |
1312 |
|
comp_stamps = new MoleculeStamp * [n_components]; |
1313 |
+ |
bool haveCutoffGroups; |
1314 |
|
|
1315 |
+ |
haveCutoffGroups = false; |
1316 |
+ |
|
1317 |
|
// make an array of molecule stamps that match the components used. |
1318 |
|
// also extract the used stamps out into a separate linked list |
1319 |
|
|
1348 |
|
headStamp->add(currentStamp); |
1349 |
|
comp_stamps[i] = headStamp->match(id); |
1350 |
|
} |
1351 |
+ |
|
1352 |
+ |
if(comp_stamps[i]->getNCutoffGroups() > 0) |
1353 |
+ |
haveCutoffGroups = true; |
1354 |
|
} |
1355 |
+ |
|
1356 |
+ |
for (i = 0; i < nInfo; i++) |
1357 |
+ |
info[i].haveCutoffGroups = haveCutoffGroups; |
1358 |
|
|
1359 |
|
#ifdef IS_MPI |
1360 |
|
strcpy(checkPointMsg, "Component stamps successfully extracted\n"); |
1529 |
|
info[l].atoms = the_atoms; |
1530 |
|
info[l].molecules = the_molecules; |
1531 |
|
info[l].nGlobalExcludes = 0; |
1532 |
< |
|
1532 |
> |
|
1533 |
|
the_ff->setSimInfo(info); |
1534 |
|
} |
1535 |
|
} |