ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/group/trunk/OOPSE/libmdtools/Symplectic.cpp
(Generate patch)

Comparing trunk/OOPSE/libmdtools/Symplectic.cpp (file contents):
Revision 466 by gezelter, Mon Apr 7 14:30:36 2003 UTC vs.
Revision 468 by gezelter, Mon Apr 7 16:56:38 2003 UTC

# Line 184 | Line 184 | void Symplectic::integrate( void ){
184    int status_n = (int)( statusTime / dt );
185    int vel_n    = (int)( thermalTime / dt );
186  
187 <  int calcPot;
187 >  int calcPot, calcStress;
188  
189     Thermo *tStats = new Thermo( entry_plug );
190  
# Line 197 | Line 197 | void Symplectic::integrate( void ){
197  
198    // initialize the forces the before the first step
199  
200 <  myFF->doForces(1,0);
200 >  myFF->doForces(1,1);
201    
202    if( entry_plug->setTemp ){
203      
# Line 325 | Line 325 | void Symplectic::integrate( void ){
325        
326        // calculate the forces
327        
328 <      myFF->doForces(calcPot, 0);
328 >      myFF->doForces(calcPot, calcStress);
329        
330        // move b
331  
# Line 396 | Line 396 | void Symplectic::integrate( void ){
396          if( !(time % vel_n) ) tStats->velocitize();
397        }
398        if( !(time % sample_n) ) dump_out->writeDump( time * dt );
399 <      if( !((time+1) % status_n) ) calcPot = 1;
400 <      if( !(time % status_n) ){ e_out->writeStat( time * dt ); calcPot = 0; }
399 >      if( !((time+1) % status_n) ) {
400 >        calcPot = 1;
401 >        calcStress = 1;
402 >      }
403 >      if( !(time % status_n) ){
404 >        e_out->writeStat( time * dt );
405 >        calcPot = 0;
406 >        calcStress = 0;
407 >      }
408      }
409    }
410    else{
# Line 495 | Line 502 | void Symplectic::integrate( void ){
502        
503        // calculate the forces
504        
505 <      myFF->doForces(calcPot,0);
505 >      myFF->doForces(calcPot,calcStress);
506        
507        for( i=0; i< nAtoms; i++ ){
508          
# Line 554 | Line 561 | void Symplectic::integrate( void ){
561          if( !(time % vel_n) ) tStats->velocitize();
562        }
563        if( !(time % sample_n) ) dump_out->writeDump( time * dt );
564 <      if( !((time+1) % status_n) ) calcPot = 1;
565 <      if( !(time % status_n) ){ e_out->writeStat( time * dt ); calcPot = 0; }
564 >      if( !((time+1) % status_n) ) {
565 >        calcPot = 1;
566 >        calcStress = 1;
567 >      }
568 >      if( !(time % status_n) ){
569 >        e_out->writeStat( time * dt );
570 >        calcPot = 0;
571 >        calcStress = 0;
572 >      }      
573      }
574    }
575  

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines