--- branches/development/src/parallel/ForceDecomposition.cpp 2011/06/16 22:00:08 1583 +++ branches/development/src/parallel/ForceDecomposition.cpp 2011/09/14 21:15:17 1629 @@ -89,9 +89,10 @@ namespace OpenMD { void ForceDecomposition::fillSelfData(SelfData &sdat, int atom1) { - sdat.atype = ff_->getAtomType(idents[atom1]); - - // Still Missing skippedCharge + sdat.atype = atypesLocal[atom1]; + + sdat.pot = &embeddingPot; + if (storageLayout_ & DataStorage::dslElectroFrame) { sdat.eFrame = &(snap_->atomData.electroFrame[atom1]); } @@ -112,6 +113,10 @@ namespace OpenMD { sdat.dfrhodrho = &(snap_->atomData.functionalDerivative[atom1]); } + if (storageLayout_ & DataStorage::dslSkippedCharge) { + sdat.skippedCharge = &(snap_->atomData.skippedCharge[atom1]); + } + if (storageLayout_ & DataStorage::dslParticlePot) { sdat.particlePot = &(snap_->atomData.particlePot[atom1]); } @@ -124,10 +129,7 @@ namespace OpenMD { // if we have changed the group identities or haven't set up the // saved positions we automatically will need a neighbor list update: - if ( saved_CG_positions_.size() != nGroups ) { - cerr << "build because size\n"; - return true; - } + if ( saved_CG_positions_.size() != nGroups ) return true; RealType dispmax = 0.0; Vector3d disp; @@ -146,12 +148,9 @@ namespace OpenMD { dispmax = 2.0 * sqrt (3.0 * dispmax * dispmax); - if (dispmax > skinThickness_) { - cerr << "build because movement\n"; + if (dispmax > skinThickness_) return (dispmax > skinThickness_); - } else { - cerr << "not rebuilding\n"; - } + return false; } }