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

Comparing trunk/OOPSE/libmdtools/SimSetup.cpp (file contents):
Revision 604 by gezelter, Tue Jul 15 03:08:00 2003 UTC vs.
Revision 605 by gezelter, Tue Jul 15 03:27:24 2003 UTC

# Line 788 | Line 788 | void SimSetup::createSim( void ){
788    NPTi* myNPTi = NULL;
789    NPTf* myNPTf = NULL;
790    NPTim* myNPTim = NULL;
791 +  NPTfm* myNPTfm = NULL;
792  
793    switch( ensembleCase ){
794  
# Line 915 | Line 916 | void SimSetup::createSim( void ){
916        simError();
917      }
918      break;
919 +
920 +  case NPTfm_ENS:
921 +    myNPTfm = new NPTfm( simnfo, the_ff );
922 +    myNPTfm->setTargetTemp( the_globals->getTargetTemp());
923  
924 +    if (the_globals->haveTargetPressure())
925 +      myNPTfm->setTargetPressure(the_globals->getTargetPressure());
926 +    else {
927 +      sprintf( painCave.errMsg,
928 +               "SimSetup error: If you use a constant pressure\n"
929 +               "    ensemble, you must set targetPressure in the BASS file.\n");
930 +      painCave.isFatal = 1;
931 +      simError();
932 +    }
933      
934 +    if( the_globals->haveTauThermostat() )
935 +      myNPTfm->setTauThermostat( the_globals->getTauThermostat() );
936 +    else{
937 +      sprintf( painCave.errMsg,
938 +               "SimSetup error: If you use an NPT\n"
939 +               "    ensemble, you must set tauThermostat.\n");
940 +      painCave.isFatal = 1;
941 +      simError();
942 +    }
943 +
944 +    if( the_globals->haveTauBarostat() )
945 +      myNPTfm->setTauBarostat( the_globals->getTauBarostat() );
946 +    else{
947 +      sprintf( painCave.errMsg,
948 +               "SimSetup error: If you use an NPT\n"
949 +               "    ensemble, you must set tauBarostat.\n");
950 +      painCave.isFatal = 1;
951 +      simError();
952 +    }
953 +    break;
954  
955    default:
956      sprintf( painCave.errMsg,

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines