ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/MitPhysics/Mods/src/GeneratorMod.cc
Revision: 1.13
Committed: Tue Dec 2 09:35:54 2008 UTC (16 years, 5 months ago) by loizides
Content type: text/plain
Branch: MAIN
Changes since 1.12: +18 -10 lines
Log Message:
Set name on collections.

File Contents

# User Rev Content
1 loizides 1.13 // $Id: GeneratorMod.cc,v 1.12 2008/12/01 11:44:34 ceballos Exp $
2 loizides 1.1
3     #include "MitPhysics/Mods/interface/GeneratorMod.h"
4     #include "MitCommon/MathTools/interface/MathUtils.h"
5 loizides 1.8 #include "MitPhysics/Init/interface/ModNames.h"
6 loizides 1.1 #include <TH1D.h>
7     #include <TH2D.h>
8    
9     using namespace mithep;
10    
11     ClassImp(mithep::GeneratorMod)
12    
13     //--------------------------------------------------------------------------------------------------
14 loizides 1.8 GeneratorMod::GeneratorMod(const char *name, const char *title) :
15 loizides 1.1 BaseMod(name,title),
16 loizides 1.5 fFillHist(kFALSE),
17 loizides 1.1 fMCPartName(Names::gkMCPartBrn),
18 loizides 1.8 fMCLeptonsName(ModNames::gkMCLeptonsName),
19     fMCAllLeptonsName(ModNames::gkMCAllLeptonsName),
20     fMCTausName(ModNames::gkMCTausName),
21     fMCNeutrinosName(ModNames::gkMCNeutrinosName),
22     fMCQuarksName(ModNames::gkMCQuarksName),
23     fMCqqHsName(ModNames::gkMCqqHsName),
24     fMCBosonsName(ModNames::gkMCBosonsName),
25 ceballos 1.10 fMCPhotonsName(ModNames::gkMCPhotonsName),
26 loizides 1.6 fParticles(0)
27 loizides 1.1 {
28     // Constructor.
29     }
30    
31     //--------------------------------------------------------------------------------------------------
32     void GeneratorMod::Process()
33     {
34 loizides 1.5 // Process entries of the tree.
35 loizides 1.1
36 loizides 1.5 // these arrays will be filled in the loop of particles
37 loizides 1.9 MCParticleOArr *GenLeptons = new MCParticleOArr;
38 loizides 1.13 GenLeptons->SetName(fMCLeptonsName);
39 loizides 1.9 MCParticleOArr *GenAllLeptons = new MCParticleOArr;
40 loizides 1.13 GenAllLeptons->SetName(fMCAllLeptonsName);
41 loizides 1.9 MCParticleOArr *GenTaus = new MCParticleOArr;
42 loizides 1.13 GenTaus->SetName(fMCTausName);
43     GenTaus->SetOwner(kTRUE);
44 loizides 1.9 MCParticleOArr *GenNeutrinos = new MCParticleOArr;
45 loizides 1.13 GenNeutrinos->SetName(fMCNeutrinosName);
46 loizides 1.9 MCParticleOArr *GenQuarks = new MCParticleOArr;
47 loizides 1.13 GenQuarks->SetName(fMCQuarksName);
48 loizides 1.9 MCParticleOArr *GenqqHs = new MCParticleOArr;
49 loizides 1.13 GenqqHs->SetName(fMCqqHsName);
50 loizides 1.9 MCParticleOArr *GenBosons = new MCParticleOArr;
51 loizides 1.13 GenBosons->SetName(fMCBosonsName);
52 ceballos 1.10 MCParticleOArr *GenPhotons = new MCParticleOArr;
53 loizides 1.13 GenPhotons->SetName(fMCPhotonsName);
54 loizides 1.1
55 loizides 1.5 // load MCParticle branch
56     LoadBranch(fMCPartName);
57    
58 loizides 1.6 Bool_t isqqH = kFALSE;
59 loizides 1.5 for (UInt_t i=0; i<fParticles->GetEntries(); ++i) {
60 loizides 1.7 const MCParticle *p = fParticles->At(i);
61 loizides 1.5
62     if (!p->IsGenerated()) continue;
63    
64     // muons/electrons from W/Z decays
65 loizides 1.7 if ((p->Is(MCParticle::kEl) || p->Is(MCParticle::kMu)) && p->Status() == 1) {
66 loizides 1.5 if (p->Pt() > 3.0 && TMath::Abs(p->Eta()) < 3.0) {
67     GenAllLeptons->Add(p);
68     }
69 loizides 1.6 Bool_t isGoodLepton = kFALSE;
70 loizides 1.7 const MCParticle *pm = p;
71 loizides 1.5 while (pm->HasMother() && isGoodLepton == kFALSE) {
72 loizides 1.7 if (pm->Mother()->Is(MCParticle::kZ) || pm->Mother()->Is(MCParticle::kW)) {
73 loizides 1.5 GenLeptons->Add(p);
74     isGoodLepton = kTRUE;
75 loizides 1.7 break;
76 loizides 1.8 } else if (pm->Mother()->Is(MCParticle::kPi0) || pm->Mother()->Is(MCParticle::kEta)) {
77 loizides 1.7 // this is fake, but it is a trick to get rid of these cases and abort the loop
78 loizides 1.5 isGoodLepton = kTRUE;
79 loizides 1.7 break;
80     }
81     pm = pm->Mother();
82 loizides 1.1 }
83 loizides 1.5 }
84    
85 loizides 1.7 // hadronic taus
86     else if (p->Is(MCParticle::kTau) && p->Status() == 2) {
87     if (!p->HasDaughter(MCParticle::kEl) && !p->HasDaughter(MCParticle::kMu)) {
88     const MCParticle *tv = p->FindDaughter(MCParticle::kTauNu);
89     if (tv) {
90     MCParticle *pm_f = new MCParticle(*p);
91     pm_f->SetMom(p->Px()-tv->Px(), p->Py()-tv->Py(),
92     p->Pz()-tv->Pz(), p->E()-tv->E());
93     GenTaus->AddOwned(pm_f);
94     } else {
95     SendError(kWarning, "Process", "Could not find tau neutrino!");
96 loizides 1.5 }
97 loizides 1.1 }
98 loizides 1.5 }
99 loizides 1.1
100 loizides 1.5 // neutrinos
101 loizides 1.7 else if (p->Status() == 1 && p->IsNeutrino()) {
102 loizides 1.5 GenNeutrinos->Add(p);
103     }
104 loizides 1.1
105 loizides 1.5 // quarks from W/Z decays or top particles
106 loizides 1.7 else if (p->IsQuark() && p->HasMother()) {
107     if (p->Mother()->Is(MCParticle::kZ) || p->Mother()->Is(MCParticle::kW) ||
108     p->Is(MCParticle::kTop) || p->Mother()->Is(MCParticle::kTop)) {
109 loizides 1.5 GenQuarks->Add(p);
110 loizides 1.1 }
111 loizides 1.5 }
112 loizides 1.1
113 loizides 1.5 // qqH, information about the forward jets
114 loizides 1.8 else if (isqqH == kFALSE && p->Is(MCParticle::kH)) {
115 loizides 1.5 isqqH = kTRUE;
116     MCParticle *pq1 = fParticles->At(i-1);
117     MCParticle *pq2 = fParticles->At(i-2);
118 loizides 1.7 if (!pq1 || !pq2) {
119     SendError(kWarning, "Process", "Could not find quark pair!");
120 loizides 1.8 } else if (pq1->IsQuark() && pq2->IsQuark() &&
121     pq1->HasMother() && pq2->HasMother() &&
122     pq1->Mother()->PdgId() == p->Mother()->PdgId() &&
123     pq2->Mother()->PdgId() == p->Mother()->PdgId()) {
124 loizides 1.5 GenqqHs->Add(pq1);
125     GenqqHs->Add(pq2);
126 loizides 1.1 }
127 loizides 1.7 if (p->Status() == 3)
128     GenBosons->Add(p); // take higgs boson in account here rather in next else if
129 loizides 1.5 }
130 loizides 1.1
131 loizides 1.5 // information about bosons: W, Z, h, Z', W', H0, A0, H+
132 loizides 1.7 else if (p->Status() == 3 &&
133     (p->Is(MCParticle::kZ) || p->Is(MCParticle::kW) || p->Is(MCParticle::kH) ||
134     p->Is(MCParticle::kZp) || p->Is(MCParticle::kZpp) ||
135     p->Is(MCParticle::kH0) || p->Is(MCParticle::kA0) || p->Is(MCParticle::kHp))) {
136 loizides 1.5 GenBosons->Add(p);
137 loizides 1.1 }
138 ceballos 1.10
139 ceballos 1.12 // photons, only with Pt > 15
140 ceballos 1.10 else if (p->Status() == 1 && p->Is(MCParticle::kGamma) &&
141 ceballos 1.12 p->Pt() > 15) {
142 ceballos 1.10 GenPhotons->Add(p);
143     }
144    
145 loizides 1.5 }
146 loizides 1.1
147 loizides 1.8 // add objects to this event for other modules to use
148 loizides 1.13 AddObjThisEvt(GenLeptons);
149     AddObjThisEvt(GenAllLeptons);
150     AddObjThisEvt(GenTaus);
151     AddObjThisEvt(GenNeutrinos);
152     AddObjThisEvt(GenQuarks);
153     AddObjThisEvt(GenqqHs);
154     AddObjThisEvt(GenBosons);
155     AddObjThisEvt(GenPhotons);
156 ceballos 1.10
157 loizides 1.5 // fill histograms if requested
158     if (fFillHist) {
159    
160 loizides 1.6 // leptons
161 loizides 1.1 hDGenLeptons[0]->Fill(GenLeptons->GetEntries());
162 loizides 1.5 Int_t idxMaxLep[2] = {-1, -1};
163     Double_t ptMaxLep[2] = {-1, -1};
164     for(UInt_t i=0; i<GenLeptons->GetEntries(); i++) {
165 loizides 1.1 hDGenLeptons[1]->Fill(GenLeptons->At(i)->Pt());
166 loizides 1.5 hDGenLeptons[2]->Fill(TMath::Abs(GenLeptons->At(i)->Eta()));
167     hDGenLeptons[3]->Fill(GenLeptons->At(i)->PhiDeg());
168     for(UInt_t j=i+1; j<GenLeptons->GetEntries(); j++) {
169 loizides 1.1 CompositeParticle *dilepton = new CompositeParticle();
170     dilepton->AddDaughter(GenLeptons->At(i));
171     dilepton->AddDaughter(GenLeptons->At(j));
172     hDGenLeptons[4]->Fill(dilepton->Mass());
173     delete dilepton;
174     }
175 loizides 1.6 // selecting the two highest pt leptons
176 loizides 1.5 if (GenLeptons->At(i)->Pt() > ptMaxLep[0]) {
177 loizides 1.1 ptMaxLep[1] = ptMaxLep[0];
178     idxMaxLep[1] = idxMaxLep[0];
179     ptMaxLep[0] = GenLeptons->At(i)->Pt();
180     idxMaxLep[0] = i;
181     }
182 loizides 1.5 else if (GenLeptons->At(i)->Pt() > ptMaxLep[1]) {
183 loizides 1.1 ptMaxLep[1] = GenLeptons->At(i)->Pt();
184     idxMaxLep[1] = i;
185     }
186     }
187 loizides 1.6 // looking at events with at least two leptons
188 loizides 1.5 if (ptMaxLep[0] > 0 && ptMaxLep[1] > 0) {
189     hDGenLeptons[5]->Fill(TMath::Min(TMath::Max(TMath::Abs(GenLeptons->At(idxMaxLep[0])->Eta()),
190     TMath::Abs(GenLeptons->At(idxMaxLep[1])->Eta())),
191     4.999));
192     hDGenLeptons[6]->Fill(TMath::Min(TMath::Min(TMath::Abs(GenLeptons->At(idxMaxLep[0])->Eta()),
193     TMath::Abs(GenLeptons->At(idxMaxLep[1])->Eta())),
194     4.999));
195     if (TMath::Abs(GenLeptons->At(idxMaxLep[0])->Eta()) < 2.5 &&
196     TMath::Abs(GenLeptons->At(idxMaxLep[1])->Eta()) < 2.5) {
197 loizides 1.1 hDGenLeptons[7]->Fill(TMath::Min(GenLeptons->At(idxMaxLep[0])->Pt(),199.999));
198 loizides 1.5 if (GenLeptons->At(idxMaxLep[0])->Pt() > 20.0) {
199 loizides 1.1 hDGenLeptons[8]->Fill(TMath::Min(GenLeptons->At(idxMaxLep[1])->Pt(),199.999));
200 loizides 1.5 if (GenLeptons->At(idxMaxLep[1])->Pt() > 10.0) {
201 loizides 1.1 CompositeParticle *dilepton = new CompositeParticle();
202     dilepton->AddDaughter(GenLeptons->At(idxMaxLep[0]));
203     dilepton->AddDaughter(GenLeptons->At(idxMaxLep[1]));
204     hDGenLeptons[9]->Fill(TMath::Min(dilepton->Mass(),999.999));
205     hDGenLeptons[10]->Fill(MathUtils::DeltaPhi(GenLeptons->At(idxMaxLep[0])->Phi(),
206     GenLeptons->At(idxMaxLep[1])->Phi())
207     * 180./ TMath::Pi());
208     delete dilepton;
209     }
210     }
211     }
212     }
213    
214 loizides 1.6 // all leptons
215 ceballos 1.3 hDGenAllLeptons[0]->Fill(GenAllLeptons->GetEntries());
216 loizides 1.5 for(UInt_t i=0; i<GenAllLeptons->GetEntries(); i++) {
217 ceballos 1.3 hDGenAllLeptons[1]->Fill(GenAllLeptons->At(i)->Pt());
218     hDGenAllLeptons[2]->Fill(GenAllLeptons->At(i)->Eta());
219 loizides 1.5 hDGenAllLeptons[3]->Fill(GenAllLeptons->At(i)->PhiDeg());
220 ceballos 1.3 }
221    
222 loizides 1.6 // taus
223 loizides 1.1 hDGenTaus[0]->Fill(GenTaus->GetEntries());
224 loizides 1.5 for(UInt_t i=0; i<GenTaus->GetEntries(); i++) {
225 loizides 1.1 hDGenTaus[1]->Fill(GenTaus->At(i)->Pt());
226     hDGenTaus[2]->Fill(GenTaus->At(i)->Eta());
227 loizides 1.5 hDGenTaus[3]->Fill(GenTaus->At(i)->PhiDeg());
228 loizides 1.1 }
229    
230 loizides 1.6 // neutrinos
231 loizides 1.1 hDGenNeutrinos[0]->Fill(GenNeutrinos->GetEntries());
232     CompositeParticle *neutrinoTotal = new CompositeParticle();
233 loizides 1.5 for(UInt_t i=0; i<GenNeutrinos->GetEntries(); i++) {
234     if (GenNeutrinos->At(i)->HasMother())
235 loizides 1.1 neutrinoTotal->AddDaughter(GenNeutrinos->At(i));
236     }
237 loizides 1.5 if (GenNeutrinos->GetEntries() > 0) {
238 loizides 1.1 hDGenNeutrinos[1]->Fill(neutrinoTotal->Pt());
239     hDGenNeutrinos[2]->Fill(neutrinoTotal->Eta());
240 loizides 1.5 hDGenNeutrinos[3]->Fill(neutrinoTotal->PhiDeg());
241 loizides 1.1 }
242     delete neutrinoTotal;
243    
244 loizides 1.6 // quarks
245 loizides 1.1 hDGenQuarks[0]->Fill(GenQuarks->GetEntries());
246 loizides 1.5 for(UInt_t i=0; i<GenQuarks->GetEntries(); i++) {
247     for(UInt_t j=i+1; j<GenQuarks->GetEntries(); j++) {
248 loizides 1.1 CompositeParticle *dijet = new CompositeParticle();
249     dijet->AddDaughter(GenQuarks->At(i));
250     dijet->AddDaughter(GenQuarks->At(j));
251     hDGenQuarks[1]->Fill(dijet->Pt());
252     hDGenQuarks[2]->Fill(dijet->Mass());
253 loizides 1.5 if (TMath::Abs(GenQuarks->At(i)->Eta()) < 2.5 &&
254     TMath::Abs(GenQuarks->At(j)->Eta()) < 2.5) {
255 loizides 1.1 hDGenQuarks[3]->Fill(dijet->Pt());
256     hDGenQuarks[4]->Fill(dijet->Mass());
257     }
258     delete dijet;
259     }
260 ceballos 1.2 // b quark info
261 loizides 1.5 if (GenQuarks->At(i)->AbsPdgId() == 5) {
262 ceballos 1.2 hDGenQuarks[5]->Fill(GenQuarks->At(i)->Pt());
263     hDGenQuarks[6]->Fill(GenQuarks->At(i)->Eta());
264     hDGenQuarks[7]->Fill(GenQuarks->At(i)->Phi());
265 loizides 1.5 if (ptMaxLep[0] > 20 && ptMaxLep[1] > 15) {
266     if (TMath::Abs(GenLeptons->At(idxMaxLep[0])->Eta()) < 2.5 &&
267     TMath::Abs(GenLeptons->At(idxMaxLep[1])->Eta()) < 2.5) {
268 ceballos 1.2 hDGenQuarks[8]->Fill(GenQuarks->At(i)->Pt());
269     hDGenQuarks[9]->Fill(GenQuarks->At(i)->Eta());
270     hDGenQuarks[10]->Fill(GenQuarks->At(i)->Phi());
271     }
272     }
273     }
274     // t quark info
275 loizides 1.5 else if (GenQuarks->At(i)->AbsPdgId() == 6) {
276 ceballos 1.2 hDGenQuarks[11]->Fill(GenQuarks->At(i)->Pt());
277     hDGenQuarks[12]->Fill(GenQuarks->At(i)->Eta());
278     hDGenQuarks[13]->Fill(GenQuarks->At(i)->Phi());
279     }
280     // light quark info
281     else {
282     hDGenQuarks[14]->Fill(GenQuarks->At(i)->Pt());
283     hDGenQuarks[15]->Fill(GenQuarks->At(i)->Eta());
284     hDGenQuarks[16]->Fill(GenQuarks->At(i)->Phi());
285     }
286 loizides 1.1 }
287    
288 loizides 1.6 // wbf
289 loizides 1.5 if (GenqqHs->GetEntries() == 2) {
290 loizides 1.1 hDGenWBF[0]->Fill(MathUtils::DeltaPhi(GenqqHs->At(0)->Phi(),
291     GenqqHs->At(1)->Phi()) * 180./ TMath::Pi());
292 loizides 1.5 hDGenWBF[1]->Fill(TMath::Abs(GenqqHs->At(0)->Eta()-GenqqHs->At(1)->Eta()));
293 loizides 1.1 hDGenWBF[2]->Fill(TMath::Max(GenqqHs->At(0)->Pt(),GenqqHs->At(1)->Pt()));
294     hDGenWBF[3]->Fill(TMath::Min(GenqqHs->At(0)->Pt(),GenqqHs->At(1)->Pt()));
295     CompositeParticle *diqq = new CompositeParticle();
296     diqq->AddDaughter(GenqqHs->At(0));
297     diqq->AddDaughter(GenqqHs->At(1));
298     hDGenWBF[4]->Fill(diqq->Mass());
299     delete diqq;
300     }
301    
302 loizides 1.6 // bosons
303 loizides 1.1 hDGenBosons[0]->Fill(GenBosons->GetEntries());
304 loizides 1.5 for(UInt_t i=0; i<GenBosons->GetEntries(); i++) {
305 loizides 1.1 hDGenBosons[1]->Fill(GenBosons->At(i)->Pt());
306     hDGenBosons[2]->Fill(GenBosons->At(i)->Eta());
307     hDGenBosons[3]->Fill(GenBosons->At(i)->Mass());
308     }
309 ceballos 1.10
310     // photons
311     hDGenPhotons[0]->Fill(GenPhotons->GetEntries());
312     for(UInt_t i=0; i<GenPhotons->GetEntries(); i++) {
313     hDGenPhotons[1]->Fill(GenPhotons->At(i)->Pt());
314     hDGenPhotons[2]->Fill(GenPhotons->At(i)->Eta());
315     }
316 loizides 1.1 }
317     }
318    
319     //--------------------------------------------------------------------------------------------------
320     void GeneratorMod::SlaveBegin()
321     {
322 loizides 1.5 // Book branch and histograms if wanted.
323    
324 loizides 1.1 ReqBranch(fMCPartName, fParticles);
325    
326 loizides 1.5 // fill histograms
327     if (fFillHist == kTRUE) {
328     char sb[1024];
329    
330 loizides 1.6 // leptons from W
331 loizides 1.1 sprintf(sb,"hDGenLeptons_%d", 0); hDGenLeptons[0] = new TH1D(sb,sb,10,-0.5,9.5);
332     sprintf(sb,"hDGenLeptons_%d", 1); hDGenLeptons[1] = new TH1D(sb,sb,100,0.0,200.0);
333     sprintf(sb,"hDGenLeptons_%d", 2); hDGenLeptons[2] = new TH1D(sb,sb,50,0.0,5.0);
334     sprintf(sb,"hDGenLeptons_%d", 3); hDGenLeptons[3] = new TH1D(sb,sb,90,0.0,180.0);
335     sprintf(sb,"hDGenLeptons_%d", 4); hDGenLeptons[4] = new TH1D(sb,sb,1000,0.0,1000.0);
336     sprintf(sb,"hDGenLeptons_%d", 5); hDGenLeptons[5] = new TH1D(sb,sb,50,0.0,5.0);
337     sprintf(sb,"hDGenLeptons_%d", 6); hDGenLeptons[6] = new TH1D(sb,sb,50,0.0,5.0);
338     sprintf(sb,"hDGenLeptons_%d", 7); hDGenLeptons[7] = new TH1D(sb,sb,100,0.0,200.0);
339     sprintf(sb,"hDGenLeptons_%d", 8); hDGenLeptons[8] = new TH1D(sb,sb,100,0.0,200.0);
340     sprintf(sb,"hDGenLeptons_%d", 9); hDGenLeptons[9] = new TH1D(sb,sb,1000,0.0,1000.0);
341     sprintf(sb,"hDGenLeptons_%d",10); hDGenLeptons[10] = new TH1D(sb,sb,90,0.0,180.0);
342 loizides 1.5 for(Int_t i=0; i<11; i++) AddOutput(hDGenLeptons[i]);
343 loizides 1.1
344 loizides 1.6 // all leptons
345 ceballos 1.3 sprintf(sb,"hDGenAllLeptons_%d", 0); hDGenAllLeptons[0] = new TH1D(sb,sb,10,-0.5,9.5);
346     sprintf(sb,"hDGenAllLeptons_%d", 1); hDGenAllLeptons[1] = new TH1D(sb,sb,100,0.0,200.0);
347     sprintf(sb,"hDGenAllLeptons_%d", 2); hDGenAllLeptons[2] = new TH1D(sb,sb,60,-3.0,3.0);
348     sprintf(sb,"hDGenAllLeptons_%d", 3); hDGenAllLeptons[3] = new TH1D(sb,sb,90,0.0,180.0);
349 loizides 1.5 for(Int_t i=0; i<4; i++) AddOutput(hDGenAllLeptons[i]);
350 ceballos 1.3
351 loizides 1.6 // taus
352 loizides 1.1 sprintf(sb,"hDGenTaus_%d", 0); hDGenTaus[0] = new TH1D(sb,sb,10,-0.5,9.5);
353     sprintf(sb,"hDGenTaus_%d", 1); hDGenTaus[1] = new TH1D(sb,sb,100,0.0,200.0);
354     sprintf(sb,"hDGenTaus_%d", 2); hDGenTaus[2] = new TH1D(sb,sb,100,-5.0,5.0);
355     sprintf(sb,"hDGenTaus_%d", 3); hDGenTaus[3] = new TH1D(sb,sb,90,0.0,180.0);
356 loizides 1.5 for(Int_t i=0; i<4; i++) AddOutput(hDGenTaus[i]);
357 loizides 1.1
358 loizides 1.6 // neutrinos
359 loizides 1.1 sprintf(sb,"hDGenNeutrinos_%d", 0); hDGenNeutrinos[0] = new TH1D(sb,sb,10,-0.5,9.5);
360     sprintf(sb,"hDGenNeutrinos_%d", 1); hDGenNeutrinos[1] = new TH1D(sb,sb,100,0.0,200.0);
361     sprintf(sb,"hDGenNeutrinos_%d", 2); hDGenNeutrinos[2] = new TH1D(sb,sb,100,-5.0,5.0);
362     sprintf(sb,"hDGenNeutrinos_%d", 3); hDGenNeutrinos[3] = new TH1D(sb,sb,90,0.0,180.0);
363 loizides 1.5 for(Int_t i=0; i<4; i++) AddOutput(hDGenNeutrinos[i]);
364 loizides 1.1
365 loizides 1.6 // quarks
366 loizides 1.1 sprintf(sb,"hDGenQuarks_%d", 0); hDGenQuarks[0] = new TH1D(sb,sb,10,-0.5,9.5);
367     sprintf(sb,"hDGenQuarks_%d", 1); hDGenQuarks[1] = new TH1D(sb,sb,200,0.0,400.);
368     sprintf(sb,"hDGenQuarks_%d", 2); hDGenQuarks[2] = new TH1D(sb,sb,2000,0.0,2000.);
369     sprintf(sb,"hDGenQuarks_%d", 3); hDGenQuarks[3] = new TH1D(sb,sb,200,0.0,400.);
370     sprintf(sb,"hDGenQuarks_%d", 4); hDGenQuarks[4] = new TH1D(sb,sb,2000,0.0,2000.);
371 ceballos 1.2 sprintf(sb,"hDGenQuarks_%d", 5); hDGenQuarks[5] = new TH1D(sb,sb,200,0.0,400.);
372     sprintf(sb,"hDGenQuarks_%d", 6); hDGenQuarks[6] = new TH1D(sb,sb,200,-10.0,10.);
373 loizides 1.5 sprintf(sb,"hDGenQuarks_%d", 7); hDGenQuarks[7] = new TH1D(sb,sb,200,-TMath::Pi(),
374     TMath::Pi());
375 ceballos 1.2 sprintf(sb,"hDGenQuarks_%d", 8); hDGenQuarks[8] = new TH1D(sb,sb,200,0.0,400.);
376     sprintf(sb,"hDGenQuarks_%d", 9); hDGenQuarks[9] = new TH1D(sb,sb,200,-10.0,10.);
377 loizides 1.5 sprintf(sb,"hDGenQuarks_%d",10); hDGenQuarks[10] = new TH1D(sb,sb,200,-TMath::Pi(),
378     TMath::Pi());
379 ceballos 1.2 sprintf(sb,"hDGenQuarks_%d",11); hDGenQuarks[11] = new TH1D(sb,sb,200,0.0,400.);
380     sprintf(sb,"hDGenQuarks_%d",12); hDGenQuarks[12] = new TH1D(sb,sb,200,-10.0,10.);
381 loizides 1.5 sprintf(sb,"hDGenQuarks_%d",13); hDGenQuarks[13] = new TH1D(sb,sb,200,-TMath::Pi(),
382     TMath::Pi());
383 ceballos 1.2 sprintf(sb,"hDGenQuarks_%d",14); hDGenQuarks[14] = new TH1D(sb,sb,200,0.0,400.);
384     sprintf(sb,"hDGenQuarks_%d",15); hDGenQuarks[15] = new TH1D(sb,sb,200,-10.0,10.);
385 loizides 1.5 sprintf(sb,"hDGenQuarks_%d",16); hDGenQuarks[16] = new TH1D(sb,sb,200,-TMath::Pi(),
386     TMath::Pi());
387     for(Int_t i=0; i<17; i++) AddOutput(hDGenQuarks[i]);
388 loizides 1.1
389     // qqH
390     sprintf(sb,"hDGenWBF_%d", 0); hDGenWBF[0] = new TH1D(sb,sb,90,0.0,180.);
391     sprintf(sb,"hDGenWBF_%d", 1); hDGenWBF[1] = new TH1D(sb,sb,100,0.0,10.);
392     sprintf(sb,"hDGenWBF_%d", 2); hDGenWBF[2] = new TH1D(sb,sb,200,0.0,400.);
393     sprintf(sb,"hDGenWBF_%d", 3); hDGenWBF[3] = new TH1D(sb,sb,200,0.0,400.);
394     sprintf(sb,"hDGenWBF_%d", 4); hDGenWBF[4] = new TH1D(sb,sb,200,0.0,4000.);
395 loizides 1.5 for(Int_t i=0; i<5; i++) AddOutput(hDGenWBF[i]);
396 loizides 1.1
397 loizides 1.6 // bosons
398 loizides 1.1 sprintf(sb,"hDGenBosons_%d", 0); hDGenBosons[0] = new TH1D(sb,sb,10,-0.5,9.5);
399     sprintf(sb,"hDGenBosons_%d", 1); hDGenBosons[1] = new TH1D(sb,sb,200,0.0,400.0);
400     sprintf(sb,"hDGenBosons_%d", 2); hDGenBosons[2] = new TH1D(sb,sb,100,-5.0,5.0);
401     sprintf(sb,"hDGenBosons_%d", 3); hDGenBosons[3] = new TH1D(sb,sb,2000,0.0,2000.0);
402 loizides 1.5 for(Int_t i=0; i<4; i++) AddOutput(hDGenBosons[i]);
403 ceballos 1.10
404     // photons
405     sprintf(sb,"hDGenPhotons_%d", 0); hDGenPhotons[0] = new TH1D(sb,sb,10,-0.5,9.5);
406     sprintf(sb,"hDGenPhotons_%d", 1); hDGenPhotons[1] = new TH1D(sb,sb,200,0.0,400.0);
407     sprintf(sb,"hDGenPhotons_%d", 2); hDGenPhotons[2] = new TH1D(sb,sb,50,-2.5,2.5);
408     for(Int_t i=0; i<3; i++) AddOutput(hDGenPhotons[i]);
409 loizides 1.1 }
410     }