449 |
|
Molecule::CutoffGroupIterator ci; |
450 |
|
CutoffGroup* cg; |
451 |
|
|
452 |
< |
// forces are zeroed here, before any are accumulated. |
452 |
> |
// forces and potentials are zeroed here, before any are |
453 |
> |
// accumulated. |
454 |
|
|
455 |
+ |
Snapshot* snap = info_->getSnapshotManager()->getCurrentSnapshot(); |
456 |
+ |
|
457 |
+ |
snap->setBondPotential(0.0); |
458 |
+ |
snap->setBendPotential(0.0); |
459 |
+ |
snap->setTorsionPotential(0.0); |
460 |
+ |
snap->setInversionPotential(0.0); |
461 |
+ |
|
462 |
+ |
potVec zeroPot(0.0); |
463 |
+ |
snap->setLongRangePotential(zeroPot); |
464 |
+ |
snap->setExcludedPotentials(zeroPot); |
465 |
+ |
|
466 |
+ |
snap->setRestraintPotential(0.0); |
467 |
+ |
snap->setRawPotential(0.0); |
468 |
+ |
|
469 |
|
for (mol = info_->beginMolecule(mi); mol != NULL; |
470 |
|
mol = info_->nextMolecule(mi)) { |
471 |
|
for(atom = mol->beginAtom(ai); atom != NULL; |
623 |
|
curSnapshot->setTorsionPotential(torsionPotential); |
624 |
|
curSnapshot->setInversionPotential(inversionPotential); |
625 |
|
|
626 |
< |
RealType shortRangePotential = bondPotential + bendPotential + |
627 |
< |
torsionPotential + inversionPotential; |
626 |
> |
// RealType shortRangePotential = bondPotential + bendPotential + |
627 |
> |
// torsionPotential + inversionPotential; |
628 |
|
|
629 |
< |
curSnapshot->setShortRangePotential(shortRangePotential); |
629 |
> |
// curSnapshot->setShortRangePotential(shortRangePotential); |
630 |
|
} |
631 |
|
|
632 |
|
void ForceManager::longRangeInteractions() { |
896 |
|
longRangePotential = *(fDecomp_->getEmbeddingPotential()) + |
897 |
|
*(fDecomp_->getPairwisePotential()); |
898 |
|
|
899 |
< |
curSnapshot->setLongRangePotentialFamilies(longRangePotential); |
899 |
> |
curSnapshot->setLongRangePotential(longRangePotential); |
900 |
|
|
901 |
< |
lrPot = longRangePotential.sum(); |
901 |
> |
// lrPot = longRangePotential.sum(); |
902 |
|
|
903 |
< |
//store the long range potential |
904 |
< |
curSnapshot->setLongRangePotential(lrPot); |
903 |
> |
// //store the long range potential |
904 |
> |
// curSnapshot->setLongRangePotential(lrPot); |
905 |
|
|
906 |
|
curSnapshot->setExcludedPotentials(*(fDecomp_->getExcludedSelfPotential()) + |
907 |
|
*(fDecomp_->getExcludedPotential())); |
915 |
|
Molecule::RigidBodyIterator rbIter; |
916 |
|
RigidBody* rb; |
917 |
|
Snapshot* curSnapshot = info_->getSnapshotManager()->getCurrentSnapshot(); |
918 |
< |
|
918 |
> |
|
919 |
|
// collect the atomic forces onto rigid bodies |
920 |
|
|
921 |
|
for (mol = info_->beginMolecule(mi); mol != NULL; |