Selector to generate Monte Carlo events with Pythia8. 
 
#define ProofPythia_cxx
 
#include <TFormula.h>
 
 
ProofPythia::ProofPythia()
{
   
 
   fHist = 0;
   fPt = 0;
   fEta = 0;
   fPythia = 0;
   fP = 0;
}
 
ProofPythia::~ProofPythia()
{
   
 
}
 
void ProofPythia::Begin(
TTree * )
 
{
   
   
   
 
   Info(
"Begin", 
"starting a simple exercise with process option: %s", 
option.Data());
 
}
 
void ProofPythia::SlaveBegin(
TTree * )
 
{
   
   
   
 
 
   
   fTot = 
new TH1F(
"histo1", 
"total multiplicity", 25, 0.5, 2500.5);
 
   fHist = 
new TH1F(
"histo2", 
"charged multiplicity", 20, 0.5, 500.5);
   fPt = 
new TH1F(
"histo3", 
"particles pT", 100, 0., 10);
   fEta = 
new TH1F(
"histo4", 
"particles Eta", 100, -10., 10);
   fHist->SetFillColor(
kRed);
   fOutput->Add(fHist);
   fOutput->Add(fPt);
   fOutput->Add(fEta);
 
   
   fPythia->SetName("pythia8");
   fPythia->ReadConfigFile("pythia8/main03.cmnd");
 
   
   fPythia->Initialize( 2212, 2212, 14000.);
 
}
 
{
   
 
   fPythia->GenerateEvent();
      fPythia->EventListing();
   fPythia->ImportParticles(fP, "All");
   fPythia->ImportParticles(fP, "All");
   
      if (
pt > 0.) fPt->Fill(
pt);
 
      if ((eta > -10) && (eta < 10)) fEta->Fill(eta);
   }
 
}
 
void ProofPythia::SlaveTerminate()
{
   
   
   
}
 
void ProofPythia::Terminate()
{
   
   
   
 
   
   
   
 
   if ((
fTot = 
dynamic_cast<TH1F *
>(fOutput->FindObject(
"histo1")))) {
 
   }
 
   if ((fHist = 
dynamic_cast<TH1F *
>(fOutput->FindObject(
"histo2")))) {
 
      fHist->Draw("h");
   }
 
   if ((fPt = 
dynamic_cast<TH1F *
>(fOutput->FindObject(
"histo3")))) {
 
      fPt->Draw("h");
   }
 
   if ((fEta = 
dynamic_cast<TH1F *
>(fOutput->FindObject(
"histo4")))) {
 
      fEta->Draw("h");
   }
 
   
}
Selector to generate Monte Carlo events with Pythia8.
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t np
An array of clone (identical) objects.
static TDatabasePDG * Instance()
static function
1-D histogram with a float per channel (see TH1 documentation)
Description of the dynamic properties of a particle.
TPythia8 is an interface class to C++ version of Pythia 8.1   event generators, written by T....
A TTree represents a columnar dataset.
- Author
- Gerardo Ganis (gerar.nosp@m.do.g.nosp@m.anis@.nosp@m.cern.nosp@m..ch) 
Definition in file ProofPythia.C.