CMS 3D CMS Logo

edm::Herwig6Source Class Reference

#include <GeneratorInterface/Herwig6Interface/interface/Herwig6Source.h>

Inheritance diagram for edm::Herwig6Source:

edm::GeneratedInputSource edm::ConfigurableInputSource edm::InputSource edm::ProductRegistryHelper

List of all members.

Public Member Functions

void endRun (Run &r)
 Herwig6Source (const ParameterSet &, const InputSourceDescription &)
virtual ~Herwig6Source ()

Private Member Functions

void clear ()
bool hwgive (const std::string &iParm)
virtual bool produce (Event &e)
bool setRngSeeds (int)

Private Attributes

double comenergy
bool doMPInteraction_
HepMC::GenEvent * evt
double extCrossSect
double extFilterEff
CLHEP::HepRandomEngine * fRandomEngine
bool herwigHepMCVerbosity_
int herwigLhapdfVerbosity_
int herwigVerbosity_
double intCrossSect
std::string lhapdfSetPath_
int maxEventsToPrint_
int numTrials_
bool printCards_
bool useJimmy_


Detailed Description

Definition at line 25 of file Herwig6Source.h.


Constructor & Destructor Documentation

Herwig6Source::Herwig6Source ( const ParameterSet pset,
const InputSourceDescription desc 
)

Definition at line 47 of file Herwig6Source.cc.

References comenergy, edm::errors::Configuration, doMPInteraction_, fRandomEngine, edm::ParameterSet::getParameter(), herwigHepMCVerbosity_, herwigLhapdfVerbosity_, herwigVerbosity_, hwgive(), hwprop, i, int, jimmin, jminit, jmparm, lhapdfSetPath_, edm::InputSource::maxEvents(), maxEventsToPrint_, mysetpdfpath, NULL, pars, printCards_, randomEngine, setherwpdf, setRngSeeds(), and useJimmy_.

00048                                                                  :
00049   GeneratedInputSource(pset, desc), evt(0), 
00050   herwigVerbosity_ (pset.getUntrackedParameter<int>("herwigVerbosity",0)),
00051   herwigHepMCVerbosity_ (pset.getUntrackedParameter<bool>("herwigHepMCVerbosity",false)),
00052   herwigLhapdfVerbosity_ (pset.getUntrackedParameter<int>("herwigLhapdfVerbosity",0)),
00053   maxEventsToPrint_ (pset.getUntrackedParameter<int>("maxEventsToPrint",0)),
00054   comenergy(pset.getUntrackedParameter<double>("comEnergy",14000.)),
00055   lhapdfSetPath_(pset.getUntrackedParameter<string>("lhapdfSetPath","")),
00056   useJimmy_(pset.getUntrackedParameter<bool>("useJimmy",true)),
00057   doMPInteraction_(pset.getUntrackedParameter<bool>("doMPInteraction",true)),
00058   printCards_(pset.getUntrackedParameter<bool>("printCards",false)),
00059   numTrials_(pset.getUntrackedParameter<int>("numTrialsMPI",100)),
00060   extCrossSect(pset.getUntrackedParameter<double>("crossSection", -1.)),
00061   extFilterEff(pset.getUntrackedParameter<double>("filterEfficiency", -1.))
00062 {
00063 
00064   std::ostringstream header_str;
00065 
00066   header_str << "----------------------------------------------\n";
00067   header_str << "Initializing Herwig6Source\n";
00068   header_str << "----------------------------------------------\n";
00069 
00070   
00071   /* herwigVerbosity Level IPRINT
00072      valid argumets are: 0: print title only
00073                          1: + print selected input parameters
00074                          2: + print table of particle codes and properties
00075                          3: + tables of Sudakov form factors  
00076               *** NOT IMPLEMENTED ***
00077       LHA vebosity:      0=silent 
00078                          1=lowkey (default) 
00079                          2=all 
00080   */
00081 
00082   header_str << "   Herwig verbosity level         = " << herwigVerbosity_ << "\n";
00083   header_str << "   LHAPDF verbosity level         = " << herwigLhapdfVerbosity_ << "\n";
00084   header_str << "   HepMC verbosity                = " << herwigHepMCVerbosity_ << "\n";
00085   header_str << "   Number of events to be printed = " << maxEventsToPrint_ << "\n";
00086 
00087 
00088   if(useJimmy_) {
00089     header_str << "   HERWIG will be using JIMMY for UE/MI." << "\n";
00090     if(doMPInteraction_) 
00091       header_str << "   JIMMY trying to generate multiple interactions." << "\n";
00092   }
00093 
00094   // setting up lhapdf path name from environment varaible (***)
00095   char* lhaPdfs = NULL;
00096   header_str<<"   Trying to find LHAPATH in environment ...";
00097   lhaPdfs = getenv("LHAPATH");
00098   if(lhaPdfs != NULL) {
00099     header_str<<" done.\n";
00100     lhapdfSetPath_=std::string(lhaPdfs);
00101   }
00102   else
00103     header_str<<" failed.\n";
00104 
00105 
00106   // Call hwudat to set up HERWIG block data
00107   hwudat();
00108   
00109 
00110   // Setting basic parameters ...
00111   hwproc.PBEAM1 = comenergy/2.;
00112   hwproc.PBEAM2 = comenergy/2.;
00113   hwbmch.PART1[0]  = 'P';
00114   hwbmch.PART2[0]  = 'P';
00115   for(int i=1;i<8;++i){
00116     hwbmch.PART1[i]  = ' ';
00117     hwbmch.PART2[i]  = ' ';}
00118   int numEvents = maxEvents();  
00119   if(useJimmy_) jmparm.MSFLAG = 1;
00120 
00121   // initialize other common blocks ...
00122   hwigin();
00123 
00124   hwevnt.MAXER = int(numEvents/10);
00125   if(hwevnt.MAXER<100) hwevnt.MAXER = 100;
00126 
00127   if(useJimmy_) jimmin();
00128   
00129   // set some 'non-herwig' defaults
00130   hwevnt.MAXPR =  maxEventsToPrint_;           // no printing out of events
00131   hwpram.IPRINT = herwigVerbosity_;            // HERWIG print out mode
00132   hwprop.RMASS[6] = 175.0;
00133 
00134   // Set HERWIG parameters in a single ParameterSet
00135   ParameterSet herwig_params = 
00136     pset.getParameter<ParameterSet>("HerwigParameters") ;
00137   
00138   // The parameter sets to be read (default, min bias, user ...) in the proper order.
00139   vector<string> setNames = 
00140     herwig_params.getParameter<vector<string> >("parameterSets");  
00141   
00142   // Loop over the sets
00143   for ( unsigned i=0; i<setNames.size(); ++i ) {    
00144     string mySet = setNames[i];
00145     vector<string> pars = 
00146       herwig_params.getParameter<vector<string> >(mySet);
00147     
00148     header_str << "----------------------------------------------" << "\n";
00149     header_str << "Read HERWIG parameter set " << mySet << "\n";
00150     header_str << "----------------------------------------------" << "\n";
00151     
00152     // Loop over all parameters and stop in case of mistake
00153     for( vector<string>::const_iterator  
00154            itPar = pars.begin(); itPar != pars.end(); ++itPar ) {
00155       static string sRandomValueSetting1("NRN(1)");
00156       static string sRandomValueSetting2("NRN(2)");
00157       if( (0 == itPar->compare(0,sRandomValueSetting1.size(),sRandomValueSetting1) )||(0 == itPar->compare(0,sRandomValueSetting2.size(),sRandomValueSetting2) )) {
00158         throw edm::Exception(edm::errors::Configuration,"HerwigError")
00159           <<" attempted to set random number using pythia command 'NRN(.)'. This is not allowed.\n  Please use the RandomNumberGeneratorService to set the random number seed.";
00160       }
00161       
00162       if( ! hwgive(*itPar) ) {
00163         throw edm::Exception(edm::errors::Configuration,"HerwigError") 
00164           <<" herwig did not accept the following \""<<*itPar<<"\"";
00165       }
00166       else if(printCards_)
00167         header_str << "   " << *itPar << "\n";
00168     }
00169   }
00170 
00171   // setting up herwgi RNG seeds NRN(.)
00172   header_str << "----------------------------------------------" << "\n";
00173   header_str << "Setting Herwig random number generator seeds" << "\n";
00174   header_str << "----------------------------------------------" << "\n";
00175   edm::Service<RandomNumberGenerator> rng;
00176   fRandomEngine = &(rng->getEngine());
00177   randomEngine = fRandomEngine;
00178   int wwseed = rng->mySeed();
00179   bool rngok = setRngSeeds(wwseed);
00180   if(!rngok)
00181     throw edm::Exception(edm::errors::Configuration,"HerwigError")
00182       <<" Impossible error in setting 'NRN(.)'.";
00183   header_str << "   NRN(1) = "<<hwevnt.NRN[0]<<"\n";
00184   header_str << "   NRN(2) = "<<hwevnt.NRN[1]<<"\n";
00185 
00186   // set the LHAPDF grid directory and path
00187   setherwpdf();
00188   char pdfpath[232];
00189   int pathlen = lhapdfSetPath_.length();
00190   for(int i=0; i<pathlen; ++i) 
00191   pdfpath[i]=lhapdfSetPath_.at(i);
00192   for(int i=pathlen; i<232; ++i) 
00193   pdfpath[i]=' ';
00194   mysetpdfpath(pdfpath);
00195 
00196   // HERWIG preparations ...
00197   hwuinc();
00198   hwusta("PI0     ",1);
00199   hweini();
00200   if(useJimmy_) jminit();
00201 
00202   produces<HepMCProduct>();
00203   produces<GenInfoProduct, edm::InRun>();
00204 
00205   header_str << "\n----------------------------------------------" << "\n";
00206   header_str << "Starting event generation" << "\n";
00207   header_str << "----------------------------------------------" << "\n";
00208 
00209   edm::LogInfo("")<<header_str.str(); 
00210 
00211 
00212 }

Herwig6Source::~Herwig6Source (  )  [virtual]

Definition at line 215 of file Herwig6Source.cc.

References clear().

00215                              {
00216 
00217   std::ostringstream footer_str;
00218 
00219   footer_str << "----------------------------------------------" << "\n";
00220   footer_str << "Event generation done" << "\n";
00221   footer_str << "----------------------------------------------" << "\n";
00222 
00223   LogInfo("") << footer_str.str();
00224 
00225   clear();
00226 }


Member Function Documentation

void Herwig6Source::clear ( void   )  [private]

Definition at line 228 of file Herwig6Source.cc.

References jmefin, and useJimmy_.

Referenced by ~Herwig6Source().

00228                           {
00229   // teminate elementary process
00230   hwefin();
00231   if(useJimmy_) jmefin();
00232 }

void Herwig6Source::endRun ( Run r  )  [virtual]

Reimplemented from edm::ConfigurableInputSource.

Definition at line 1081 of file Herwig6Source.cc.

References extCrossSect, extFilterEff, intCrossSect, and edm::Run::put().

01081                                   {
01082  
01083  auto_ptr<GenInfoProduct> giprod (new GenInfoProduct());
01084 
01085  //-----------------------------------------------
01086  // compute cross-section (internal HERWIG style)
01087  double RNWGT=1./hwevnt.NWGTS;
01088  double AVWGT=hwevnt.WGTSUM*RNWGT;
01089 
01090  intCrossSect=1000.*AVWGT;
01091  //-----------------------------------------------
01092 
01093  giprod->set_cross_section(intCrossSect);
01094  giprod->set_external_cross_section(extCrossSect);
01095  giprod->set_filter_efficiency(extFilterEff);
01096  r.put(giprod);
01097 
01098 }

bool Herwig6Source::hwgive ( const std::string &  iParm  )  [private]

Definition at line 302 of file Herwig6Source.cc.

References Exception, hw6202, hw6203, hw6300, hw6500, hwbosc, hwbrch, hwdist, hwdspn, hwgupr, hwhard, hwminb, hwprop, hwrpar, hwsusy, hwuclu, hwusud, hwuwts, and jmparm.

Referenced by Herwig6Source().

00302                                                            {
00303   bool accepted = 1;
00304 
00305  
00306   if(!strncmp(ParameterString.c_str(),"IPROC",5)) {
00307     hwproc.IPROC = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);
00308     if(hwproc.IPROC<0) {
00309       throw cms::Exception("HerwigError")
00310         <<" Attempted to set IPROC to a negative value. This is not allowed.\n Please use the McatnloInterface to cope with negative valued IPROCs.";
00311     }
00312   }
00313   else if(!strncmp(ParameterString.c_str(),"AUTPDF(",7)){
00314     LogWarning("") <<"   WARNING: AUTPDF parameter *not* suported. HERWIG will use LHAPDF."<<"\n";
00315   }
00316   else if(!strncmp(ParameterString.c_str(),"TAUDEC",6)){
00317     int tostart=0;
00318     while(ParameterString.c_str()[tostart]!='=') tostart++;
00319     tostart++;
00320     while(ParameterString.c_str()[tostart]==' ') tostart++;
00321     int todo = 0;
00322     while(ParameterString.c_str()[todo+tostart]!='\0') {
00323       hwdspn.TAUDEC[todo]=ParameterString.c_str()[todo+tostart];
00324       todo++;
00325     }
00326     if(todo != 6) {
00327       throw cms::Exception("HerwigError")
00328         <<" Attempted to set TAUDEC to "<<hwdspn.TAUDEC<<". This is not allowed.\n Options for TAUDEC are HERWIG and TAUOLA.";
00329     }
00330   }
00331   else if(!strncmp(ParameterString.c_str(),"BDECAY",6)){
00332     LogWarning("")<<"   WARNING: BDECAY parameter *not* suported. HERWIG will use default b decay."<<"\n";
00333   }
00334   else if(!strncmp(ParameterString.c_str(),"QCDLAM",6))
00335     hwpram.QCDLAM = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);
00336   else if(!strncmp(ParameterString.c_str(),"VQCUT",5))
00337     hwpram.VQCUT = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00338   else if(!strncmp(ParameterString.c_str(),"VGCUT",5))
00339     hwpram.VGCUT = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00340   else if(!strncmp(ParameterString.c_str(),"VPCUT",5))
00341     hwpram.VPCUT = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00342   else if(!strncmp(ParameterString.c_str(),"CLMAX",5))
00343     hwpram.CLMAX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00344   else if(!strncmp(ParameterString.c_str(),"CLPOW",5))
00345     hwpram.CLPOW = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00346   else if(!strncmp(ParameterString.c_str(),"PSPLT(1)",8))
00347     hwpram.PSPLT[0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00348   else if(!strncmp(ParameterString.c_str(),"PSPLT(2)",8))
00349     hwpram.PSPLT[1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00350   else if(!strncmp(ParameterString.c_str(),"QDIQK",5))
00351     hwpram.QDIQK = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00352   else if(!strncmp(ParameterString.c_str(),"PDIQK",5))
00353     hwpram.PDIQK = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00354   else if(!strncmp(ParameterString.c_str(),"QSPAC",5))
00355     hwpram.QSPAC = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00356   else if(!strncmp(ParameterString.c_str(),"PTRMS",5))
00357     hwpram.PTRMS = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00358   else if(!strncmp(ParameterString.c_str(),"IPRINT",6))
00359     hwpram.IPRINT = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00360   else if(!strncmp(ParameterString.c_str(),"PRVTX",5))
00361     hwpram.PRVTX = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00362   else if(!strncmp(ParameterString.c_str(),"NPRFMT",6))
00363     hwpram.NPRFMT = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00364   else if(!strncmp(ParameterString.c_str(),"PRNDEC",6))
00365     hwpram.PRNDEC = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00366   else if(!strncmp(ParameterString.c_str(),"PRNDEF",6))
00367     hwpram.PRNDEF = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00368   else if(!strncmp(ParameterString.c_str(),"PRNTEX",6))
00369     hwpram.PRNTEX = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00370   else if(!strncmp(ParameterString.c_str(),"PRNWEB",6))
00371     hwpram.PRNWEB = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00372   else if(!strncmp(ParameterString.c_str(),"MAXPR",5))
00373     hwevnt.MAXPR = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00374   else if(!strncmp(ParameterString.c_str(),"MAXER",5))
00375     hwevnt.MAXER = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00376   else if(!strncmp(ParameterString.c_str(),"LWEVT",5))
00377     hwevnt.LWEVT = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00378   else if(!strncmp(ParameterString.c_str(),"LRSUD",5))
00379     hwpram.LRSUD = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00380   else if(!strncmp(ParameterString.c_str(),"LWSUD",5))
00381     hwpram.LWSUD = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00382   else if(!strncmp(ParameterString.c_str(),"NRN(1)",6))
00383     hwevnt.NRN[0] = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00384   else if(!strncmp(ParameterString.c_str(),"NRN(2)",6))
00385     hwevnt.NRN[1] = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00386   else if(!strncmp(ParameterString.c_str(),"WGTMAX",6))
00387     hwevnt.WGTMAX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00388   else if(!strncmp(ParameterString.c_str(),"NOWGT",5))
00389     hwevnt.NOWGT = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00390   else if(!strncmp(ParameterString.c_str(),"AVWGT",5))
00391     hwevnt.AVWGT = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00392   else if(!strncmp(ParameterString.c_str(),"AZSOFT",6))
00393     hwpram.AZSOFT = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00394   else if(!strncmp(ParameterString.c_str(),"AZSPIN",6))
00395     hwpram.AZSPIN = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00396   else if(!strncmp(ParameterString.c_str(),"HARDME",6))
00397     hwpram.HARDME = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00398   else if(!strncmp(ParameterString.c_str(),"SOFTME",6))
00399     hwpram.SOFTME = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00400   else if(!strncmp(ParameterString.c_str(),"GCUTME",6))
00401     hwpram.GCUTME = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00402   else if(!strncmp(ParameterString.c_str(),"NCOLO",5))
00403     hwpram.NCOLO = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00404   else if(!strncmp(ParameterString.c_str(),"NFLAV",5))
00405     hwpram.NFLAV = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00406   else if(!strncmp(ParameterString.c_str(),"MODPDF(1)",9))
00407     hwpram.MODPDF[0] = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);
00408   else if(!strncmp(ParameterString.c_str(),"MODPDF(2)",9))
00409     hwpram.MODPDF[1] = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);
00410   else if(!strncmp(ParameterString.c_str(),"NSTRU",5))
00411     hwpram.NSTRU = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00412   else if(!strncmp(ParameterString.c_str(),"PRSOF",5))
00413     hwpram.PRSOF = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00414   else if(!strncmp(ParameterString.c_str(),"ENSOF",5))
00415     hwpram.ENSOF = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00416   else if(!strncmp(ParameterString.c_str(),"IOPREM",6))
00417     hwpram.IOPREM = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00418   else if(!strncmp(ParameterString.c_str(),"BTCLM",5))
00419     hwpram.BTCLM = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00420   else if(!strncmp(ParameterString.c_str(),"ETAMIX",6))
00421     hwpram.ETAMIX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00422   else if(!strncmp(ParameterString.c_str(),"PHIMIX",6))
00423     hwpram.PHIMIX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00424   else if(!strncmp(ParameterString.c_str(),"H1MIX",5))
00425     hwpram.H1MIX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00426   else if(!strncmp(ParameterString.c_str(),"F0MIX",5))
00427     hwpram.F0MIX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00428   else if(!strncmp(ParameterString.c_str(),"F1MIX",5))
00429     hwpram.F1MIX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00430   else if(!strncmp(ParameterString.c_str(),"F2MIX",5))
00431     hwpram.F2MIX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00432   else if(!strncmp(ParameterString.c_str(),"ET2MIX",6))
00433     hwpram.ET2MIX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00434   else if(!strncmp(ParameterString.c_str(),"OMHMIX",6))
00435     hwpram.OMHMIX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00436   else if(!strncmp(ParameterString.c_str(),"PH3MIX",6))
00437     hwpram.PH3MIX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00438   else if(!strncmp(ParameterString.c_str(),"B1LIM",5))
00439     hwpram.B1LIM = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00440   else if(!strncmp(ParameterString.c_str(),"CLDIR(1)",8))
00441     hwpram.CLDIR[0] = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00442   else if(!strncmp(ParameterString.c_str(),"CLDIR(2)",8))
00443     hwpram.CLDIR[1] = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);   
00444   else if(!strncmp(ParameterString.c_str(),"CLSMR(1)",8))
00445     hwpram.CLSMR[0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00446   else if(!strncmp(ParameterString.c_str(),"CLSMR(2)",8))
00447     hwpram.CLSMR[1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00448   else if(!strncmp(ParameterString.c_str(),"RMASS(1)",8))
00449     hwprop.RMASS[1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00450   else if(!strncmp(ParameterString.c_str(),"RMASS(2)",8))
00451     hwprop.RMASS[2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00452   else if(!strncmp(ParameterString.c_str(),"RMASS(3)",8))
00453     hwprop.RMASS[3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00454   else if(!strncmp(ParameterString.c_str(),"RMASS(4)",8))
00455     hwprop.RMASS[4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00456   else if(!strncmp(ParameterString.c_str(),"RMASS(5)",8))
00457     hwprop.RMASS[5] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00458   else if(!strncmp(ParameterString.c_str(),"RMASS(6)",8))
00459     hwprop.RMASS[6] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00460   else if(!strncmp(ParameterString.c_str(),"RMASS(13)",9))
00461     hwprop.RMASS[13] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00462   else if(!strncmp(ParameterString.c_str(),"SUDORD",6))
00463     hwusud.SUDORD = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00464   else if(!strncmp(ParameterString.c_str(),"INTER",5))
00465     hwusud.INTER = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00466   else if(!strncmp(ParameterString.c_str(),"NEGWTS",6))
00467     hw6203.NEGWTS = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00468   else if(!strncmp(ParameterString.c_str(),"PMBN1",5))
00469     hwminb.PMBN1 = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00470   else if(!strncmp(ParameterString.c_str(),"PMBN2",5))
00471     hwminb.PMBN2 = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00472   else if(!strncmp(ParameterString.c_str(),"PMBN3",5))
00473     hwminb.PMBN3 = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00474   else if(!strncmp(ParameterString.c_str(),"PMBK1",5))
00475     hwminb.PMBK1 = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00476   else if(!strncmp(ParameterString.c_str(),"PMBK2",5))
00477     hwminb.PMBK2 = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00478   else if(!strncmp(ParameterString.c_str(),"PMBM1",5))
00479     hwminb.PMBM1 = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00480   else if(!strncmp(ParameterString.c_str(),"PMBM2",5))
00481     hwminb.PMBM2 = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00482   else if(!strncmp(ParameterString.c_str(),"PMBP1",5))
00483     hwminb.PMBP1 = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00484   else if(!strncmp(ParameterString.c_str(),"PMBP2",5))
00485     hwminb.PMBP2 = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00486   else if(!strncmp(ParameterString.c_str(),"PMBP3",5))
00487     hwminb.PMBP3 = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00488   else if(!strncmp(ParameterString.c_str(),"VMIN2",5))
00489     hwdist.VMIN2 = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00490   else if(!strncmp(ParameterString.c_str(),"EXAG",4))
00491     hwdist.EXAG = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00492   else if(!strncmp(ParameterString.c_str(),"PRECO",5))
00493     hwuclu.PRECO = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00494   else if(!strncmp(ParameterString.c_str(),"CLRECO",6))
00495     hwuclu.CLRECO = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00496   else if(!strncmp(ParameterString.c_str(),"PWT(1)",6))
00497     hwuwts.PWT[0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00498   else if(!strncmp(ParameterString.c_str(),"PWT(2)",6))
00499     hwuwts.PWT[1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00500   else if(!strncmp(ParameterString.c_str(),"PWT(3)",6))
00501     hwuwts.PWT[2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00502   else if(!strncmp(ParameterString.c_str(),"PWT(4)",6))
00503     hwuwts.PWT[3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00504   else if(!strncmp(ParameterString.c_str(),"PWT(5)",6))
00505     hwuwts.PWT[4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00506   else if(!strncmp(ParameterString.c_str(),"PWT(6)",6))
00507     hwuwts.PWT[5] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00508   else if(!strncmp(ParameterString.c_str(),"PWT(7)",6))
00509     hwuwts.PWT[6] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00510   else if(!strncmp(ParameterString.c_str(),"REPWT(0,0,0)",12))
00511     hwuwts.REPWT[0][0][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00512   else if(!strncmp(ParameterString.c_str(),"REPWT(0,0,1)",12))
00513     hwuwts.REPWT[0][0][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00514   else if(!strncmp(ParameterString.c_str(),"REPWT(0,0,2)",12))
00515     hwuwts.REPWT[0][0][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00516   else if(!strncmp(ParameterString.c_str(),"REPWT(0,0,3)",12))
00517     hwuwts.REPWT[0][0][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00518   else if(!strncmp(ParameterString.c_str(),"REPWT(0,0,4)",12))
00519     hwuwts.REPWT[0][0][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00520   else if(!strncmp(ParameterString.c_str(),"REPWT(0,1,0)",12))
00521     hwuwts.REPWT[0][1][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00522   else if(!strncmp(ParameterString.c_str(),"REPWT(0,1,1)",12))
00523     hwuwts.REPWT[0][1][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00524   else if(!strncmp(ParameterString.c_str(),"REPWT(0,1,2)",12))
00525     hwuwts.REPWT[0][1][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00526   else if(!strncmp(ParameterString.c_str(),"REPWT(0,1,3)",12))
00527     hwuwts.REPWT[0][1][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00528   else if(!strncmp(ParameterString.c_str(),"REPWT(0,1,4)",12))
00529     hwuwts.REPWT[0][1][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00530   else if(!strncmp(ParameterString.c_str(),"REPWT(0,2,0)",12))
00531     hwuwts.REPWT[0][2][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00532   else if(!strncmp(ParameterString.c_str(),"REPWT(0,2,1)",12))
00533     hwuwts.REPWT[0][2][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00534   else if(!strncmp(ParameterString.c_str(),"REPWT(0,2,2)",12))
00535     hwuwts.REPWT[0][2][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00536   else if(!strncmp(ParameterString.c_str(),"REPWT(0,2,3)",12))
00537     hwuwts.REPWT[0][2][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00538   else if(!strncmp(ParameterString.c_str(),"REPWT(0,2,4)",12))
00539     hwuwts.REPWT[0][2][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00540   else if(!strncmp(ParameterString.c_str(),"REPWT(0,3,0)",12))
00541     hwuwts.REPWT[0][3][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00542   else if(!strncmp(ParameterString.c_str(),"REPWT(0,3,1)",12))
00543     hwuwts.REPWT[0][3][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00544   else if(!strncmp(ParameterString.c_str(),"REPWT(0,3,2)",12))
00545     hwuwts.REPWT[0][3][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00546   else if(!strncmp(ParameterString.c_str(),"REPWT(0,3,3)",12))
00547     hwuwts.REPWT[0][3][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00548   else if(!strncmp(ParameterString.c_str(),"REPWT(0,3,4)",12))
00549     hwuwts.REPWT[0][3][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00550   else if(!strncmp(ParameterString.c_str(),"REPWT(0,4,0)",12))
00551     hwuwts.REPWT[0][4][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00552   else if(!strncmp(ParameterString.c_str(),"REPWT(0,4,1)",12))
00553     hwuwts.REPWT[0][4][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00554   else if(!strncmp(ParameterString.c_str(),"REPWT(0,4,2)",12))
00555     hwuwts.REPWT[0][4][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00556   else if(!strncmp(ParameterString.c_str(),"REPWT(0,4,3)",12))
00557     hwuwts.REPWT[0][4][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00558   else if(!strncmp(ParameterString.c_str(),"REPWT(0,4,4)",12))
00559     hwuwts.REPWT[0][4][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00560   else if(!strncmp(ParameterString.c_str(),"REPWT(1,0,0)",12))
00561     hwuwts.REPWT[1][0][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00562   else if(!strncmp(ParameterString.c_str(),"REPWT(1,0,1)",12))
00563     hwuwts.REPWT[1][0][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00564   else if(!strncmp(ParameterString.c_str(),"REPWT(1,0,2)",12))
00565     hwuwts.REPWT[1][0][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00566   else if(!strncmp(ParameterString.c_str(),"REPWT(1,0,3)",12))
00567     hwuwts.REPWT[1][0][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00568   else if(!strncmp(ParameterString.c_str(),"REPWT(1,0,4)",12))
00569     hwuwts.REPWT[1][0][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00570   else if(!strncmp(ParameterString.c_str(),"REPWT(1,1,0)",12))
00571     hwuwts.REPWT[1][1][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00572   else if(!strncmp(ParameterString.c_str(),"REPWT(1,1,1)",12))
00573     hwuwts.REPWT[1][1][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00574   else if(!strncmp(ParameterString.c_str(),"REPWT(1,1,2)",12))
00575     hwuwts.REPWT[1][1][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00576   else if(!strncmp(ParameterString.c_str(),"REPWT(1,1,3)",12))
00577     hwuwts.REPWT[1][1][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00578   else if(!strncmp(ParameterString.c_str(),"REPWT(1,1,4)",12))
00579     hwuwts.REPWT[1][1][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00580   else if(!strncmp(ParameterString.c_str(),"REPWT(1,2,0)",12))
00581     hwuwts.REPWT[1][2][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00582   else if(!strncmp(ParameterString.c_str(),"REPWT(1,2,1)",12))
00583     hwuwts.REPWT[1][2][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00584   else if(!strncmp(ParameterString.c_str(),"REPWT(1,2,2)",12))
00585     hwuwts.REPWT[1][2][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00586   else if(!strncmp(ParameterString.c_str(),"REPWT(1,2,3)",12))
00587     hwuwts.REPWT[1][2][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00588   else if(!strncmp(ParameterString.c_str(),"REPWT(1,2,4)",12))
00589     hwuwts.REPWT[1][2][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00590   else if(!strncmp(ParameterString.c_str(),"REPWT(1,3,0)",12))
00591     hwuwts.REPWT[1][3][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00592   else if(!strncmp(ParameterString.c_str(),"REPWT(1,3,1)",12))
00593     hwuwts.REPWT[1][3][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00594   else if(!strncmp(ParameterString.c_str(),"REPWT(1,3,2)",12))
00595     hwuwts.REPWT[1][3][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00596   else if(!strncmp(ParameterString.c_str(),"REPWT(1,3,3)",12))
00597     hwuwts.REPWT[1][3][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00598   else if(!strncmp(ParameterString.c_str(),"REPWT(1,3,4)",12))
00599     hwuwts.REPWT[1][3][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00600   else if(!strncmp(ParameterString.c_str(),"REPWT(1,4,0)",12))
00601     hwuwts.REPWT[1][4][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00602   else if(!strncmp(ParameterString.c_str(),"REPWT(1,4,1)",12))
00603     hwuwts.REPWT[1][4][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00604   else if(!strncmp(ParameterString.c_str(),"REPWT(1,4,2)",12))
00605     hwuwts.REPWT[1][4][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00606   else if(!strncmp(ParameterString.c_str(),"REPWT(1,4,3)",12))
00607     hwuwts.REPWT[1][4][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00608   else if(!strncmp(ParameterString.c_str(),"REPWT(1,4,4)",12))
00609     hwuwts.REPWT[1][4][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00610   else if(!strncmp(ParameterString.c_str(),"REPWT(2,0,0)",12))
00611     hwuwts.REPWT[2][0][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00612   else if(!strncmp(ParameterString.c_str(),"REPWT(2,0,1)",12))
00613     hwuwts.REPWT[2][0][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00614   else if(!strncmp(ParameterString.c_str(),"REPWT(2,0,2)",12))
00615     hwuwts.REPWT[2][0][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00616   else if(!strncmp(ParameterString.c_str(),"REPWT(2,0,3)",12))
00617     hwuwts.REPWT[2][0][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00618   else if(!strncmp(ParameterString.c_str(),"REPWT(2,0,4)",12))
00619     hwuwts.REPWT[2][0][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00620   else if(!strncmp(ParameterString.c_str(),"REPWT(2,1,0)",12))
00621     hwuwts.REPWT[2][1][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00622   else if(!strncmp(ParameterString.c_str(),"REPWT(2,1,1)",12))
00623     hwuwts.REPWT[2][1][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00624   else if(!strncmp(ParameterString.c_str(),"REPWT(2,1,2)",12))
00625     hwuwts.REPWT[2][1][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00626   else if(!strncmp(ParameterString.c_str(),"REPWT(2,1,3)",12))
00627     hwuwts.REPWT[2][1][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00628   else if(!strncmp(ParameterString.c_str(),"REPWT(2,1,4)",12))
00629     hwuwts.REPWT[2][1][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00630   else if(!strncmp(ParameterString.c_str(),"REPWT(2,2,0)",12))
00631     hwuwts.REPWT[2][2][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00632   else if(!strncmp(ParameterString.c_str(),"REPWT(2,2,1)",12))
00633     hwuwts.REPWT[2][2][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00634   else if(!strncmp(ParameterString.c_str(),"REPWT(2,2,2)",12))
00635     hwuwts.REPWT[2][2][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00636   else if(!strncmp(ParameterString.c_str(),"REPWT(2,2,3)",12))
00637     hwuwts.REPWT[2][2][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00638   else if(!strncmp(ParameterString.c_str(),"REPWT(2,2,4)",12))
00639     hwuwts.REPWT[2][2][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00640   else if(!strncmp(ParameterString.c_str(),"REPWT(2,3,0)",12))
00641     hwuwts.REPWT[2][3][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00642   else if(!strncmp(ParameterString.c_str(),"REPWT(2,3,1)",12))
00643     hwuwts.REPWT[2][3][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00644   else if(!strncmp(ParameterString.c_str(),"REPWT(2,3,2)",12))
00645     hwuwts.REPWT[2][3][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00646   else if(!strncmp(ParameterString.c_str(),"REPWT(2,3,3)",12))
00647     hwuwts.REPWT[2][3][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00648   else if(!strncmp(ParameterString.c_str(),"REPWT(2,3,4)",12))
00649     hwuwts.REPWT[2][3][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00650   else if(!strncmp(ParameterString.c_str(),"REPWT(2,4,0)",12))
00651     hwuwts.REPWT[2][4][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00652   else if(!strncmp(ParameterString.c_str(),"REPWT(2,4,1)",12))
00653     hwuwts.REPWT[2][4][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00654   else if(!strncmp(ParameterString.c_str(),"REPWT(2,4,2)",12))
00655     hwuwts.REPWT[2][4][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00656   else if(!strncmp(ParameterString.c_str(),"REPWT(2,4,3)",12))
00657     hwuwts.REPWT[2][4][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00658   else if(!strncmp(ParameterString.c_str(),"REPWT(2,4,4)",12))
00659     hwuwts.REPWT[2][4][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00660   else if(!strncmp(ParameterString.c_str(),"REPWT(3,0,0)",12))
00661     hwuwts.REPWT[3][0][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00662   else if(!strncmp(ParameterString.c_str(),"REPWT(3,0,1)",12))
00663     hwuwts.REPWT[3][0][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00664   else if(!strncmp(ParameterString.c_str(),"REPWT(3,0,2)",12))
00665     hwuwts.REPWT[3][0][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00666   else if(!strncmp(ParameterString.c_str(),"REPWT(3,0,3)",12))
00667     hwuwts.REPWT[3][0][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00668   else if(!strncmp(ParameterString.c_str(),"REPWT(3,0,4)",12))
00669     hwuwts.REPWT[3][0][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00670   else if(!strncmp(ParameterString.c_str(),"REPWT(3,1,0)",12))
00671     hwuwts.REPWT[3][1][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00672   else if(!strncmp(ParameterString.c_str(),"REPWT(3,1,1)",12))
00673     hwuwts.REPWT[3][1][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00674   else if(!strncmp(ParameterString.c_str(),"REPWT(3,1,2)",12))
00675     hwuwts.REPWT[3][1][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00676   else if(!strncmp(ParameterString.c_str(),"REPWT(3,1,3)",12))
00677     hwuwts.REPWT[3][1][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00678   else if(!strncmp(ParameterString.c_str(),"REPWT(3,1,4)",12))
00679     hwuwts.REPWT[3][1][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00680   else if(!strncmp(ParameterString.c_str(),"REPWT(3,2,0)",12))
00681     hwuwts.REPWT[3][2][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00682   else if(!strncmp(ParameterString.c_str(),"REPWT(3,2,1)",12))
00683     hwuwts.REPWT[3][2][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00684   else if(!strncmp(ParameterString.c_str(),"REPWT(3,2,2)",12))
00685     hwuwts.REPWT[3][2][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00686   else if(!strncmp(ParameterString.c_str(),"REPWT(3,2,3)",12))
00687     hwuwts.REPWT[3][2][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00688   else if(!strncmp(ParameterString.c_str(),"REPWT(3,2,4)",12))
00689     hwuwts.REPWT[3][2][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00690   else if(!strncmp(ParameterString.c_str(),"REPWT(3,3,0)",12))
00691     hwuwts.REPWT[3][3][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00692   else if(!strncmp(ParameterString.c_str(),"REPWT(3,3,1)",12))
00693     hwuwts.REPWT[3][3][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00694   else if(!strncmp(ParameterString.c_str(),"REPWT(3,3,2)",12))
00695     hwuwts.REPWT[3][3][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00696   else if(!strncmp(ParameterString.c_str(),"REPWT(3,3,3)",12))
00697     hwuwts.REPWT[3][3][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00698   else if(!strncmp(ParameterString.c_str(),"REPWT(3,3,4)",12))
00699     hwuwts.REPWT[3][3][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00700   else if(!strncmp(ParameterString.c_str(),"REPWT(3,4,0)",12))
00701     hwuwts.REPWT[3][4][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00702   else if(!strncmp(ParameterString.c_str(),"REPWT(3,4,1)",12))
00703     hwuwts.REPWT[3][4][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00704   else if(!strncmp(ParameterString.c_str(),"REPWT(3,4,2)",12))
00705     hwuwts.REPWT[3][4][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00706   else if(!strncmp(ParameterString.c_str(),"REPWT(3,4,3)",12))
00707     hwuwts.REPWT[3][4][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00708   else if(!strncmp(ParameterString.c_str(),"REPWT(3,4,4)",12))
00709     hwuwts.REPWT[3][4][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00710   else if(!strncmp(ParameterString.c_str(),"SNGWT",5))
00711     hwuwts.SNGWT = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00712   else if(!strncmp(ParameterString.c_str(),"DECWT",5))
00713     hwuwts.DECWT = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00714   else if(!strncmp(ParameterString.c_str(),"PLTCUT",6))
00715     hwdist.PLTCUT = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00716   else if(!strncmp(ParameterString.c_str(),"VTOCDK(",7)){
00717     // we find the index ...
00718     int ind = atoi(&ParameterString[7]);  
00719     hwprop.VTOCDK[ind] = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);}
00720   else if(!strncmp(ParameterString.c_str(),"VTORDK(",7)){
00721     // we find the index ...
00722     int ind = atoi(&ParameterString[7]);  
00723     hwprop.VTORDK[ind] = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);}
00724   else if(!strncmp(ParameterString.c_str(),"PIPSMR",6))
00725     hwdist.PIPSMR = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00726   else if(!strncmp(ParameterString.c_str(),"VIPWID(1)",9))
00727     hw6202.VIPWID[0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00728   else if(!strncmp(ParameterString.c_str(),"VIPWID(2)",9))
00729     hw6202.VIPWID[1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00730   else if(!strncmp(ParameterString.c_str(),"VIPWID(3)",9))
00731     hw6202.VIPWID[2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00732   else if(!strncmp(ParameterString.c_str(),"MAXDKL",6))
00733     hwdist.MAXDKL = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00734   else if(!strncmp(ParameterString.c_str(),"IOPDKL",6))
00735     hwdist.IOPDKL = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00736   else if(!strncmp(ParameterString.c_str(),"DXRCYL",6))
00737     hw6202.DXRCYL = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00738   else if(!strncmp(ParameterString.c_str(),"DXZMAX",6))
00739     hw6202.DXZMAX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00740   else if(!strncmp(ParameterString.c_str(),"DXRSPH",6))
00741     hw6202.DXRSPH = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00742   //  else if(!strncmp(ParameterString.c_str(),"BDECAY",6))
00743   //    hwprch.BDECAY = ParameterString[strcspn(ParameterString.c_str(),"=")+1];  
00744   else if(!strncmp(ParameterString.c_str(),"MIXING",6))
00745     hwdist.MIXING = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00746   else if(!strncmp(ParameterString.c_str(),"XMIX(1)",7))
00747     hwdist.XMIX[0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00748   else if(!strncmp(ParameterString.c_str(),"XMIX(2)",7))
00749     hwdist.XMIX[1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00750   else if(!strncmp(ParameterString.c_str(),"YMIX(1)",7))
00751     hwdist.YMIX[0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00752   else if(!strncmp(ParameterString.c_str(),"YMIX(2)",7))
00753     hwdist.YMIX[1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);  
00754   else if(!strncmp(ParameterString.c_str(),"RMASS(198)",10))
00755     hwprop.RMASS[198] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);      
00756   else if(!strncmp(ParameterString.c_str(),"RMASS(199)",10))
00757     hwprop.RMASS[199] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);      
00758   else if(!strncmp(ParameterString.c_str(),"GAMW",4))
00759     hwpram.GAMW = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);      
00760   else if(!strncmp(ParameterString.c_str(),"GAMZ",4))
00761     hwpram.GAMZ = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);      
00762   else if(!strncmp(ParameterString.c_str(),"RMASS(200)",10))
00763     hwprop.RMASS[200] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00764   else if(!strncmp(ParameterString.c_str(),"WZRFR",5))
00765     hw6202.WZRFR = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00766   else if(!strncmp(ParameterString.c_str(),"MODBOS(",7)) {
00767     int ind = atoi(&ParameterString[7]);
00768     hwbosc.MODBOS[ind-1] = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00769   else if(!strncmp(ParameterString.c_str(),"RMASS(201)",10))
00770     hwprop.RMASS[201] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00771   else if(!strncmp(ParameterString.c_str(),"IOPHIG",6))
00772     hwbosc.IOPHIG = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00773   else if(!strncmp(ParameterString.c_str(),"GAMMAX",6))
00774     hwbosc.GAMMAX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00775   else if(!strncmp(ParameterString.c_str(),"ENHANC(",7)) {
00776     int ind = atoi(&ParameterString[7]);
00777     hwbosc.ENHANC[ind-1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00778   else if(!strncmp(ParameterString.c_str(),"RMASS(209)",10))
00779     hwprop.RMASS[209] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00780   else if(!strncmp(ParameterString.c_str(),"RMASS(215)",10))
00781     hwprop.RMASS[215] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00782   else if(!strncmp(ParameterString.c_str(),"ALPHEM",6))
00783     hwpram.ALPHEM = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00784   else if(!strncmp(ParameterString.c_str(),"SWEIN",5))
00785     hwpram.SWEIN = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00786   else if(!strncmp(ParameterString.c_str(),"QFCH(",5)){
00787     int ind = atoi(&ParameterString[5]);
00788     hwpram.QFCH[ind-1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00789   else if(!strncmp(ParameterString.c_str(),"AFCH(1,",7)){
00790     int ind = atoi(&ParameterString[7]); if(ind<1||ind>2) return 0;
00791     hwpram.AFCH[ind-1][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00792   else if(!strncmp(ParameterString.c_str(),"AFCH(2,",7)){
00793     int ind = atoi(&ParameterString[7]);if(ind<1||ind>2) return 0;
00794     hwpram.AFCH[ind-1][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00795   else if(!strncmp(ParameterString.c_str(),"AFCH(3,",7)){
00796     int ind = atoi(&ParameterString[7]);if(ind<1||ind>2) return 0;
00797     hwpram.AFCH[ind-1][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00798   else if(!strncmp(ParameterString.c_str(),"AFCH(4,",7)){
00799     int ind = atoi(&ParameterString[7]);if(ind<1||ind>2) return 0;
00800     hwpram.AFCH[ind-1][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00801   else if(!strncmp(ParameterString.c_str(),"AFCH(5,",7)){
00802     int ind = atoi(&ParameterString[7]);if(ind<1||ind>2) return 0;
00803     hwpram.AFCH[ind-1][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00804   else if(!strncmp(ParameterString.c_str(),"AFCH(6,",7)){
00805     int ind = atoi(&ParameterString[7]);if(ind<1||ind>2) return 0;
00806     hwpram.AFCH[ind-1][5] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00807   else if(!strncmp(ParameterString.c_str(),"AFCH(7,",7)){
00808     int ind = atoi(&ParameterString[7]);if(ind<1||ind>2) return 0;
00809     hwpram.AFCH[ind-1][6] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00810   else if(!strncmp(ParameterString.c_str(),"AFCH(8,",7)){
00811     int ind = atoi(&ParameterString[7]);if(ind<1||ind>2) return 0;
00812     hwpram.AFCH[ind-1][7] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00813   else if(!strncmp(ParameterString.c_str(),"AFCH(9,",7)){
00814     int ind = atoi(&ParameterString[7]);if(ind<1||ind>2) return 0;
00815     hwpram.AFCH[ind-1][8] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00816   else if(!strncmp(ParameterString.c_str(),"AFCH(10,",8)){
00817     int ind = atoi(&ParameterString[8]);if(ind<1||ind>2) return 0;
00818     hwpram.AFCH[ind-1][9] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00819   else if(!strncmp(ParameterString.c_str(),"AFCH(11,",8)){
00820     int ind = atoi(&ParameterString[8]);if(ind<1||ind>2) return 0;
00821     hwpram.AFCH[ind-1][10] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00822   else if(!strncmp(ParameterString.c_str(),"AFCH(12,",8)){
00823     int ind = atoi(&ParameterString[8]);if(ind<1||ind>2) return 0;
00824     hwpram.AFCH[ind-1][11] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00825   else if(!strncmp(ParameterString.c_str(),"AFCH(13,",8)){
00826     int ind = atoi(&ParameterString[8]);if(ind<1||ind>2) return 0;
00827     hwpram.AFCH[ind-1][12] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00828   else if(!strncmp(ParameterString.c_str(),"AFCH(14,",8)){
00829     int ind = atoi(&ParameterString[8]);if(ind<1||ind>2) return 0;
00830     hwpram.AFCH[ind-1][13] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00831   else if(!strncmp(ParameterString.c_str(),"AFCH(15,",8)){
00832     int ind = atoi(&ParameterString[8]);if(ind<1||ind>2) return 0;
00833     hwpram.AFCH[ind-1][14] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00834   else if(!strncmp(ParameterString.c_str(),"AFCH(16,",8)){
00835     int ind = atoi(&ParameterString[8]);if(ind<1||ind>2) return 0;
00836     hwpram.AFCH[ind-1][15] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00837   else if(!strncmp(ParameterString.c_str(),"VFCH(1,",7)){
00838     int ind = atoi(&ParameterString[7]); if(ind<1||ind>2) return 0;
00839     hwpram.VFCH[ind-1][0] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00840   else if(!strncmp(ParameterString.c_str(),"VFCH(2,",7)){
00841     int ind = atoi(&ParameterString[7]);if(ind<1||ind>2) return 0;
00842     hwpram.VFCH[ind-1][1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00843   else if(!strncmp(ParameterString.c_str(),"VFCH(3,",7)){
00844     int ind = atoi(&ParameterString[7]);if(ind<1||ind>2) return 0;
00845     hwpram.VFCH[ind-1][2] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00846   else if(!strncmp(ParameterString.c_str(),"VFCH(4,",7)){
00847     int ind = atoi(&ParameterString[7]);if(ind<1||ind>2) return 0;
00848     hwpram.VFCH[ind-1][3] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00849   else if(!strncmp(ParameterString.c_str(),"VFCH(5,",7)){
00850     int ind = atoi(&ParameterString[7]);if(ind<1||ind>2) return 0;
00851     hwpram.VFCH[ind-1][4] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00852   else if(!strncmp(ParameterString.c_str(),"VFCH(6,",7)){
00853     int ind = atoi(&ParameterString[7]);if(ind<1||ind>2) return 0;
00854     hwpram.VFCH[ind-1][5] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00855   else if(!strncmp(ParameterString.c_str(),"VFCH(7,",7)){
00856     int ind = atoi(&ParameterString[7]);if(ind<1||ind>2) return 0;
00857     hwpram.VFCH[ind-1][6] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00858   else if(!strncmp(ParameterString.c_str(),"VFCH(8,",7)){
00859     int ind = atoi(&ParameterString[7]);if(ind<1||ind>2) return 0;
00860     hwpram.VFCH[ind-1][7] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00861   else if(!strncmp(ParameterString.c_str(),"VFCH(9,",7)){
00862     int ind = atoi(&ParameterString[7]);if(ind<1||ind>2) return 0;
00863     hwpram.VFCH[ind-1][8] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00864   else if(!strncmp(ParameterString.c_str(),"VFCH(10,",8)){
00865     int ind = atoi(&ParameterString[8]);if(ind<1||ind>2) return 0;
00866     hwpram.VFCH[ind-1][9] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00867   else if(!strncmp(ParameterString.c_str(),"VFCH(11,",8)){
00868     int ind = atoi(&ParameterString[8]);if(ind<1||ind>2) return 0;
00869     hwpram.VFCH[ind-1][10] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00870   else if(!strncmp(ParameterString.c_str(),"VFCH(12,",8)){
00871     int ind = atoi(&ParameterString[8]);if(ind<1||ind>2) return 0;
00872     hwpram.VFCH[ind-1][11] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00873   else if(!strncmp(ParameterString.c_str(),"VFCH(13,",8)){
00874     int ind = atoi(&ParameterString[8]);if(ind<1||ind>2) return 0;
00875     hwpram.VFCH[ind-1][12] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00876   else if(!strncmp(ParameterString.c_str(),"VFCH(14,",8)){
00877     int ind = atoi(&ParameterString[8]);if(ind<1||ind>2) return 0;
00878     hwpram.VFCH[ind-1][13] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00879   else if(!strncmp(ParameterString.c_str(),"VFCH(15,",8)){
00880     int ind = atoi(&ParameterString[8]);if(ind<1||ind>2) return 0;
00881     hwpram.VFCH[ind-1][14] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00882   else if(!strncmp(ParameterString.c_str(),"VFCH(16,",8)){
00883     int ind = atoi(&ParameterString[8]);if(ind<1||ind>2) return 0;
00884     hwpram.VFCH[ind-1][15] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00885   else if(!strncmp(ParameterString.c_str(),"ZPRIME",6))
00886     hwpram.ZPRIME = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00887   else if(!strncmp(ParameterString.c_str(),"RMASS(202)",10))
00888     hwprop.RMASS[202] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00889   else if(!strncmp(ParameterString.c_str(),"GAMZP",5))
00890     hwpram.GAMZP = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00891   else if(!strncmp(ParameterString.c_str(),"VCKM(",5)) {
00892     int ind1 = atoi(&ParameterString[5]);
00893     if(ind1<1||ind1>3) return 0;
00894     int ind2 = atoi(&ParameterString[7]);
00895     if(ind2<1||ind2>3) return 0;
00896     hwpram.VCKM[ind2][ind1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00897   else if(!strncmp(ParameterString.c_str(),"SCABI",5))
00898     hwpram.SCABI = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00899   else if(!strncmp(ParameterString.c_str(),"EPOLN(",6)) {
00900     int ind = atoi(&ParameterString[6]);
00901     if(ind<1||ind>3) return 0;
00902     hwhard.EPOLN[ind-1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00903   else if(!strncmp(ParameterString.c_str(),"PPOLN(",6)) {
00904     int ind = atoi(&ParameterString[6]);
00905     if(ind<1||ind>3) return 0;
00906     hwhard.PPOLN[ind-1] = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); }
00907   else if(!strncmp(ParameterString.c_str(),"QLIM",4))
00908     hwhard.QLIM = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);         
00909   else if(!strncmp(ParameterString.c_str(),"THMAX",5))
00910     hwhard.THMAX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);         
00911   else if(!strncmp(ParameterString.c_str(),"Y4JT",4))
00912     hwhard.Y4JT = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);         
00913   else if(!strncmp(ParameterString.c_str(),"DURHAM",6))
00914     hwhard.DURHAM = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);         
00915   else if(!strncmp(ParameterString.c_str(),"IOP4JT(1)",9))
00916     hwpram.IOP4JT[0] = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);         
00917   else if(!strncmp(ParameterString.c_str(),"IOP4JT(2)",9))
00918     hwpram.IOP4JT[1] = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);         
00919   else if(!strncmp(ParameterString.c_str(),"BGSHAT",6))
00920     hwhard.BGSHAT = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);         
00921   else if(!strncmp(ParameterString.c_str(),"BREIT",5))
00922     hwbrch.BREIT = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);         
00923   else if(!strncmp(ParameterString.c_str(),"USECMF",6))
00924     hwbrch.USECMF = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);         
00925   else if(!strncmp(ParameterString.c_str(),"NOSPAC",6))
00926     hwpram.NOSPAC = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);         
00927   else if(!strncmp(ParameterString.c_str(),"ISPAC",5))
00928     hwpram.ISPAC = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);         
00929   else if(!strncmp(ParameterString.c_str(),"TMNISR",6))
00930     hwhard.TMNISR = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);         
00931   else if(!strncmp(ParameterString.c_str(),"ZMXISR",6))
00932     hwhard.ZMXISR = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);         
00933   else if(!strncmp(ParameterString.c_str(),"ASFIXD",6))
00934     hwhard.ASFIXD = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);         
00935   else if(!strncmp(ParameterString.c_str(),"OMEGA0",6))
00936     hwhard.OMEGA0 = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);         
00937   else if(!strncmp(ParameterString.c_str(),"IAPHIG",6))
00938     hwhard.IAPHIG = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);         
00939   else if(!strncmp(ParameterString.c_str(),"PHOMAS",6))
00940     hwhard.PHOMAS = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);         
00941   else if(!strncmp(ParameterString.c_str(),"PRESPL",6))
00942     hw6500.PRESPL = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]);            
00943   else if(!strncmp(ParameterString.c_str(),"PTMIN",5))
00944     hwhard.PTMIN = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00945   else if(!strncmp(ParameterString.c_str(),"PTMAX",5))
00946     hwhard.PTMAX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00947   else if(!strncmp(ParameterString.c_str(),"PTPOW",5))
00948     hwhard.PTPOW = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00949   else if(!strncmp(ParameterString.c_str(),"YJMIN",5))
00950     hwhard.YJMIN = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00951   else if(!strncmp(ParameterString.c_str(),"YJMAX",5))
00952     hwhard.YJMAX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00953   else if(!strncmp(ParameterString.c_str(),"EMMIN",5))
00954     hwhard.EMMIN = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00955   else if(!strncmp(ParameterString.c_str(),"EMMAX",5))
00956     hwhard.EMMAX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00957   else if(!strncmp(ParameterString.c_str(),"EMPOW",5))
00958     hwhard.EMPOW = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00959   else if(!strncmp(ParameterString.c_str(),"Q2MIN",5))
00960     hwhard.Q2MIN = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00961   else if(!strncmp(ParameterString.c_str(),"Q2MAX",5))
00962     hwhard.Q2MAX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00963   else if(!strncmp(ParameterString.c_str(),"Q2POW",5))
00964     hwhard.Q2POW = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00965   else if(!strncmp(ParameterString.c_str(),"YBMIN",5))
00966     hwhard.YBMIN = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00967   else if(!strncmp(ParameterString.c_str(),"YBMAX",5))
00968     hwhard.YBMAX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00969   else if(!strncmp(ParameterString.c_str(),"WHMIN",5))
00970     hwhard.WHMIN = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00971   else if(!strncmp(ParameterString.c_str(),"ZJMAX",5))
00972     hwhard.ZJMAX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00973   else if(!strncmp(ParameterString.c_str(),"Q2WWMN",6))
00974     hwhard.Q2WWMN = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00975   else if(!strncmp(ParameterString.c_str(),"Q2WWMX",6))
00976     hwhard.Q2WWMX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00977   else if(!strncmp(ParameterString.c_str(),"YWWMIN",6))
00978     hwhard.YWWMIN = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00979   else if(!strncmp(ParameterString.c_str(),"YWWMAX",6))
00980     hwhard.YWWMAX = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00981   else if(!strncmp(ParameterString.c_str(),"CSPEED",6))
00982     hwpram.CSPEED = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00983   else if(!strncmp(ParameterString.c_str(),"GEV2NB",6))
00984     hwpram.GEV2NB = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00985   else if(!strncmp(ParameterString.c_str(),"IBSH",4))
00986     hwhard.IBSH = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00987   else if(!strncmp(ParameterString.c_str(),"IBRN(1)",7))
00988     hwhard.IBRN[0] = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00989   else if(!strncmp(ParameterString.c_str(),"IBRN(2)",7))
00990     hwhard.IBRN[1] = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00991   else if(!strncmp(ParameterString.c_str(),"NQEV",4))
00992     hwusud.NQEV = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00993   else if(!strncmp(ParameterString.c_str(),"ZBINM",5))
00994     hwpram.ZBINM = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00995   else if(!strncmp(ParameterString.c_str(),"NZBIN",5))
00996     hwpram.NZBIN = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00997   else if(!strncmp(ParameterString.c_str(),"NBTRY",5))
00998     hwpram.NBTRY = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
00999   else if(!strncmp(ParameterString.c_str(),"NCTRY",5))
01000     hwpram.NCTRY = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01001   else if(!strncmp(ParameterString.c_str(),"NETRY",5))
01002     hwpram.NETRY = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01003   else if(!strncmp(ParameterString.c_str(),"NSTRY",5))
01004     hwpram.NSTRY = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01005   else if(!strncmp(ParameterString.c_str(),"ACCUR",5))
01006     hwusud.ACCUR = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01007   else if(!strncmp(ParameterString.c_str(),"RPARTY",6))
01008     hwrpar.RPARTY = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01009   else if(!strncmp(ParameterString.c_str(),"SUSYIN",6))
01010     hwsusy.SUSYIN = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01011   else if(!strncmp(ParameterString.c_str(),"LRSUSY",6))
01012     hw6202.LRSUSY = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01013   else if(!strncmp(ParameterString.c_str(),"SYSPIN",6))
01014     hwdspn.SYSPIN = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01015   else if(!strncmp(ParameterString.c_str(),"THREEB",6))
01016     hwdspn.THREEB = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01017   else if(!strncmp(ParameterString.c_str(),"FOURB",5))
01018     hwdspn.FOURB = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01019   else if(!strncmp(ParameterString.c_str(),"LHSOFT",6))
01020     hwgupr.LHSOFT = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01021   else if(!strncmp(ParameterString.c_str(),"LHGLSF",6))
01022     hwgupr.LHGLSF = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01023   else if(!strncmp(ParameterString.c_str(),"OPTM",4))
01024     hw6300.OPTM = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01025   else if(!strncmp(ParameterString.c_str(),"IOPSTP",6))
01026     hw6300.IOPSTP = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01027   else if(!strncmp(ParameterString.c_str(),"IOPSH",5))
01028     hw6300.IOPSH = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01029   else if(!strncmp(ParameterString.c_str(),"JMUEO",5))
01030     jmparm.JMUEO = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01031   else if(!strncmp(ParameterString.c_str(),"PTJIM",5))
01032     jmparm.PTJIM = atof(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01033   else if(!strncmp(ParameterString.c_str(),"JMRAD(73)",9))
01034     jmparm.JMRAD[72] = atoi(&ParameterString[strcspn(ParameterString.c_str(),"=")+1]); 
01035 
01036   else accepted = 0;
01037 
01038   return accepted;
01039 }

bool Herwig6Source::produce ( Event e  )  [private, virtual]

Implements edm::ConfigurableInputSource.

Definition at line 235 of file Herwig6Source.cc.

References conv, counter(), doMPInteraction_, evt, Exception, herwigHepMCVerbosity_, hwmsct_dummy, edm::ConfigurableInputSource::numberEventsInRun(), numTrials_, edm::Event::put(), edm::InputSource::remainingEvents(), and useJimmy_.

00235                                      {
00236 
00237   int counter = 0;
00238   double mpiok = 1.0;
00239 
00240   while(mpiok > 0.5 && counter < numTrials_) {
00241 
00242     // call herwig routines to create HEPEVT
00243     hwuine();
00244     hwepro();
00245     hwbgen();  
00246 
00247     // call jimmy ... only if event is not killed yet by HERWIG
00248     if(useJimmy_ && doMPInteraction_ && hwevnt.IERROR==0)
00249       mpiok = hwmsct_dummy(1.1);
00250     else mpiok = 0.0;
00251     counter++;
00252   }
00253   
00254   // event after numTrials MP is not ok -> skip event
00255   if(mpiok > 0.5) {
00256     LogWarning("") <<"   JIMMY could not produce MI in "<<numTrials_<<" trials.\n"<<"   Event will be skipped to prevent from deadlock.\n";
00257     return true;
00258   }  
00259   
00260   hwdhob();
00261   hwcfor();
00262   hwcdec();
00263   hwdhad();
00264   hwdhvy();
00265   hwmevt();
00266   hwufne();
00267   
00268   // if event was killed by HERWIG; skip 
00269   if(hwevnt.IERROR!=0) return true;
00270 
00271   // -----------------  HepMC converter --------------------
00272   HepMC::IO_HERWIG conv;
00273 
00274   // HEPEVT is ok, create new HepMC event
00275   evt = new HepMC::GenEvent();
00276   bool ok = conv.fill_next_event( evt );
00277   // if conversion failed; throw excpetion and stop processing
00278   if(!ok) throw cms::Exception("HerwigError")
00279     <<" Conversion problems in event nr."<<numberEventsInRun() - remainingEvents() - 1<<".";  
00280 
00281   // set process id and event number
00282   evt->set_signal_process_id(hwproc.IPROC);  
00283   evt->set_event_number(numberEventsInRun() - remainingEvents() - 1);
00284   
00285   if (herwigHepMCVerbosity_) {
00286     LogWarning("") << "Event process = " << evt->signal_process_id() << "\n----------------------\n";
00287     evt->print();
00288   }
00289   
00290   // dummy if: event MUST be there
00291   if(evt)  {
00292     auto_ptr<HepMCProduct> bare_product(new HepMCProduct());  
00293     bare_product->addHepMCData(evt );
00294     e.put(bare_product);
00295   }
00296   
00297   return true;
00298 }

bool Herwig6Source::setRngSeeds ( int  mseed  )  [private]

Definition at line 1052 of file Herwig6Source.cc.

References c, i, and int.

Referenced by Herwig6Source().

01053 {
01054   double temx[5];
01055   for (int i=0; i<5; i++) {
01056     mseed = mseed * 29943829 - 1;
01057     temx[i] = mseed * (1./(65536.*65536.));
01058   }
01059   long double c;
01060   c = (long double)2111111111.0 * temx[3] +
01061     1492.0 * (temx[3] = temx[2]) +
01062     1776.0 * (temx[2] = temx[1]) +
01063     5115.0 * (temx[1] = temx[0]) +
01064     temx[4];
01065   temx[4] = floorl(c);
01066   temx[0] = c - temx[4];
01067   temx[4] = temx[4] * (1./(65536.*65536.));
01068   hwevnt.NRN[0]=int(temx[0]*99999);
01069   c = (long double)2111111111.0 * temx[3] +
01070     1492.0 * (temx[3] = temx[2]) +
01071     1776.0 * (temx[2] = temx[1]) +
01072     5115.0 * (temx[1] = temx[0]) +
01073     temx[4];
01074   temx[4] = floorl(c);
01075   temx[0] = c - temx[4];
01076   hwevnt.NRN[1]=int(temx[0]*99999);
01077 
01078   return true;
01079 }


Member Data Documentation

double edm::Herwig6Source::comenergy [private]

Definition at line 47 of file Herwig6Source.h.

Referenced by Herwig6Source().

bool edm::Herwig6Source::doMPInteraction_ [private]

Definition at line 50 of file Herwig6Source.h.

Referenced by Herwig6Source(), and produce().

HepMC::GenEvent* edm::Herwig6Source::evt [private]

Definition at line 42 of file Herwig6Source.h.

Referenced by produce().

double edm::Herwig6Source::extCrossSect [private]

Definition at line 54 of file Herwig6Source.h.

Referenced by endRun().

double edm::Herwig6Source::extFilterEff [private]

Definition at line 56 of file Herwig6Source.h.

Referenced by endRun().

CLHEP::HepRandomEngine* edm::Herwig6Source::fRandomEngine [private]

Definition at line 58 of file Herwig6Source.h.

Referenced by Herwig6Source().

bool edm::Herwig6Source::herwigHepMCVerbosity_ [private]

Definition at line 44 of file Herwig6Source.h.

Referenced by Herwig6Source(), and produce().

int edm::Herwig6Source::herwigLhapdfVerbosity_ [private]

Definition at line 45 of file Herwig6Source.h.

Referenced by Herwig6Source().

int edm::Herwig6Source::herwigVerbosity_ [private]

Definition at line 43 of file Herwig6Source.h.

Referenced by Herwig6Source().

double edm::Herwig6Source::intCrossSect [private]

Definition at line 55 of file Herwig6Source.h.

Referenced by endRun().

std::string edm::Herwig6Source::lhapdfSetPath_ [private]

Definition at line 48 of file Herwig6Source.h.

Referenced by Herwig6Source().

int edm::Herwig6Source::maxEventsToPrint_ [private]

Definition at line 46 of file Herwig6Source.h.

Referenced by Herwig6Source().

int edm::Herwig6Source::numTrials_ [private]

Definition at line 52 of file Herwig6Source.h.

Referenced by produce().

bool edm::Herwig6Source::printCards_ [private]

Definition at line 51 of file Herwig6Source.h.

Referenced by Herwig6Source().

bool edm::Herwig6Source::useJimmy_ [private]

Definition at line 49 of file Herwig6Source.h.

Referenced by clear(), Herwig6Source(), and produce().


The documentation for this class was generated from the following files:
Generated on Tue Jun 9 18:41:14 2009 for CMSSW by  doxygen 1.5.4