| 116 |
|
void printMe( void ){ |
| 117 |
|
|
| 118 |
|
std::cerr << "LinkedAtype " << name << ": ident = " << ident << "\n"; |
| 119 |
< |
if( next != NULL ) next->printMe(); |
| 119 |
> |
// if( next != NULL ) next->printMe(); |
| 120 |
|
|
| 121 |
|
} |
| 122 |
|
|
| 477 |
|
// Init the atomStruct mpi type |
| 478 |
|
|
| 479 |
|
atomStruct atomProto; // mpiPrototype |
| 480 |
< |
int atomBC[3] = {15,11,4}; // block counts |
| 480 |
> |
int atomBC[3] = {15,12,5}; // block counts |
| 481 |
|
MPI_Aint atomDspls[3]; // displacements |
| 482 |
|
MPI_Datatype atomMbrTypes[3]; // member mpi types |
| 483 |
|
|
| 730 |
|
currentAtomType = headAtomType->next; //skip the first element who is a place holder. |
| 731 |
|
while( currentAtomType != NULL ){ |
| 732 |
|
currentAtomType->duplicate( atomInfo ); |
| 733 |
– |
|
| 734 |
– |
|
| 733 |
|
|
| 734 |
|
sendFrcStruct( &atomInfo, mpiAtomStructType ); |
| 735 |
|
|
| 748 |
|
else{ |
| 749 |
|
|
| 750 |
|
// listen for node 0 to send out the force params |
| 751 |
< |
|
| 751 |
> |
|
| 752 |
|
MPIcheckPoint(); |
| 753 |
|
|
| 754 |
|
headAtomType = new LinkedAtomType; |
| 755 |
< |
recieveFrcStruct( &atomInfo, mpiAtomStructType ); |
| 755 |
> |
receiveFrcStruct( &atomInfo, mpiAtomStructType ); |
| 756 |
|
|
| 757 |
|
while( !atomInfo.last ){ |
| 760 |
– |
|
| 761 |
– |
|
| 758 |
|
|
| 759 |
|
headAtomType->add( atomInfo ); |
| 760 |
|
|
| 761 |
|
MPIcheckPoint(); |
| 762 |
|
|
| 763 |
< |
recieveFrcStruct( &atomInfo, mpiAtomStructType ); |
| 763 |
> |
receiveFrcStruct( &atomInfo, mpiAtomStructType ); |
| 764 |
|
} |
| 765 |
|
} |
| 766 |
|
|
| 894 |
|
MPIcheckPoint(); |
| 895 |
|
|
| 896 |
|
headBondType = new LinkedBondType; |
| 897 |
< |
recieveFrcStruct( &bondInfo, mpiBondStructType ); |
| 897 |
> |
receiveFrcStruct( &bondInfo, mpiBondStructType ); |
| 898 |
|
while( !bondInfo.last ){ |
| 899 |
|
|
| 900 |
|
headBondType->add( bondInfo ); |
| 901 |
< |
recieveFrcStruct( &bondInfo, mpiBondStructType ); |
| 901 |
> |
receiveFrcStruct( &bondInfo, mpiBondStructType ); |
| 902 |
|
} |
| 903 |
|
} |
| 904 |
|
|
| 922 |
|
fastForward( "BendTypes", "initializeBends" ); |
| 923 |
|
|
| 924 |
|
// we are now at the bendTypes section |
| 925 |
< |
|
| 925 |
> |
|
| 926 |
|
eof_test = fgets( readLine, sizeof(readLine), frcFile ); |
| 927 |
|
lineNum++; |
| 928 |
|
|
| 977 |
|
MPIcheckPoint(); |
| 978 |
|
|
| 979 |
|
headBendType = new LinkedBendType; |
| 980 |
< |
recieveFrcStruct( &bendInfo, mpiBendStructType ); |
| 980 |
> |
receiveFrcStruct( &bendInfo, mpiBendStructType ); |
| 981 |
|
while( !bendInfo.last ){ |
| 982 |
|
|
| 983 |
|
headBendType->add( bendInfo ); |
| 984 |
< |
recieveFrcStruct( &bendInfo, mpiBendStructType ); |
| 984 |
> |
receiveFrcStruct( &bendInfo, mpiBendStructType ); |
| 985 |
|
} |
| 986 |
|
} |
| 987 |
|
|
| 1062 |
|
MPIcheckPoint(); |
| 1063 |
|
|
| 1064 |
|
headTorsionType = new LinkedTorsionType; |
| 1065 |
< |
recieveFrcStruct( &torsionInfo, mpiTorsionStructType ); |
| 1065 |
> |
receiveFrcStruct( &torsionInfo, mpiTorsionStructType ); |
| 1066 |
|
while( !torsionInfo.last ){ |
| 1067 |
|
|
| 1068 |
|
headTorsionType->add( torsionInfo ); |
| 1069 |
< |
recieveFrcStruct( &torsionInfo, mpiTorsionStructType ); |
| 1069 |
> |
receiveFrcStruct( &torsionInfo, mpiTorsionStructType ); |
| 1070 |
|
} |
| 1071 |
|
} |
| 1072 |
|
|
| 1120 |
|
// initialize the atoms |
| 1121 |
|
|
| 1122 |
|
DirectionalAtom* dAtom; |
| 1123 |
+ |
double ji[3]; |
| 1124 |
|
|
| 1125 |
|
for(int i=0; i<nAtoms; i++ ){ |
| 1126 |
|
|
| 1134 |
|
} |
| 1135 |
|
|
| 1136 |
|
the_atoms[i]->setMass( currentAtomType->mass ); |
| 1140 |
– |
the_atoms[i]->setEpslon( currentAtomType->epslon ); |
| 1141 |
– |
the_atoms[i]->setSigma( currentAtomType->sigma ); |
| 1137 |
|
the_atoms[i]->setIdent( currentAtomType->ident ); |
| 1143 |
– |
the_atoms[i]->setLJ(); |
| 1138 |
|
|
| 1139 |
|
if( bigSigma < currentAtomType->sigma ) bigSigma = currentAtomType->sigma; |
| 1140 |
|
|
| 1142 |
|
if( the_atoms[i]->isDirectional() ){ |
| 1143 |
|
|
| 1144 |
|
dAtom = (DirectionalAtom *) the_atoms[i]; |
| 1151 |
– |
dAtom->setMu( currentAtomType->dipole ); |
| 1145 |
|
dAtom->setHasDipole( 1 ); |
| 1146 |
< |
dAtom->setJx( 0.0 ); |
| 1147 |
< |
dAtom->setJy( 0.0 ); |
| 1148 |
< |
dAtom->setJz( 0.0 ); |
| 1146 |
> |
|
| 1147 |
> |
ji[0] = 0.0; |
| 1148 |
> |
ji[1] = 0.0; |
| 1149 |
> |
ji[2] = 0.0; |
| 1150 |
> |
|
| 1151 |
> |
dAtom->setJ( ji ); |
| 1152 |
|
|
| 1153 |
|
if(!strcmp("SSD",the_atoms[i]->getType())){ |
| 1154 |
|
dAtom->setI( waterI ); |
| 1159 |
– |
dAtom->setSSD( 1 ); |
| 1155 |
|
} |
| 1156 |
|
else if(!strcmp("HEAD",the_atoms[i]->getType())){ |
| 1157 |
|
dAtom->setI( headI ); |
| 1163 |
– |
dAtom->setSSD( 0 ); |
| 1158 |
|
} |
| 1159 |
|
else{ |
| 1160 |
|
sprintf(painCave.errMsg, |
| 1178 |
|
else{ |
| 1179 |
|
if( the_atoms[i]->isDirectional() ){ |
| 1180 |
|
sprintf( painCave.errMsg, |
| 1181 |
< |
"DUFF error: Atom \"%s\" was given a standard" |
| 1181 |
> |
"DUFF error: Atom \"%s\" was given a standard " |
| 1182 |
|
"orientation in the BASS file, yet it is not a dipole.\n", |
| 1183 |
|
currentAtomType->name); |
| 1184 |
|
painCave.isFatal = 1; |