]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - PYTHIA6/AliGenPythia.cxx
Fix axis label
[u/mrichter/AliRoot.git] / PYTHIA6 / AliGenPythia.cxx
index b8371da4934f852e2fc4f688187ab2f6cab669eb..f2a4023d2c33c55de511ebc6ffd65d7550268307 100644 (file)
@@ -70,6 +70,7 @@ AliGenPythia::AliGenPythia():
     fFlavorSelect(0),
     fXsection(0.),
     fPythia(0),
+    fWeightPower(0.),
     fPtHardMin(0.),
     fPtHardMax(1.e4),
     fYHardMin(-1.e10),
@@ -192,6 +193,7 @@ AliGenPythia::AliGenPythia(Int_t npart)
      fFlavorSelect(0),
      fXsection(0.),
      fPythia(0),
+     fWeightPower(0.),
      fPtHardMin(0.),
      fPtHardMax(1.e4),
      fYHardMin(-1.e10),
@@ -391,8 +393,8 @@ void AliGenPythia::Init()
 //
     fParentWeight=1./Float_t(fNpart);
 //
-
-
+    if (fWeightPower != 0)
+      fPythia->SetWeightPower(fWeightPower);
     fPythia->SetCKIN(3,fPtHardMin);
     fPythia->SetCKIN(4,fPtHardMax);
     fPythia->SetCKIN(7,fYHardMin);
@@ -1379,8 +1381,9 @@ void AliGenPythia::MakeHeader()
                
 //
 // Store Event Weight
-    ((AliGenPythiaEventHeader*) fHeader)->SetEventWeight(fPythia->GetPARI(7));
-                               
+    ((AliGenPythiaEventHeader*) fHeader)->SetEventWeight(fPythia->GetPARI(7)*fPythia->GetPARI(10));
+    // PARI(7) is 1 or -1, for weighted generation with accept/reject, e.g. POWHEG
+    // PARI(10) is a weight associated with reweighted generation, using Pyevwt
 //
 //  Pass header
 //