void OPVACF::newG(const NEventData& PDat) { //This ensures the list stays at accumilator size for (size_t i = 0; i < Sim->N; ++i) G[i].push_front(Sim->particleList[i].getVelocity()); //Go back and fix the pushes BOOST_FOREACH(const ParticleEventData&PDat2, PDat.L1partChanges) G[PDat2.getParticle().getID()].front() = PDat2.getOldVel(); BOOST_FOREACH(const PairEventData& PDat2, PDat.L2partChanges) { G[PDat2.particle1_.getParticle().getID()].front() = PDat2.particle1_.getOldVel(); G[PDat2.particle2_.getParticle().getID()].front() = PDat2.particle2_.getOldVel(); } //This ensures the list gets to accumilator size if (notReady) { if (++currCorrLen != CorrelatorLength) return; notReady = false; } accPass(); }
void OPVACF::ticker() { for (const Particle& part : Sim->particles) velHistory[part.getID()].push_front(part.getVelocity()); if (notReady) { if (++currCorrLength != length) return; notReady = false; } accPass(); }
void OPThermalDiffusionE::newG() { //This ensures the list stays at accumilator size G.push_front (delG); Gsp1.push_front(delGsp1); if (notReady) { if (++currlen != CorrelatorLength) return; notReady = false; } accPass(); }
void OPViscosityE::newG(const matrix& Gval) { for (size_t iDim = 0; iDim < NDIM; ++iDim) for (size_t jDim = 0; jDim < NDIM; ++jDim) avgTrace[iDim][jDim] += Gval[iDim][jDim]; G.push_front(Gval); if (notReady) { if (++currlen != CorrelatorLength) return; notReady = false; } accPass(); }
void OPThermalConductivitySpeciesSpeciesE::newG() { //This ensures the list stays at accumilator size size_t Nsp(Sim->dynamics.getSpecies().size()); for (size_t id(0); id < Nsp; ++id) G[id].push_front(delG[id]); if (notReady) { if (++currlen != CorrelatorLength) return; notReady = false; } accPass(); }
void OPMSDOrientationalCorrelator::ticker() { const std::vector<Dynamics::rotData>& current_rdat(Sim->dynamics->getCompleteRotData()); BOOST_FOREACH(const Particle& part, Sim->particles) { historicalData[part.getID()].push_front(RUpair(part.getPosition(), current_rdat[part.getID()].orientation)); } if (notReady) { if (++currCorrLength != length) { return; } notReady = false; } accPass(); }
void OPVACF::newG(const ParticleEventData& PDat) { if (Sim->dynamics.liouvilleanTypeTest<LSLLOD>()) Sim->dynamics.getLiouvillean().updateAllParticles(); for (size_t i = 0; i < Sim->N; ++i) G[i].push_front(Sim->particleList[i].getVelocity()); //Now correct the fact that the wrong velocity has been pushed G[PDat.getParticle().getID()].front() = PDat.getOldVel(); //This ensures the list gets to accumilator size if (notReady) { if (++currCorrLen != CorrelatorLength) return; notReady = false; } accPass(); }
void OPVACF::newG(const PairEventData& PDat) { for (size_t i = 0; i < Sim->N; ++i) G[i].push_front(Sim->particleList[i].getVelocity()); //Now correct the fact that the wrong velocity has been pushed G[PDat.particle1_.getParticle().getID()].front() = PDat.particle1_.getOldVel(); G[PDat.particle2_.getParticle().getID()].front() = PDat.particle2_.getOldVel(); //This ensures the list gets to accumilator size if (notReady) { if (++currCorrLen != CorrelatorLength) return; notReady = false; } accPass(); }