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

Comparing branches/development/src/nonbonded/Morse.cpp (file contents):
Revision 1535 by gezelter, Sun Oct 3 22:18:59 2010 UTC vs.
Revision 1536 by gezelter, Wed Jan 5 14:49:05 2011 UTC

# Line 142 | Line 142 | namespace OpenMD {
142      }    
143    }
144    
145 <  void Morse::calcForce(InteractionData idat) {
145 >  void Morse::calcForce(InteractionData &idat) {
146  
147      if (!initialized_) initialize();
148      
# Line 221 | Line 221 | namespace OpenMD {
221        }
222        
223        RealType pot_temp = idat.vdwMult * (myPot - myPotC);
224 <      idat.vpair += pot_temp;
224 >      idat.vpair[0] += pot_temp;
225        
226        RealType dudr = idat.sw * idat.vdwMult * (myDeriv - myDerivC);
227        
228 <      idat.pot += idat.sw * pot_temp;
228 >      idat.pot[0] += idat.sw * pot_temp;
229        idat.f1 = idat.d * dudr / idat.rij;
230      }
231      return;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines