ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/OpenMD/branches/development/src/parallel/ForceMatrixDecomposition.cpp
(Generate patch)

Comparing branches/development/src/parallel/ForceMatrixDecomposition.cpp (file contents):
Revision 1803 by gezelter, Wed Oct 3 14:20:07 2012 UTC vs.
Revision 1849 by gezelter, Wed Feb 20 13:52:51 2013 UTC

# Line 679 | Line 679 | namespace OpenMD {
679          snap_->atomData.density[i] += rho_tmp[i];
680      }
681  
682 +    // this isn't necessary if we don't have polarizable atoms, but
683 +    // we'll leave it here for now.
684      if (storageLayout_ & DataStorage::dslElectricField) {
685        
686        AtomPlanVectorRow->scatter(atomRowData.electricField,
# Line 785 | Line 787 | namespace OpenMD {
787        for (int i = 0; i < nq; i++)
788          snap_->atomData.flucQFrc[i] += fqfrc_tmp[i];
789              
790 +    }
791 +
792 +    if (storageLayout_ & DataStorage::dslElectricField) {
793 +
794 +      int nef = snap_->atomData.electricField.size();
795 +      vector<Vector3d> efield_tmp(nef, V3Zero);
796 +
797 +      AtomPlanVectorRow->scatter(atomRowData.electricField, efield_tmp);
798 +      for (int i = 0; i < nef; i++) {
799 +        snap_->atomData.electricField[i] += efield_tmp[i];
800 +        efield_tmp[i] = 0.0;
801 +      }
802 +      
803 +      AtomPlanVectorColumn->scatter(atomColData.electricField, efield_tmp);
804 +      for (int i = 0; i < nef; i++)
805 +        snap_->atomData.electricField[i] += efield_tmp[i];
806      }
807 +
808  
809      nLocal_ = snap_->getNumberOfAtoms();
810  
# Line 1186 | Line 1205 | namespace OpenMD {
1205        idat.A1 = &(snap_->atomData.aMat[atom1]);
1206        idat.A2 = &(snap_->atomData.aMat[atom2]);
1207      }
1208 +
1209 +    RealType ct = dot(idat.A1->getColumn(2), idat.A2->getColumn(2));
1210  
1211      if (storageLayout_ & DataStorage::dslTorque) {
1212        idat.t1 = &(snap_->atomData.torque[atom1]);
# Line 1306 | Line 1327 | namespace OpenMD {
1327   #endif
1328  
1329      RealType rList_ = (largestRcut_ + skinThickness_);
1309    RealType rl2 = rList_ * rList_;
1330      Snapshot* snap_ = sman_->getCurrentSnapshot();
1331      Mat3x3d Hmat = snap_->getHmat();
1332      Vector3d Hx = Hmat.getColumn(0);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines