--- trunk/src/brains/SimInfo.cpp 2014/04/15 20:36:19 1983 +++ trunk/src/brains/SimInfo.cpp 2015/03/07 21:41:51 2071 @@ -70,16 +70,17 @@ namespace OpenMD { SimInfo::SimInfo(ForceField* ff, Globals* simParams) : forceField_(ff), simParams_(simParams), - ndf_(0), fdf_local(0), ndfRaw_(0), ndfTrans_(0), nZconstraint_(0), + nAtoms_(0), nBonds_(0), nBends_(0), nTorsions_(0), nInversions_(0), + nRigidBodies_(0), nIntegrableObjects_(0), nCutoffGroups_(0), + nConstraints_(0), nFluctuatingCharges_(0), nGlobalMols_(0), nGlobalAtoms_(0), nGlobalCutoffGroups_(0), nGlobalIntegrableObjects_(0), nGlobalRigidBodies_(0), nGlobalFluctuatingCharges_(0), nGlobalBonds_(0), nGlobalBends_(0), nGlobalTorsions_(0), nGlobalInversions_(0), nGlobalConstraints_(0), - nAtoms_(0), nBonds_(0), nBends_(0), nTorsions_(0), nInversions_(0), - nRigidBodies_(0), nIntegrableObjects_(0), nCutoffGroups_(0), - nConstraints_(0), nFluctuatingCharges_(0), sman_(NULL), - topologyDone_(false), calcBoxDipole_(false), useAtomicVirial_(true), - hasNGlobalConstraints_(false) { + hasNGlobalConstraints_(false), + ndf_(0), fdf_local(0), ndfRaw_(0), ndfTrans_(0), nZconstraint_(0), + sman_(NULL), topologyDone_(false), calcBoxDipole_(false), + calcBoxQuadrupole_(false), useAtomicVirial_(true) { MoleculeStamp* molStamp; int nMolWithSameStamp; @@ -751,7 +752,6 @@ namespace OpenMD { int nproc; MPI_Comm_size( MPI_COMM_WORLD, &nproc); - // int nproc = MPI::COMM_WORLD.Get_size(); // we need arrays to hold the counts and displacement vectors for // all processors @@ -761,8 +761,6 @@ namespace OpenMD { // fill the counts array MPI_Allgather(&count_local, 1, MPI_INT, &counts[0], 1, MPI_INT, MPI_COMM_WORLD); - // MPI::COMM_WORLD.Allgather(&count_local, 1, MPI::INT, &counts[0], - // 1, MPI::INT); // use the processor counts to compute the displacement array disps[0] = 0; @@ -779,9 +777,6 @@ namespace OpenMD { MPI_Allgatherv(&foundTypes[0], count_local, MPI_INT, &ftGlobal[0], &counts[0], &disps[0], MPI_INT, MPI_COMM_WORLD); - // MPI::COMM_WORLD.Allgatherv(&foundTypes[0], count_local, MPI::INT, - // &ftGlobal[0], &counts[0], &disps[0], - // MPI::INT); vector::iterator j; @@ -828,6 +823,13 @@ namespace OpenMD { if ( simParams_->getAccumulateBoxDipole() ) { calcBoxDipole_ = true; } + // we only call setAccumulateBoxQuadrupole if the accumulateBoxQuadrupole + // parameter is true + calcBoxQuadrupole_ = false; + if ( simParams_->haveAccumulateBoxQuadrupole() ) + if ( simParams_->getAccumulateBoxQuadrupole() ) { + calcBoxQuadrupole_ = true; + } set::iterator i; set atomTypes;