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

Comparing trunk/OOPSE/libmdtools/EAM_FF.cpp (file contents):
Revision 829 by gezelter, Tue Oct 28 16:03:37 2003 UTC vs.
Revision 1224 by gezelter, Wed Jun 2 18:27:52 2004 UTC

# Line 228 | Line 228 | EAM_FF::EAM_FF(){
228        frcFile = fopen( fileName, "r" );
229        
230        if( frcFile == NULL ){
231 <        
231 >
232          sprintf( painCave.errMsg,
233 <                 "Error opening the force field parameter file: %s\n"
234 <                 "Have you tried setting the FORCE_PARAM_PATH environment "
235 <                 "vairable?\n",
233 >                 "Error opening the force field parameter file:\n"
234 >                 "\t%s\n"
235 >                 "\tHave you tried setting the FORCE_PARAM_PATH environment "
236 >                 "variable?\n",
237                   fileName );
238 +        painCave.severity = OOPSE_ERROR;
239          painCave.isFatal = 1;
240          simError();
241        }
# Line 267 | Line 269 | void EAM_FF::calcRcut( void ){
269  
270   void EAM_FF::calcRcut( void ){
271    
272 <  #ifdef IS_MPI
272 > #ifdef IS_MPI
273    double tempEamRcut = eamRcut;
274    MPI_Allreduce( &tempEamRcut, &eamRcut, 1, MPI_DOUBLE, MPI_MAX,
275                   MPI_COMM_WORLD);
276   #endif  //is_mpi
277 <  entry_plug->setRcut(eamRcut);
277 >  entry_plug->setDefaultRcut(eamRcut);
278   }
279  
280  
# Line 407 | Line 409 | void EAM_FF::readParams( void ){
409      MPIcheckPoint();
410  
411      headAtomType = new LinkedAtomType;
412 <    recieveFrcStruct( &info, mpiAtomStructType );
412 >    receiveFrcStruct( &info, mpiAtomStructType );
413  
414      while( !info.last ){
415        
# Line 433 | Line 435 | void EAM_FF::readParams( void ){
435        
436        MPIcheckPoint();
437  
438 <      recieveFrcStruct( &info, mpiAtomStructType );
438 >      receiveFrcStruct( &info, mpiAtomStructType );
439  
440  
441      }
# Line 449 | Line 451 | void EAM_FF::readParams( void ){
451    int isDipole = 0;
452    int isSSD = 0;
453    int isGB = 0;
454 <  int isEAM= 1;
454 >  int isEAM = 1;
455 >  int isCharge = 0;
456    double dipole = 0.0;
457 +  double charge = 0.0;
458    double eamSigma = 0.0;
459    double eamEpslon = 0.0;
460    
# Line 465 | Line 469 | void EAM_FF::readParams( void ){
469                   &isDipole,
470                   &isGB,
471                   &isEAM,
472 +                 &isCharge,
473                   &eamEpslon,
474                   &eamSigma,
475 +                 &charge,
476                   &dipole,
477                   &isError );
478        if( isError ){
# Line 544 | Line 550 | void EAM_FF::initializeAtoms( int nAtoms, Atom** the_a
550      
551      the_atoms[i]->setMass( currentAtomType->mass );
552      the_atoms[i]->setIdent( currentAtomType->ident );
547    the_atoms[i]->setEAM();
548    the_atoms[i]->setEamRcut( currentAtomType->eam_rcut);
553  
554      if (eamRcut < currentAtomType->eam_rcut) eamRcut = currentAtomType->eam_rcut;
555 <
555 >    
556    }
557   }
558  
# Line 725 | Line 729 | int EAM_NS::parseEAM(atomStruct &info, char *eamPotFil
729        sprintf( painCave.errMsg,
730                 "Error opening the EAM force parameter file: %s\n"
731                 "Have you tried setting the FORCE_PARAM_PATH environment "
732 <               "vairable?\n",
732 >               "variable?\n",
733                 eamPotFile );
734        painCave.isFatal = 1;
735        simError();

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines