--- trunk/OOPSE/libmdtools/StatWriter.cpp 2004/05/27 20:06:38 1207 +++ trunk/OOPSE/libmdtools/StatWriter.cpp 2004/06/01 17:15:43 1212 @@ -36,7 +36,7 @@ StatWriter::StatWriter( SimInfo* the_entry_plug ){ //outFile.setf( ios::scientific ); outFile << "#time(fs)\ttot_E\tpotential\tkinetic\ttemperature\tpressure\tvolume\tconserved quantity\n"; - if (entry_plug->useThermInt) { + if (entry_plug->useSolidThermInt && !entry_plug->useLiquidThermInt) { rawFile.open(rawName, ios::out | ios::trunc ); if( !rawFile ){ @@ -51,6 +51,34 @@ StatWriter::StatWriter( SimInfo* the_entry_plug ){ rawFile << "#time(fs)\tRaw Pot\t Raw Harm\n"; } + if (entry_plug->useLiquidThermInt) { + if (entry_plug->useSolidThermInt) { + sprintf( painCave.errMsg, + "It appears that you have both solid and liquid thermodynamic\n" + "integration activated in your .bass file. To avoid confusion,\n" + "specify only one technique in your .bass file. Liquid-state\n" + "thermodynamic integration will be assumed for the current\n" + "simulation. If this is not what you desire, set useSolidThermInt\n" + "to 'true' and useLiquidThermInt to 'false' in your .bass file.", + rawName); + painCave.isFatal = 0; + simError(); + } + + rawFile.open(rawName, ios::out | ios::trunc ); + + if( !rawFile ){ + + sprintf( painCave.errMsg, + "Could not open \"%s\" for stat output.\n", + rawName); + painCave.isFatal = 1; + simError(); + } + + rawFile << "#time(fs)\tRaw Pot\n"; + } + #ifdef IS_MPI }