--- trunk/OOPSE/libmdtools/EAM_FF.cpp 2003/11/10 21:50:36 859 +++ trunk/OOPSE/libmdtools/EAM_FF.cpp 2004/06/02 18:27:52 1224 @@ -228,12 +228,14 @@ EAM_FF::EAM_FF(){ frcFile = fopen( fileName, "r" ); if( frcFile == NULL ){ - + sprintf( painCave.errMsg, - "Error opening the force field parameter file: %s\n" - "Have you tried setting the FORCE_PARAM_PATH environment " - "vairable?\n", + "Error opening the force field parameter file:\n" + "\t%s\n" + "\tHave you tried setting the FORCE_PARAM_PATH environment " + "variable?\n", fileName ); + painCave.severity = OOPSE_ERROR; painCave.isFatal = 1; simError(); } @@ -267,7 +269,7 @@ void EAM_FF::calcRcut( void ){ void EAM_FF::calcRcut( void ){ - #ifdef IS_MPI +#ifdef IS_MPI double tempEamRcut = eamRcut; MPI_Allreduce( &tempEamRcut, &eamRcut, 1, MPI_DOUBLE, MPI_MAX, MPI_COMM_WORLD); @@ -407,7 +409,7 @@ void EAM_FF::readParams( void ){ MPIcheckPoint(); headAtomType = new LinkedAtomType; - recieveFrcStruct( &info, mpiAtomStructType ); + receiveFrcStruct( &info, mpiAtomStructType ); while( !info.last ){ @@ -433,7 +435,7 @@ void EAM_FF::readParams( void ){ MPIcheckPoint(); - recieveFrcStruct( &info, mpiAtomStructType ); + receiveFrcStruct( &info, mpiAtomStructType ); } @@ -449,8 +451,10 @@ void EAM_FF::readParams( void ){ int isDipole = 0; int isSSD = 0; int isGB = 0; - int isEAM= 1; + int isEAM = 1; + int isCharge = 0; double dipole = 0.0; + double charge = 0.0; double eamSigma = 0.0; double eamEpslon = 0.0; @@ -465,8 +469,10 @@ void EAM_FF::readParams( void ){ &isDipole, &isGB, &isEAM, + &isCharge, &eamEpslon, &eamSigma, + &charge, &dipole, &isError ); if( isError ){ @@ -544,11 +550,9 @@ void EAM_FF::initializeAtoms( int nAtoms, Atom** the_a the_atoms[i]->setMass( currentAtomType->mass ); the_atoms[i]->setIdent( currentAtomType->ident ); - the_atoms[i]->setEAM(); - the_atoms[i]->setEamRcut( currentAtomType->eam_rcut); if (eamRcut < currentAtomType->eam_rcut) eamRcut = currentAtomType->eam_rcut; - + } } @@ -725,7 +729,7 @@ int EAM_NS::parseEAM(atomStruct &info, char *eamPotFil sprintf( painCave.errMsg, "Error opening the EAM force parameter file: %s\n" "Have you tried setting the FORCE_PARAM_PATH environment " - "vairable?\n", + "variable?\n", eamPotFile ); painCave.isFatal = 1; simError();