TauSpinner Implementation

Documentation and Code

Libraries needed

  • TAUOLA
  • HEPMC
  • LHAPDF

These are the commands line I used to set up my working area (32bit machine):

mkdir HEPMC
cd HEPMC/
../HepMC-2.06.09/configure CXXFLAG=-m32 CFLAGS=-m32 CPPFLAGS=-m32 FFLAGS=-m32 --with-momentum=GEV --with-length=MM --prefix=$PWD
make
make check
make install

...

mkdir LHAPDF
cd lhapdf-5.8.9b2
./configure --prefix=/path/to/LHAPDF CXXFLAGS="-m32 -fno-inline" CFLAGS="-m32 -fno-inline" CPPFLAGS="-m32 -fno-inline" FCFLAGS="-m32 -fno-inline" FFLAGS="-m32 -fno-inline" --disable-pyext
make
make check
make install

...

cd TAUOLA/
./configure --with-hepmc=/path/to/HEPMC/ CXXFLAG=-m32 CFLAGS=-m32 CPPFLAGS=-m32 FFLAGS=-m32
make
make check
make install

Then, in addition to linking to the lib/ and include/ directories, it is necessary to set the LHAPATH to the directory which contains the PDFsets:

export LHAPATH=path/to/pdfsets_directory

Implementation

Check out the files here: AnalysisLib, plus this: mcReader.h. I have written a new interface, so instead of using Prepare_For_TauSpinnering.h and Prepare_For_TauSpinnering.cxx, please use:

Initialize TAUOLA and the PDF:

     /*******Initialize Tauola********/
      Tauola::initialize();
      double CMSENE = 8000.0; // center of mass system energy.
      bool Ipp = true;  // for pp collisions
      int Ipol = 2;
      initialize_spinner(Ipp, Ipol, CMSENE);

      /*******Initialize PDFs********/
      string name="MRSTMCal.LHgrid";//MSTW2008nnlo90cl.LHgrid";
      LHAPDF::initPDFSetByName(name);

      /*******Initialize mcReader**/
      mcReader my_mcReader;
      my_mcReader.Reset();

In the event loop:

my_mcReader.Reset();
float spin_weight = 1.;
my_mcReader.mc_n = mc_n;
for(unsigned int i = 0;i<mc_n;i++){
   my_mcReader.mc_pt->push_back(mc_pt->at(i));
   my_mcReader.mc_eta->push_back(mc_eta->at(i));
   my_mcReader.mc_phi->push_back(mc_phi->at(i));
   my_mcReader.mc_m->push_back(mc_m->at(i));
   my_mcReader.mc_pdgId->push_back(mc_pdgId->at(i));
   my_mcReader.mc_child_index->push_back(std::vector<int>());
   for(unsigned int j = 0;j<mc_n;j++) my_mcReader.mc_child_index->at(i).push_back(*mc_child_index[i][j]);
}
spin_weight = GetSpinWeight(my_mcReader,"Emb_");


Major updates:
-- DanieleZanzi - 24-Jan-2013

Edit | Attach | Watch | Print version | History: r3 < r2 < r1 | Backlinks | Raw View | WYSIWYG | More topic actions
Topic revision: r3 - 2013-02-07 - DanieleZanzi
 
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    Main All webs login

This site is powered by the TWiki collaboration platform Powered by PerlCopyright & 2008-2019 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback