--- trunk/OOPSE/libmdtools/ForceFields.cpp 2003/03/27 20:12:15 423 +++ trunk/OOPSE/libmdtools/ForceFields.cpp 2003/03/31 21:50:59 438 @@ -2,6 +2,7 @@ #ifdef IS_MPI #include +#include #endif // is_mpi @@ -20,7 +21,7 @@ void ForceFields::calcRcut( void ){ //calc rCut and rList - entry_plug->rCut = 2.5 bigSigma; + entry_plug->rCut = 2.5 * bigSigma; if(entry_plug->rCut > (entry_plug->box_x / 2.0)) entry_plug->rCut = entry_plug->box_x / 2.0; if(entry_plug->rCut > (entry_plug->box_y / 2.0)) @@ -53,7 +54,7 @@ void ForceFields::doForces( int calcPot, int calcStres } for(i=0; in_mol; i++ ){ - entry_plug->molecules[i]->calc_forces(); + entry_plug->molecules[i].calcForces(); } frc = Atom::getFrcArray(); @@ -61,12 +62,13 @@ void ForceFields::doForces( int calcPot, int calcStres trq = Atom::getTrqArray(); A = Atom::getAmatArray(); u_l = Atom::getUlArray(); - tau = entry_plug->tau; - + + isError = 0; entry_plug->lrPot = 0.0; + fortranForceLoop( pos, A, @@ -80,6 +82,8 @@ void ForceFields::doForces( int calcPot, int calcStres &isError ); + + if( isError ){ sprintf( painCave.errMsg, "Error returned from the fortran force calculation.\n" );