Added methods to define standard cuts for pp and PbPb (Andrea)
[u/mrichter/AliRoot.git] / PWG3 / vertexingHF / AliAnalysisTaskSECharmFraction.cxx
CommitLineData
624c07ab 1/**************************************************************************
2 * Copyright(c) 1998-2009, ALICE Experiment at CERN, All rights reserved. *
3 * *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
6 * *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
15
16/////////////////////////////////////////////////////////////
17//
18// Class AliAnalysisTaskSECharmFraction
19// AliAnalysisTaskSE for the extraction of the fraction of prompt charm
20// using the charm hadron impact parameter to the primary vertex
21//
22// Author: Andrea Rossi, andrea.rossi@ts.infn.it
23/////////////////////////////////////////////////////////////
24
ac4c229c 25
624c07ab 26#include <TH1F.h>
27#include <TH2F.h>
624c07ab 28#include <TDatabasePDG.h>
29#include <TMath.h>
30#include <TROOT.h>
624c07ab 31#include "AliAODEvent.h"
624c07ab 32#include "AliAODRecoDecayHF2Prong.h"
33#include "AliAODRecoDecayHF.h"
34#include "AliAODRecoDecay.h"
e047b348 35#include "AliAnalysisDataSlot.h"
36#include "AliAnalysisDataContainer.h"
624c07ab 37#include "AliAODTrack.h"
e047b348 38#include "AliAODHandler.h"
39#include "AliESDtrack.h"
624c07ab 40#include "AliAODVertex.h"
e047b348 41#include "AliESDVertex.h"
42#include "AliVertexerTracks.h"
624c07ab 43#include "AliAODMCParticle.h"
e047b348 44#include "AliAODPid.h"
45#include "AliTPCPIDResponse.h"
624c07ab 46#include "AliAODMCHeader.h"
ac4c229c 47#include "AliAnalysisVertexingHF.h"
624c07ab 48#include "AliAnalysisTaskSECharmFraction.h"
e047b348 49#include "AliRDHFCutsD0toKpi.h"
50#include "AliAODInputHandler.h"
51#include "AliAnalysisManager.h"
ac4c229c 52
53class TCanvas;
54class TTree;
55class TChain;
ac4c229c 56class AliAnalysisTaskSE;
57
58
624c07ab 59ClassImp(AliAnalysisTaskSECharmFraction)
60
61//________________________________________________________________________
62 AliAnalysisTaskSECharmFraction::AliAnalysisTaskSECharmFraction()
63 : AliAnalysisTaskSE(),
e047b348 64 fCutsLoose(0),
65 fCutsTight(0),
bf74e6db 66 fReadMC(kFALSE),
e047b348 67 fLikeSign(kFALSE),
68 fusePID(kTRUE),
624c07ab 69 fmD0PDG(),
e047b348 70 fnbins(1),
624c07ab 71 fptbins(0),
e047b348 72 fNtrMaxforVtx(-1),
73 fptAll(),
74 fptAllSq(),
75 fptMax(),
c387e585 76 fAcceptanceCuts(),
624c07ab 77 fsignalInvMassCut(),
78 flargeInvMassCut(),
79 fsidebandInvMassCut(),
80 fsidebandInvMassWindow(),
81 fUseMC(kTRUE),
82 fNentries(0),
83 fSignalType(0),
84 fSignalTypeLsCuts(0),
85 fSignalTypeTghCuts(0),
e047b348 86 flistMCproperties(0),
ac4c229c 87 flistNoCutsSignal(0),
88 flistNoCutsBack(0),
89 flistNoCutsFromB(0),
90 flistNoCutsFromDstar(0),
91 flistNoCutsOther(0),
92 flistLsCutsSignal(0),
93 flistLsCutsBack(0),
94 flistLsCutsFromB(0),
95 flistLsCutsFromDstar(0),
96 flistLsCutsOther(0),
97 flistTghCutsSignal(0),
98 flistTghCutsBack(0),
99 flistTghCutsFromB(0),
100 flistTghCutsFromDstar(0),
101 flistTghCutsOther(0)
624c07ab 102
103{
104 //Default constructor
105}
106//________________________________________________________________________
107 AliAnalysisTaskSECharmFraction::AliAnalysisTaskSECharmFraction(const char *name)
108 : AliAnalysisTaskSE(name),
e047b348 109 fCutsLoose(0x0),
110 fCutsTight(0x0),
bf74e6db 111 fReadMC(kFALSE),
e047b348 112 fLikeSign(kFALSE),
113 fusePID(kTRUE),
624c07ab 114 fmD0PDG(),
e047b348 115 fnbins(1),
624c07ab 116 fptbins(0),
e047b348 117 fNtrMaxforVtx(-1),
118 fptAll(),
119 fptAllSq(),
120 fptMax(),
c387e585 121 fAcceptanceCuts(),
e047b348 122 fsignalInvMassCut(-1.),
123 flargeInvMassCut(-1.),
124 fsidebandInvMassCut(-1.),
125 fsidebandInvMassWindow(-1.),
126 fUseMC(kFALSE),
624c07ab 127 fNentries(0),
128 fSignalType(0),
129 fSignalTypeLsCuts(0),
130 fSignalTypeTghCuts(0),
e047b348 131 flistMCproperties(0),
ac4c229c 132 flistNoCutsSignal(0),
133 flistNoCutsBack(0),
134 flistNoCutsFromB(0),
135 flistNoCutsFromDstar(0),
136 flistNoCutsOther(0),
137 flistLsCutsSignal(0),
138 flistLsCutsBack(0),
139 flistLsCutsFromB(0),
140 flistLsCutsFromDstar(0),
141 flistLsCutsOther(0),
142 flistTghCutsSignal(0),
143 flistTghCutsBack(0),
144 flistTghCutsFromB(0),
145 flistTghCutsFromDstar(0),
146 flistTghCutsOther(0)
624c07ab 147
148{
149 // Constructor
150
151 // Define input and output slots here
152 // Input slot #0 works with a TChain
153 // Output slot #0 writes into a TH1 container
154
155 //Standard pt bin
e047b348 156 fnbins=SetStandardCuts(fptbins);// THIS TO SET NBINS AND BINNING
157
624c07ab 158 DefineOutput(1, TH1F::Class());
159 DefineOutput(2, TH1F::Class());
160 DefineOutput(3, TH1F::Class());
161 DefineOutput(4, TH1F::Class());
e047b348 162 for(Int_t j=5;j<21;j++){
624c07ab 163 DefineOutput(j, TList::Class());
164 }
165
e047b348 166 // Output slot for the Cut Objects
167 DefineOutput(21,AliRDHFCutsD0toKpi::Class()); //My private output
168 DefineOutput(22,AliRDHFCutsD0toKpi::Class()); //My private output
624c07ab 169
170}
171
172
e047b348 173AliAnalysisTaskSECharmFraction::AliAnalysisTaskSECharmFraction(const char *name,AliRDHFCutsD0toKpi *cutsA,AliRDHFCutsD0toKpi *cutsB)
624c07ab 174 : AliAnalysisTaskSE(name),
e047b348 175 fCutsLoose(0),
176 fCutsTight(0),
bf74e6db 177 fReadMC(kFALSE),
e047b348 178 fLikeSign(kFALSE),
179 fusePID(kTRUE),
624c07ab 180 fmD0PDG(),
e047b348 181 fnbins(1),
624c07ab 182 fptbins(0),
e047b348 183 fNtrMaxforVtx(-1),
184 fptAll(),
185 fptAllSq(),
186 fptMax(),
c387e585 187 fAcceptanceCuts(),
e047b348 188 fsignalInvMassCut(-1.),
189 flargeInvMassCut(-1.),
190 fsidebandInvMassCut(-1.),
191 fsidebandInvMassWindow(-1.),
192 fUseMC(kFALSE),
624c07ab 193 fNentries(0),
194 fSignalType(0),
195 fSignalTypeLsCuts(0),
196 fSignalTypeTghCuts(0),
e047b348 197 flistMCproperties(0),
ac4c229c 198 flistNoCutsSignal(0),
199 flistNoCutsBack(0),
200 flistNoCutsFromB(0),
201 flistNoCutsFromDstar(0),
202 flistNoCutsOther(0),
203 flistLsCutsSignal(0),
204 flistLsCutsBack(0),
205 flistLsCutsFromB(0),
206 flistLsCutsFromDstar(0),
207 flistLsCutsOther(0),
208 flistTghCutsSignal(0),
209 flistTghCutsBack(0),
210 flistTghCutsFromB(0),
211 flistTghCutsFromDstar(0),
212 flistTghCutsOther(0)
624c07ab 213{
214 // Constructor
e047b348 215 if(fCutsTight)delete fCutsTight;fCutsTight=NULL;
216 if(fCutsLoose)delete fCutsLoose;fCutsLoose=NULL;
217
218 //Check consistency between sets of cuts:
219 if(cutsA->GetNPtBins()!=cutsB->GetNPtBins()){
220 printf("Different number of pt bins between the two sets of cuts: SWITCH TO STANDARD CUTS \n");
221 fnbins=SetStandardCuts(fptbins);
222 }
223 else{
224 fCutsTight=new AliRDHFCutsD0toKpi(*cutsA);
225 fCutsLoose=new AliRDHFCutsD0toKpi(*cutsB);
226 for(Int_t j=0;j<cutsA->GetNPtBins();j++){
227 if(TMath::Abs(cutsA->GetPtBinLimits()[j]-cutsB->GetPtBinLimits()[j])>1.e-7){
228 printf("Different pt bin limits in the two set of cuts: use the first as reference \n");
229 fCutsLoose->SetPtBins(cutsA->GetNPtBins(),cutsA->GetPtBinLimits());
230 break;
231 }
232 }
233 SetPtBins(fCutsTight->GetNPtBins(),fCutsTight->GetPtBinLimits());
234 }
624c07ab 235
624c07ab 236 // Output slot #0 writes into a TH1 container
237 DefineOutput(1, TH1F::Class());
238 DefineOutput(2, TH1F::Class());
239 DefineOutput(3, TH1F::Class());
240 DefineOutput(4, TH1F::Class());
e047b348 241 for(Int_t j=5;j<21;j++){
624c07ab 242
243 DefineOutput(j, TList::Class());
244 }
e047b348 245 // Output slot for the Cut Objects
246 DefineOutput(21,AliRDHFCutsD0toKpi::Class()); //My private output
247 DefineOutput(22,AliRDHFCutsD0toKpi::Class()); //My private output
624c07ab 248
249}
250
251//________________________________________________________________________
252AliAnalysisTaskSECharmFraction::~AliAnalysisTaskSECharmFraction()
253{ //Destructor
254
e047b348 255 if (fCutsTight) {
256 delete fCutsTight;
257 fCutsTight = 0;
624c07ab 258 }
e047b348 259 if (fCutsLoose) {
260 delete fCutsLoose;
261 fCutsLoose = 0;
624c07ab 262 }
ac4c229c 263 if(fptbins){
264 delete fptbins;
265 fptbins =0;
266 }
c387e585 267 /* if(fAcceptanceCuts){
ac4c229c 268 delete fAcceptanceCuts;
269 fAcceptanceCuts=0;
c387e585 270 }*/
624c07ab 271 if (fNentries) {
272 delete fNentries;
273 fNentries = 0;
274 }
275 if (fSignalType) {
276 delete fSignalType;
277 fSignalType = 0;
278 }
279 if (fSignalTypeLsCuts) {
280 delete fSignalTypeLsCuts;
281 fSignalTypeLsCuts = 0;
282 }
283 if (fSignalTypeTghCuts) {
284 delete fSignalTypeTghCuts;
285 fSignalTypeTghCuts = 0;
286 }
e047b348 287 if(flistMCproperties){
288 delete flistMCproperties;
289 flistMCproperties=0;
290 }
ac4c229c 291 if(flistNoCutsSignal){
292 delete flistNoCutsSignal;
293 flistNoCutsSignal=0;
624c07ab 294 }
ac4c229c 295 if(flistNoCutsBack){
296 delete flistNoCutsBack;
297 flistNoCutsBack=0;
624c07ab 298 }
ac4c229c 299 if(flistNoCutsFromB){
300 delete flistNoCutsFromB;
301 flistNoCutsFromB=0;
624c07ab 302 }
ac4c229c 303 if(flistNoCutsFromDstar){
304 delete flistNoCutsFromDstar;
305 flistNoCutsFromDstar=0;
624c07ab 306 }
ac4c229c 307 if(flistNoCutsOther){
308 delete flistNoCutsOther;
309 flistNoCutsOther=0;
624c07ab 310 }
311
ac4c229c 312 if(flistLsCutsSignal){
313 delete flistLsCutsSignal;
314 flistLsCutsSignal=0;
624c07ab 315 }
ac4c229c 316 if(flistLsCutsBack){
317 delete flistLsCutsBack;
318 flistLsCutsBack=0;
624c07ab 319 }
ac4c229c 320 if(flistLsCutsFromB){
321 delete flistLsCutsFromB;
322 flistLsCutsFromB=0;
624c07ab 323 }
ac4c229c 324 if(flistLsCutsFromDstar){
325 delete flistLsCutsFromDstar;
326 flistLsCutsFromDstar=0;
624c07ab 327 }
ac4c229c 328 if(flistLsCutsOther){
329 delete flistLsCutsOther;
330 flistLsCutsOther=0;
624c07ab 331 }
332
ac4c229c 333 if(flistTghCutsSignal){
334 delete flistTghCutsSignal;
335 flistTghCutsSignal=0;
624c07ab 336 }
ac4c229c 337 if(flistTghCutsBack){
338 delete flistTghCutsBack;
339 flistTghCutsBack=0;
624c07ab 340 }
ac4c229c 341 if(flistTghCutsFromB){
342 delete flistTghCutsFromB;
343 flistTghCutsFromB=0;
624c07ab 344 }
ac4c229c 345 if(flistTghCutsFromDstar){
346 delete flistTghCutsFromDstar;
347 flistTghCutsFromDstar=0;
624c07ab 348 }
ac4c229c 349 if(flistTghCutsOther){
350 delete flistTghCutsOther;
351 flistTghCutsOther=0;
624c07ab 352 }
353
354
355}
356
357
358//________________________________________________________________________
359void AliAnalysisTaskSECharmFraction::Init()
360{
361 // Initialization
362
363 if(fDebug > 1) printf("AnalysisTaskSED0Mass::Init() \n");
364 fmD0PDG = TDatabasePDG::Instance()->GetParticle(421)->Mass();
365
e047b348 366 // gROOT->LoadMacro("$ALICE_ROOT/PWG3/vertexingHF/ConfigVertexingHF.C");
367 // gROOT->LoadMacro("$ALICE_ROOT/PWG3/vertexingHF/D0fromBSetCuts.C");
368 // 2 sets of dedicated cuts: fCutsTight is assumed as the standard cut object
624c07ab 369
e047b348 370 // SetAcceptanceCut();
371 if(fNtrMaxforVtx<0)SetNMaxTrForVtx(3); //DEFAULT : NO SELECTION
372 if(fsignalInvMassCut<0.||flargeInvMassCut<0.||fsidebandInvMassCut<0.||fsidebandInvMassWindow<0.){
373 printf("AliAnalysisTaskSECharmFraction: Not All info for mass selection provided: switch to default values \n");
374 SetStandardMassSelection();
624c07ab 375 }
e047b348 376
377 AliRDHFCutsD0toKpi* copyfCutsTight=new AliRDHFCutsD0toKpi(*fCutsTight);
378 const char* nameoutputTight=GetOutputSlot(21)->GetContainer()->GetName();
379 copyfCutsTight->SetName(nameoutputTight);
380 AliRDHFCutsD0toKpi* copyfCutsLoose=new AliRDHFCutsD0toKpi(*fCutsLoose);
381 const char* nameoutputLoose=GetOutputSlot(22)->GetContainer()->GetName();
382 copyfCutsLoose->SetName(nameoutputLoose);
383 // Post the data
384 PostData(21,copyfCutsTight);
385 PostData(22,copyfCutsLoose);
386
624c07ab 387 return;
388}
389
390//________________________________________________________________________
391void AliAnalysisTaskSECharmFraction::UserCreateOutputObjects()
392{
393 // Create histograms
394 // Called once
c387e585 395
396 // ################ NAMING SCHEME ###################################
397 // LISTS NAMING SCHEME
398 // "list" + cut selection string + MC selection string
399 // cut strings: "NC" =nocuts, "LSC"= loose cuts, "TGHC"= tight cuts
400 // MC sel. strings: "sign"= D0 from c quark
401 // "fromDstar" = D0 from Dstar from c quark
402 // "fromB"= D0from B decay (->from b quark) + D0from Dstar from B
403 // "back"= backgroun, generic except the cas "other"
404 // "other"= background case for candidates made of a pion and a kaon coming from the same D0 (in 4 prong) or from D+
405 //
406 // HISTS NAMING SCHEME
407 //
408 // "h" + specific name + cut selection string + MC selection string + (InvMass region string) + (pt string)
409 //
410 // cut selection strings = those for lists
411 // MC selection strings = those for lists
412 // inv mass region strings : "PM" or "SB" for global properties and pt integrated histos
413 // "_PkMss" or "_SBMss" for impact par. pt dependent histos
414 // pt string : "_pt" + integer number of ptbin
415 //
416 //###################################################################
624c07ab 417
418 TString namehist;
419 TString titlehist;
420 TString strnamept,strtitlept;
e047b348 421 Printf("INSIDE USER CREATE \n");
624c07ab 422 fNentries=new TH1F("nentriesChFr", "Look at the number of entries! = number of AODs", 2,1.,2.);
e047b348 423 fSignalType=new TH1F("hsignaltype", "Histo for type of MC signal", 61,-1.,60.);
424 fSignalTypeLsCuts=new TH1F("hsignaltypeLsCuts", "Histo for type of MC signal with loose cuts", 61,-1.,60.);
425 fSignalTypeTghCuts=new TH1F("hsignaltypeTghCuts", "Histo for type of MC signal with tight cuts", 61,-1.,60.);
624c07ab 426
427 //########## DEFINE THE TLISTS ##################
e047b348 428 flistMCproperties=new TList();
429 flistMCproperties->SetOwner();
430 flistMCproperties->SetName("listMCproperties");
431
ac4c229c 432 flistNoCutsSignal = new TList();
433 flistNoCutsSignal->SetOwner();
434 flistNoCutsSignal->SetName("listNCsign");
624c07ab 435
ac4c229c 436 flistNoCutsBack = new TList();
437 flistNoCutsBack->SetOwner();
438 flistNoCutsBack->SetName("listNCback");
624c07ab 439
ac4c229c 440 flistNoCutsFromB = new TList();
441 flistNoCutsFromB->SetOwner();
442 flistNoCutsFromB->SetName("listNCfromB");
624c07ab 443
ac4c229c 444 flistNoCutsFromDstar = new TList();
445 flistNoCutsFromDstar->SetOwner();
446 flistNoCutsFromDstar->SetName("listNCfromDstar");
624c07ab 447
ac4c229c 448 flistNoCutsOther = new TList();
449 flistNoCutsOther->SetOwner();
450 flistNoCutsOther->SetName("listNCother");
624c07ab 451
452
ac4c229c 453 flistLsCutsSignal = new TList();
454 flistLsCutsSignal->SetOwner();
455 flistLsCutsSignal->SetName("listLSCsign");
624c07ab 456
ac4c229c 457 flistLsCutsBack = new TList();
458 flistLsCutsBack->SetOwner();
459 flistLsCutsBack->SetName("listLSCback");
624c07ab 460
ac4c229c 461 flistLsCutsFromB = new TList();
462 flistLsCutsFromB->SetOwner();
463 flistLsCutsFromB->SetName("listLSCfromB");
624c07ab 464
ac4c229c 465 flistLsCutsFromDstar = new TList();
466 flistLsCutsFromDstar->SetOwner();
467 flistLsCutsFromDstar->SetName("listLSCfromDstar");
624c07ab 468
ac4c229c 469 flistLsCutsOther = new TList();
470 flistLsCutsOther->SetOwner();
471 flistLsCutsOther->SetName("listLSCother");
624c07ab 472
473
ac4c229c 474 flistTghCutsSignal = new TList();
475 flistTghCutsSignal->SetOwner();
476 flistTghCutsSignal->SetName("listTGHCsign");
624c07ab 477
ac4c229c 478 flistTghCutsBack = new TList();
479 flistTghCutsBack->SetOwner();
480 flistTghCutsBack->SetName("listTGHCback");
624c07ab 481
ac4c229c 482 flistTghCutsFromB = new TList();
483 flistTghCutsFromB->SetOwner();
484 flistTghCutsFromB->SetName("listTGHCfromB");
624c07ab 485
ac4c229c 486 flistTghCutsFromDstar = new TList();
487 flistTghCutsFromDstar->SetOwner();
488 flistTghCutsFromDstar->SetName("listTGHCfromDstar");
624c07ab 489
ac4c229c 490 flistTghCutsOther = new TList();
491 flistTghCutsOther->SetOwner();
492 flistTghCutsOther->SetName("listTGHCother");
624c07ab 493
494
495
e047b348 496 Float_t ptbinsD0arr[35]={0.,0.1,0.2,0.3,0.4,0.5,0.6,0.8,1.,1.25,1.5,1.75,2.,2.3,2.6,3.,3.5,4.,4.5,5.,5.5,6.,7.,8.,9.,10.,12.,14.,16.,20.,25.,30.,40.,50.,100.};
497 Float_t dumbinning[201];
498 for(Int_t j=0;j<201;j++){
499 dumbinning[j]=(Float_t)j*0.5;
500 }
501 //################################################################################################
502 // #
503 // HISTO FOR MC PROPERTIES OF D0, c quarks and B mesons #
504 // #
505 //################################################################################################
506 TH1F *hMCcquarkAllPt=new TH1F("hMCcquarkAllPt","c quark Pt (all cquarks produced)",34,ptbinsD0arr);
507 TH1F *hMCcquarkAllEta=new TH1F("hMCcquarkAllEta","c quark Eta (all cquarks produced)",50,-3.,3.);
508 TH1F *hMCcquarkAllEnergy=new TH1F("hMCcquarkAllEnergy","c quark Pt (all cquarks produced)",200,0.,100.);
509 TH1F *hMCcquarkNdaught=new TH1F("hMCcquarkNdaught","N cquark daughters (all cquarks produced)",100,0.,100.);
510 TH1F *hMCD0fromcPt=new TH1F("hMCD0fromcPt","D0 from c Pt",34,ptbinsD0arr);
511 TH1F *hMCD0fromcEta=new TH1F("hMCD0fromcEta","D0 from c Eta",50,-3.,3.);
512 TH1F *hMCD0fromcEnergy=new TH1F("hMCD0fromcEnergy","D0 from c Energy",200,0.,100.);
513
514 TH2F *hMCD0VscquarkPt=new TH2F("hMCD0VscquarkPt","D0 pt Vs cquark pt",34,ptbinsD0arr,34,ptbinsD0arr);
515 TH2F *hMCD0VscquarkEnergy=new TH2F("hMCD0VscquarkEnergy","D0 Energy Vs cquark Energy",200,0.,50.,200,0.,50.);
516 TH1F *hMCD0deltacquarkEnergy=new TH1F("hMCD0deltacquarkEnergy","Fractional D0 Energy w.r.t. cquark Energy",20,0.,1.);
517 TH1F *hMCD0EnergyVsAvcquarkDaughtEn=new TH1F("hMCD0EnergyVsAvcquarkDaughtEn","#Delta(E^{D^0}-E_{avg})/E_{cquark}",40,-1.,1.);
518 TH1F *hMCD0cquarkAngle=new TH1F("hMCD0cquarkAngle","cosine of the angle between D0 and c quark particle",40,-1.,1.);
519 TH2F *hMCD0cquarkAngleEnergy=new TH2F("hMCD0cquarkAngleEnergy","cosine of the angle between D0 and c quark particle as a function of Energy",25,0.,50.,40,-1.,1.);
520
521 TH1I *hMCfromBpdgB=new TH1I("hMCfromBpdgB","hMCfromBpdgB",10000,0.,10000);
522 TH1F *hMCBhadrPt=new TH1F("hMCBhadrPt","B hadr Pt",34,ptbinsD0arr);
523 TH1F *hMCBhadrEta=new TH1F("hMCBhadrEta","B hadr Eta",50,-3.,3.);
524 TH1F *hMCBhadrEnergy=new TH1F("hMCBhadrEnergy","B hadr Pt",200,0.,100.);
525 TH1F *hMCBhadrNdaught=new TH1F("hMCBhadrNdaught","N Bhadr daughters",100,0.,100.);
526 TH1F *hMCD0fromBPt=new TH1F("hMCD0fromBPt","D0 from B Pt",34,ptbinsD0arr);
527 TH1F *hMCD0fromBEta=new TH1F("hMCD0fromBEta","D0 from B Eta",50,-3.,3.);
528 TH1F *hMCD0fromBEnergy=new TH1F("hMCD0fromBEnergy","D0 from B Energy",200,0.,100.);
529
530 TH2F *hMCD0VsBhadrPt=new TH2F("hMCD0VsBhadrPt","D0 pt Vs Bhadr pt",34,ptbinsD0arr,34,ptbinsD0arr);
531 TH2F *hMCD0VsBhadrEnergy=new TH2F("hMCD0VsBhadrEnergy","D0 Energy Vs Bhadr Energy",200,0.,50.,200,0.,50.);
532 TH1F *hMCD0deltaBhadrEnergy=new TH1F("hMCD0deltaBhadrEnergy","Fractional D0 Energy w.r.t. Bhadr Energy",20,0.,1.);
533 TH1F *hMCD0EnergyVsAvBDaughtEn=new TH1F("hMCD0EnergyVsAvBDaughtEn","#Delta(E^{D^0}-E_{avg})/E_{Bahdr}",40,-1.,1.);
534 TH1F *hMCD0BhadrAngle=new TH1F("hMCD0BhadrAngle","cosine of the angle between D0 and Bhadr particle",40,-1.,1.);
535 TH2F *hMCD0BhadrAngleEnergy=new TH2F("hMCD0BhadrAngleEnergy","cosine of the angle between D0 and Bhadr particle as a function of Energy",25,0.,50.,40,-1.,1.);
536
537 TH1I *hMCPartFound=new TH1I("hMCPartFound","1=c,2=D0,3=fromBall,4=fromBmeson,5=fromBbaryon",6,0,6);
538
539
540 flistMCproperties->Add(hMCcquarkAllPt);
541 flistMCproperties->Add(hMCcquarkAllEta);
542 flistMCproperties->Add(hMCcquarkAllEnergy);
543 flistMCproperties->Add(hMCcquarkNdaught);
544 flistMCproperties->Add(hMCD0fromcPt);
545 flistMCproperties->Add(hMCD0fromcEta);
546 flistMCproperties->Add(hMCD0fromcEnergy);
547 flistMCproperties->Add(hMCD0VscquarkPt);
548 flistMCproperties->Add(hMCD0VscquarkEnergy);
549 flistMCproperties->Add(hMCD0deltacquarkEnergy);
550 flistMCproperties->Add(hMCD0EnergyVsAvcquarkDaughtEn);
551 flistMCproperties->Add(hMCD0cquarkAngle);
552 flistMCproperties->Add(hMCD0cquarkAngleEnergy);
553
554 flistMCproperties->Add(hMCfromBpdgB);
555 flistMCproperties->Add(hMCBhadrPt);
556 flistMCproperties->Add(hMCBhadrEta);
557 flistMCproperties->Add(hMCBhadrEnergy);
558 flistMCproperties->Add(hMCBhadrNdaught);
559 flistMCproperties->Add(hMCD0fromBPt);
560 flistMCproperties->Add(hMCD0fromBEta);
561 flistMCproperties->Add(hMCD0fromBEnergy);
562 flistMCproperties->Add(hMCD0VsBhadrPt);
563 flistMCproperties->Add(hMCD0VsBhadrEnergy);
564 flistMCproperties->Add(hMCD0deltaBhadrEnergy);
565 flistMCproperties->Add(hMCD0EnergyVsAvBDaughtEn);
566 flistMCproperties->Add(hMCD0BhadrAngle);
567 flistMCproperties->Add(hMCD0BhadrAngleEnergy);
568 flistMCproperties->Add(hMCPartFound);
624c07ab 569
570 //################################################################################################
571 // #
572 // HISTOS FOR NO CUTS CASE #
573 // #
574 //################################################################################################
e047b348 575 Printf("AFTER MC HISTOS \n");
624c07ab 576
577 //############ NO CUTS SIGNAL HISTOGRAMS ###############
578 //
579 // ####### global properties histo ############
580
e047b348 581 TH2F *hCPtaVSd0d0NCsign=new TH2F("hCPtaVSd0d0NCsign","hCPtaVSd0d0_NoCuts_Signal",1000,-100000.,100000.,100,-1.,1.);
ac4c229c 582 TH1F *hSecVtxZNCsign=new TH1F("hSecVtxZNCsign","hSecVtxZ_NoCuts_Signal",1000,-8.,8.);
583 TH1F *hSecVtxXNCsign=new TH1F("hSecVtxXNCsign","hSecVtxX_NoCuts_Signal",1000,-3000.,3000.);
584 TH1F *hSecVtxYNCsign=new TH1F("hSecVtxYNCsign","hSecVtxY_NoCuts_Signal",1000,-3000.,3000.);
585 TH2F *hSecVtxXYNCsign=new TH2F("hSecVtxXYNCsign","hSecVtxXY_NoCuts_Signal",1000,-3000.,3000.,1000,-3000.,3000.);
586 TH1F *hSecVtxPhiNCsign=new TH1F("hSecVtxPhiNCsign","hSecVtxPhi_NoCuts_Signal",180,-180.1,180.1);
e047b348 587 TH1F *hd0singlTrackNCsign=new TH1F("hd0singlTrackNCsign","hd0singlTrackNoCuts_Signal",1000,-5000.,5000.);
588 TH1F *hCPtaNCsign=new TH1F("hCPtaNCsign","hCPta_NoCuts_Signal",100,-1.,1.);
ac4c229c 589 TH1F *hd0xd0NCsign=new TH1F("hd0xd0NCsign","hd0xd0_NoCuts_Signal",1000,-100000.,100000.);
590 TH1F *hMassTrueNCsign=new TH1F("hMassTrueNCsign","D^{0} MC inv. Mass No Cuts Signal(All momenta)",600,1.600,2.200);
591 TH1F *hMassNCsign=new TH1F("hMassNCsign","D^{0} inv. Mass No Cuts Signal (All momenta)",600,1.600,2.200);
592 hMassNCsign->Sumw2();
593 TH1F *hMassTrueNCsignPM=new TH1F("hMassTrueNCsignPM","D^{0} MC inv. Mass No Cuts Signal, Mass Peak. (All momenta)",600,1.600,2.200);
594 TH1F *hMassNCsignPM=new TH1F("hMassNCsignPM","D^{0} inv. Mass No Cuts Signal (All momenta), MassPeak",600,1.600,2.200);
595 hMassNCsignPM->Sumw2();
596
597 TH1F *hMassTrueNCsignSB=new TH1F("hMassTrueNCsignSB","D^{0} MC inv. Mass in Side Bands No Cuts Signal(All momenta)",600,1.600,2.200);
598 TH1F *hMassNCsignSB=new TH1F("hMassNCsignSB","D^{0} inv. Mass in Side Bands No Cuts Signal (All momenta)",600,1.600,2.200);
599 hMassNCsignSB->Sumw2();
600
601 flistNoCutsSignal->Add(hCPtaVSd0d0NCsign);
602 flistNoCutsSignal->Add(hSecVtxZNCsign);
603 flistNoCutsSignal->Add(hSecVtxYNCsign);
604 flistNoCutsSignal->Add(hSecVtxXNCsign);
605 flistNoCutsSignal->Add(hSecVtxXYNCsign);
606 flistNoCutsSignal->Add(hSecVtxPhiNCsign);
e047b348 607 flistNoCutsSignal->Add(hd0singlTrackNCsign);
ac4c229c 608 flistNoCutsSignal->Add(hCPtaNCsign);
609 flistNoCutsSignal->Add(hd0xd0NCsign);
610 flistNoCutsSignal->Add(hMassTrueNCsign);
611 flistNoCutsSignal->Add(hMassNCsign);
612 flistNoCutsSignal->Add(hMassTrueNCsignPM);
613 flistNoCutsSignal->Add(hMassNCsignPM);
614 flistNoCutsSignal->Add(hMassTrueNCsignSB);
615 flistNoCutsSignal->Add(hMassNCsignSB);
e047b348 616
617 //%%% NEW HISTOS %%%%%%%%%%%%%%%%
618 TH1F *hdcaNCsign=new TH1F("hdcaNCsign","hdca_NoCuts_Signal",100,0.,1000.);
619 hdcaNCsign->SetXTitle("dca [#mum]");
620 hdcaNCsign->SetYTitle("Entries");
621 TH1F *hcosthetastarNCsign=new TH1F("hcosthetastarNCsign","hCosThetaStar_NoCuts_Signal",50,-1.,1.);
622 hcosthetastarNCsign->SetXTitle("cos #theta^{*}");
623 hcosthetastarNCsign->SetYTitle("Entries");
624 TH1F *hptD0NCsign=new TH1F("hptD0NCsign","D^{0} transverse momentum distribution",34,ptbinsD0arr);
625 hptD0NCsign->SetXTitle("p_{t} [GeV/c]");
626 hptD0NCsign->SetYTitle("Entries");
627 TH1F *hptD0VsMaxPtNCsign=new TH1F("hptD0VsMaxPtNCsign","Difference between D^{0} pt and highest (or second) pt",400,-50.,50.);
628 TH2F *hptD0PTallsqrtNCsign=new TH2F("hptD0PTallsqrtNCsign","D^{0} pt Vs Sqrt(Sum pt square)",34,ptbinsD0arr,200,dumbinning);
629 TH2F *hptD0PTallNCsign=new TH2F("hptD0PTallNCsign","D^{0} pt Vs Sum pt ",34,ptbinsD0arr,200,dumbinning);
630 TH2F *hptD0vsptBNCsign=new TH2F("hptD0vsptBNCsign","D^{0} pt Vs B pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
631 TH2F *hpD0vspBNCsign=new TH2F("hpD0vspBNCsign","D^{0} tot momentum Vs B tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
632 TH2F *hptD0vsptcquarkNCsign=new TH2F("hptD0vsptcquarkNCsign","D^{0} pt Vs cquark pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
633 TH2F *hpD0vspcquarkNCsign=new TH2F("hpD0vspcquarkNCsign","D^{0} tot momentum Vs cquark tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
634 flistNoCutsSignal->Add(hdcaNCsign);
635 flistNoCutsSignal->Add(hcosthetastarNCsign);
636 flistNoCutsSignal->Add(hptD0NCsign);
637 flistNoCutsSignal->Add(hptD0VsMaxPtNCsign);
638 flistNoCutsSignal->Add(hptD0PTallsqrtNCsign);
639 flistNoCutsSignal->Add(hptD0PTallNCsign);
640 flistNoCutsSignal->Add(hptD0vsptBNCsign);
641 flistNoCutsSignal->Add(hpD0vspBNCsign);
642 flistNoCutsSignal->Add(hptD0vsptcquarkNCsign);
643 flistNoCutsSignal->Add(hpD0vspcquarkNCsign);
644
645 TH1F *hd0zD0ptNCsign;
646 TH1F *hInvMassNCsign;
647 TH2F *hInvMassPtNCsign=new TH2F("hInvMassPtNCsign","Candidate p_{t} Vs invariant mass",330,1.700,2.030,200,0.,20.);
648 flistNoCutsSignal->Add(hInvMassPtNCsign);
649 TH1F *hetaNCsign;
650 TH1F *hCosPDPBNCsign;
651 TH1F *hCosPcPDNCsign;
652 // ADDITIONAL HISTOS
653 TH2F *hd0D0VSd0xd0NCsignpt;
654 TH2F *hangletracksVSd0xd0NCsignpt;
655 TH2F *hangletracksVSd0D0NCsignpt;
656 TH1F *hd0xd0NCsignpt;
657
658 TH2F *hTOFpidNCsign=new TH2F("hTOFpidNCsign","TOF time VS momentum",10,0.,4.,50,-50000.,50000.);
659 flistNoCutsSignal->Add(hTOFpidNCsign);
660
661 //##################
662 for(Int_t i=0;i<fnbins;i++){
663 //Printf("INSIDE HISTOS CREATION LOOP: %d \n",fnbins);
664
665 namehist="hd0zD0ptNCsign_pt";
666 namehist+=i;
667 titlehist="d0(z) No Cuts Signalm ptbin=";
668 titlehist+=i;
669 hd0zD0ptNCsign=new TH1F(namehist.Data(),titlehist.Data(),1000,-3000,3000.);
670 hd0zD0ptNCsign->SetXTitle("d_{0}(z) [#mum]");
671 hd0zD0ptNCsign->SetYTitle("Entries");
672 flistNoCutsSignal->Add(hd0zD0ptNCsign);
673
674 namehist="hInvMassNCsign_pt";
675 namehist+=i;
676 titlehist="Invariant Mass No Cuts Signal ptbin=";
677 titlehist+=i;
678 hInvMassNCsign=new TH1F(namehist.Data(),titlehist.Data(),600,1.600,2.200);
679 hInvMassNCsign->SetXTitle("Invariant Mass [GeV]");
680 hInvMassNCsign->SetYTitle("Entries");
681 flistNoCutsSignal->Add(hInvMassNCsign);
682
683 namehist="hetaNCsign_pt";
684 namehist+=i;
685 titlehist="eta No Cuts Signal ptbin=";
686 titlehist+=i;
687 hetaNCsign=new TH1F(namehist.Data(),titlehist.Data(),100,-3.,3.);
688 hetaNCsign->SetXTitle("Pseudorapidity");
689 hetaNCsign->SetYTitle("Entries");
690 flistNoCutsSignal->Add(hetaNCsign);
691
692 namehist="hCosPDPBNCsign_pt";
693 namehist+=i;
694 titlehist="Cosine between D0 momentum and B momentum, ptbin=";
695 titlehist+=i;
696 hCosPDPBNCsign=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
697 hCosPDPBNCsign->SetXTitle("Cosine between D0 momentum and B momentum");
698 hCosPDPBNCsign->SetYTitle("Entries");
699 flistNoCutsSignal->Add(hCosPDPBNCsign);
700
701 namehist="hCosPcPDNCsign_pt";
702 namehist+=i;
703 titlehist="Cosine between cquark momentum and D0 momentum, ptbin=";
704 titlehist+=i;
705 hCosPcPDNCsign=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
706 hCosPcPDNCsign->SetXTitle("Cosine between c quark momentum and D0 momentum");
707 hCosPcPDNCsign->SetYTitle("Entries");
708 flistNoCutsSignal->Add(hCosPcPDNCsign);
709
710
711 // %%%%%%%%%%% HERE THE ADDITIONAL HISTS %%%%%%%%%%%%%%%%%
712 namehist="hd0xd0NCsign_pt";
713 namehist+=i;
714 titlehist="d0xd0 No Cuts Signal ptbin=";
715 titlehist+=i;
716 hd0xd0NCsignpt=new TH1F(namehist.Data(),titlehist.Data(),1000,-50000.,10000.);
717 hd0xd0NCsignpt->SetXTitle("d_{0}^{K}xd_{0}^{#pi} [#mum^2]");
718 hd0xd0NCsignpt->SetYTitle("Entries");
719 flistNoCutsSignal->Add(hd0xd0NCsignpt);
720
721
722 namehist="hd0D0VSd0xd0NCsign_pt";
723 namehist+=i;
724 titlehist="d_{0}^{D^{0}} Vs d_{0}^{K}xd_{0}^{#pi} No Cuts Signal ptbin=";
725 titlehist+=i;
726 hd0D0VSd0xd0NCsignpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,100,-300,300);
727 hd0D0VSd0xd0NCsignpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
728 hd0D0VSd0xd0NCsignpt->SetYTitle(" d_{0}^{D^{0}} [#mum]");
729 flistNoCutsSignal->Add(hd0D0VSd0xd0NCsignpt);
730
731
732 namehist="hangletracksVSd0xd0NCsign_pt";
733 namehist+=i;
734 titlehist="Angle between K and #pi tracks Vs d_{0}^{K}xd_{0}^{#pi} No Cuts Signal ptbin=";
735 titlehist+=i;
736 hangletracksVSd0xd0NCsignpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,40,-0.1,3.24);
737 hangletracksVSd0xd0NCsignpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
738 hangletracksVSd0xd0NCsignpt->SetYTitle(" angle between K and #p tracks [rad]");
739 flistNoCutsSignal->Add(hangletracksVSd0xd0NCsignpt);
740
741
742 namehist="hangletracksVSd0D0NCsign_pt";
743 namehist+=i;
744 titlehist="Angle between K and #pi tracks Vs d_{0}^{D^{0}} No Cuts Signal ptbin=";
745 titlehist+=i;
746 hangletracksVSd0D0NCsignpt=new TH2F(namehist.Data(),titlehist.Data(),200,-400.,400.,40,-0.12,3.24);
747 hangletracksVSd0D0NCsignpt->SetXTitle(" d_{0}^{D^{0}} [#mum]");
748 hangletracksVSd0D0NCsignpt->SetYTitle(" angle between K and #p tracks [rad]");
749 flistNoCutsSignal->Add(hangletracksVSd0D0NCsignpt);
750
751 }
752 Printf("AFTER LOOP HISTOS CREATION \n");
753 // %%%%%%%% END OF NEW HISTOS %%%%%%%%%%%%%
754 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
624c07ab 755
756 // ####### d0 D0 histos ############
ac4c229c 757 TH1F *hd0D0NCsignPM = new TH1F("hd0D0NCsignPM","D^{0} impact par. plot , No Cuts ,Signal,Mass Peak (All momenta)",1000,-1000.,1000.);
758 hd0D0NCsignPM->SetXTitle("Impact parameter [#mum]");
759 hd0D0NCsignPM->SetYTitle("Entries");
760
761 TH1F *hd0D0VtxTrueNCsignPM = new TH1F("hd0D0VtxTrueNCsignPM","D^{0} impact par. w.r.t. True Vtx, No Cuts, Signal,Mass Peak (All momenta)",1000,-1000.,1000.);
762 hd0D0VtxTrueNCsignPM->SetXTitle("Impact parameter [#mum]");
763 hd0D0VtxTrueNCsignPM->SetYTitle("Entries");
764
765 TH1F *hMCd0D0NCsignPM = new TH1F("hMCd0D0NCsignPM","D^{0} impact par. plot, No Cuts, Signal,Mass Peak (All momenta)",1000,-1000.,1000.);
766 hMCd0D0NCsignPM->SetXTitle("MC Impact parameter [#mum]");
767 hMCd0D0NCsignPM->SetYTitle("Entries");
768
769 TH1F *hd0D0NCsignSB = new TH1F("hd0D0NCsignSB","D^{0} impact par. plot , No Cuts ,Signal,Mass Peak (All momenta)",1000,-1000.,1000.);
770 hd0D0NCsignSB->SetXTitle("Impact parameter [#mum]");
771 hd0D0NCsignSB->SetYTitle("Entries");
772
773 TH1F *hd0D0VtxTrueNCsignSB = new TH1F("hd0D0VtxTrueNCsignSB","D^{0} impact par. w.r.t. True Vtx, No Cuts, Signal,Mass Peak (All momenta)",1000,-1000.,1000.);
774 hd0D0VtxTrueNCsignSB->SetXTitle("Impact parameter [#mum]");
775 hd0D0VtxTrueNCsignSB->SetYTitle("Entries");
776
777 TH1F *hMCd0D0NCsignSB = new TH1F("hMCd0D0NCsignSB","D^{0} impact par. plot, No Cuts, Signal,Mass Peak (All momenta)",1000,-1000.,1000.);
778 hMCd0D0NCsignSB->SetXTitle("MC Impact parameter [#mum]");
779 hMCd0D0NCsignSB->SetYTitle("Entries");
780
781 flistNoCutsSignal->Add(hd0D0NCsignPM);
782 flistNoCutsSignal->Add(hd0D0VtxTrueNCsignPM);
783 flistNoCutsSignal->Add(hMCd0D0NCsignPM);
784 flistNoCutsSignal->Add(hd0D0NCsignSB);
785 flistNoCutsSignal->Add(hd0D0VtxTrueNCsignSB);
786 flistNoCutsSignal->Add(hMCd0D0NCsignSB);
787
e047b348 788 TH1F *hd0D0ptNCsignPM;
789 TH1F *hMCd0D0ptNCsignPM;
790 TH1F *hd0D0VtxTrueptNCsignPM;
791 TH1F *hd0D0ptNCsignSB;
792 TH1F *hMCd0D0ptNCsignSB;
793 TH1F *hd0D0VtxTrueptNCsignSB;
ac4c229c 794 namehist="hd0D0ptNCsign_";
624c07ab 795 titlehist="D^{0} impact par. plot, No Cuts, Signal, ";
796 for(Int_t i=0;i<fnbins;i++){
e047b348 797 Printf("IN HISTOS CREATION USING PTBINS VALUES for NAMES \n");
624c07ab 798 strnamept=namehist;
799 strnamept.Append("PkMss_pt");
800 strnamept+=i;
801
802 strtitlept=titlehist;
803 strtitlept.Append(" Mass Peak, ");
e047b348 804
624c07ab 805 strtitlept+=fptbins[i];
e047b348 806 Printf("IN HISTOS CREATION USING PTBINS VALUES for NAMES %d: %f\n",i,fptbins[i]);
624c07ab 807 strtitlept.Append("<= pt <");
808 strtitlept+=fptbins[i+1];
809 strtitlept.Append(" [GeV/c]");
810
e047b348 811 hd0D0ptNCsignPM= new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
812 hd0D0ptNCsignPM->SetXTitle("Impact parameter [#mum] ");
813 hd0D0ptNCsignPM->SetYTitle("Entries");
814 flistNoCutsSignal->Add(hd0D0ptNCsignPM);
624c07ab 815
816 strnamept.ReplaceAll("hd0D0","hMCd0D0");
e047b348 817 hMCd0D0ptNCsignPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
818 hMCd0D0ptNCsignPM->SetXTitle("MC Impact parameter [#mum] ");
819 hMCd0D0ptNCsignPM->SetYTitle("Entries");
820 flistNoCutsSignal->Add(hMCd0D0ptNCsignPM);
624c07ab 821
822
823 strnamept.ReplaceAll("hMCd0D0","hd0D0VtxTrue");
e047b348 824 hd0D0VtxTrueptNCsignPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
825 hd0D0VtxTrueptNCsignPM->SetXTitle("Impact parameter w.r.t. True Vtx [#mum] ");
826 hd0D0VtxTrueptNCsignPM->SetYTitle("Entries");
827 flistNoCutsSignal->Add(hd0D0VtxTrueptNCsignPM);
624c07ab 828
829 strnamept=namehist;
830 strnamept.Append("SBMss_pt");
831 strnamept+=i;
832
833 strtitlept=titlehist;
834 strtitlept.Append(" Side Bands, ");
835 strtitlept+=fptbins[i];
836 strtitlept.Append("<= pt <");
837 strtitlept+=fptbins[i+1];
838 strtitlept.Append(" [GeV/c]");
839
e047b348 840 hd0D0ptNCsignSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
841 hd0D0ptNCsignSB->SetXTitle("Impact parameter [#mum] ");
842 hd0D0ptNCsignSB->SetYTitle("Entries");
843 flistNoCutsSignal->Add(hd0D0ptNCsignSB);
624c07ab 844
845 strnamept.ReplaceAll("hd0D0","hMCd0D0");
e047b348 846 hMCd0D0ptNCsignSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
847 hMCd0D0ptNCsignSB->SetXTitle("MC Impact parameter [#mum] ");
848 hMCd0D0ptNCsignSB->SetYTitle("Entries");
849 flistNoCutsSignal->Add(hMCd0D0ptNCsignSB);
624c07ab 850
851 strnamept.ReplaceAll("hMCd0D0","hd0D0VtxTrue");
e047b348 852 hd0D0VtxTrueptNCsignSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
853 hd0D0VtxTrueptNCsignSB->SetXTitle("Impact parameter w.r.t. True Vtx [#mum] ");
854 hd0D0VtxTrueptNCsignSB->SetYTitle("Entries");
855 flistNoCutsSignal->Add(hd0D0VtxTrueptNCsignSB);
624c07ab 856 }
857
e047b348 858 Printf("AFTER SIGNAL HISTOS CREATION for NOCUTS\n");
859
624c07ab 860
861 //############ NO CUTS BACKGROUND HISTOGRAMS ###########
862 //
863 // ######## global properties histos #######
e047b348 864 TH2F *hCPtaVSd0d0NCback=new TH2F("hCPtaVSd0d0NCback","hCPtaVSd0d0_NoCuts_Background",1000,-100000.,100000.,100,-1.,1.);
ac4c229c 865 TH1F *hSecVtxZNCback=new TH1F("hSecVtxZNCback","hSecVtxZ_NoCuts_Background",1000,-8.,8.);
866 TH1F *hSecVtxXNCback=new TH1F("hSecVtxXNCback","hSecVtxX_NoCuts_Background",1000,-3000.,3000.);
867 TH1F *hSecVtxYNCback=new TH1F("hSecVtxYNCback","hSecVtxY_NoCuts_Background",1000,-3000.,3000.);
868 TH2F *hSecVtxXYNCback=new TH2F("hSecVtxXYNCback","hSecVtxXY_NoCuts_Background",1000,-3000.,3000.,1000,-3000.,3000.);
869 TH1F *hSecVtxPhiNCback=new TH1F("hSecVtxPhiNCback","hSecVtxPhi_NoCuts_Background",180,-180.1,180.1);
e047b348 870 TH1F *hd0singlTrackNCback=new TH1F("hd0singlTrackNCback","hd0singlTrackNoCuts_Back",1000,-5000.,5000.);
871 TH1F *hCPtaNCback=new TH1F("hCPtaNCback","hCPta_NoCuts_Background",100,-1.,1.);
ac4c229c 872 TH1F *hd0xd0NCback=new TH1F("hd0xd0NCback","hd0xd0_NoCuts_Background",1000,-100000.,100000.);
873 TH1F *hMassTrueNCback=new TH1F("hMassTrueNCback","D^{0} MC inv. Mass No Cuts Background(All momenta)",600,1.600,2.200);
874 TH1F *hMassNCback=new TH1F("hMassNCback","D^{0} inv. Mass No Cuts Background (All momenta)",600,1.600,2.200);
875 hMassNCback->Sumw2();
876 TH1F *hMassTrueNCbackPM=new TH1F("hMassTrueNCbackPM","D^{0} MC inv. Mass No Cuts Background, Mass Peak. (All momenta)",600,1.600,2.200);
877 TH1F *hMassNCbackPM=new TH1F("hMassNCbackPM","D^{0} inv. Mass No Cuts Background (All momenta), MassPeak",600,1.600,2.200);
878 hMassNCbackPM->Sumw2();
879 TH1F *hMassTrueNCbackSB=new TH1F("hMassTrueNCbackSB","D^{0} MC inv. Mass in Side Bands No Cuts Background(All momenta)",600,1.600,2.200);
880 TH1F *hMassNCbackSB=new TH1F("hMassNCbackSB","D^{0} inv. Mass in Side Bands No Cuts Background (All momenta)",600,1.600,2.200);
881 hMassNCbackSB->Sumw2();
882
883 flistNoCutsBack->Add(hCPtaVSd0d0NCback);
884 flistNoCutsBack->Add(hSecVtxZNCback);
885 flistNoCutsBack->Add(hSecVtxYNCback);
886 flistNoCutsBack->Add(hSecVtxXNCback);
887 flistNoCutsBack->Add(hSecVtxXYNCback);
888 flistNoCutsBack->Add(hSecVtxPhiNCback);
e047b348 889 flistNoCutsBack->Add(hd0singlTrackNCback);
ac4c229c 890 flistNoCutsBack->Add(hCPtaNCback);
891 flistNoCutsBack->Add(hd0xd0NCback);
892 flistNoCutsBack->Add(hMassTrueNCback);
893 flistNoCutsBack->Add(hMassNCback);
894 flistNoCutsBack->Add(hMassTrueNCbackPM);
895 flistNoCutsBack->Add(hMassNCbackPM);
896 flistNoCutsBack->Add(hMassTrueNCbackSB);
897 flistNoCutsBack->Add(hMassNCbackSB);
624c07ab 898
899
e047b348 900 //%%% NEW HISTOS %%%%%%%%%%%%%%%%
901 TH1F *hdcaNCback=new TH1F("hdcaNCback","hdca_NoCuts_Backgr",100,0.,1000.);
902 hdcaNCback->SetXTitle("dca [#mum]");
903 hdcaNCback->SetYTitle("Entries");
904 TH1F *hcosthetastarNCback=new TH1F("hcosthetastarNCback","hCosThetaStar_NoCuts_Backgr",50,-1.,1.);
905 hcosthetastarNCback->SetXTitle("cos #theta^{*}");
906 hcosthetastarNCback->SetYTitle("Entries");
907 TH1F *hptD0NCback=new TH1F("hptD0NCback","D^{0} transverse momentum distribution",34,ptbinsD0arr);
908 hptD0NCback->SetXTitle("p_{t} [GeV/c]");
909 hptD0NCback->SetYTitle("Entries");
910 TH1F *hptD0VsMaxPtNCback=new TH1F("hptD0VsMaxPtNCback","Difference between D^{0} pt and highest (or second) pt",400,-50.,50.);
911 TH2F *hptD0PTallsqrtNCback=new TH2F("hptD0PTallsqrtNCback","D^{0} pt Vs Sqrt(Sum pt square)",34,ptbinsD0arr,200,dumbinning);
912 TH2F *hptD0PTallNCback=new TH2F("hptD0PTallNCback","D^{0} pt Vs Sum pt ",34,ptbinsD0arr,200,dumbinning);
913 TH2F *hptD0vsptBNCback=new TH2F("hptD0vsptBNCback","D^{0} pt Vs B pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
914 TH2F *hpD0vspBNCback=new TH2F("hpD0vspBNCback","D^{0} tot momentum Vs B tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
915 TH2F *hptD0vsptcquarkNCback=new TH2F("hptD0vsptcquarkNCback","D^{0} pt Vs cquark pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
916 TH2F *hpD0vspcquarkNCback=new TH2F("hpD0vspcquarkNCback","D^{0} tot momentum Vs cquark tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
917 flistNoCutsBack->Add(hdcaNCback);
918 flistNoCutsBack->Add(hcosthetastarNCback);
919 flistNoCutsBack->Add(hptD0NCback);
920 flistNoCutsBack->Add(hptD0VsMaxPtNCback);
921 flistNoCutsBack->Add(hptD0PTallsqrtNCback);
922 flistNoCutsBack->Add(hptD0PTallNCback);
923 flistNoCutsBack->Add(hptD0vsptBNCback);
924 flistNoCutsBack->Add(hpD0vspBNCback);
925 flistNoCutsBack->Add(hptD0vsptcquarkNCback);
926 flistNoCutsBack->Add(hpD0vspcquarkNCback);
927
928 TH1F *hd0zD0ptNCback;
929 TH1F *hInvMassNCback;
930 TH2F *hInvMassPtNCback=new TH2F("hInvMassPtNCback","Candidate p_{t} Vs invariant mass",330,1.700,2.030,200,0.,20.);
931 TH1F *hetaNCback;
932 TH1F *hCosPDPBNCback;
933 TH1F *hCosPcPDNCback;
934 // %%%%%%%%%%% HERE THE ADDITIONAL HISTS %%%%%%%%%%%%%%%%%
935 TH2F *hd0D0VSd0xd0NCbackpt;
936 TH2F *hangletracksVSd0xd0NCbackpt;
937 TH2F *hangletracksVSd0D0NCbackpt;
938 TH1F *hd0xd0NCbackpt;
939 flistNoCutsBack->Add(hInvMassPtNCback);
940
941 TH2F *hTOFpidNCback=new TH2F("hTOFpidNCback","TOF time VS momentum",10,0.,4.,50,-50000.,50000.);
942 flistNoCutsBack->Add(hTOFpidNCback);
943
944 for(Int_t i=0;i<fnbins;i++){
945 namehist="hd0zD0ptNCback_pt";
946 namehist+=i;
947 titlehist="d0(z) No Cuts Backgrm ptbin=";
948 titlehist+=i;
949 hd0zD0ptNCback=new TH1F(namehist.Data(),titlehist.Data(),1000,-3000,3000.);
950 hd0zD0ptNCback->SetXTitle("d_{0}(z) [#mum]");
951 hd0zD0ptNCback->SetYTitle("Entries");
952 flistNoCutsBack->Add(hd0zD0ptNCback);
953
954 namehist="hInvMassNCback_pt";
955 namehist+=i;
956 titlehist="Invariant Mass No Cuts Backgr ptbin=";
957 titlehist+=i;
958 hInvMassNCback=new TH1F(namehist.Data(),titlehist.Data(),600,1.600,2.200);
959 hInvMassNCback->SetXTitle("Invariant Mass [GeV]");
960 hInvMassNCback->SetYTitle("Entries");
961 flistNoCutsBack->Add(hInvMassNCback);
962
963 namehist="hetaNCback_pt";
964 namehist+=i;
965 titlehist="eta No Cuts Backgr ptbin=";
966 titlehist+=i;
967 hetaNCback=new TH1F(namehist.Data(),titlehist.Data(),100,-3.,3.);
968 hetaNCback->SetXTitle("Pseudorapidity");
969 hetaNCback->SetYTitle("Entries");
970 flistNoCutsBack->Add(hetaNCback);
971
972 namehist="hCosPDPBNCback_pt";
973 namehist+=i;
974 titlehist="Cosine between D0 momentum and B momentum, ptbin=";
975 titlehist+=i;
976 hCosPDPBNCback=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
977 hCosPDPBNCback->SetXTitle("Cosine between D0 momentum and B momentum");
978 hCosPDPBNCback->SetYTitle("Entries");
979 flistNoCutsBack->Add(hCosPDPBNCback);
980
981 namehist="hCosPcPDNCback_pt";
982 namehist+=i;
983 titlehist="Cosine between cquark momentum and D0 momentum, ptbin=";
984 titlehist+=i;
985 hCosPcPDNCback=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
986 hCosPcPDNCback->SetXTitle("Cosine between c quark momentum and D0 momentum");
987 hCosPcPDNCback->SetYTitle("Entries");
988 flistNoCutsBack->Add(hCosPcPDNCback);
989
990
991 // %%%%%%%%%%% HERE THE ADDITIONAL HISTS %%%%%%%%%%%%%%%%%
992 namehist="hd0xd0NCback_pt";
993 namehist+=i;
994 titlehist="d0xd0 No Cuts Background ptbin=";
995 titlehist+=i;
996 hd0xd0NCbackpt=new TH1F(namehist.Data(),titlehist.Data(),1000,-50000.,10000.);
997 hd0xd0NCbackpt->SetXTitle("d_{0}^{K}xd_{0}^{#pi} [#mum^2]");
998 hd0xd0NCbackpt->SetYTitle("Entries");
999 flistNoCutsBack->Add(hd0xd0NCbackpt);
1000
1001
1002 namehist="hd0D0VSd0xd0NCback_pt";
1003 namehist+=i;
1004 titlehist="d_{0}^{D^{0}} Vs d_{0}^{K}xd_{0}^{#pi} No Cuts Back ptbin=";
1005 titlehist+=i;
1006 hd0D0VSd0xd0NCbackpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,100,-300,300);
1007 hd0D0VSd0xd0NCbackpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
1008 hd0D0VSd0xd0NCbackpt->SetYTitle(" d_{0}^{D^{0}} [#mum]");
1009 flistNoCutsBack->Add(hd0D0VSd0xd0NCbackpt);
1010
1011
1012 namehist="hangletracksVSd0xd0NCback_pt";
1013 namehist+=i;
1014 titlehist="Angle between K and #pi tracks Vs d_{0}^{K}xd_{0}^{#pi} No Cuts Back ptbin=";
1015 titlehist+=i;
1016 hangletracksVSd0xd0NCbackpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,40,-0.1,3.24);
1017 hangletracksVSd0xd0NCbackpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
1018 hangletracksVSd0xd0NCbackpt->SetYTitle(" angle between K and #p tracks [rad]");
1019 flistNoCutsBack->Add(hangletracksVSd0xd0NCbackpt);
1020
1021
1022 namehist="hangletracksVSd0D0NCback_pt";
1023 namehist+=i;
1024 titlehist="Angle between K and #pi tracks Vs d_{0}^{D^{0}} No Cuts Back ptbin=";
1025 titlehist+=i;
1026 hangletracksVSd0D0NCbackpt=new TH2F(namehist.Data(),titlehist.Data(),200,-400.,400.,40,-0.12,3.24);
1027 hangletracksVSd0D0NCbackpt->SetXTitle(" d_{0}^{D^{0}} [#mum]");
1028 hangletracksVSd0D0NCbackpt->SetYTitle(" angle between K and #p tracks [rad]");
1029 flistNoCutsBack->Add(hangletracksVSd0D0NCbackpt);
1030
1031
1032
1033 }
1034 // %%%%%%%% END OF NEW HISTOS %%%%%%%%%%%%%
1035 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
1036
1037
1038
624c07ab 1039 // ####### d0 D0 histos ############
1040
ac4c229c 1041 TH1F *hd0D0NCbackPM = new TH1F("hd0D0NCbackPM","D^{0} impact par. plot , No Cuts ,Background,Mass Peak (All momenta)",1000,-1000.,1000.);
1042 hd0D0NCbackPM->SetXTitle("Impact parameter [#mum]");
1043 hd0D0NCbackPM->SetYTitle("Entries");
1044
1045 TH1F *hd0D0VtxTrueNCbackPM = new TH1F("hd0D0VtxTrueNCbackPM","D^{0} impact par. w.r.t. True Vtx, No Cuts, Background,Mass Peak (All momenta)",1000,-1000.,1000.);
1046 hd0D0VtxTrueNCbackPM->SetXTitle("Impact parameter [#mum]");
1047 hd0D0VtxTrueNCbackPM->SetYTitle("Entries");
1048
1049 TH1F *hMCd0D0NCbackPM = new TH1F("hMCd0D0NCbackPM","D^{0} impact par. plot, No Cuts, Background,Mass Peak (All momenta)",1000,-1000.,1000.);
1050 hMCd0D0NCbackPM->SetXTitle("MC Impact parameter [#mum]");
1051 hMCd0D0NCbackPM->SetYTitle("Entries");
1052
1053 TH1F *hd0D0NCbackSB = new TH1F("hd0D0NCbackSB","D^{0} impact par. plot , No Cuts ,Background,Mass Peak (All momenta)",1000,-1000.,1000.);
1054 hd0D0NCbackSB->SetXTitle("Impact parameter [#mum]");
1055 hd0D0NCbackSB->SetYTitle("Entries");
1056
1057 TH1F *hd0D0VtxTrueNCbackSB = new TH1F("hd0D0VtxTrueNCbackSB","D^{0} impact par. w.r.t. True Vtx, No Cuts, Background,Mass Peak (All momenta)",1000,-1000.,1000.);
1058 hd0D0VtxTrueNCbackSB->SetXTitle("Impact parameter [#mum]");
1059 hd0D0VtxTrueNCbackSB->SetYTitle("Entries");
1060
1061 TH1F *hMCd0D0NCbackSB = new TH1F("hMCd0D0NCbackSB","D^{0} impact par. plot, No Cuts, Background,Mass Peak (All momenta)",1000,-1000.,1000.);
1062 hMCd0D0NCbackSB->SetXTitle("MC Impact parameter [#mum]");
1063 hMCd0D0NCbackSB->SetYTitle("Entries");
1064
1065 flistNoCutsBack->Add(hd0D0NCbackPM);
1066 flistNoCutsBack->Add(hd0D0VtxTrueNCbackPM);
1067 flistNoCutsBack->Add(hMCd0D0NCbackPM);
1068 flistNoCutsBack->Add(hd0D0NCbackSB);
1069 flistNoCutsBack->Add(hd0D0VtxTrueNCbackSB);
1070 flistNoCutsBack->Add(hMCd0D0NCbackSB);
1071
e047b348 1072 TH1F *hd0D0ptNCbackPM;
1073 TH1F *hMCd0D0ptNCbackPM;
1074 TH1F *hd0D0VtxTrueptNCbackPM;
1075 TH1F *hd0D0ptNCbackSB;
1076 TH1F *hMCd0D0ptNCbackSB;
1077 TH1F *hd0D0VtxTrueptNCbackSB;
ac4c229c 1078 namehist="hd0D0ptNCback_";
624c07ab 1079 titlehist="D^{0} impact par. plot, No Cuts, Background, ";
1080 for(Int_t i=0;i<fnbins;i++){
1081 strnamept=namehist;
1082 strnamept.Append("PkMss_pt");
1083 strnamept+=i;
1084
1085 strtitlept=titlehist;
1086 strtitlept.Append(" Mass Peak, ");
1087 strtitlept+=fptbins[i];
1088 strtitlept.Append("<= pt <");
1089 strtitlept+=fptbins[i+1];
1090 strtitlept.Append(" [GeV/c]");
1091
e047b348 1092 hd0D0ptNCbackPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1093 hd0D0ptNCbackPM->SetXTitle("Impact parameter [#mum] ");
1094 hd0D0ptNCbackPM->SetYTitle("Entries");
1095 flistNoCutsBack->Add(hd0D0ptNCbackPM);
624c07ab 1096
1097 strnamept.ReplaceAll("hd0D0","hMCd0D0");
e047b348 1098 hMCd0D0ptNCbackPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1099 hMCd0D0ptNCbackPM->SetXTitle("MC Impact parameter [#mum] ");
1100 hMCd0D0ptNCbackPM->SetYTitle("Entries");
1101 flistNoCutsBack->Add(hMCd0D0ptNCbackPM);
624c07ab 1102
1103
1104 strnamept.ReplaceAll("hMCd0D0","hd0D0VtxTrue");
e047b348 1105 hd0D0VtxTrueptNCbackPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1106 hd0D0VtxTrueptNCbackPM->SetXTitle("Impact parameter w.r.t. True Vtx [#mum] ");
1107 hd0D0VtxTrueptNCbackPM->SetYTitle("Entries");
1108 flistNoCutsBack->Add(hd0D0VtxTrueptNCbackPM);
624c07ab 1109
1110 strnamept=namehist;
1111 strnamept.Append("SBMss_pt");
1112 strnamept+=i;
1113
1114 strtitlept=titlehist;
1115 strtitlept.Append(" Side Bands, ");
1116 strtitlept+=fptbins[i];
1117 strtitlept.Append("<= pt <");
1118 strtitlept+=fptbins[i+1];
1119 strtitlept.Append(" [GeV/c]");
1120
e047b348 1121 hd0D0ptNCbackSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1122 hd0D0ptNCbackSB->SetXTitle("Impact parameter [#mum] ");
1123 hd0D0ptNCbackSB->SetYTitle("Entries");
1124 flistNoCutsBack->Add(hd0D0ptNCbackSB);
624c07ab 1125
1126 strnamept.ReplaceAll("hd0D0","hMCd0D0");
e047b348 1127 hMCd0D0ptNCbackSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1128 hMCd0D0ptNCbackSB->SetXTitle("MC Impact parameter [#mum] ");
1129 hMCd0D0ptNCbackSB->SetYTitle("Entries");
1130 flistNoCutsBack->Add(hMCd0D0ptNCbackSB);
624c07ab 1131
1132 strnamept.ReplaceAll("hMCd0D0","hd0D0VtxTrue");
e047b348 1133 hd0D0VtxTrueptNCbackSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1134 hd0D0VtxTrueptNCbackSB->SetXTitle("Impact parameter w.r.t. True Vtx [#mum] ");
1135 hd0D0VtxTrueptNCbackSB->SetYTitle("Entries");
1136 flistNoCutsBack->Add(hd0D0VtxTrueptNCbackSB);
624c07ab 1137 }
1138
1139
1140
1141 //############ NO CUTS FROMB HISTOGRAMS ###########
1142 //
1143 //####### global properties histos
1144
e047b348 1145 TH2F *hCPtaVSd0d0NCfromB=new TH2F("hCPtaVSd0d0NCfromB","hCPtaVSd0d0_NoCuts_FromB",1000,-100000.,100000.,100,-1.,1.);
ac4c229c 1146 TH1F *hSecVtxZNCfromB=new TH1F("hSecVtxZNCfromB","hSecVtxZ_NoCuts_FromB",1000,-8.,8.);
1147 TH1F *hSecVtxXNCfromB=new TH1F("hSecVtxXNCfromB","hSecVtxX_NoCuts_FromB",1000,-3000.,3000.);
1148 TH1F *hSecVtxYNCfromB=new TH1F("hSecVtxYNCfromB","hSecVtxY_NoCuts_FromB",1000,-3000.,3000.);
1149 TH2F *hSecVtxXYNCfromB=new TH2F("hSecVtxXYNCfromB","hSecVtxXY_NoCuts_FromB",1000,-3000.,3000.,1000,-3000.,3000.);
1150 TH1F *hSecVtxPhiNCfromB=new TH1F("hSecVtxPhiNCfromB","hSecVtxPhi_NoCuts_FromB",180,-180.1,180.1);
e047b348 1151 TH1F *hd0singlTrackNCfromB=new TH1F("hd0singlTrackNCfromB","hd0singlTrackNoCuts_FromB",1000,-5000.,5000.);
1152 TH1F *hCPtaNCfromB=new TH1F("hCPtaNCfromB","hCPta_NoCuts_FromB",100,-1.,1.);
ac4c229c 1153 TH1F *hd0xd0NCfromB=new TH1F("hd0xd0NCfromB","hd0xd0_NoCuts_FromB",1000,-100000.,100000.);
1154 TH1F *hMassTrueNCfromB=new TH1F("hMassTrueNCfromB","D^{0} MC inv. Mass No Cuts FromB(All momenta)",600,1.600,2.200);
1155 TH1F *hMassNCfromB=new TH1F("hMassNCfromB","D^{0} inv. Mass No Cuts FromB (All momenta)",600,1.600,2.200);
1156 hMassNCfromB->Sumw2();
1157 TH1F *hMassTrueNCfromBPM=new TH1F("hMassTrueNCfromBPM","D^{0} MC inv. Mass No Cuts FromB, Mass Peak. (All momenta)",600,1.600,2.200);
1158 TH1F *hMassNCfromBPM=new TH1F("hMassNCfromBPM","D^{0} inv. Mass No Cuts FromB (All momenta), MassPeak",600,1.600,2.200);
1159 hMassNCfromB->Sumw2();
1160 TH1F *hMassTrueNCfromBSB=new TH1F("hMassTrueNCfromBSB","D^{0} MC inv. Mass in Side Bands No Cuts FromB(All momenta)",600,1.600,2.200);
1161 TH1F *hMassNCfromBSB=new TH1F("hMassNCfromBSB","D^{0} inv. Mass in Side Bands No Cuts FromB (All momenta)",600,1.600,2.200);
1162 hMassNCfromBSB->Sumw2();
1163
1164 flistNoCutsFromB->Add(hCPtaVSd0d0NCfromB);
1165 flistNoCutsFromB->Add(hSecVtxZNCfromB);
1166 flistNoCutsFromB->Add(hSecVtxYNCfromB);
1167 flistNoCutsFromB->Add(hSecVtxXNCfromB);
1168 flistNoCutsFromB->Add(hSecVtxXYNCfromB);
1169 flistNoCutsFromB->Add(hSecVtxPhiNCfromB);
e047b348 1170 flistNoCutsFromB->Add(hd0singlTrackNCfromB);
ac4c229c 1171 flistNoCutsFromB->Add(hCPtaNCfromB);
1172 flistNoCutsFromB->Add(hd0xd0NCfromB);
1173 flistNoCutsFromB->Add(hMassTrueNCfromB);
1174 flistNoCutsFromB->Add(hMassNCfromB);
1175 flistNoCutsFromB->Add(hMassTrueNCfromBPM);
1176 flistNoCutsFromB->Add(hMassNCfromBPM);
1177 flistNoCutsFromB->Add(hMassTrueNCfromBSB);
1178 flistNoCutsFromB->Add(hMassNCfromBSB);
624c07ab 1179
e047b348 1180
1181
1182
1183
1184 //%%% NEW HISTOS %%%%%%%%%%%%%%%%
1185 TH1F *hdcaNCfromB=new TH1F("hdcaNCfromB","hdca_NoCuts_FromB",100,0.,1000.);
1186 hdcaNCfromB->SetXTitle("dca [#mum]");
1187 hdcaNCfromB->SetYTitle("Entries");
1188 TH1F *hcosthetastarNCfromB=new TH1F("hcosthetastarNCfromB","hCosThetaStar_NoCuts_FromB",50,-1.,1.);
1189 hcosthetastarNCfromB->SetXTitle("cos #theta^{*}");
1190 hcosthetastarNCfromB->SetYTitle("Entries");
1191 TH1F *hptD0NCfromB=new TH1F("hptD0NCfromB","D^{0} transverse momentum distribution",34,ptbinsD0arr);
1192 hptD0NCfromB->SetXTitle("p_{t} [GeV/c]");
1193 hptD0NCfromB->SetYTitle("Entries");
1194 TH1F *hptD0VsMaxPtNCfromB=new TH1F("hptD0VsMaxPtNCfromB","Difference between D^{0} pt and highest (or second) pt",400,-50.,50.);
1195 TH2F *hptD0PTallsqrtNCfromB=new TH2F("hptD0PTallsqrtNCfromB","D^{0} pt Vs Sqrt(Sum pt square)",34,ptbinsD0arr,200,dumbinning);
1196 TH2F *hptD0PTallNCfromB=new TH2F("hptD0PTallNCfromB","D^{0} pt Vs Sum pt ",34,ptbinsD0arr,200,dumbinning);
1197 TH2F *hptD0vsptBNCfromB=new TH2F("hptD0vsptBNCfromB","D^{0} pt Vs B pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
1198 TH2F *hpD0vspBNCfromB=new TH2F("hpD0vspBNCfromB","D^{0} tot momentum Vs B tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
1199 TH2F *hptD0vsptcquarkNCfromB=new TH2F("hptD0vsptcquarkNCfromB","D^{0} pt Vs cquark pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
1200 TH2F *hpD0vspcquarkNCfromB=new TH2F("hpD0vspcquarkNCfromB","D^{0} tot momentum Vs cquark tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
1201 flistNoCutsFromB->Add(hdcaNCfromB);
1202 flistNoCutsFromB->Add(hcosthetastarNCfromB);
1203 flistNoCutsFromB->Add(hptD0NCfromB);
1204 flistNoCutsFromB->Add(hptD0VsMaxPtNCfromB);
1205 flistNoCutsFromB->Add(hptD0PTallsqrtNCfromB);
1206 flistNoCutsFromB->Add(hptD0PTallNCfromB);
1207 flistNoCutsFromB->Add(hptD0vsptBNCfromB);
1208 flistNoCutsFromB->Add(hpD0vspBNCfromB);
1209 flistNoCutsFromB->Add(hptD0vsptcquarkNCfromB);
1210 flistNoCutsFromB->Add(hpD0vspcquarkNCfromB);
1211
1212 TH1F *hd0zD0ptNCfromB;
1213 TH1F *hInvMassNCfromB;
1214 TH2F *hInvMassPtNCfromB=new TH2F("hInvMassPtNCfromB","Candidate p_{t} Vs invariant mass",330,1.700,2.030,200,0.,20.);
1215 TH1F *hetaNCfromB;
1216 TH1F *hCosPDPBNCfromB;
1217 TH1F *hCosPcPDNCfromB;
1218
1219 // %%%%%%%%%%% HERE THE ADDITIONAL HISTS %%%%%%%%%%%%%%%%%
1220 TH2F *hd0D0VSd0xd0NCfromBpt;
1221 TH2F *hangletracksVSd0xd0NCfromBpt;
1222 TH2F *hangletracksVSd0D0NCfromBpt;
1223 TH1F *hd0xd0NCfromBpt;
1224 flistNoCutsFromB->Add(hInvMassPtNCfromB);
1225
1226 TH2F *hTOFpidNCfromB=new TH2F("hTOFpidNCfromB","TOF time VS momentum",10,0.,4.,50,-50000.,50000.);
1227 flistNoCutsFromB->Add(hTOFpidNCfromB);
1228
1229 for(Int_t i=0;i<fnbins;i++){
1230 namehist="hd0zD0ptNCfromB_pt";
1231 namehist+=i;
1232 titlehist="d0(z) No Cuts FromB ptbin=";
1233 titlehist+=i;
1234 hd0zD0ptNCfromB=new TH1F(namehist.Data(),titlehist.Data(),1000,-3000,3000.);
1235 hd0zD0ptNCfromB->SetXTitle("d_{0}(z) [#mum]");
1236 hd0zD0ptNCfromB->SetYTitle("Entries");
1237 flistNoCutsFromB->Add(hd0zD0ptNCfromB);
1238
1239 namehist="hInvMassNCfromB_pt";
1240 namehist+=i;
1241 titlehist="Invariant Mass No Cuts FromB ptbin=";
1242 titlehist+=i;
1243 hInvMassNCfromB=new TH1F(namehist.Data(),titlehist.Data(),600,1.600,2.200);
1244 hInvMassNCfromB->SetXTitle("Invariant Mass [GeV]");
1245 hInvMassNCfromB->SetYTitle("Entries");
1246 flistNoCutsFromB->Add(hInvMassNCfromB);
1247
1248 namehist="hetaNCfromB_pt";
1249 namehist+=i;
1250 titlehist="eta No Cuts FromB ptbin=";
1251 titlehist+=i;
1252 hetaNCfromB=new TH1F(namehist.Data(),titlehist.Data(),100,-3.,3.);
1253 hetaNCfromB->SetXTitle("Pseudorapidity");
1254 hetaNCfromB->SetYTitle("Entries");
1255 flistNoCutsFromB->Add(hetaNCfromB);
1256
1257 namehist="hCosPDPBNCfromB_pt";
1258 namehist+=i;
1259 titlehist="Cosine between D0 momentum and B momentum, ptbin=";
1260 titlehist+=i;
1261 hCosPDPBNCfromB=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
1262 hCosPDPBNCfromB->SetXTitle("Cosine between D0 momentum and B momentum");
1263 hCosPDPBNCfromB->SetYTitle("Entries");
1264 flistNoCutsFromB->Add(hCosPDPBNCfromB);
1265
1266 namehist="hCosPcPDNCfromB_pt";
1267 namehist+=i;
1268 titlehist="Cosine between cquark momentum and D0 momentum, ptbin=";
1269 titlehist+=i;
1270 hCosPcPDNCfromB=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
1271 hCosPcPDNCfromB->SetXTitle("Cosine between c quark momentum and D0 momentum");
1272 hCosPcPDNCfromB->SetYTitle("Entries");
1273 flistNoCutsFromB->Add(hCosPcPDNCfromB);
1274
1275// %%%%%%%%%%% HERE THE ADDITIONAL HISTS %%%%%%%%%%%%%%%%%
1276 namehist="hd0xd0NCfromB_pt";
1277 namehist+=i;
1278 titlehist="d0xd0 No Cuts FromB ptbin=";
1279 titlehist+=i;
1280 hd0xd0NCfromBpt=new TH1F(namehist.Data(),titlehist.Data(),1000,-50000.,10000.);
1281 hd0xd0NCfromBpt->SetXTitle("d_{0}^{K}xd_{0}^{#pi} [#mum^2]");
1282 hd0xd0NCfromBpt->SetYTitle("Entries");
1283 flistNoCutsFromB->Add(hd0xd0NCfromBpt);
1284
1285
1286 namehist="hd0D0VSd0xd0NCfromB_pt";
1287 namehist+=i;
1288 titlehist="d_{0}^{D^{0}} Vs d_{0}^{K}xd_{0}^{#pi} No Cuts FromB ptbin=";
1289 titlehist+=i;
1290 hd0D0VSd0xd0NCfromBpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,100,-300,300);
1291 hd0D0VSd0xd0NCfromBpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
1292 hd0D0VSd0xd0NCfromBpt->SetYTitle(" d_{0}^{D^{0}} [#mum]");
1293 flistNoCutsFromB->Add(hd0D0VSd0xd0NCfromBpt);
1294
1295
1296 namehist="hangletracksVSd0xd0NCfromB_pt";
1297 namehist+=i;
1298 titlehist="Angle between K and #pi tracks Vs d_{0}^{K}xd_{0}^{#pi} No Cuts FromB ptbin=";
1299 titlehist+=i;
1300 hangletracksVSd0xd0NCfromBpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,40,-0.1,3.24);
1301 hangletracksVSd0xd0NCfromBpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
1302 hangletracksVSd0xd0NCfromBpt->SetYTitle(" angle between K and #p tracks [rad]");
1303 flistNoCutsFromB->Add(hangletracksVSd0xd0NCfromBpt);
1304
1305
1306 namehist="hangletracksVSd0D0NCfromB_pt";
1307 namehist+=i;
1308 titlehist="Angle between K and #pi tracks Vs d_{0}^{D^{0}} No Cuts FromB ptbin=";
1309 titlehist+=i;
1310 hangletracksVSd0D0NCfromBpt=new TH2F(namehist.Data(),titlehist.Data(),200,-400.,400.,40,-0.12,3.24);
1311 hangletracksVSd0D0NCfromBpt->SetXTitle(" d_{0}^{D^{0}} [#mum]");
1312 hangletracksVSd0D0NCfromBpt->SetYTitle(" angle between K and #p tracks [rad]");
1313 flistNoCutsFromB->Add(hangletracksVSd0D0NCfromBpt);
1314
1315
1316 }
1317 // %%%%%%%% END OF NEW HISTOS %%%%%%%%%%%%%
1318 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
1319
1320
1321
624c07ab 1322 // ######### d0 D0 histos ##############
ac4c229c 1323 TH1F *hd0D0NCfromBPM = new TH1F("hd0D0NCfromBPM","D^{0} impact par. plot , No Cuts ,FromB,Mass Peak (All momenta)",1000,-1000.,1000.);
1324 hd0D0NCfromBPM->SetXTitle("Impact parameter [#mum]");
1325 hd0D0NCfromBPM->SetYTitle("Entries");
1326
1327 TH1F *hd0D0VtxTrueNCfromBPM = new TH1F("hd0D0VtxTrueNCfromBPM","D^{0} impact par. w.r.t. True Vtx, No Cuts, FromB,Mass Peak (All momenta)",1000,-1000.,1000.);
1328 hd0D0VtxTrueNCfromBPM->SetXTitle("Impact parameter [#mum]");
1329 hd0D0VtxTrueNCfromBPM->SetYTitle("Entries");
1330
1331 TH1F *hMCd0D0NCfromBPM = new TH1F("hMCd0D0NCfromBPM","D^{0} impact par. plot, No Cuts, FromB,Mass Peak (All momenta)",1000,-1000.,1000.);
1332 hMCd0D0NCfromBPM->SetXTitle("MC Impact parameter [#mum]");
1333 hMCd0D0NCfromBPM->SetYTitle("Entries");
1334
1335 TH1F *hd0D0NCfromBSB = new TH1F("hd0D0NCfromBSB","D^{0} impact par. plot , No Cuts ,FromB,Mass Peak (All momenta)",1000,-1000.,1000.);
1336 hd0D0NCfromBSB->SetXTitle("Impact parameter [#mum]");
1337 hd0D0NCfromBSB->SetYTitle("Entries");
1338
1339 TH1F *hd0D0VtxTrueNCfromBSB = new TH1F("hd0D0VtxTrueNCfromBSB","D^{0} impact par. w.r.t. True Vtx, No Cuts, FromB,Mass Peak (All momenta)",1000,-1000.,1000.);
1340 hd0D0VtxTrueNCfromBSB->SetXTitle("Impact parameter [#mum]");
1341 hd0D0VtxTrueNCfromBSB->SetYTitle("Entries");
1342
1343 TH1F *hMCd0D0NCfromBSB = new TH1F("hMCd0D0NCfromBSB","D^{0} impact par. plot, No Cuts, FromB,Mass Peak (All momenta)",1000,-1000.,1000.);
1344 hMCd0D0NCfromBSB->SetXTitle("MC Impact parameter [#mum]");
1345 hMCd0D0NCfromBSB->SetYTitle("Entries");
1346
1347 flistNoCutsFromB->Add(hd0D0NCfromBPM);
1348 flistNoCutsFromB->Add(hd0D0VtxTrueNCfromBPM);
1349 flistNoCutsFromB->Add(hMCd0D0NCfromBPM);
1350 flistNoCutsFromB->Add(hd0D0NCfromBSB);
1351 flistNoCutsFromB->Add(hd0D0VtxTrueNCfromBSB);
1352 flistNoCutsFromB->Add(hMCd0D0NCfromBSB);
1353
e047b348 1354 TH1F *hd0D0ptNCfromBPM;
1355 TH1F *hMCd0D0ptNCfromBPM;
1356 TH1F *hd0D0VtxTrueptNCfromBPM;
1357 TH1F *hd0D0ptNCfromBSB;
1358 TH1F *hMCd0D0ptNCfromBSB;
1359 TH1F *hd0D0VtxTrueptNCfromBSB;
ac4c229c 1360 namehist="hd0D0ptNCfromB_";
624c07ab 1361 titlehist="D^{0} impact par. plot, No Cuts, FromB, ";
1362 for(Int_t i=0;i<fnbins;i++){
1363 strnamept=namehist;
1364 strnamept.Append("PkMss_pt");
1365 strnamept+=i;
1366
1367 strtitlept=titlehist;
1368 strtitlept.Append(" Mass Peak, ");
1369 strtitlept+=fptbins[i];
1370 strtitlept.Append("<= pt <");
1371 strtitlept+=fptbins[i+1];
1372 strtitlept.Append(" [GeV/c]");
1373
e047b348 1374 hd0D0ptNCfromBPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1375 hd0D0ptNCfromBPM->SetXTitle("Impact parameter [#mum] ");
1376 hd0D0ptNCfromBPM->SetYTitle("Entries");
1377 flistNoCutsFromB->Add(hd0D0ptNCfromBPM);
624c07ab 1378
1379 strnamept.ReplaceAll("hd0D0","hMCd0D0");
e047b348 1380 hMCd0D0ptNCfromBPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1381 hMCd0D0ptNCfromBPM->SetXTitle("MC Impact parameter [#mum] ");
1382 hMCd0D0ptNCfromBPM->SetYTitle("Entries");
1383 flistNoCutsFromB->Add(hMCd0D0ptNCfromBPM);
624c07ab 1384
1385
1386 strnamept.ReplaceAll("hMCd0D0","hd0D0VtxTrue");
e047b348 1387 hd0D0VtxTrueptNCfromBPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1388 hd0D0VtxTrueptNCfromBPM->SetXTitle("Impact parameter w.r.t. True Vtx [#mum] ");
1389 hd0D0VtxTrueptNCfromBPM->SetYTitle("Entries");
1390 flistNoCutsFromB->Add(hd0D0VtxTrueptNCfromBPM);
624c07ab 1391
1392 strnamept=namehist;
1393 strnamept.Append("SBMss_pt");
1394 strnamept+=i;
1395
1396 strtitlept=titlehist;
1397 strtitlept.Append(" Side Bands, ");
1398 strtitlept+=fptbins[i];
1399 strtitlept.Append("<= pt <");
1400 strtitlept+=fptbins[i+1];
1401 strtitlept.Append(" [GeV/c]");
1402
e047b348 1403 hd0D0ptNCfromBSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1404 hd0D0ptNCfromBSB->SetXTitle("Impact parameter [#mum] ");
1405 hd0D0ptNCfromBSB->SetYTitle("Entries");
1406 flistNoCutsFromB->Add(hd0D0ptNCfromBSB);
624c07ab 1407
1408 strnamept.ReplaceAll("hd0D0","hMCd0D0");
e047b348 1409 hMCd0D0ptNCfromBSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1410 hMCd0D0ptNCfromBSB->SetXTitle("MC Impact parameter [#mum] ");
1411 hMCd0D0ptNCfromBSB->SetYTitle("Entries");
1412 flistNoCutsFromB->Add(hMCd0D0ptNCfromBSB);
624c07ab 1413
1414 strnamept.ReplaceAll("hMCd0D0","hd0D0VtxTrue");
e047b348 1415 hd0D0VtxTrueptNCfromBSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1416 hd0D0VtxTrueptNCfromBSB->SetXTitle("Impact parameter w.r.t. True Vtx [#mum] ");
1417 hd0D0VtxTrueptNCfromBSB->SetYTitle("Entries");
1418 flistNoCutsFromB->Add(hd0D0VtxTrueptNCfromBSB);
624c07ab 1419 }
1420
1421
1422
1423 //############ NO CUTS FROM DSTAR HISTOGRAMS ###########
1424 //
1425 //############# global properties histos #######
1426
e047b348 1427 TH2F *hCPtaVSd0d0NCfromDstar=new TH2F("hCPtaVSd0d0NCfromDstar","hCPtaVSd0d0_NoCuts_FromDStar",1000,-100000.,100000.,100,-1.,1.);
ac4c229c 1428 TH1F *hSecVtxZNCfromDstar=new TH1F("hSecVtxZNCfromDstar","hSecVtxZ_NoCuts_FromDStar",1000,-8.,8.);
1429 TH1F *hSecVtxXNCfromDstar=new TH1F("hSecVtxXNCfromDstar","hSecVtxX_NoCuts_FromDStar",1000,-3000.,3000.);
1430 TH1F *hSecVtxYNCfromDstar=new TH1F("hSecVtxYNCfromDstar","hSecVtxY_NoCuts_FromDStar",1000,-3000.,3000.);
1431 TH2F *hSecVtxXYNCfromDstar=new TH2F("hSecVtxXYNCfromDstar","hSecVtxXY_NoCuts_FromDStar",1000,-3000.,3000.,1000,-3000.,3000.);
1432 TH1F *hSecVtxPhiNCfromDstar=new TH1F("hSecVtxPhiNCfromDstar","hSecVtxPhi_NoCuts_FromDStar",180,-180.1,180.1);
e047b348 1433 TH1F *hd0singlTrackNCfromDstar=new TH1F("hd0singlTrackNCfromDstar","hd0singlTrackNoCuts_fromDstar",1000,-5000.,5000.);
1434 TH1F *hCPtaNCfromDstar=new TH1F("hCPtaNCfromDstar","hCPta_NoCuts_FromDStar",100,-1.,1.);
ac4c229c 1435 TH1F *hd0xd0NCfromDstar=new TH1F("hd0xd0NCfromDstar","hd0xd0_NoCuts_FromDStar",1000,-100000.,100000.);
1436 TH1F *hMassTrueNCfromDstar=new TH1F("hMassTrueNCfromDstar","D^{0} MC inv. Mass No Cuts FromDStar(All momenta)",600,1.600,2.200);
1437 TH1F *hMassNCfromDstar=new TH1F("hMassNCfromDstar","D^{0} inv. Mass No Cuts FromDStar (All momenta)",600,1.600,2.200);
1438 hMassNCfromDstar->Sumw2();
1439 TH1F *hMassTrueNCfromDstarPM=new TH1F("hMassTrueNCfromDstarPM","D^{0} MC inv. Mass No Cuts FromDStar, Mass Peak. (All momenta)",600,1.600,2.200);
1440 TH1F *hMassNCfromDstarPM=new TH1F("hMassNCfromDstarPM","D^{0} inv. Mass No Cuts FromDStar (All momenta), MassPeak",600,1.600,2.200);
1441 hMassNCfromDstarPM->Sumw2();
1442 TH1F *hMassTrueNCfromDstarSB=new TH1F("hMassTrueNCfromDstarSB","D^{0} MC inv. Mass in Side Bands No Cuts FromDStar(All momenta)",600,1.600,2.200);
1443 TH1F *hMassNCfromDstarSB=new TH1F("hMassNCfromDstarSB","D^{0} inv. Mass in Side Bands No Cuts FromDStar (All momenta)",600,1.600,2.200);
1444 hMassNCfromDstarSB->Sumw2();
1445
1446 flistNoCutsFromDstar->Add(hCPtaVSd0d0NCfromDstar);
1447 flistNoCutsFromDstar->Add(hSecVtxZNCfromDstar);
1448 flistNoCutsFromDstar->Add(hSecVtxYNCfromDstar);
1449 flistNoCutsFromDstar->Add(hSecVtxXNCfromDstar);
1450 flistNoCutsFromDstar->Add(hSecVtxXYNCfromDstar);
1451 flistNoCutsFromDstar->Add(hSecVtxPhiNCfromDstar);
e047b348 1452 flistNoCutsFromDstar->Add(hd0singlTrackNCfromDstar);
ac4c229c 1453 flistNoCutsFromDstar->Add(hCPtaNCfromDstar);
1454 flistNoCutsFromDstar->Add(hd0xd0NCfromDstar);
1455 flistNoCutsFromDstar->Add(hMassTrueNCfromDstar);
1456 flistNoCutsFromDstar->Add(hMassNCfromDstar);
1457 flistNoCutsFromDstar->Add(hMassTrueNCfromDstarPM);
1458 flistNoCutsFromDstar->Add(hMassNCfromDstarPM);
1459 flistNoCutsFromDstar->Add(hMassTrueNCfromDstarSB);
1460 flistNoCutsFromDstar->Add(hMassNCfromDstarSB);
624c07ab 1461
e047b348 1462
1463
1464
1465//%%% NEW HISTOS %%%%%%%%%%%%%%%%
1466 TH1F *hdcaNCfromDstar=new TH1F("hdcaNCfromDstar","hdca_NoCuts_FromDstar",100,0.,1000.);
1467 hdcaNCfromDstar->SetXTitle("dca [#mum]");
1468 hdcaNCfromDstar->SetYTitle("Entries");
1469 TH1F *hcosthetastarNCfromDstar=new TH1F("hcosthetastarNCfromDstar","hCosThetaStar_NoCuts_FromDstar",50,-1.,1.);
1470 hcosthetastarNCfromDstar->SetXTitle("cos #theta^{*}");
1471 hcosthetastarNCfromDstar->SetYTitle("Entries");
1472 TH1F *hptD0NCfromDstar=new TH1F("hptD0NCfromDstar","D^{0} transverse momentum distribution",34,ptbinsD0arr);
1473 hptD0NCfromDstar->SetXTitle("p_{t} [GeV/c]");
1474 hptD0NCfromDstar->SetYTitle("Entries");
1475 TH1F *hptD0VsMaxPtNCfromDstar=new TH1F("hptD0VsMaxPtNCfromDstar","Difference between D^{0} pt and highest (or second) pt",400,-50.,50.);
1476 TH2F *hptD0PTallsqrtNCfromDstar=new TH2F("hptD0PTallsqrtNCfromDstar","D^{0} pt Vs Sqrt(Sum pt square)",34,ptbinsD0arr,200,dumbinning);
1477 TH2F *hptD0PTallNCfromDstar=new TH2F("hptD0PTallNCfromDstar","D^{0} pt Vs Sum pt ",34,ptbinsD0arr,200,dumbinning);
1478 TH2F *hptD0vsptBNCfromDstar=new TH2F("hptD0vsptBNCfromDstar","D^{0} pt Vs B pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
1479 TH2F *hpD0vspBNCfromDstar=new TH2F("hpD0vspBNCfromDstar","D^{0} tot momentum Vs B tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
1480 TH2F *hptD0vsptcquarkNCfromDstar=new TH2F("hptD0vsptcquarkNCfromDstar","D^{0} pt Vs cquark pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
1481 TH2F *hpD0vspcquarkNCfromDstar=new TH2F("hpD0vspcquarkNCfromDstar","D^{0} tot momentum Vs cquark tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
1482 flistNoCutsFromDstar->Add(hdcaNCfromDstar);
1483 flistNoCutsFromDstar->Add(hcosthetastarNCfromDstar);
1484 flistNoCutsFromDstar->Add(hptD0NCfromDstar);
1485 flistNoCutsFromDstar->Add(hptD0VsMaxPtNCfromDstar);
1486 flistNoCutsFromDstar->Add(hptD0PTallsqrtNCfromDstar);
1487 flistNoCutsFromDstar->Add(hptD0PTallNCfromDstar);
1488 flistNoCutsFromDstar->Add(hptD0vsptBNCfromDstar);
1489 flistNoCutsFromDstar->Add(hpD0vspBNCfromDstar);
1490 flistNoCutsFromDstar->Add(hptD0vsptcquarkNCfromDstar);
1491 flistNoCutsFromDstar->Add(hpD0vspcquarkNCfromDstar);
1492
1493 TH1F *hd0zD0ptNCfromDstar;
1494 TH1F *hInvMassNCfromDstar;
1495 TH2F *hInvMassPtNCfromDstar=new TH2F("hInvMassPtNCfromDstar","Candidate p_{t} Vs invariant mass",330,1.700,2.030,200,0.,20.);
1496 TH1F *hetaNCfromDstar;
1497 TH1F *hCosPDPBNCfromDstar;
1498 TH1F *hCosPcPDNCfromDstar;
1499 flistNoCutsFromDstar->Add(hInvMassPtNCfromDstar);
1500 // %%%%%%%%%%% HERE THE ADDITIONAL HISTS %%%%%%%%%%%%%%%%%
1501 TH2F *hd0D0VSd0xd0NCfromDstarpt;
1502 TH2F *hangletracksVSd0xd0NCfromDstarpt;
1503 TH2F *hangletracksVSd0D0NCfromDstarpt;
1504 TH1F *hd0xd0NCfromDstarpt;
1505
1506 TH2F *hTOFpidNCfromDstar=new TH2F("hTOFpidNCfromDstar","TOF time VS momentum",10,0.,4.,50,-50000.,50000.);
1507 flistNoCutsFromDstar->Add(hTOFpidNCfromDstar);
1508
1509 for(Int_t i=0;i<fnbins;i++){
1510 namehist="hd0zD0ptNCfromDstar_pt";
1511 namehist+=i;
1512 titlehist="d0(z) No Cuts FromDstarm ptbin=";
1513 titlehist+=i;
1514 hd0zD0ptNCfromDstar=new TH1F(namehist.Data(),titlehist.Data(),1000,-3000,3000.);
1515 hd0zD0ptNCfromDstar->SetXTitle("d_{0}(z) [#mum]");
1516 hd0zD0ptNCfromDstar->SetYTitle("Entries");
1517 flistNoCutsFromDstar->Add(hd0zD0ptNCfromDstar);
1518
1519 namehist="hInvMassNCfromDstar_pt";
1520 namehist+=i;
1521 titlehist="Invariant Mass No Cuts FromDstar ptbin=";
1522 titlehist+=i;
1523 hInvMassNCfromDstar=new TH1F(namehist.Data(),titlehist.Data(),600,1.600,2.200);
1524 hInvMassNCfromDstar->SetXTitle("Invariant Mass [GeV]");
1525 hInvMassNCfromDstar->SetYTitle("Entries");
1526 flistNoCutsFromDstar->Add(hInvMassNCfromDstar);
1527
1528 namehist="hetaNCfromDstar_pt";
1529 namehist+=i;
1530 titlehist="eta No Cuts FromDstar ptbin=";
1531 titlehist+=i;
1532 hetaNCfromDstar=new TH1F(namehist.Data(),titlehist.Data(),100,-3.,3.);
1533 hetaNCfromDstar->SetXTitle("Pseudorapidity");
1534 hetaNCfromDstar->SetYTitle("Entries");
1535 flistNoCutsFromDstar->Add(hetaNCfromDstar);
1536
1537 namehist="hCosPDPBNCfromDstar_pt";
1538 namehist+=i;
1539 titlehist="Cosine between D0 momentum and B momentum, ptbin=";
1540 titlehist+=i;
1541 hCosPDPBNCfromDstar=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
1542 hCosPDPBNCfromDstar->SetXTitle("Cosine between D0 momentum and B momentum");
1543 hCosPDPBNCfromDstar->SetYTitle("Entries");
1544 flistNoCutsFromDstar->Add(hCosPDPBNCfromDstar);
1545
1546 namehist="hCosPcPDNCfromDstar_pt";
1547 namehist+=i;
1548 titlehist="Cosine between cquark momentum and D0 momentum, ptbin=";
1549 titlehist+=i;
1550 hCosPcPDNCfromDstar=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
1551 hCosPcPDNCfromDstar->SetXTitle("Cosine between c quark momentum and D0 momentum");
1552 hCosPcPDNCfromDstar->SetYTitle("Entries");
1553 flistNoCutsFromDstar->Add(hCosPcPDNCfromDstar);
1554
1555 // %%%%%%%%%%% HERE THE ADDITIONAL HISTS %%%%%%%%%%%%%%%%%
1556 namehist="hd0xd0NCfromDstar_pt";
1557 namehist+=i;
1558 titlehist="d0xd0 No Cuts FromDstar ptbin=";
1559 titlehist+=i;
1560 hd0xd0NCfromDstarpt=new TH1F(namehist.Data(),titlehist.Data(),1000,-50000.,10000.);
1561 hd0xd0NCfromDstarpt->SetXTitle("d_{0}^{K}xd_{0}^{#pi} [#mum^2]");
1562 hd0xd0NCfromDstarpt->SetYTitle("Entries");
1563 flistNoCutsFromDstar->Add(hd0xd0NCfromDstarpt);
1564
1565
1566 namehist="hd0D0VSd0xd0NCfromDstar_pt";
1567 namehist+=i;
1568 titlehist="d_{0}^{D^{0}} Vs d_{0}^{K}xd_{0}^{#pi} No Cuts FromDstar ptbin=";
1569 titlehist+=i;
1570 hd0D0VSd0xd0NCfromDstarpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,100,-300,300);
1571 hd0D0VSd0xd0NCfromDstarpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
1572 hd0D0VSd0xd0NCfromDstarpt->SetYTitle(" d_{0}^{D^{0}} [#mum]");
1573 flistNoCutsFromDstar->Add(hd0D0VSd0xd0NCfromDstarpt);
1574
1575
1576 namehist="hangletracksVSd0xd0NCfromDstar_pt";
1577 namehist+=i;
1578 titlehist="Angle between K and #pi tracks Vs d_{0}^{K}xd_{0}^{#pi} No Cuts FromDstar ptbin=";
1579 titlehist+=i;
1580 hangletracksVSd0xd0NCfromDstarpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,40,-0.1,3.24);
1581 hangletracksVSd0xd0NCfromDstarpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
1582 hangletracksVSd0xd0NCfromDstarpt->SetYTitle(" angle between K and #p tracks [rad]");
1583 flistNoCutsFromDstar->Add(hangletracksVSd0xd0NCfromDstarpt);
1584
1585
1586 namehist="hangletracksVSd0D0NCfromDstar_pt";
1587 namehist+=i;
1588 titlehist="Angle between K and #pi tracks Vs d_{0}^{D^{0}} No Cuts FromDstar ptbin=";
1589 titlehist+=i;
1590 hangletracksVSd0D0NCfromDstarpt=new TH2F(namehist.Data(),titlehist.Data(),200,-400.,400.,40,-0.12,3.24);
1591 hangletracksVSd0D0NCfromDstarpt->SetXTitle(" d_{0}^{D^{0}} [#mum]");
1592 hangletracksVSd0D0NCfromDstarpt->SetYTitle(" angle between K and #p tracks [rad]");
1593 flistNoCutsFromDstar->Add(hangletracksVSd0D0NCfromDstarpt);
1594
1595 }
1596 // %%%%%%%% END OF NEW HISTOS %%%%%%%%%%%%%
1597 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
1598
1599
624c07ab 1600 //########## d0 D0 histos #############
ac4c229c 1601 TH1F *hd0D0NCfromDstPM = new TH1F("hd0D0NCfromDstarPM","D^{0} impact par. plot , No Cuts ,FromDStar,Mass Peak (All momenta)",1000,-1000.,1000.);
1602 hd0D0NCfromDstPM->SetXTitle("Impact parameter [#mum]");
1603 hd0D0NCfromDstPM->SetYTitle("Entries");
1604
1605 TH1F *hd0D0VtxTrueNCfromDstPM = new TH1F("hd0D0VtxTrueNCfromDstarPM","D^{0} impact par. w.r.t. True Vtx, No Cuts, FromDStar,Mass Peak (All momenta)",1000,-1000.,1000.);
1606 hd0D0VtxTrueNCfromDstPM->SetXTitle("Impact parameter [#mum]");
1607 hd0D0VtxTrueNCfromDstPM->SetYTitle("Entries");
1608
1609 TH1F *hMCd0D0NCfromDstPM = new TH1F("hMCd0D0NCfromDstarPM","D^{0} impact par. plot, No Cuts, FromDStar,Mass Peak (All momenta)",1000,-1000.,1000.);
1610 hMCd0D0NCfromDstPM->SetXTitle("MC Impact parameter [#mum]");
1611 hMCd0D0NCfromDstPM->SetYTitle("Entries");
1612
1613 TH1F *hd0D0NCfromDstSB = new TH1F("hd0D0NCfromDstarSB","D^{0} impact par. plot , No Cuts ,FromDStar,Mass Peak (All momenta)",1000,-1000.,1000.);
1614 hd0D0NCfromDstSB->SetXTitle("Impact parameter [#mum]");
1615 hd0D0NCfromDstSB->SetYTitle("Entries");
1616
1617 TH1F *hd0D0VtxTrueNCfromDstSB = new TH1F("hd0D0VtxTrueNCfromDstarSB","D^{0} impact par. w.r.t. True Vtx, No Cuts, FromDStar,Mass Peak (All momenta)",1000,-1000.,1000.);
1618 hd0D0VtxTrueNCfromDstSB->SetXTitle("Impact parameter [#mum]");
1619 hd0D0VtxTrueNCfromDstSB->SetYTitle("Entries");
1620
1621 TH1F *hMCd0D0NCfromDstSB = new TH1F("hMCd0D0NCfromDstarSB","D^{0} impact par. plot, No Cuts, FromDStar,Mass Peak (All momenta)",1000,-1000.,1000.);
1622 hMCd0D0NCfromDstSB->SetXTitle("MC Impact parameter [#mum]");
1623 hMCd0D0NCfromDstSB->SetYTitle("Entries");
1624
1625 flistNoCutsFromDstar->Add(hd0D0NCfromDstPM);
1626 flistNoCutsFromDstar->Add(hd0D0VtxTrueNCfromDstPM);
1627 flistNoCutsFromDstar->Add(hMCd0D0NCfromDstPM);
1628 flistNoCutsFromDstar->Add(hd0D0NCfromDstSB);
1629 flistNoCutsFromDstar->Add(hd0D0VtxTrueNCfromDstSB);
1630 flistNoCutsFromDstar->Add(hMCd0D0NCfromDstSB);
1631
e047b348 1632 TH1F *hd0D0ptNCfromDstPM;
1633 TH1F *hMCd0D0ptNCfromDstPM;
1634 TH1F *hd0D0VtxTrueptNCfromDstPM;
1635 TH1F *hd0D0ptNCfromDstSB;
1636 TH1F *hMCd0D0ptNCfromDstSB;
1637 TH1F *hd0D0VtxTrueptNCfromDstSB;
ac4c229c 1638 namehist="hd0D0ptNCfromDstar_";
624c07ab 1639 titlehist="D^{0} impact par. plot, No Cuts, FromDStar, ";
1640 for(Int_t i=0;i<fnbins;i++){
1641 strnamept=namehist;
1642 strnamept.Append("PkMss_pt");
1643 strnamept+=i;
1644
1645 strtitlept=titlehist;
1646 strtitlept.Append(" Mass Peak, ");
1647 strtitlept+=fptbins[i];
1648 strtitlept.Append("<= pt <");
1649 strtitlept+=fptbins[i+1];
1650 strtitlept.Append(" [GeV/c]");
1651
e047b348 1652 hd0D0ptNCfromDstPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1653 hd0D0ptNCfromDstPM->SetXTitle("Impact parameter [#mum] ");
1654 hd0D0ptNCfromDstPM->SetYTitle("Entries");
1655 flistNoCutsFromDstar->Add(hd0D0ptNCfromDstPM);
624c07ab 1656
1657 strnamept.ReplaceAll("hd0D0","hMCd0D0");
e047b348 1658 hMCd0D0ptNCfromDstPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1659 hMCd0D0ptNCfromDstPM->SetXTitle("MC Impact parameter [#mum] ");
1660 hMCd0D0ptNCfromDstPM->SetYTitle("Entries");
1661 flistNoCutsFromDstar->Add(hMCd0D0ptNCfromDstPM);
624c07ab 1662
1663
1664 strnamept.ReplaceAll("hMCd0D0","hd0D0VtxTrue");
e047b348 1665 hd0D0VtxTrueptNCfromDstPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1666 hd0D0VtxTrueptNCfromDstPM->SetXTitle("Impact parameter w.r.t. True Vtx [#mum] ");
1667 hd0D0VtxTrueptNCfromDstPM->SetYTitle("Entries");
1668 flistNoCutsFromDstar->Add(hd0D0VtxTrueptNCfromDstPM);
624c07ab 1669
1670 strnamept=namehist;
1671 strnamept.Append("SBMss_pt");
1672 strnamept+=i;
1673
1674 strtitlept=titlehist;
1675 strtitlept.Append(" Side Bands, ");
1676 strtitlept+=fptbins[i];
1677 strtitlept.Append("<= pt <");
1678 strtitlept+=fptbins[i+1];
1679 strtitlept.Append(" [GeV/c]");
1680
e047b348 1681 hd0D0ptNCfromDstSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1682 hd0D0ptNCfromDstSB->SetXTitle("Impact parameter [#mum] ");
1683 hd0D0ptNCfromDstSB->SetYTitle("Entries");
1684 flistNoCutsFromDstar->Add(hd0D0ptNCfromDstSB);
624c07ab 1685
1686 strnamept.ReplaceAll("hd0D0","hMCd0D0");
e047b348 1687 hMCd0D0ptNCfromDstSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1688 hMCd0D0ptNCfromDstSB->SetXTitle("MC Impact parameter [#mum] ");
1689 hMCd0D0ptNCfromDstSB->SetYTitle("Entries");
1690 flistNoCutsFromDstar->Add(hMCd0D0ptNCfromDstSB);
624c07ab 1691
1692 strnamept.ReplaceAll("hMCd0D0","hd0D0VtxTrue");
e047b348 1693 hd0D0VtxTrueptNCfromDstSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1694 hd0D0VtxTrueptNCfromDstSB->SetXTitle("Impact parameter w.r.t. True Vtx [#mum] ");
1695 hd0D0VtxTrueptNCfromDstSB->SetYTitle("Entries");
1696 flistNoCutsFromDstar->Add(hd0D0VtxTrueptNCfromDstSB);
624c07ab 1697 }
1698
1699
1700 //############ NO CUTS OTHER HISTOGRAMS ###########
1701 //
1702 //########### global properties histos ###########
1703
e047b348 1704 TH2F *hCPtaVSd0d0NCother=new TH2F("hCPtaVSd0d0NCother","hCPtaVSd0d0_NoCuts_other",1000,-100000.,100000.,100,-1.,1.);
ac4c229c 1705 TH1F *hSecVtxZNCother=new TH1F("hSecVtxZNCother","hSecVtxZ_NoCuts_other",1000,-8.,8.);
1706 TH1F *hSecVtxXNCother=new TH1F("hSecVtxXNCother","hSecVtxX_NoCuts_other",1000,-3000.,3000.);
1707 TH1F *hSecVtxYNCother=new TH1F("hSecVtxYNCother","hSecVtxY_NoCuts_other",1000,-3000.,3000.);
1708 TH2F *hSecVtxXYNCother=new TH2F("hSecVtxXYNCother","hSecVtxXY_NoCuts_other",1000,-3000.,3000.,1000,-3000.,3000.);
1709 TH1F *hSecVtxPhiNCother=new TH1F("hSecVtxPhiNCother","hSecVtxPhi_NoCuts_other",180,-180.1,180.1);
e047b348 1710 TH1F *hd0singlTrackNCother=new TH1F("hd0singlTrackNCother","hd0singlTrackNoCuts_Other",1000,-5000.,5000.);
1711 TH1F *hCPtaNCother=new TH1F("hCPtaNCother","hCPta_NoCuts_other",100,-1.,1.);
ac4c229c 1712 TH1F *hd0xd0NCother=new TH1F("hd0xd0NCother","hd0xd0_NoCuts_other",1000,-100000.,100000.);
1713 TH1F *hMassTrueNCother=new TH1F("hMassTrueNCother","D^{0} MC inv. Mass No Cuts other(All momenta)",600,1.600,2.200);
1714 TH1F *hMassNCother=new TH1F("hMassNCother","D^{0} inv. Mass No Cuts other (All momenta)",600,1.600,2.200);
1715 hMassNCother->Sumw2();
1716 TH1F *hMassTrueNCotherPM=new TH1F("hMassTrueNCotherPM","D^{0} MC inv. Mass No Cuts Other, Mass Peak. (All momenta)",600,1.600,2.200);
1717 TH1F *hMassNCotherPM=new TH1F("hMassNCotherPM","D^{0} inv. Mass No Cuts Other (All momenta), MassPeak",600,1.600,2.200);
1718 hMassNCotherPM->Sumw2();
1719 TH1F *hMassTrueNCotherSB=new TH1F("hMassTrueNCotherSB","D^{0} MC inv. Mass in Side Bands No Cuts other(All momenta)",600,1.600,2.200);
1720 TH1F *hMassNCotherSB=new TH1F("hMassNCotherSB","D^{0} inv. Mass in Side Bands No Cuts other (All momenta)",600,1.600,2.200);
1721 hMassNCotherSB->Sumw2();
1722
1723 flistNoCutsOther->Add(hCPtaVSd0d0NCother);
1724 flistNoCutsOther->Add(hSecVtxZNCother);
1725 flistNoCutsOther->Add(hSecVtxYNCother);
1726 flistNoCutsOther->Add(hSecVtxXNCother);
1727 flistNoCutsOther->Add(hSecVtxXYNCother);
1728 flistNoCutsOther->Add(hSecVtxPhiNCother);
e047b348 1729 flistNoCutsOther->Add(hd0singlTrackNCother);
ac4c229c 1730 flistNoCutsOther->Add(hCPtaNCother);
1731 flistNoCutsOther->Add(hd0xd0NCother);
1732 flistNoCutsOther->Add(hMassTrueNCother);
1733 flistNoCutsOther->Add(hMassNCother);
1734 flistNoCutsOther->Add(hMassTrueNCotherPM);
1735 flistNoCutsOther->Add(hMassNCotherPM);
1736 flistNoCutsOther->Add(hMassTrueNCotherSB);
1737 flistNoCutsOther->Add(hMassNCotherSB);
624c07ab 1738
e047b348 1739
1740
1741 //%%% NEW HISTOS %%%%%%%%%%%%%%%%
1742 TH1F *hdcaNCother=new TH1F("hdcaNCother","hdca_NoCuts_Other",100,0.,1000.);
1743 hdcaNCother->SetXTitle("dca [#mum]");
1744 hdcaNCother->SetYTitle("Entries");
1745 TH1F *hcosthetastarNCother=new TH1F("hcosthetastarNCother","hCosThetaStar_NoCuts_Other",50,-1.,1.);
1746 hcosthetastarNCother->SetXTitle("cos #theta^{*}");
1747 hcosthetastarNCother->SetYTitle("Entries");
1748 TH1F *hptD0NCother=new TH1F("hptD0NCother","D^{0} transverse momentum distribution",34,ptbinsD0arr);
1749 hptD0NCother->SetXTitle("p_{t} [GeV/c]");
1750 hptD0NCother->SetYTitle("Entries");
1751 TH1F *hptD0VsMaxPtNCother=new TH1F("hptD0VsMaxPtNCother","Difference between D^{0} pt and highest (or second) pt",400,-50.,50.);
1752 TH2F *hptD0PTallsqrtNCother=new TH2F("hptD0PTallsqrtNCother","D^{0} pt Vs Sqrt(Sum pt square)",34,ptbinsD0arr,200,dumbinning);
1753 TH2F *hptD0PTallNCother=new TH2F("hptD0PTallNCother","D^{0} pt Vs Sum pt ",34,ptbinsD0arr,200,dumbinning);
1754 TH2F *hptD0vsptBNCother=new TH2F("hptD0vsptBNCother","D^{0} pt Vs B pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
1755 TH2F *hpD0vspBNCother=new TH2F("hpD0vspBNCother","D^{0} tot momentum Vs B tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
1756 TH2F *hptD0vsptcquarkNCother=new TH2F("hptD0vsptcquarkNCother","D^{0} pt Vs cquark pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
1757 TH2F *hpD0vspcquarkNCother=new TH2F("hpD0vspcquarkNCother","D^{0} tot momentum Vs cquark tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
1758 flistNoCutsOther->Add(hdcaNCother);
1759 flistNoCutsOther->Add(hcosthetastarNCother);
1760 flistNoCutsOther->Add(hptD0NCother);
1761 flistNoCutsOther->Add(hptD0VsMaxPtNCother);
1762 flistNoCutsOther->Add(hptD0PTallsqrtNCother);
1763 flistNoCutsOther->Add(hptD0PTallNCother);
1764 flistNoCutsOther->Add(hptD0vsptBNCother);
1765 flistNoCutsOther->Add(hpD0vspBNCother);
1766 flistNoCutsOther->Add(hptD0vsptcquarkNCother);
1767 flistNoCutsOther->Add(hpD0vspcquarkNCother);
1768
1769 TH1F *hd0zD0ptNCother;
1770 TH1F *hInvMassNCother;
1771 TH2F *hInvMassPtNCother=new TH2F("hInvMassPtNCother","Candidate p_{t} Vs invariant mass",330,1.700,2.030,200,0.,20.);
1772 TH1F *hetaNCother;
1773 TH1F *hCosPDPBNCother;
1774 TH1F *hCosPcPDNCother;
1775 flistNoCutsOther->Add(hInvMassPtNCother);
1776 // %%%%%%%%%%% HERE THE ADDITIONAL HISTS %%%%%%%%%%%%%%%%%
1777 TH2F *hd0D0VSd0xd0NCotherpt;
1778 TH2F *hangletracksVSd0xd0NCotherpt;
1779 TH2F *hangletracksVSd0D0NCotherpt;
1780 TH1F *hd0xd0NCotherpt;
1781
1782 TH2F *hTOFpidNCother=new TH2F("hTOFpidNCother","TOF time VS momentum",10,0.,4.,50,-50000.,50000.);
1783 flistNoCutsOther->Add(hTOFpidNCother);
1784
1785 for(Int_t i=0;i<fnbins;i++){
1786 namehist="hd0zD0ptNCother_pt";
1787 namehist+=i;
1788 titlehist="d0(z) No Cuts Otherm ptbin=";
1789 titlehist+=i;
1790 hd0zD0ptNCother=new TH1F(namehist.Data(),titlehist.Data(),1000,-3000,3000.);
1791 hd0zD0ptNCother->SetXTitle("d_{0}(z) [#mum]");
1792 hd0zD0ptNCother->SetYTitle("Entries");
1793 flistNoCutsOther->Add(hd0zD0ptNCother);
1794
1795 namehist="hInvMassNCother_pt";
1796 namehist+=i;
1797 titlehist="Invariant Mass No Cuts Other ptbin=";
1798 titlehist+=i;
1799 hInvMassNCother=new TH1F(namehist.Data(),titlehist.Data(),600,1.600,2.200);
1800 hInvMassNCother->SetXTitle("Invariant Mass [GeV]");
1801 hInvMassNCother->SetYTitle("Entries");
1802 flistNoCutsOther->Add(hInvMassNCother);
1803
1804 namehist="hetaNCother_pt";
1805 namehist+=i;
1806 titlehist="eta No Cuts Other ptbin=";
1807 titlehist+=i;
1808 hetaNCother=new TH1F(namehist.Data(),titlehist.Data(),100,-3.,3.);
1809 hetaNCother->SetXTitle("Pseudorapidity");
1810 hetaNCother->SetYTitle("Entries");
1811 flistNoCutsOther->Add(hetaNCother);
1812
1813 namehist="hCosPDPBNCother_pt";
1814 namehist+=i;
1815 titlehist="Cosine between D0 momentum and B momentum, ptbin=";
1816 titlehist+=i;
1817 hCosPDPBNCother=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
1818 hCosPDPBNCother->SetXTitle("Cosine between D0 momentum and B momentum");
1819 hCosPDPBNCother->SetYTitle("Entries");
1820 flistNoCutsOther->Add(hCosPDPBNCother);
1821
1822 namehist="hCosPcPDNCother_pt";
1823 namehist+=i;
1824 titlehist="Cosine between cquark momentum and D0 momentum, ptbin=";
1825 titlehist+=i;
1826 hCosPcPDNCother=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
1827 hCosPcPDNCother->SetXTitle("Cosine between c quark momentum and D0 momentum");
1828 hCosPcPDNCother->SetYTitle("Entries");
1829 flistNoCutsOther->Add(hCosPcPDNCother);
1830
1831
1832 // %%%%%%%%%%% HERE THE ADDITIONAL HISTS %%%%%%%%%%%%%%%%%
1833 namehist="hd0xd0NCother_pt";
1834 namehist+=i;
1835 titlehist="d0xd0 No Cuts Other ptbin=";
1836 titlehist+=i;
1837 hd0xd0NCotherpt=new TH1F(namehist.Data(),titlehist.Data(),1000,-50000.,10000.);
1838 hd0xd0NCotherpt->SetXTitle("d_{0}^{K}xd_{0}^{#pi} [#mum^2]");
1839 hd0xd0NCotherpt->SetYTitle("Entries");
1840 flistNoCutsOther->Add(hd0xd0NCotherpt);
1841
1842
1843 namehist="hd0D0VSd0xd0NCother_pt";
1844 namehist+=i;
1845 titlehist="d_{0}^{D^{0}} Vs d_{0}^{K}xd_{0}^{#pi} No Cuts Other ptbin=";
1846 titlehist+=i;
1847 hd0D0VSd0xd0NCotherpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,100,-300,300);
1848 hd0D0VSd0xd0NCotherpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
1849 hd0D0VSd0xd0NCotherpt->SetYTitle(" d_{0}^{D^{0}} [#mum]");
1850 flistNoCutsOther->Add(hd0D0VSd0xd0NCotherpt);
1851
1852
1853 namehist="hangletracksVSd0xd0NCother_pt";
1854 namehist+=i;
1855 titlehist="Angle between K and #pi tracks Vs d_{0}^{K}xd_{0}^{#pi} No Cuts Other ptbin=";
1856 titlehist+=i;
1857 hangletracksVSd0xd0NCotherpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,40,-0.1,3.24);
1858 hangletracksVSd0xd0NCotherpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
1859 hangletracksVSd0xd0NCotherpt->SetYTitle(" angle between K and #p tracks [rad]");
1860 flistNoCutsOther->Add(hangletracksVSd0xd0NCotherpt);
1861
1862
1863 namehist="hangletracksVSd0D0NCother_pt";
1864 namehist+=i;
1865 titlehist="Angle between K and #pi tracks Vs d_{0}^{D^{0}} No Cuts Other ptbin=";
1866 titlehist+=i;
1867 hangletracksVSd0D0NCotherpt=new TH2F(namehist.Data(),titlehist.Data(),200,-400.,400.,40,-0.12,3.24);
1868 hangletracksVSd0D0NCotherpt->SetXTitle(" d_{0}^{D^{0}} [#mum]");
1869 hangletracksVSd0D0NCotherpt->SetYTitle(" angle between K and #p tracks [rad]");
1870 flistNoCutsOther->Add(hangletracksVSd0D0NCotherpt);
1871
1872 }
1873 // %%%%%%%% END OF NEW HISTOS %%%%%%%%%%%%%
1874 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
1875
1876
1877
1878
624c07ab 1879 //############# d0 D0 histos ###############à
ac4c229c 1880 TH1F *hd0D0NCotherPM = new TH1F("hd0D0NCotherPM","D^{0} impact par. plot , No Cuts ,Other,Mass Peak (All momenta)",1000,-1000.,1000.);
1881 hd0D0NCotherPM->SetXTitle("Impact parameter [#mum]");
1882 hd0D0NCotherPM->SetYTitle("Entries");
1883
1884 TH1F *hd0D0VtxTrueNCotherPM = new TH1F("hd0D0VtxTrueNCotherPM","D^{0} impact par. w.r.t. True Vtx, No Cuts, Other,Mass Peak (All momenta)",1000,-1000.,1000.);
1885 hd0D0VtxTrueNCotherPM->SetXTitle("Impact parameter [#mum]");
1886 hd0D0VtxTrueNCotherPM->SetYTitle("Entries");
1887
1888 TH1F *hMCd0D0NCotherPM = new TH1F("hMCd0D0NCotherPM","D^{0} impact par. plot, No Cuts, Other,Mass Peak (All momenta)",1000,-1000.,1000.);
1889 hMCd0D0NCotherPM->SetXTitle("MC Impact parameter [#mum]");
1890 hMCd0D0NCotherPM->SetYTitle("Entries");
1891
1892 TH1F *hd0D0NCotherSB = new TH1F("hd0D0NCotherSB","D^{0} impact par. plot , No Cuts ,Other,Mass Peak (All momenta)",1000,-1000.,1000.);
1893 hd0D0NCotherSB->SetXTitle("Impact parameter [#mum]");
1894 hd0D0NCotherSB->SetYTitle("Entries");
1895
1896 TH1F *hd0D0VtxTrueNCotherSB = new TH1F("hd0D0VtxTrueNCotherSB","D^{0} impact par. w.r.t. True Vtx, No Cuts, Other,Mass Peak (All momenta)",1000,-1000.,1000.);
1897 hd0D0VtxTrueNCotherSB->SetXTitle("Impact parameter [#mum]");
1898 hd0D0VtxTrueNCotherSB->SetYTitle("Entries");
1899
1900 TH1F *hMCd0D0NCotherSB = new TH1F("hMCd0D0NCotherSB","D^{0} impact par. plot, No Cuts, Other,Mass Peak (All momenta)",1000,-1000.,1000.);
1901 hMCd0D0NCotherSB->SetXTitle("MC Impact parameter [#mum]");
1902 hMCd0D0NCotherSB->SetYTitle("Entries");
1903
1904 flistNoCutsOther->Add(hd0D0NCotherPM);
1905 flistNoCutsOther->Add(hd0D0VtxTrueNCotherPM);
1906 flistNoCutsOther->Add(hMCd0D0NCotherPM);
1907 flistNoCutsOther->Add(hd0D0NCotherSB);
1908 flistNoCutsOther->Add(hd0D0VtxTrueNCotherSB);
1909 flistNoCutsOther->Add(hMCd0D0NCotherSB);
1910
e047b348 1911 TH1F *hd0D0ptNCotherPM;
1912 TH1F *hMCd0D0ptNCotherPM;
1913 TH1F *hd0D0VtxTrueptNCotherPM;
1914 TH1F *hd0D0ptNCotherSB;
1915 TH1F *hMCd0D0ptNCotherSB;
1916 TH1F *hd0D0VtxTrueptNCotherSB;
ac4c229c 1917 namehist="hd0D0ptNCother_";
624c07ab 1918 titlehist="D^{0} impact par. plot, No Cuts, Other, ";
1919 for(Int_t i=0;i<fnbins;i++){
1920 strnamept=namehist;
1921 strnamept.Append("PkMss_pt");
1922 strnamept+=i;
1923
1924 strtitlept=titlehist;
1925 strtitlept.Append(" Mass Peak, ");
1926 strtitlept+=fptbins[i];
1927 strtitlept.Append("<= pt <");
1928 strtitlept+=fptbins[i+1];
1929 strtitlept.Append(" [GeV/c]");
1930
e047b348 1931 hd0D0ptNCotherPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1932 hd0D0ptNCotherPM->SetXTitle("Impact parameter [#mum] ");
1933 hd0D0ptNCotherPM->SetYTitle("Entries");
1934 flistNoCutsOther->Add(hd0D0ptNCotherPM);
624c07ab 1935
1936 strnamept.ReplaceAll("hd0D0","hMCd0D0");
e047b348 1937 hMCd0D0ptNCotherPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1938 hMCd0D0ptNCotherPM->SetXTitle("MC Impact parameter [#mum] ");
1939 hMCd0D0ptNCotherPM->SetYTitle("Entries");
1940 flistNoCutsOther->Add(hMCd0D0ptNCotherPM);
624c07ab 1941
1942
1943 strnamept.ReplaceAll("hMCd0D0","hd0D0VtxTrue");
e047b348 1944 hd0D0VtxTrueptNCotherPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1945 hd0D0VtxTrueptNCotherPM->SetXTitle("Impact parameter w.r.t. True Vtx [#mum] ");
1946 hd0D0VtxTrueptNCotherPM->SetYTitle("Entries");
1947 flistNoCutsOther->Add(hd0D0VtxTrueptNCotherPM);
624c07ab 1948
1949 strnamept=namehist;
1950 strnamept.Append("SBMss_pt");
1951 strnamept+=i;
1952
1953 strtitlept=titlehist;
1954 strtitlept.Append(" Side Bands, ");
1955 strtitlept+=fptbins[i];
1956 strtitlept.Append("<= pt <");
1957 strtitlept+=fptbins[i+1];
1958 strtitlept.Append(" [GeV/c]");
1959
e047b348 1960 hd0D0ptNCotherSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1961 hd0D0ptNCotherSB->SetXTitle("Impact parameter [#mum] ");
1962 hd0D0ptNCotherSB->SetYTitle("Entries");
1963 flistNoCutsOther->Add(hd0D0ptNCotherSB);
624c07ab 1964
1965 strnamept.ReplaceAll("hd0D0","hMCd0D0");
e047b348 1966 hMCd0D0ptNCotherSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1967 hMCd0D0ptNCotherSB->SetXTitle("MC Impact parameter [#mum] ");
1968 hMCd0D0ptNCotherSB->SetYTitle("Entries");
1969 flistNoCutsOther->Add(hMCd0D0ptNCotherSB);
624c07ab 1970
1971 strnamept.ReplaceAll("hMCd0D0","hd0D0VtxTrue");
e047b348 1972 hd0D0VtxTrueptNCotherSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
1973 hd0D0VtxTrueptNCotherSB->SetXTitle("Impact parameter w.r.t. True Vtx [#mum] ");
1974 hd0D0VtxTrueptNCotherSB->SetYTitle("Entries");
1975 flistNoCutsOther->Add(hd0D0VtxTrueptNCotherSB);
624c07ab 1976 }
1977
1978
1979 //################################################################################################
1980 // #
1981 // HISTOS FOR LOOSE CUTS #
1982 // #
1983 //################################################################################################
1984
1985 //############ LOOSE CUTS SIGNAL HISTOGRAMS ###############
1986 //
1987 // ####### global properties histo ############
1988
e047b348 1989 TH2F *hCPtaVSd0d0LSCsign=new TH2F("hCPtaVSd0d0LSCsign","hCPtaVSd0d0_LooseCuts_Signal",1000,-100000.,100000.,100,-1.,1.);
ac4c229c 1990 TH1F *hSecVtxZLSCsign=new TH1F("hSecVtxZLSCsign","hSecVtxZ_LooseCuts_Signal",1000,-8.,8.);
1991 TH1F *hSecVtxXLSCsign=new TH1F("hSecVtxXLSCsign","hSecVtxX_LooseCuts_Signal",1000,-3000.,3000.);
1992 TH1F *hSecVtxYLSCsign=new TH1F("hSecVtxYLSCsign","hSecVtxY_LooseCuts_Signal",1000,-3000.,3000.);
1993 TH2F *hSecVtxXYLSCsign=new TH2F("hSecVtxXYLSCsign","hSecVtxXY_LooseCuts_Signal",1000,-3000.,3000.,1000,-3000.,3000.);
1994 TH1F *hSecVtxPhiLSCsign=new TH1F("hSecVtxPhiLSCsign","hSecVtxPhi_LooseCuts_Signal",180,-180.1,180.1);
e047b348 1995 TH1F *hd0singlTrackLSCsign=new TH1F("hd0singlTrackLSCsign","hd0singlTrackLooseCuts_Signal",1000,-5000.,5000.);
1996 TH1F *hCPtaLSCsign=new TH1F("hCPtaLSCsign","hCPta_LooseCuts_Signal",100,-1.,1.);
ac4c229c 1997 TH1F *hd0xd0LSCsign=new TH1F("hd0xd0LSCsign","hd0xd0_LooseCuts_Signal",1000,-100000.,100000.);
1998 TH1F *hMassTrueLSCsign=new TH1F("hMassTrueLSCsign","D^{0} MC inv. Mass Loose Cuts Signal(All momenta)",600,1.600,2.200);
1999 TH1F *hMassLSCsign=new TH1F("hMassLSCsign","D^{0} inv. Mass Loose Cuts Signal (All momenta)",600,1.600,2.200);
2000 hMassLSCsign->Sumw2();
2001 TH1F *hMassTrueLSCsignPM=new TH1F("hMassTrueLSCsignPM","D^{0} MC inv. Mass Loose Cuts Signal, Mass Peak. (All momenta)",600,1.600,2.200);
2002 TH1F *hMassLSCsignPM=new TH1F("hMassLSCsignPM","D^{0} inv. Mass Loose Cuts Signal (All momenta), MassPeak",600,1.600,2.200);
2003 hMassLSCsignPM->Sumw2();
2004 TH1F *hMassTrueLSCsignSB=new TH1F("hMassTrueLSCsignSB","D^{0} MC inv. Mass in Side Bands Loose Cuts Signal(All momenta)",600,1.600,2.200);
2005 TH1F *hMassLSCsignSB=new TH1F("hMassLSCsignSB","D^{0} inv. Mass in Side Bands Loose Cuts Signal (All momenta)",600,1.600,2.200);
2006 hMassLSCsignSB->Sumw2();
2007
2008 flistLsCutsSignal->Add(hCPtaVSd0d0LSCsign);
2009 flistLsCutsSignal->Add(hSecVtxZLSCsign);
2010 flistLsCutsSignal->Add(hSecVtxYLSCsign);
2011 flistLsCutsSignal->Add(hSecVtxXLSCsign);
2012 flistLsCutsSignal->Add(hSecVtxXYLSCsign);
2013 flistLsCutsSignal->Add(hSecVtxPhiLSCsign);
e047b348 2014 flistLsCutsSignal->Add(hd0singlTrackLSCsign);
ac4c229c 2015 flistLsCutsSignal->Add(hCPtaLSCsign);
2016 flistLsCutsSignal->Add(hd0xd0LSCsign);
2017 flistLsCutsSignal->Add(hMassTrueLSCsign);
2018 flistLsCutsSignal->Add(hMassLSCsign);
2019 flistLsCutsSignal->Add(hMassTrueLSCsignPM);
2020 flistLsCutsSignal->Add(hMassLSCsignPM);
2021 flistLsCutsSignal->Add(hMassTrueLSCsignSB);
2022 flistLsCutsSignal->Add(hMassLSCsignSB);
624c07ab 2023
e047b348 2024
2025 //%%% NEW HISTOS %%%%%%%%%%%%%%%%
2026 TH1F *hdcaLSCsign=new TH1F("hdcaLSCsign","hdca_LooseCuts_Sign",100,0.,1000.);
2027 hdcaLSCsign->SetXTitle("dca [#mum]");
2028 hdcaLSCsign->SetYTitle("Entries");
2029 TH1F *hcosthetastarLSCsign=new TH1F("hcosthetastarLSCsign","hCosThetaStar_LooseCuts_Sign",50,-1.,1.);
2030 hcosthetastarLSCsign->SetXTitle("cos #theta^{*}");
2031 hcosthetastarLSCsign->SetYTitle("Entries");
2032 TH1F *hptD0LSCsign=new TH1F("hptD0LSCsign","D^{0} transverse momentum distribution",34,ptbinsD0arr);
2033 hptD0LSCsign->SetXTitle("p_{t} [GeV/c]");
2034 hptD0LSCsign->SetYTitle("Entries");
2035 TH1F *hptD0VsMaxPtLSCsign=new TH1F("hptD0VsMaxPtLSCsign","Difference between D^{0} pt and highest (or second) pt",400,-50.,50.);
2036 TH2F *hptD0PTallsqrtLSCsign=new TH2F("hptD0PTallsqrtLSCsign","D^{0} pt Vs Sqrt(Sum pt square)",34,ptbinsD0arr,200,dumbinning);
2037 TH2F *hptD0PTallLSCsign=new TH2F("hptD0PTallLSCsign","D^{0} pt Vs Sum pt ",34,ptbinsD0arr,200,dumbinning);
2038 TH2F *hptD0vsptBLSCsign=new TH2F("hptD0vsptBLSCsign","D^{0} pt Vs B pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
2039 TH2F *hpD0vspBLSCsign=new TH2F("hpD0vspBLSCsign","D^{0} tot momentum Vs B tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
2040 TH2F *hptD0vsptcquarkLSCsign=new TH2F("hptD0vsptcquarkLSCsign","D^{0} pt Vs cquark pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
2041 TH2F *hpD0vspcquarkLSCsign=new TH2F("hpD0vspcquarkLSCsign","D^{0} tot momentum Vs cquark tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
2042 flistLsCutsSignal->Add(hdcaLSCsign);
2043 flistLsCutsSignal->Add(hcosthetastarLSCsign);
2044 flistLsCutsSignal->Add(hptD0LSCsign);
2045 flistLsCutsSignal->Add(hptD0VsMaxPtLSCsign);
2046 flistLsCutsSignal->Add(hptD0PTallsqrtLSCsign);
2047 flistLsCutsSignal->Add(hptD0PTallLSCsign);
2048 flistLsCutsSignal->Add(hptD0vsptBLSCsign);
2049 flistLsCutsSignal->Add(hpD0vspBLSCsign);
2050 flistLsCutsSignal->Add(hptD0vsptcquarkLSCsign);
2051 flistLsCutsSignal->Add(hpD0vspcquarkLSCsign);
2052
2053 TH1F *hd0zD0ptLSCsign;
2054 TH1F *hInvMassLSCsign;
2055 TH2F *hInvMassPtLSCsign=new TH2F("hInvMassPtLSCsign","Candidate p_{t} Vs invariant mass",330,1.700,2.030,200,0.,20.);
2056 TH1F *hetaLSCsign;
2057 TH1F *hCosPDPBLSCsign;
2058 TH1F *hCosPcPDLSCsign;
2059 flistLsCutsSignal->Add(hInvMassPtLSCsign);
2060
2061 // %%%%%%%%%%% HERE THE ADDITIONAL HISTS %%%%%%%%%%%%%%%%%
2062 TH2F *hd0D0VSd0xd0LSCsignpt;
2063 TH2F *hangletracksVSd0xd0LSCsignpt;
2064 TH2F *hangletracksVSd0D0LSCsignpt;
2065 TH1F *hd0xd0LSCsignpt;
2066
2067 TH2F *hTOFpidLSCsign=new TH2F("hTOFpidLSCsign","TOF time VS momentum",10,0.,4.,50,-50000.,50000.);
2068 flistLsCutsSignal->Add(hTOFpidLSCsign);
2069
2070 for(Int_t i=0;i<fnbins;i++){
2071 namehist="hd0zD0ptLSCsign_pt";
2072 namehist+=i;
2073 titlehist="d0(z) Loose Cuts Signm ptbin=";
2074 titlehist+=i;
2075 hd0zD0ptLSCsign=new TH1F(namehist.Data(),titlehist.Data(),1000,-3000,3000.);
2076 hd0zD0ptLSCsign->SetXTitle("d_{0}(z) [#mum]");
2077 hd0zD0ptLSCsign->SetYTitle("Entries");
2078 flistLsCutsSignal->Add(hd0zD0ptLSCsign);
2079
2080 namehist="hInvMassLSCsign_pt";
2081 namehist+=i;
2082 titlehist="Invariant Mass Loose Cuts Sign ptbin=";
2083 titlehist+=i;
2084 hInvMassLSCsign=new TH1F(namehist.Data(),titlehist.Data(),600,1.600,2.200);
2085 hInvMassLSCsign->SetXTitle("Invariant Mass [GeV]");
2086 hInvMassLSCsign->SetYTitle("Entries");
2087 flistLsCutsSignal->Add(hInvMassLSCsign);
2088
2089 namehist="hetaLSCsign_pt";
2090 namehist+=i;
2091 titlehist="eta Loose Cuts Sign ptbin=";
2092 titlehist+=i;
2093 hetaLSCsign=new TH1F(namehist.Data(),titlehist.Data(),100,-3.,3.);
2094 hetaLSCsign->SetXTitle("Pseudorapidity");
2095 hetaLSCsign->SetYTitle("Entries");
2096 flistLsCutsSignal->Add(hetaLSCsign);
2097
2098 namehist="hCosPDPBLSCsign_pt";
2099 namehist+=i;
2100 titlehist="Cosine between D0 momentum and B momentum, ptbin=";
2101 titlehist+=i;
2102 hCosPDPBLSCsign=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
2103 hCosPDPBLSCsign->SetXTitle("Cosine between D0 momentum and B momentum");
2104 hCosPDPBLSCsign->SetYTitle("Entries");
2105 flistLsCutsSignal->Add(hCosPDPBLSCsign);
2106
2107 namehist="hCosPcPDLSCsign_pt";
2108 namehist+=i;
2109 titlehist="Cosine between cquark momentum and D0 momentum, ptbin=";
2110 titlehist+=i;
2111 hCosPcPDLSCsign=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
2112 hCosPcPDLSCsign->SetXTitle("Cosine between c quark momentum and D0 momentum");
2113 hCosPcPDLSCsign->SetYTitle("Entries");
2114 flistLsCutsSignal->Add(hCosPcPDLSCsign);
2115
2116
2117 // %%%%%%%%%%% HERE THE ADDITIONAL HISTS %%%%%%%%%%%%%%%%%
2118 namehist="hd0xd0LSCsign_pt";
2119 namehist+=i;
2120 titlehist="d0xd0 Loose Cuts Sign ptbin=";
2121 titlehist+=i;
2122 hd0xd0LSCsignpt=new TH1F(namehist.Data(),titlehist.Data(),1000,-50000.,10000.);
2123 hd0xd0LSCsignpt->SetXTitle("d_{0}^{K}xd_{0}^{#pi} [#mum^2]");
2124 hd0xd0LSCsignpt->SetYTitle("Entries");
2125 flistLsCutsSignal->Add(hd0xd0LSCsignpt);
2126
2127
2128 namehist="hd0D0VSd0xd0LSCsign_pt";
2129 namehist+=i;
2130 titlehist="d_{0}^{D^{0}} Vs d_{0}^{K}xd_{0}^{#pi} Loose Cuts Sign ptbin=";
2131 titlehist+=i;
2132 hd0D0VSd0xd0LSCsignpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,100,-300,300);
2133 hd0D0VSd0xd0LSCsignpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
2134 hd0D0VSd0xd0LSCsignpt->SetYTitle(" d_{0}^{D^{0}} [#mum]");
2135 flistLsCutsSignal->Add(hd0D0VSd0xd0LSCsignpt);
2136
2137
2138 namehist="hangletracksVSd0xd0LSCsign_pt";
2139 namehist+=i;
2140 titlehist="Angle between K and #pi tracks Vs d_{0}^{K}xd_{0}^{#pi} Loose Cuts Sign ptbin=";
2141 titlehist+=i;
2142 hangletracksVSd0xd0LSCsignpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,40,-0.1,3.24);
2143 hangletracksVSd0xd0LSCsignpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
2144 hangletracksVSd0xd0LSCsignpt->SetYTitle(" angle between K and #p tracks [rad]");
2145 flistLsCutsSignal->Add(hangletracksVSd0xd0LSCsignpt);
2146
2147
2148 namehist="hangletracksVSd0D0LSCsign_pt";
2149 namehist+=i;
2150 titlehist="Angle between K and #pi tracks Vs d_{0}^{D^{0}} Loose Cuts Sign ptbin=";
2151 titlehist+=i;
2152 hangletracksVSd0D0LSCsignpt=new TH2F(namehist.Data(),titlehist.Data(),200,-400.,400.,40,-0.12,3.24);
2153 hangletracksVSd0D0LSCsignpt->SetXTitle(" d_{0}^{D^{0}} [#mum]");
2154 hangletracksVSd0D0LSCsignpt->SetYTitle(" angle between K and #p tracks [rad]");
2155 flistLsCutsSignal->Add(hangletracksVSd0D0LSCsignpt);
2156
2157
2158 }
2159 // %%%%%%%% END OF NEW HISTOS %%%%%%%%%%%%%
2160 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
2161
2162
624c07ab 2163 // ####### d0 D0 histos ############
ac4c229c 2164 TH1F *hd0D0LSCsignPM = new TH1F("hd0D0LSCsignPM","D^{0} impact par. plot , Loose Cuts ,Signal,Mass Peak (All momenta)",1000,-1000.,1000.);
2165 hd0D0LSCsignPM->SetXTitle("Impact parameter [#mum]");
2166 hd0D0LSCsignPM->SetYTitle("Entries");
2167
2168 TH1F *hd0D0VtxTrueLSCsignPM = new TH1F("hd0D0VtxTrueLSCsignPM","D^{0} impact par. w.r.t. True Vtx, Loose Cuts, Signal,Mass Peak (All momenta)",1000,-1000.,1000.);
2169 hd0D0VtxTrueLSCsignPM->SetXTitle("Impact parameter [#mum]");
2170 hd0D0VtxTrueLSCsignPM->SetYTitle("Entries");
2171
2172 TH1F *hMCd0D0LSCsignPM = new TH1F("hMCd0D0LSCsignPM","D^{0} impact par. plot, Loose Cuts, Signal,Mass Peak (All momenta)",1000,-1000.,1000.);
2173 hMCd0D0LSCsignPM->SetXTitle("MC Impact parameter [#mum]");
2174 hMCd0D0LSCsignPM->SetYTitle("Entries");
2175
2176 TH1F *hd0D0LSCsignSB = new TH1F("hd0D0LSCsignSB","D^{0} impact par. plot , Loose Cuts ,Signal,Mass Peak (All momenta)",1000,-1000.,1000.);
2177 hd0D0LSCsignSB->SetXTitle("Impact parameter [#mum]");
2178 hd0D0LSCsignSB->SetYTitle("Entries");
2179
2180 TH1F *hd0D0VtxTrueLSCsignSB = new TH1F("hd0D0VtxTrueLSCsignSB","D^{0} impact par. w.r.t. True Vtx, Loose Cuts, Signal,Mass Peak (All momenta)",1000,-1000.,1000.);
2181 hd0D0VtxTrueLSCsignSB->SetXTitle("Impact parameter [#mum]");
2182 hd0D0VtxTrueLSCsignSB->SetYTitle("Entries");
2183
2184 TH1F *hMCd0D0LSCsignSB = new TH1F("hMCd0D0LSCsignSB","D^{0} impact par. plot, Loose Cuts, Signal,Mass Peak (All momenta)",1000,-1000.,1000.);
2185 hMCd0D0LSCsignSB->SetXTitle("MC Impact parameter [#mum]");
2186 hMCd0D0LSCsignSB->SetYTitle("Entries");
2187
2188 flistLsCutsSignal->Add(hd0D0LSCsignPM);
2189 flistLsCutsSignal->Add(hd0D0VtxTrueLSCsignPM);
2190 flistLsCutsSignal->Add(hMCd0D0LSCsignPM);
2191 flistLsCutsSignal->Add(hd0D0LSCsignSB);
2192 flistLsCutsSignal->Add(hd0D0VtxTrueLSCsignSB);
2193 flistLsCutsSignal->Add(hMCd0D0LSCsignSB);
2194
e047b348 2195 TH1F *hd0D0ptLSCsignPM;
2196 TH1F *hMCd0D0ptLSCsignPM;
2197 TH1F *hd0D0VtxTrueptLSCsignPM;
2198 TH1F *hd0D0ptLSCsignSB;
2199 TH1F *hMCd0D0ptLSCsignSB;
2200 TH1F *hd0D0VtxTrueptLSCsignSB;
ac4c229c 2201 namehist="hd0D0ptLSCsign_";
624c07ab 2202 titlehist="D^{0} impact par. plot, Loose Cuts, Signal, ";
2203 for(Int_t i=0;i<fnbins;i++){
2204 strnamept=namehist;
2205 strnamept.Append("PkMss_pt");
2206 strnamept+=i;
2207
2208 strtitlept=titlehist;
2209 strtitlept.Append(" Mass Peak, ");
2210 strtitlept+=fptbins[i];
2211 strtitlept.Append("<= pt <");
2212 strtitlept+=fptbins[i+1];
2213 strtitlept.Append(" [GeV/c]");
2214
e047b348 2215 hd0D0ptLSCsignPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2216 hd0D0ptLSCsignPM->SetXTitle("Impact parameter [#mum] ");
2217 hd0D0ptLSCsignPM->SetYTitle("Entries");
2218 flistLsCutsSignal->Add(hd0D0ptLSCsignPM);
624c07ab 2219
2220 strnamept.ReplaceAll("hd0D0","hMCd0D0");
e047b348 2221 hMCd0D0ptLSCsignPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2222 hMCd0D0ptLSCsignPM->SetXTitle("MC Impact parameter [#mum] ");
2223 hMCd0D0ptLSCsignPM->SetYTitle("Entries");
2224 flistLsCutsSignal->Add(hMCd0D0ptLSCsignPM);
624c07ab 2225
2226
2227 strnamept.ReplaceAll("hMCd0D0","hd0D0VtxTrue");
e047b348 2228 hd0D0VtxTrueptLSCsignPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2229 hd0D0VtxTrueptLSCsignPM->SetXTitle("Impact parameter w.r.t. True Vtx [#mum] ");
2230 hd0D0VtxTrueptLSCsignPM->SetYTitle("Entries");
2231 flistLsCutsSignal->Add(hd0D0VtxTrueptLSCsignPM);
624c07ab 2232
2233 strnamept=namehist;
2234 strnamept.Append("SBMss_pt");
2235 strnamept+=i;
2236
2237 strtitlept=titlehist;
2238 strtitlept.Append(" Side Bands, ");
2239 strtitlept+=fptbins[i];
2240 strtitlept.Append("<= pt <");
2241 strtitlept+=fptbins[i+1];
2242 strtitlept.Append(" [GeV/c]");
2243
e047b348 2244 hd0D0ptLSCsignSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2245 hd0D0ptLSCsignSB->SetXTitle("Impact parameter [#mum] ");
2246 hd0D0ptLSCsignSB->SetYTitle("Entries");
2247 flistLsCutsSignal->Add(hd0D0ptLSCsignSB);
624c07ab 2248
2249 strnamept.ReplaceAll("hd0D0","hMCd0D0");
e047b348 2250 hMCd0D0ptLSCsignSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2251 hMCd0D0ptLSCsignSB->SetXTitle("MC Impact parameter [#mum] ");
2252 hMCd0D0ptLSCsignSB->SetYTitle("Entries");
2253 flistLsCutsSignal->Add(hMCd0D0ptLSCsignSB);
624c07ab 2254
2255 strnamept.ReplaceAll("hMCd0D0","hd0D0VtxTrue");
e047b348 2256 hd0D0VtxTrueptLSCsignSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2257 hd0D0VtxTrueptLSCsignSB->SetXTitle("Impact parameter w.r.t. True Vtx [#mum] ");
2258 hd0D0VtxTrueptLSCsignSB->SetYTitle("Entries");
2259 flistLsCutsSignal->Add(hd0D0VtxTrueptLSCsignSB);
624c07ab 2260 }
2261
2262
2263 //############ LOOSE CUTS BACKGROUND HISTOGRAMS ###########
2264 //
2265 // ######## global properties histos #######
e047b348 2266 TH2F *hCPtaVSd0d0LSCback=new TH2F("hCPtaVSd0d0LSCback","hCPtaVSd0d0_LooseCuts_Background",1000,-100000.,100000.,100,-1.,1.);
ac4c229c 2267 TH1F *hSecVtxZLSCback=new TH1F("hSecVtxZLSCback","hSecVtxZ_LooseCuts_Background",1000,-8.,8.);
2268 TH1F *hSecVtxXLSCback=new TH1F("hSecVtxXLSCback","hSecVtxX_LooseCuts_Background",1000,-3000.,3000.);
2269 TH1F *hSecVtxYLSCback=new TH1F("hSecVtxYLSCback","hSecVtxY_LooseCuts_Background",1000,-3000.,3000.);
2270 TH2F *hSecVtxXYLSCback=new TH2F("hSecVtxXYLSCback","hSecVtxXY_LooseCuts_Background",1000,-3000.,3000.,1000,-3000.,3000.);
2271 TH1F *hSecVtxPhiLSCback=new TH1F("hSecVtxPhiLSCback","hSecVtxPhi_LooseCuts_Background",180,-180.1,180.1);
e047b348 2272 TH1F *hd0singlTrackLSCback=new TH1F("hd0singlTrackLSCback","hd0singlTrackLooseCuts_Back",1000,-5000.,5000.);
2273 TH1F *hCPtaLSCback=new TH1F("hCPtaLSCback","hCPta_LooseCuts_Background",100,-1.,1.);
ac4c229c 2274 TH1F *hd0xd0LSCback=new TH1F("hd0xd0LSCback","hd0xd0_LooseCuts_Background",1000,-100000.,100000.);
2275 TH1F *hMassTrueLSCback=new TH1F("hMassTrueLSCback","D^{0} MC inv. Mass Loose Cuts Background(All momenta)",600,1.600,2.200);
2276 TH1F *hMassLSCback=new TH1F("hMassLSCback","D^{0} inv. Mass Loose Cuts Background (All momenta)",600,1.600,2.200);
2277 hMassLSCback->Sumw2();
2278 TH1F *hMassTrueLSCbackPM=new TH1F("hMassTrueLSCbackPM","D^{0} MC inv. Mass Loose Cuts Background, Mass Peak. (All momenta)",600,1.600,2.200);
2279 TH1F *hMassLSCbackPM=new TH1F("hMassLSCbackPM","D^{0} inv. Mass Loose Cuts Background (All momenta), MassPeak",600,1.600,2.200);
2280 hMassLSCbackPM->Sumw2();
2281 TH1F *hMassTrueLSCbackSB=new TH1F("hMassTrueLSCbackSB","D^{0} MC inv. Mass in Side Bands Loose Cuts Background(All momenta)",600,1.600,2.200);
2282 TH1F *hMassLSCbackSB=new TH1F("hMassLSCbackSB","D^{0} inv. Mass in Side Bands Loose Cuts Background (All momenta)",600,1.600,2.200);
2283 hMassLSCbackSB->Sumw2();
2284
2285 flistLsCutsBack->Add(hCPtaVSd0d0LSCback);
2286 flistLsCutsBack->Add(hSecVtxZLSCback);
2287 flistLsCutsBack->Add(hSecVtxYLSCback);
2288 flistLsCutsBack->Add(hSecVtxXLSCback);
2289 flistLsCutsBack->Add(hSecVtxXYLSCback);
2290 flistLsCutsBack->Add(hSecVtxPhiLSCback);
e047b348 2291 flistLsCutsBack->Add(hd0singlTrackLSCback);
ac4c229c 2292 flistLsCutsBack->Add(hCPtaLSCback);
2293 flistLsCutsBack->Add(hd0xd0LSCback);
2294 flistLsCutsBack->Add(hMassTrueLSCback);
2295 flistLsCutsBack->Add(hMassLSCback);
2296 flistLsCutsBack->Add(hMassTrueLSCbackPM);
2297 flistLsCutsBack->Add(hMassLSCbackPM);
2298 flistLsCutsBack->Add(hMassTrueLSCbackSB);
2299 flistLsCutsBack->Add(hMassLSCbackSB);
624c07ab 2300
2301
e047b348 2302
2303
2304
2305
2306
2307
2308 //%%% NEW HISTOS %%%%%%%%%%%%%%%%
2309 TH1F *hdcaLSCback=new TH1F("hdcaLSCback","hdca_LooseCuts_Backgr",100,0.,1000.);
2310 hdcaLSCback->SetXTitle("dca [#mum]");
2311 hdcaLSCback->SetYTitle("Entries");
2312 TH1F *hcosthetastarLSCback=new TH1F("hcosthetastarLSCback","hCosThetaStar_LooseCuts_Backgr",50,-1.,1.);
2313 hcosthetastarLSCback->SetXTitle("cos #theta^{*}");
2314 hcosthetastarLSCback->SetYTitle("Entries");
2315 TH1F *hptD0LSCback=new TH1F("hptD0LSCback","D^{0} transverse momentum distribution",34,ptbinsD0arr);
2316 hptD0LSCback->SetXTitle("p_{t} [GeV/c]");
2317 hptD0LSCback->SetYTitle("Entries");
2318 TH1F *hptD0VsMaxPtLSCback=new TH1F("hptD0VsMaxPtLSCback","Difference between D^{0} pt and highest (or second) pt",400,-50.,50.);
2319 TH2F *hptD0PTallsqrtLSCback=new TH2F("hptD0PTallsqrtLSCback","D^{0} pt Vs Sqrt(Sum pt square)",34,ptbinsD0arr,200,dumbinning);
2320 TH2F *hptD0PTallLSCback=new TH2F("hptD0PTallLSCback","D^{0} pt Vs Sum pt ",34,ptbinsD0arr,200,dumbinning);
2321 TH2F *hptD0vsptBLSCback=new TH2F("hptD0vsptBLSCback","D^{0} pt Vs B pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
2322 TH2F *hpD0vspBLSCback=new TH2F("hpD0vspBLSCback","D^{0} tot momentum Vs B tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
2323 TH2F *hptD0vsptcquarkLSCback=new TH2F("hptD0vsptcquarkLSCback","D^{0} pt Vs cquark pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
2324 TH2F *hpD0vspcquarkLSCback=new TH2F("hpD0vspcquarkLSCback","D^{0} tot momentum Vs cquark tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
2325 flistLsCutsBack->Add(hdcaLSCback);
2326 flistLsCutsBack->Add(hcosthetastarLSCback);
2327 flistLsCutsBack->Add(hptD0LSCback);
2328 flistLsCutsBack->Add(hptD0VsMaxPtLSCback);
2329 flistLsCutsBack->Add(hptD0PTallsqrtLSCback);
2330 flistLsCutsBack->Add(hptD0PTallLSCback);
2331 flistLsCutsBack->Add(hptD0vsptBLSCback);
2332 flistLsCutsBack->Add(hpD0vspBLSCback);
2333 flistLsCutsBack->Add(hptD0vsptcquarkLSCback);
2334 flistLsCutsBack->Add(hpD0vspcquarkLSCback);
2335
2336 TH1F *hd0zD0ptLSCback;
2337 TH1F *hInvMassLSCback;
2338 TH2F *hInvMassPtLSCback=new TH2F("hInvMassPtLSCback","Candidate p_{t} Vs invariant mass",330,1.700,2.030,200,0.,20.);
2339 TH1F *hetaLSCback;
2340 TH1F *hCosPDPBLSCback;
2341 TH1F *hCosPcPDLSCback;
2342 flistLsCutsBack->Add(hInvMassPtLSCback);
2343 // %%%%%%%%%%% HERE THE ADDITIONAL HISTS %%%%%%%%%%%%%%%%%
2344 TH2F *hd0D0VSd0xd0LSCbackpt;
2345 TH2F *hangletracksVSd0xd0LSCbackpt;
2346 TH2F *hangletracksVSd0D0LSCbackpt;
2347 TH1F *hd0xd0LSCbackpt;
2348
2349 TH2F *hTOFpidLSCback=new TH2F("hTOFpidLSCback","TOF time VS momentum",10,0.,4.,50,-50000.,50000.);
2350 flistLsCutsBack->Add(hTOFpidLSCback);
2351
2352 for(Int_t i=0;i<fnbins;i++){
2353 namehist="hd0zD0ptLSCback_pt";
2354 namehist+=i;
2355 titlehist="d0(z) Loose Cuts Backgr ptbin=";
2356 titlehist+=i;
2357 hd0zD0ptLSCback=new TH1F(namehist.Data(),titlehist.Data(),1000,-3000,3000.);
2358 hd0zD0ptLSCback->SetXTitle("d_{0}(z) [#mum]");
2359 hd0zD0ptLSCback->SetYTitle("Entries");
2360 flistLsCutsBack->Add(hd0zD0ptLSCback);
2361
2362 namehist="hInvMassLSCback_pt";
2363 namehist+=i;
2364 titlehist="Invariant Mass Loose Cuts Backgr ptbin=";
2365 titlehist+=i;
2366 hInvMassLSCback=new TH1F(namehist.Data(),titlehist.Data(),600,1.600,2.200);
2367 hInvMassLSCback->SetXTitle("Invariant Mass [GeV]");
2368 hInvMassLSCback->SetYTitle("Entries");
2369 flistLsCutsBack->Add(hInvMassLSCback);
2370
2371 namehist="hetaLSCback_pt";
2372 namehist+=i;
2373 titlehist="eta Loose Cuts Backgr ptbin=";
2374 titlehist+=i;
2375 hetaLSCback=new TH1F(namehist.Data(),titlehist.Data(),100,-3.,3.);
2376 hetaLSCback->SetXTitle("Pseudorapidity");
2377 hetaLSCback->SetYTitle("Entries");
2378 flistLsCutsBack->Add(hetaLSCback);
2379
2380 namehist="hCosPDPBLSCback_pt";
2381 namehist+=i;
2382 titlehist="Cosine between D0 momentum and B momentum, ptbin=";
2383 titlehist+=i;
2384 hCosPDPBLSCback=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
2385 hCosPDPBLSCback->SetXTitle("Cosine between D0 momentum and B momentum");
2386 hCosPDPBLSCback->SetYTitle("Entries");
2387 flistLsCutsBack->Add(hCosPDPBLSCback);
2388
2389 namehist="hCosPcPDLSCback_pt";
2390 namehist+=i;
2391 titlehist="Cosine between cquark momentum and D0 momentum, ptbin=";
2392 titlehist+=i;
2393 hCosPcPDLSCback=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
2394 hCosPcPDLSCback->SetXTitle("Cosine between c quark momentum and D0 momentum");
2395 hCosPcPDLSCback->SetYTitle("Entries");
2396 flistLsCutsBack->Add(hCosPcPDLSCback);
2397
2398 // %%%%%%%%%%% HERE THE ADDITIONAL HISTS %%%%%%%%%%%%%%%%%
2399 namehist="hd0xd0LSCback_pt";
2400 namehist+=i;
2401 titlehist="d0xd0 Loose Cuts Back ptbin=";
2402 titlehist+=i;
2403 hd0xd0LSCbackpt=new TH1F(namehist.Data(),titlehist.Data(),1000,-50000.,10000.);
2404 hd0xd0LSCbackpt->SetXTitle("d_{0}^{K}xd_{0}^{#pi} [#mum^2]");
2405 hd0xd0LSCbackpt->SetYTitle("Entries");
2406 flistLsCutsBack->Add(hd0xd0LSCbackpt);
2407
2408
2409 namehist="hd0D0VSd0xd0LSCback_pt";
2410 namehist+=i;
2411 titlehist="d_{0}^{D^{0}} Vs d_{0}^{K}xd_{0}^{#pi} Loose Cuts Back ptbin=";
2412 titlehist+=i;
2413 hd0D0VSd0xd0LSCbackpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,100,-300,300);
2414 hd0D0VSd0xd0LSCbackpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
2415 hd0D0VSd0xd0LSCbackpt->SetYTitle(" d_{0}^{D^{0}} [#mum]");
2416 flistLsCutsBack->Add(hd0D0VSd0xd0LSCbackpt);
2417
2418
2419 namehist="hangletracksVSd0xd0LSCback_pt";
2420 namehist+=i;
2421 titlehist="Angle between K and #pi tracks Vs d_{0}^{K}xd_{0}^{#pi} Loose Cuts Back ptbin=";
2422 titlehist+=i;
2423 hangletracksVSd0xd0LSCbackpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,40,-0.1,3.24);
2424 hangletracksVSd0xd0LSCbackpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
2425 hangletracksVSd0xd0LSCbackpt->SetYTitle(" angle between K and #p tracks [rad]");
2426 flistLsCutsBack->Add(hangletracksVSd0xd0LSCbackpt);
2427
2428
2429 namehist="hangletracksVSd0D0LSCback_pt";
2430 namehist+=i;
2431 titlehist="Angle between K and #pi tracks Vs d_{0}^{D^{0}} Loose Cuts Back ptbin=";
2432 titlehist+=i;
2433 hangletracksVSd0D0LSCbackpt=new TH2F(namehist.Data(),titlehist.Data(),200,-400.,400.,40,-0.12,3.24);
2434 hangletracksVSd0D0LSCbackpt->SetXTitle(" d_{0}^{D^{0}} [#mum]");
2435 hangletracksVSd0D0LSCbackpt->SetYTitle(" angle between K and #p tracks [rad]");
2436 flistLsCutsBack->Add(hangletracksVSd0D0LSCbackpt);
2437
2438 }
2439 // %%%%%%%% END OF NEW HISTOS %%%%%%%%%%%%%
2440 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
2441
2442
2443
2444
2445
2446
2447
624c07ab 2448 // ####### d0 D0 histos ############
2449
ac4c229c 2450 TH1F *hd0D0LSCbackPM = new TH1F("hd0D0LSCbackPM","D^{0} impact par. plot , Loose Cuts ,Background,Mass Peak (All momenta)",1000,-1000.,1000.);
2451 hd0D0LSCbackPM->SetXTitle("Impact parameter [#mum]");
2452 hd0D0LSCbackPM->SetYTitle("Entries");
2453
2454 TH1F *hd0D0VtxTrueLSCbackPM = new TH1F("hd0D0VtxTrueLSCbackPM","D^{0} impact par. w.r.t. True Vtx, Loose Cuts, Background,Mass Peak (All momenta)",1000,-1000.,1000.);
2455 hd0D0VtxTrueLSCbackPM->SetXTitle("Impact parameter [#mum]");
2456 hd0D0VtxTrueLSCbackPM->SetYTitle("Entries");
2457
2458 TH1F *hMCd0D0LSCbackPM = new TH1F("hMCd0D0LSCbackPM","D^{0} impact par. plot, Loose Cuts, Background,Mass Peak (All momenta)",1000,-1000.,1000.);
2459 hMCd0D0LSCbackPM->SetXTitle("MC Impact parameter [#mum]");
2460 hMCd0D0LSCbackPM->SetYTitle("Entries");
2461
2462 TH1F *hd0D0LSCbackSB = new TH1F("hd0D0LSCbackSB","D^{0} impact par. plot , Loose Cuts ,Background,Mass Peak (All momenta)",1000,-1000.,1000.);
2463 hd0D0LSCbackSB->SetXTitle("Impact parameter [#mum]");
2464 hd0D0LSCbackSB->SetYTitle("Entries");
2465
2466 TH1F *hd0D0VtxTrueLSCbackSB = new TH1F("hd0D0VtxTrueLSCbackSB","D^{0} impact par. w.r.t. True Vtx, Loose Cuts, Background,Mass Peak (All momenta)",1000,-1000.,1000.);
2467 hd0D0VtxTrueLSCbackSB->SetXTitle("Impact parameter [#mum]");
2468 hd0D0VtxTrueLSCbackSB->SetYTitle("Entries");
2469
2470 TH1F *hMCd0D0LSCbackSB = new TH1F("hMCd0D0LSCbackSB","D^{0} impact par. plot, Loose Cuts, Background,Mass Peak (All momenta)",1000,-1000.,1000.);
2471 hMCd0D0LSCbackSB->SetXTitle("MC Impact parameter [#mum]");
2472 hMCd0D0LSCbackSB->SetYTitle("Entries");
2473
2474 flistLsCutsBack->Add(hd0D0LSCbackPM);
2475 flistLsCutsBack->Add(hd0D0VtxTrueLSCbackPM);
2476 flistLsCutsBack->Add(hMCd0D0LSCbackPM);
2477 flistLsCutsBack->Add(hd0D0LSCbackSB);
2478 flistLsCutsBack->Add(hd0D0VtxTrueLSCbackSB);
2479 flistLsCutsBack->Add(hMCd0D0LSCbackSB);
2480
e047b348 2481 TH1F *hd0D0ptLSCbackPM;
2482 TH1F *hMCd0D0ptLSCbackPM;
2483 TH1F *hd0D0VtxTrueptLSCbackPM;
2484 TH1F *hd0D0ptLSCbackSB;
2485 TH1F *hMCd0D0ptLSCbackSB;
2486 TH1F *hd0D0VtxTrueptLSCbackSB;
ac4c229c 2487 namehist="hd0D0ptLSCback_";
624c07ab 2488 titlehist="D^{0} impact par. plot, Loose Cuts, Background, ";
2489 for(Int_t i=0;i<fnbins;i++){
2490 strnamept=namehist;
2491 strnamept.Append("PkMss_pt");
2492 strnamept+=i;
2493
2494 strtitlept=titlehist;
2495 strtitlept.Append(" Mass Peak, ");
2496 strtitlept+=fptbins[i];
2497 strtitlept.Append("<= pt <");
2498 strtitlept+=fptbins[i+1];
2499 strtitlept.Append(" [GeV/c]");
2500
e047b348 2501 hd0D0ptLSCbackPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2502 hd0D0ptLSCbackPM->SetXTitle("Impact parameter [#mum] ");
2503 hd0D0ptLSCbackPM->SetYTitle("Entries");
2504 flistLsCutsBack->Add(hd0D0ptLSCbackPM);
624c07ab 2505
2506 strnamept.ReplaceAll("hd0D0","hMCd0D0");
e047b348 2507 hMCd0D0ptLSCbackPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2508 hMCd0D0ptLSCbackPM->SetXTitle("MC Impact parameter [#mum] ");
2509 hMCd0D0ptLSCbackPM->SetYTitle("Entries");
2510 flistLsCutsBack->Add(hMCd0D0ptLSCbackPM);
624c07ab 2511
2512
2513 strnamept.ReplaceAll("hMCd0D0","hd0D0VtxTrue");
e047b348 2514 hd0D0VtxTrueptLSCbackPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2515 hd0D0VtxTrueptLSCbackPM->SetXTitle("Impact parameter w.r.t. True Vtx [#mum] ");
2516 hd0D0VtxTrueptLSCbackPM->SetYTitle("Entries");
2517 flistLsCutsBack->Add(hd0D0VtxTrueptLSCbackPM);
624c07ab 2518
2519 strnamept=namehist;
2520 strnamept.Append("SBMss_pt");
2521 strnamept+=i;
2522
2523 strtitlept=titlehist;
2524 strtitlept.Append(" Side Bands, ");
2525 strtitlept+=fptbins[i];
2526 strtitlept.Append("<= pt <");
2527 strtitlept+=fptbins[i+1];
2528 strtitlept.Append(" [GeV/c]");
2529
e047b348 2530 hd0D0ptLSCbackSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2531 hd0D0ptLSCbackSB->SetXTitle("Impact parameter [#mum] ");
2532 hd0D0ptLSCbackSB->SetYTitle("Entries");
2533 flistLsCutsBack->Add(hd0D0ptLSCbackSB);
624c07ab 2534
2535 strnamept.ReplaceAll("hd0D0","hMCd0D0");
e047b348 2536 hMCd0D0ptLSCbackSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2537 hMCd0D0ptLSCbackSB->SetXTitle("MC Impact parameter [#mum] ");
2538 hMCd0D0ptLSCbackSB->SetYTitle("Entries");
2539 flistLsCutsBack->Add(hMCd0D0ptLSCbackSB);
624c07ab 2540
2541 strnamept.ReplaceAll("hMCd0D0","hd0D0VtxTrue");
e047b348 2542 hd0D0VtxTrueptLSCbackSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2543 hd0D0VtxTrueptLSCbackSB->SetXTitle("Impact parameter w.r.t. True Vtx [#mum] ");
2544 hd0D0VtxTrueptLSCbackSB->SetYTitle("Entries");
2545 flistLsCutsBack->Add(hd0D0VtxTrueptLSCbackSB);
624c07ab 2546 }
2547
2548
2549
2550 //############ LOOSE CUTS FROMB HISTOGRAMS ###########
2551 //
2552 //####### global properties histos
2553
e047b348 2554 TH2F *hCPtaVSd0d0LSCfromB=new TH2F("hCPtaVSd0d0LSCfromB","hCPtaVSd0d0_LooseCuts_FromB",1000,-100000.,100000.,100,-1.,1.);
ac4c229c 2555 TH1F *hSecVtxZLSCfromB=new TH1F("hSecVtxZLSCfromB","hSecVtxZ_LooseCuts_FromB",1000,-8.,8.);
2556 TH1F *hSecVtxXLSCfromB=new TH1F("hSecVtxXLSCfromB","hSecVtxX_LooseCuts_FromB",1000,-3000.,3000.);
2557 TH1F *hSecVtxYLSCfromB=new TH1F("hSecVtxYLSCfromB","hSecVtxY_LooseCuts_FromB",1000,-3000.,3000.);
2558 TH2F *hSecVtxXYLSCfromB=new TH2F("hSecVtxXYLSCfromB","hSecVtxXY_LooseCuts_FromB",1000,-3000.,3000.,1000,-3000.,3000.);
2559 TH1F *hSecVtxPhiLSCfromB=new TH1F("hSecVtxPhiLSCfromB","hSecVtxPhi_LooseCuts_FromB",180,-180.1,180.1);
e047b348 2560 TH1F *hd0singlTrackLSCfromB=new TH1F("hd0singlTrackLSCfromB","hd0singlTrackLooseCuts_FromB",1000,-5000.,5000.);
2561 TH1F *hCPtaLSCfromB=new TH1F("hCPtaLSCfromB","hCPta_LooseCuts_FromB",100,-1.,1.);
ac4c229c 2562 TH1F *hd0xd0LSCfromB=new TH1F("hd0xd0LSCfromB","hd0xd0_LooseCuts_FromB",1000,-100000.,100000.);
2563 TH1F *hMassTrueLSCfromB=new TH1F("hMassTrueLSCfromB","D^{0} MC inv. Mass Loose Cuts FromB(All momenta)",600,1.600,2.200);
2564 TH1F *hMassLSCfromB=new TH1F("hMassLSCfromB","D^{0} inv. Mass Loose Cuts FromB (All momenta)",600,1.600,2.200);
2565 hMassLSCfromB->Sumw2();
2566 TH1F *hMassTrueLSCfromBPM=new TH1F("hMassTrueLSCfromBPM","D^{0} MC inv. Mass Loose Cuts FromB, Mass Peak. (All momenta)",600,1.600,2.200);
2567 TH1F *hMassLSCfromBPM=new TH1F("hMassLSCfromBPM","D^{0} inv. Mass Loose Cuts FromB (All momenta), MassPeak",600,1.600,2.200);
2568 hMassLSCfromBPM->Sumw2();
2569 TH1F *hMassTrueLSCfromBSB=new TH1F("hMassTrueLSCfromBSB","D^{0} MC inv. Mass in Side Bands Loose Cuts FromB(All momenta)",600,1.600,2.200);
2570 TH1F *hMassLSCfromBSB=new TH1F("hMassLSCfromBSB","D^{0} inv. Mass in Side Bands Loose Cuts FromB (All momenta)",600,1.600,2.200);
2571 hMassLSCfromBSB->Sumw2();
2572
2573 flistLsCutsFromB->Add(hCPtaVSd0d0LSCfromB);
2574 flistLsCutsFromB->Add(hSecVtxZLSCfromB);
2575 flistLsCutsFromB->Add(hSecVtxYLSCfromB);
2576 flistLsCutsFromB->Add(hSecVtxXLSCfromB);
2577 flistLsCutsFromB->Add(hSecVtxXYLSCfromB);
2578 flistLsCutsFromB->Add(hSecVtxPhiLSCfromB);
e047b348 2579 flistLsCutsFromB->Add(hd0singlTrackLSCfromB);
ac4c229c 2580 flistLsCutsFromB->Add(hCPtaLSCfromB);
2581 flistLsCutsFromB->Add(hd0xd0LSCfromB);
2582 flistLsCutsFromB->Add(hMassTrueLSCfromB);
2583 flistLsCutsFromB->Add(hMassLSCfromB);
2584 flistLsCutsFromB->Add(hMassTrueLSCfromBPM);
2585 flistLsCutsFromB->Add(hMassLSCfromBPM);
2586 flistLsCutsFromB->Add(hMassTrueLSCfromBSB);
2587 flistLsCutsFromB->Add(hMassLSCfromBSB);
624c07ab 2588
e047b348 2589
2590
2591
2592 //%%% NEW HISTOS %%%%%%%%%%%%%%%%
2593 TH1F *hdcaLSCfromB=new TH1F("hdcaLSCfromB","hdca_LooseCuts_FromB",100,0.,1000.);
2594 hdcaLSCfromB->SetXTitle("dca [#mum]");
2595 hdcaLSCfromB->SetYTitle("Entries");
2596 TH1F *hcosthetastarLSCfromB=new TH1F("hcosthetastarLSCfromB","hCosThetaStar_LooseCuts_FromB",50,-1.,1.);
2597 hcosthetastarLSCfromB->SetXTitle("cos #theta^{*}");
2598 hcosthetastarLSCfromB->SetYTitle("Entries");
2599 TH1F *hptD0LSCfromB=new TH1F("hptD0LSCfromB","D^{0} transverse momentum distribution",34,ptbinsD0arr);
2600 hptD0LSCfromB->SetXTitle("p_{t} [GeV/c]");
2601 hptD0LSCfromB->SetYTitle("Entries");
2602 TH1F *hptD0VsMaxPtLSCfromB=new TH1F("hptD0VsMaxPtLSCfromB","Difference between D^{0} pt and highest (or second) pt",400,-50.,50.);
2603 TH2F *hptD0PTallsqrtLSCfromB=new TH2F("hptD0PTallsqrtLSCfromB","D^{0} pt Vs Sqrt(Sum pt square)",34,ptbinsD0arr,200,dumbinning);
2604 TH2F *hptD0PTallLSCfromB=new TH2F("hptD0PTallLSCfromB","D^{0} pt Vs Sum pt ",34,ptbinsD0arr,200,dumbinning);
2605 TH2F *hptD0vsptBLSCfromB=new TH2F("hptD0vsptBLSCfromB","D^{0} pt Vs B pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
2606 TH2F *hpD0vspBLSCfromB=new TH2F("hpD0vspBLSCfromB","D^{0} tot momentum Vs B tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
2607 TH2F *hptD0vsptcquarkLSCfromB=new TH2F("hptD0vsptcquarkLSCfromB","D^{0} pt Vs cquark pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
2608 TH2F *hpD0vspcquarkLSCfromB=new TH2F("hpD0vspcquarkLSCfromB","D^{0} tot momentum Vs cquark tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
2609 flistLsCutsFromB->Add(hdcaLSCfromB);
2610 flistLsCutsFromB->Add(hcosthetastarLSCfromB);
2611 flistLsCutsFromB->Add(hptD0LSCfromB);
2612 flistLsCutsFromB->Add(hptD0VsMaxPtLSCfromB);
2613 flistLsCutsFromB->Add(hptD0PTallsqrtLSCfromB);
2614 flistLsCutsFromB->Add(hptD0PTallLSCfromB);
2615 flistLsCutsFromB->Add(hptD0vsptBLSCfromB);
2616 flistLsCutsFromB->Add(hpD0vspBLSCfromB);
2617 flistLsCutsFromB->Add(hptD0vsptcquarkLSCfromB);
2618 flistLsCutsFromB->Add(hpD0vspcquarkLSCfromB);
2619
2620 TH1F *hd0zD0ptLSCfromB;
2621 TH1F *hInvMassLSCfromB;
2622 TH2F *hInvMassPtLSCfromB=new TH2F("hInvMassPtLSCfromB","Candidate p_{t} Vs invariant mass",330,1.700,2.030,200,0.,20.);
2623 TH1F *hetaLSCfromB;
2624 TH1F *hCosPDPBLSCfromB;
2625 TH1F *hCosPcPDLSCfromB;
2626 flistLsCutsFromB->Add(hInvMassPtLSCfromB);
2627 // %%%%%%%%%%% HERE THE ADDITIONAL HISTS %%%%%%%%%%%%%%%%%
2628 TH2F *hd0D0VSd0xd0LSCfromBpt;
2629 TH2F *hangletracksVSd0xd0LSCfromBpt;
2630 TH2F *hangletracksVSd0D0LSCfromBpt;
2631 TH1F *hd0xd0LSCfromBpt;
2632
2633
2634 TH2F *hTOFpidLSCfromB=new TH2F("hTOFpidLSCfromB","TOF time VS momentum",10,0.,4.,50,-50000.,50000.);
2635 flistLsCutsFromB->Add(hTOFpidLSCfromB);
2636
2637 for(Int_t i=0;i<fnbins;i++){
2638 namehist="hd0zD0ptLSCfromB_pt";
2639 namehist+=i;
2640 titlehist="d0(z) Loose Cuts FromBm ptbin=";
2641 titlehist+=i;
2642 hd0zD0ptLSCfromB=new TH1F(namehist.Data(),titlehist.Data(),1000,-3000,3000.);
2643 hd0zD0ptLSCfromB->SetXTitle("d_{0}(z) [#mum]");
2644 hd0zD0ptLSCfromB->SetYTitle("Entries");
2645 flistLsCutsFromB->Add(hd0zD0ptLSCfromB);
2646
2647 namehist="hInvMassLSCfromB_pt";
2648 namehist+=i;
2649 titlehist="Invariant Mass Loose Cuts FromB ptbin=";
2650 titlehist+=i;
2651 hInvMassLSCfromB=new TH1F(namehist.Data(),titlehist.Data(),600,1.600,2.200);
2652 hInvMassLSCfromB->SetXTitle("Invariant Mass [GeV]");
2653 hInvMassLSCfromB->SetYTitle("Entries");
2654 flistLsCutsFromB->Add(hInvMassLSCfromB);
2655
2656 namehist="hetaLSCfromB_pt";
2657 namehist+=i;
2658 titlehist="eta Loose Cuts FromB ptbin=";
2659 titlehist+=i;
2660 hetaLSCfromB=new TH1F(namehist.Data(),titlehist.Data(),100,-3.,3.);
2661 hetaLSCfromB->SetXTitle("Pseudorapidity");
2662 hetaLSCfromB->SetYTitle("Entries");
2663 flistLsCutsFromB->Add(hetaLSCfromB);
2664
2665 namehist="hCosPDPBLSCfromB_pt";
2666 namehist+=i;
2667 titlehist="Cosine between D0 momentum and B momentum, ptbin=";
2668 titlehist+=i;
2669 hCosPDPBLSCfromB=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
2670 hCosPDPBLSCfromB->SetXTitle("Cosine between D0 momentum and B momentum");
2671 hCosPDPBLSCfromB->SetYTitle("Entries");
2672 flistLsCutsFromB->Add(hCosPDPBLSCfromB);
2673
2674 namehist="hCosPcPDLSCfromB_pt";
2675 namehist+=i;
2676 titlehist="Cosine between cquark momentum and D0 momentum, ptbin=";
2677 titlehist+=i;
2678 hCosPcPDLSCfromB=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
2679 hCosPcPDLSCfromB->SetXTitle("Cosine between c quark momentum and D0 momentum");
2680 hCosPcPDLSCfromB->SetYTitle("Entries");
2681 flistLsCutsFromB->Add(hCosPcPDLSCfromB);
2682
2683 // %%%%%%%%%%% HERE THE ADDITIONAL HISTS %%%%%%%%%%%%%%%%%
2684 namehist="hd0xd0LSCfromB_pt";
2685 namehist+=i;
2686 titlehist="d0xd0 Loose Cuts FromB ptbin=";
2687 titlehist+=i;
2688 hd0xd0LSCfromBpt=new TH1F(namehist.Data(),titlehist.Data(),1000,-50000.,10000.);
2689 hd0xd0LSCfromBpt->SetXTitle("d_{0}^{K}xd_{0}^{#pi} [#mum^2]");
2690 hd0xd0LSCfromBpt->SetYTitle("Entries");
2691 flistLsCutsFromB->Add(hd0xd0LSCfromBpt);
2692
2693
2694 namehist="hd0D0VSd0xd0LSCfromB_pt";
2695 namehist+=i;
2696 titlehist="d_{0}^{D^{0}} Vs d_{0}^{K}xd_{0}^{#pi} Loose Cuts FromB ptbin=";
2697 titlehist+=i;
2698 hd0D0VSd0xd0LSCfromBpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,100,-300,300);
2699 hd0D0VSd0xd0LSCfromBpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
2700 hd0D0VSd0xd0LSCfromBpt->SetYTitle(" d_{0}^{D^{0}} [#mum]");
2701 flistLsCutsFromB->Add(hd0D0VSd0xd0LSCfromBpt);
2702
2703
2704 namehist="hangletracksVSd0xd0LSCfromB_pt";
2705 namehist+=i;
2706 titlehist="Angle between K and #pi tracks Vs d_{0}^{K}xd_{0}^{#pi} Loose Cuts FromB ptbin=";
2707 titlehist+=i;
2708 hangletracksVSd0xd0LSCfromBpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,40,-0.1,3.24);
2709 hangletracksVSd0xd0LSCfromBpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
2710 hangletracksVSd0xd0LSCfromBpt->SetYTitle(" angle between K and #p tracks [rad]");
2711 flistLsCutsFromB->Add(hangletracksVSd0xd0LSCfromBpt);
2712
2713
2714 namehist="hangletracksVSd0D0LSCfromB_pt";
2715 namehist+=i;
2716 titlehist="Angle between K and #pi tracks Vs d_{0}^{D^{0}} Loose Cuts FromB ptbin=";
2717 titlehist+=i;
2718 hangletracksVSd0D0LSCfromBpt=new TH2F(namehist.Data(),titlehist.Data(),200,-400.,400.,40,-0.12,3.24);
2719 hangletracksVSd0D0LSCfromBpt->SetXTitle(" d_{0}^{D^{0}} [#mum]");
2720 hangletracksVSd0D0LSCfromBpt->SetYTitle(" angle between K and #p tracks [rad]");
2721 flistLsCutsFromB->Add(hangletracksVSd0D0LSCfromBpt);
2722
2723 }
2724 // %%%%%%%% END OF NEW HISTOS %%%%%%%%%%%%%
2725 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
2726
2727
2728
2729
2730
624c07ab 2731 // ######### d0 D0 histos ##############
ac4c229c 2732 TH1F *hd0D0LSCfromBPM = new TH1F("hd0D0LSCfromBPM","D^{0} impact par. plot , Loose Cuts ,FromB,Mass Peak (All momenta)",1000,-1000.,1000.);
2733 hd0D0LSCfromBPM->SetXTitle("Impact parameter [#mum]");
2734 hd0D0LSCfromBPM->SetYTitle("Entries");
2735
2736 TH1F *hd0D0VtxTrueLSCfromBPM = new TH1F("hd0D0VtxTrueLSCfromBPM","D^{0} impact par. w.r.t. True Vtx, Loose Cuts, FromB,Mass Peak (All momenta)",1000,-1000.,1000.);
2737 hd0D0VtxTrueLSCfromBPM->SetXTitle("Impact parameter [#mum]");
2738 hd0D0VtxTrueLSCfromBPM->SetYTitle("Entries");
2739
2740 TH1F *hMCd0D0LSCfromBPM = new TH1F("hMCd0D0LSCfromBPM","D^{0} impact par. plot, Loose Cuts, FromB,Mass Peak (All momenta)",1000,-1000.,1000.);
2741 hMCd0D0LSCfromBPM->SetXTitle("MC Impact parameter [#mum]");
2742 hMCd0D0LSCfromBPM->SetYTitle("Entries");
2743
2744 TH1F *hd0D0LSCfromBSB = new TH1F("hd0D0LSCfromBSB","D^{0} impact par. plot , Loose Cuts ,FromB,Mass Peak (All momenta)",1000,-1000.,1000.);
2745 hd0D0LSCfromBSB->SetXTitle("Impact parameter [#mum]");
2746 hd0D0LSCfromBSB->SetYTitle("Entries");
2747
2748 TH1F *hd0D0VtxTrueLSCfromBSB = new TH1F("hd0D0VtxTrueLSCfromBSB","D^{0} impact par. w.r.t. True Vtx, Loose Cuts, FromB,Mass Peak (All momenta)",1000,-1000.,1000.);
2749 hd0D0VtxTrueLSCfromBSB->SetXTitle("Impact parameter [#mum]");
2750 hd0D0VtxTrueLSCfromBSB->SetYTitle("Entries");
2751
2752 TH1F *hMCd0D0LSCfromBSB = new TH1F("hMCd0D0LSCfromBSB","D^{0} impact par. plot, Loose Cuts, FromB,Mass Peak (All momenta)",1000,-1000.,1000.);
2753 hMCd0D0LSCfromBSB->SetXTitle("MC Impact parameter [#mum]");
2754 hMCd0D0LSCfromBSB->SetYTitle("Entries");
2755
2756 flistLsCutsFromB->Add(hd0D0LSCfromBPM);
2757 flistLsCutsFromB->Add(hd0D0VtxTrueLSCfromBPM);
2758 flistLsCutsFromB->Add(hMCd0D0LSCfromBPM);
2759 flistLsCutsFromB->Add(hd0D0LSCfromBSB);
2760 flistLsCutsFromB->Add(hd0D0VtxTrueLSCfromBSB);
2761 flistLsCutsFromB->Add(hMCd0D0LSCfromBSB);
2762
e047b348 2763 TH1F *hd0D0ptLSCfromBPM;
2764 TH1F *hMCd0D0ptLSCfromBPM;
2765 TH1F *hd0D0VtxTrueptLSCfromBPM;
2766 TH1F *hd0D0ptLSCfromBSB;
2767 TH1F *hMCd0D0ptLSCfromBSB;
2768 TH1F *hd0D0VtxTrueptLSCfromBSB;
ac4c229c 2769 namehist="hd0D0ptLSCfromB_";
624c07ab 2770 titlehist="D^{0} impact par. plot, Loose Cuts, FromB, ";
2771 for(Int_t i=0;i<fnbins;i++){
2772 strnamept=namehist;
2773 strnamept.Append("PkMss_pt");
2774 strnamept+=i;
2775
2776 strtitlept=titlehist;
2777 strtitlept.Append(" Mass Peak, ");
2778 strtitlept+=fptbins[i];
2779 strtitlept.Append("<= pt <");
2780 strtitlept+=fptbins[i+1];
2781 strtitlept.Append(" [GeV/c]");
2782
e047b348 2783 hd0D0ptLSCfromBPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2784 hd0D0ptLSCfromBPM->SetXTitle("Impact parameter [#mum] ");
2785 hd0D0ptLSCfromBPM->SetYTitle("Entries");
2786 flistLsCutsFromB->Add(hd0D0ptLSCfromBPM);
624c07ab 2787
2788 strnamept.ReplaceAll("hd0D0","hMCd0D0");
e047b348 2789 hMCd0D0ptLSCfromBPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2790 hMCd0D0ptLSCfromBPM->SetXTitle("MC Impact parameter [#mum] ");
2791 hMCd0D0ptLSCfromBPM->SetYTitle("Entries");
2792 flistLsCutsFromB->Add(hMCd0D0ptLSCfromBPM);
624c07ab 2793
2794
2795 strnamept.ReplaceAll("hMCd0D0","hd0D0VtxTrue");
e047b348 2796 hd0D0VtxTrueptLSCfromBPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2797 hd0D0VtxTrueptLSCfromBPM->SetXTitle("Impact parameter w.r.t. True Vtx [#mum] ");
2798 hd0D0VtxTrueptLSCfromBPM->SetYTitle("Entries");
2799 flistLsCutsFromB->Add(hd0D0VtxTrueptLSCfromBPM);
624c07ab 2800
2801 strnamept=namehist;
2802 strnamept.Append("SBMss_pt");
2803 strnamept+=i;
2804
2805 strtitlept=titlehist;
2806 strtitlept.Append(" Side Bands, ");
2807 strtitlept+=fptbins[i];
2808 strtitlept.Append("<= pt <");
2809 strtitlept+=fptbins[i+1];
2810 strtitlept.Append(" [GeV/c]");
2811
e047b348 2812 hd0D0ptLSCfromBSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2813 hd0D0ptLSCfromBSB->SetXTitle("Impact parameter [#mum] ");
2814 hd0D0ptLSCfromBSB->SetYTitle("Entries");
2815 flistLsCutsFromB->Add(hd0D0ptLSCfromBSB);
624c07ab 2816
2817 strnamept.ReplaceAll("hd0D0","hMCd0D0");
e047b348 2818 hMCd0D0ptLSCfromBSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2819 hMCd0D0ptLSCfromBSB->SetXTitle("MC Impact parameter [#mum] ");
2820 hMCd0D0ptLSCfromBSB->SetYTitle("Entries");
2821 flistLsCutsFromB->Add(hMCd0D0ptLSCfromBSB);
624c07ab 2822
2823 strnamept.ReplaceAll("hMCd0D0","hd0D0VtxTrue");
e047b348 2824 hd0D0VtxTrueptLSCfromBSB = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
2825 hd0D0VtxTrueptLSCfromBSB->SetXTitle("Impact parameter w.r.t. True Vtx [#mum] ");
2826 hd0D0VtxTrueptLSCfromBSB->SetYTitle("Entries");
2827 flistLsCutsFromB->Add(hd0D0VtxTrueptLSCfromBSB);
624c07ab 2828 }
2829
2830
2831
2832 //############ LOOSE CUTS FROM DSTAR HISTOGRAMS ###########
2833 //
2834 //############## global properties histos
e047b348 2835 TH2F *hCPtaVSd0d0LSCfromDstar=new TH2F("hCPtaVSd0d0LSCfromDstar","hCPtaVSd0d0_LooseCuts_FromDStar",1000,-100000.,100000.,100,-1.,1.);
ac4c229c 2836 TH1F *hSecVtxZLSCfromDstar=new TH1F("hSecVtxZLSCfromDstar","hSecVtxZ_LooseCuts_FromDStar",1000,-8.,8.);
2837 TH1F *hSecVtxXLSCfromDstar=new TH1F("hSecVtxXLSCfromDstar","hSecVtxX_LooseCuts_FromDStar",1000,-3000.,3000.);
2838 TH1F *hSecVtxYLSCfromDstar=new TH1F("hSecVtxYLSCfromDstar","hSecVtxY_LooseCuts_FromDStar",1000,-3000.,3000.);
2839 TH2F *hSecVtxXYLSCfromDstar=new TH2F("hSecVtxXYLSCfromDstar","hSecVtxXY_LooseCuts_FromDStar",1000,-3000.,3000.,1000,-3000.,3000.);
2840 TH1F *hSecVtxPhiLSCfromDstar=new TH1F("hSecVtxPhiLSCfromDstar","hSecVtxPhi_LooseCuts_FromDStar",180,-180.1,180.1);
e047b348 2841 TH1F *hd0singlTrackLSCfromDstar=new TH1F("hd0singlTrackLSCfromDstar","hd0singlTrackLooseCuts_FromDstar",1000,-5000.,5000.);
2842 TH1F *hCPtaLSCfromDstar=new TH1F("hCPtaLSCfromDstar","hCPta_LooseCuts_FromDStar",100,-1.,1.);
ac4c229c 2843 TH1F *hd0xd0LSCfromDstar=new TH1F("hd0xd0LSCfromDstar","hd0xd0_LooseCuts_FromDStar",1000,-100000.,100000.);
2844 TH1F *hMassTrueLSCfromDstar=new TH1F("hMassTrueLSCfromDstar","D^{0} MC inv. Mass Loose Cuts FromDStar(All momenta)",600,1.600,2.200);
2845 TH1F *hMassLSCfromDstar=new TH1F("hMassLSCfromDstar","D^{0} inv. Mass Loose Cuts FromDStar (All momenta)",600,1.600,2.200);
2846 hMassLSCfromDstar->Sumw2();
2847 TH1F *hMassTrueLSCfromDstarPM=new TH1F("hMassTrueLSCfromDstarPM","D^{0} MC inv. Mass Loose Cuts FromDStar, Mass Peak. (All momenta)",600,1.600,2.200);
2848 TH1F *hMassLSCfromDstarPM=new TH1F("hMassLSCfromDstarPM","D^{0} inv. Mass Loose Cuts FromDStar (All momenta), MassPeak",600,1.600,2.200);
2849 hMassLSCfromDstarPM->Sumw2();
2850 TH1F *hMassTrueLSCfromDstarSB=new TH1F("hMassTrueLSCfromDstarSB","D^{0} MC inv. Mass in Side Bands Loose Cuts FromDStar(All momenta)",600,1.600,2.200);
2851 TH1F *hMassLSCfromDstarSB=new TH1F("hMassLSCfromDstarSB","D^{0} inv. Mass in Side Bands Loose Cuts FromDStar (All momenta)",600,1.600,2.200);
2852 hMassLSCfromDstarSB->Sumw2();
2853
2854 flistLsCutsFromDstar->Add(hCPtaVSd0d0LSCfromDstar);
2855 flistLsCutsFromDstar->Add(hSecVtxZLSCfromDstar);
2856 flistLsCutsFromDstar->Add(hSecVtxYLSCfromDstar);
2857 flistLsCutsFromDstar->Add(hSecVtxXLSCfromDstar);
2858 flistLsCutsFromDstar->Add(hSecVtxXYLSCfromDstar);
2859 flistLsCutsFromDstar->Add(hSecVtxPhiLSCfromDstar);
e047b348 2860 flistLsCutsFromDstar->Add(hd0singlTrackLSCfromDstar);
ac4c229c 2861 flistLsCutsFromDstar->Add(hCPtaLSCfromDstar);
2862 flistLsCutsFromDstar->Add(hd0xd0LSCfromDstar);
2863 flistLsCutsFromDstar->Add(hMassTrueLSCfromDstar);
2864 flistLsCutsFromDstar->Add(hMassLSCfromDstar);
e047b348 2865 flistLsCutsFromDstar->Add(hMassTrueLSCfromDstarPM);
ac4c229c 2866 flistLsCutsFromDstar->Add(hMassLSCfromDstarPM);
2867 flistLsCutsFromDstar->Add(hMassTrueLSCfromDstarSB);
2868 flistLsCutsFromDstar->Add(hMassLSCfromDstarSB);
624c07ab 2869
e047b348 2870
2871
2872
2873
2874
2875
2876 //%%% NEW HISTOS %%%%%%%%%%%%%%%%
2877 TH1F *hdcaLSCfromDstar=new TH1F("hdcaLSCfromDstar","hdca_LooseCuts_FromDstar",100,0.,1000.);
2878 hdcaLSCfromDstar->SetXTitle("dca [#mum]");
2879 hdcaLSCfromDstar->SetYTitle("Entries");
2880 TH1F *hcosthetastarLSCfromDstar=new TH1F("hcosthetastarLSCfromDstar","hCosThetaStar_LooseCuts_FromDstar",50,-1.,1.);
2881 hcosthetastarLSCfromDstar->SetXTitle("cos #theta^{*}");
2882 hcosthetastarLSCfromDstar->SetYTitle("Entries");
2883 TH1F *hptD0LSCfromDstar=new TH1F("hptD0LSCfromDstar","D^{0} transverse momentum distribution",34,ptbinsD0arr);
2884 hptD0LSCfromDstar->SetXTitle("p_{t} [GeV/c]");
2885 hptD0LSCfromDstar->SetYTitle("Entries");
2886 TH1F *hptD0VsMaxPtLSCfromDstar=new TH1F("hptD0VsMaxPtLSCfromDstar","Difference between D^{0} pt and highest (or second) pt",400,-50.,50.);
2887 TH2F *hptD0PTallsqrtLSCfromDstar=new TH2F("hptD0PTallsqrtLSCfromDstar","D^{0} pt Vs Sqrt(Sum pt square)",34,ptbinsD0arr,200,dumbinning);
2888 TH2F *hptD0PTallLSCfromDstar=new TH2F("hptD0PTallLSCfromDstar","D^{0} pt Vs Sum pt ",34,ptbinsD0arr,200,dumbinning);
2889 TH2F *hptD0vsptBLSCfromDstar=new TH2F("hptD0vsptBLSCfromDstar","D^{0} pt Vs B pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
2890 TH2F *hpD0vspBLSCfromDstar=new TH2F("hpD0vspBLSCfromDstar","D^{0} tot momentum Vs B tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
2891 TH2F *hptD0vsptcquarkLSCfromDstar=new TH2F("hptD0vsptcquarkLSCfromDstar","D^{0} pt Vs cquark pt distribution",34,ptbinsD0arr,34,ptbinsD0arr);
2892 TH2F *hpD0vspcquarkLSCfromDstar=new TH2F("hpD0vspcquarkLSCfromDstar","D^{0} tot momentum Vs cquark tot momentum distribution",34,ptbinsD0arr,34,ptbinsD0arr);
2893 flistLsCutsFromDstar->Add(hdcaLSCfromDstar);
2894 flistLsCutsFromDstar->Add(hcosthetastarLSCfromDstar);
2895 flistLsCutsFromDstar->Add(hptD0LSCfromDstar);
2896 flistLsCutsFromDstar->Add(hptD0VsMaxPtLSCfromDstar);
2897 flistLsCutsFromDstar->Add(hptD0PTallsqrtLSCfromDstar);
2898 flistLsCutsFromDstar->Add(hptD0PTallLSCfromDstar);
2899 flistLsCutsFromDstar->Add(hptD0vsptBLSCfromDstar);
2900 flistLsCutsFromDstar->Add(hpD0vspBLSCfromDstar);
2901 flistLsCutsFromDstar->Add(hptD0vsptcquarkLSCfromDstar);
2902 flistLsCutsFromDstar->Add(hpD0vspcquarkLSCfromDstar);
2903
2904 TH1F *hd0zD0ptLSCfromDstar;
2905 TH1F *hInvMassLSCfromDstar;
2906 TH2F *hInvMassPtLSCfromDstar=new TH2F("hInvMassPtLSCfromDstar","Candidate p_{t} Vs invariant mass",330,1.700,2.030,200,0.,20.);
2907 TH1F *hetaLSCfromDstar;
2908 TH1F *hCosPDPBLSCfromDstar;
2909 TH1F *hCosPcPDLSCfromDstar;
2910 flistLsCutsFromDstar->Add(hInvMassPtLSCfromDstar);
2911 // %%%%%%%%%%% HERE THE ADDITIONAL HISTS %%%%%%%%%%%%%%%%%
2912 TH2F *hd0D0VSd0xd0LSCfromDstarpt;
2913 TH2F *hangletracksVSd0xd0LSCfromDstarpt;
2914 TH2F *hangletracksVSd0D0LSCfromDstarpt;
2915 TH1F *hd0xd0LSCfromDstarpt;
2916
2917 TH2F *hTOFpidLSCfromDstar=new TH2F("hTOFpidLSCfromDstar","TOF time VS momentum",10,0.,4.,50,-50000.,50000.);
2918 flistLsCutsFromDstar->Add(hTOFpidLSCfromDstar);
2919
2920 for(Int_t i=0;i<fnbins;i++){
2921 namehist="hd0zD0ptLSCfromDstar_pt";
2922 namehist+=i;
2923 titlehist="d0(z) Loose Cuts FromDstarm ptbin=";
2924 titlehist+=i;
2925 hd0zD0ptLSCfromDstar=new TH1F(namehist.Data(),titlehist.Data(),1000,-3000,3000.);
2926 hd0zD0ptLSCfromDstar->SetXTitle("d_{0}(z) [#mum]");
2927 hd0zD0ptLSCfromDstar->SetYTitle("Entries");
2928 flistLsCutsFromDstar->Add(hd0zD0ptLSCfromDstar);
2929
2930 namehist="hInvMassLSCfromDstar_pt";
2931 namehist+=i;
2932 titlehist="Invariant Mass Loose Cuts FromDstar ptbin=";
2933 titlehist+=i;
2934 hInvMassLSCfromDstar=new TH1F(namehist.Data(),titlehist.Data(),600,1.600,2.200);
2935 hInvMassLSCfromDstar->SetXTitle("Invariant Mass [GeV]");
2936 hInvMassLSCfromDstar->SetYTitle("Entries");
2937 flistLsCutsFromDstar->Add(hInvMassLSCfromDstar);
2938
2939 namehist="hetaLSCfromDstar_pt";
2940 namehist+=i;
2941 titlehist="eta Loose Cuts FromDstar ptbin=";
2942 titlehist+=i;
2943 hetaLSCfromDstar=new TH1F(namehist.Data(),titlehist.Data(),100,-3.,3.);
2944 hetaLSCfromDstar->SetXTitle("Pseudorapidity");
2945 hetaLSCfromDstar->SetYTitle("Entries");
2946 flistLsCutsFromDstar->Add(hetaLSCfromDstar);
2947
2948 namehist="hCosPDPBLSCfromDstar_pt";
2949 namehist+=i;
2950 titlehist="Cosine between D0 momentum and B momentum, ptbin=";
2951 titlehist+=i;
2952 hCosPDPBLSCfromDstar=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
2953 hCosPDPBLSCfromDstar->SetXTitle("Cosine between D0 momentum and B momentum");
2954 hCosPDPBLSCfromDstar->SetYTitle("Entries");
2955 flistLsCutsFromDstar->Add(hCosPDPBLSCfromDstar);
2956
2957 namehist="hCosPcPDLSCfromDstar_pt";
2958 namehist+=i;
2959 titlehist="Cosine between cquark momentum and D0 momentum, ptbin=";
2960 titlehist+=i;
2961 hCosPcPDLSCfromDstar=new TH1F(namehist.Data(),titlehist.Data(),50,-1.,1.);
2962 hCosPcPDLSCfromDstar->SetXTitle("Cosine between c quark momentum and D0 momentum");
2963 hCosPcPDLSCfromDstar->SetYTitle("Entries");
2964 flistLsCutsFromDstar->Add(hCosPcPDLSCfromDstar);
2965
2966 // %%%%%%%%%%% HERE THE ADDITIONAL HISTS %%%%%%%%%%%%%%%%%
2967 namehist="hd0xd0LSCfromDstar_pt";
2968 namehist+=i;
2969 titlehist="d0xd0 Loose Cuts FromDstar ptbin=";
2970 titlehist+=i;
2971 hd0xd0LSCfromDstarpt=new TH1F(namehist.Data(),titlehist.Data(),1000,-50000.,10000.);
2972 hd0xd0LSCfromDstarpt->SetXTitle("d_{0}^{K}xd_{0}^{#pi} [#mum^2]");
2973 hd0xd0LSCfromDstarpt->SetYTitle("Entries");
2974 flistLsCutsFromDstar->Add(hd0xd0LSCfromDstarpt);
2975
2976
2977 namehist="hd0D0VSd0xd0LSCfromDstar_pt";
2978 namehist+=i;
2979 titlehist="d_{0}^{D^{0}} Vs d_{0}^{K}xd_{0}^{#pi} Loose Cuts FromDstar ptbin=";
2980 titlehist+=i;
2981 hd0D0VSd0xd0LSCfromDstarpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,100,-300,300);
2982 hd0D0VSd0xd0LSCfromDstarpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
2983 hd0D0VSd0xd0LSCfromDstarpt->SetYTitle(" d_{0}^{D^{0}} [#mum]");
2984 flistLsCutsFromDstar->Add(hd0D0VSd0xd0LSCfromDstarpt);
2985
2986
2987 namehist="hangletracksVSd0xd0LSCfromDstar_pt";
2988 namehist+=i;
2989 titlehist="Angle between K and #pi tracks Vs d_{0}^{K}xd_{0}^{#pi} Loose Cuts FromDstar ptbin=";
2990 titlehist+=i;
2991 hangletracksVSd0xd0LSCfromDstarpt=new TH2F(namehist.Data(),titlehist.Data(),200,-50000.,30000.,40,-0.1,3.24);
2992 hangletracksVSd0xd0LSCfromDstarpt->SetXTitle(" d_{0}^{K}xd_{0}^{#pi} [#mum]");
2993 hangletracksVSd0xd0LSCfromDstarpt->SetYTitle(" angle between K and #p tracks [rad]");
2994 flistLsCutsFromDstar->Add(hangletracksVSd0xd0LSCfromDstarpt);
2995
2996
2997 namehist="hangletracksVSd0D0LSCfromDstar_pt";
2998 namehist+=i;
2999 titlehist="Angle between K and #pi tracks Vs d_{0}^{D^{0}} Loose Cuts FromDstar ptbin=";
3000 titlehist+=i;
3001 hangletracksVSd0D0LSCfromDstarpt=new TH2F(namehist.Data(),titlehist.Data(),200,-400.,400.,40,-0.12,3.24);
3002 hangletracksVSd0D0LSCfromDstarpt->SetXTitle(" d_{0}^{D^{0}} [#mum]");
3003 hangletracksVSd0D0LSCfromDstarpt->SetYTitle(" angle between K and #p tracks [rad]");
3004 flistLsCutsFromDstar->Add(hangletracksVSd0D0LSCfromDstarpt);
3005
3006
3007 }
3008 // %%%%%%%% END OF NEW HISTOS %%%%%%%%%%%%%
3009 //%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3010
3011
3012
3013
3014
3015
624c07ab 3016 //########## d0 D0 histos #############
ac4c229c 3017 TH1F *hd0D0LSCfromDstPM = new TH1F("hd0D0LSCfromDstarPM","D^{0} impact par. plot , Loose Cuts ,FromDStar,Mass Peak (All momenta)",1000,-1000.,1000.);
3018 hd0D0LSCfromDstPM->SetXTitle("Impact parameter [#mum]");
3019 hd0D0LSCfromDstPM->SetYTitle("Entries");
3020
3021 TH1F *hd0D0VtxTrueLSCfromDstPM = new TH1F("hd0D0VtxTrueLSCfromDstarPM","D^{0} impact par. w.r.t. True Vtx, Loose Cuts, FromDStar,Mass Peak (All momenta)",1000,-1000.,1000.);
3022 hd0D0VtxTrueLSCfromDstPM->SetXTitle("Impact parameter [#mum]");
3023 hd0D0VtxTrueLSCfromDstPM->SetYTitle("Entries");
3024
3025 TH1F *hMCd0D0LSCfromDstPM = new TH1F("hMCd0D0LSCfromDstarPM","D^{0} impact par. plot, Loose Cuts, FromDStar,Mass Peak (All momenta)",1000,-1000.,1000.);
3026 hMCd0D0LSCfromDstPM->SetXTitle("MC Impact parameter [#mum]");
3027 hMCd0D0LSCfromDstPM->SetYTitle("Entries");
3028
3029 TH1F *hd0D0LSCfromDstSB = new TH1F("hd0D0LSCfromDstarSB","D^{0} impact par. plot , Loose Cuts ,FromDStar,Mass Peak (All momenta)",1000,-1000.,1000.);
3030 hd0D0LSCfromDstSB->SetXTitle("Impact parameter [#mum]");
3031 hd0D0LSCfromDstSB->SetYTitle("Entries");
3032
3033 TH1F *hd0D0VtxTrueLSCfromDstSB = new TH1F("hd0D0VtxTrueLSCfromDstarSB","D^{0} impact par. w.r.t. True Vtx, Loose Cuts, FromDStar,Mass Peak (All momenta)",1000,-1000.,1000.);
3034 hd0D0VtxTrueLSCfromDstSB->SetXTitle("Impact parameter [#mum]");
3035 hd0D0VtxTrueLSCfromDstSB->SetYTitle("Entries");
3036
3037 TH1F *hMCd0D0LSCfromDstSB = new TH1F("hMCd0D0LSCfromDstarSB","D^{0} impact par. plot, Loose Cuts, FromDStar,Mass Peak (All momenta)",1000,-1000.,1000.);
3038 hMCd0D0LSCfromDstSB->SetXTitle("MC Impact parameter [#mum]");
3039 hMCd0D0LSCfromDstSB->SetYTitle("Entries");
3040
3041 flistLsCutsFromDstar->Add(hd0D0LSCfromDstPM);
3042 flistLsCutsFromDstar->Add(hd0D0VtxTrueLSCfromDstPM);
3043 flistLsCutsFromDstar->Add(hMCd0D0LSCfromDstPM);
3044 flistLsCutsFromDstar->Add(hd0D0LSCfromDstSB);
3045 flistLsCutsFromDstar->Add(hd0D0VtxTrueLSCfromDstSB);
3046 flistLsCutsFromDstar->Add(hMCd0D0LSCfromDstSB);
3047
e047b348 3048 TH1F *hd0D0ptLSCfromDstPM;
3049 TH1F *hMCd0D0ptLSCfromDstPM;
3050 TH1F *hd0D0VtxTrueptLSCfromDstPM;
3051 TH1F *hd0D0ptLSCfromDstSB;
3052 TH1F *hMCd0D0ptLSCfromDstSB;
3053 TH1F *hd0D0VtxTrueptLSCfromDstSB;
ac4c229c 3054 namehist="hd0D0ptLSCfromDstar_";
624c07ab 3055 titlehist="D^{0} impact par. plot, Loose Cuts, FromDStar, ";
3056 for(Int_t i=0;i<fnbins;i++){
3057 strnamept=namehist;
3058 strnamept.Append("PkMss_pt");
3059 strnamept+=i;
3060
3061 strtitlept=titlehist;
3062 strtitlept.Append(" Mass Peak, ");
3063 strtitlept+=fptbins[i];
3064 strtitlept.Append("<= pt <");
3065 strtitlept+=fptbins[i+1];
3066 strtitlept.Append(" [GeV/c]");
3067
e047b348 3068 hd0D0ptLSCfromDstPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
3069 hd0D0ptLSCfromDstPM->SetXTitle("Impact parameter [#mum] ");
3070 hd0D0ptLSCfromDstPM->SetYTitle("Entries");
3071 flistLsCutsFromDstar->Add(hd0D0ptLSCfromDstPM);
624c07ab 3072
3073 strnamept.ReplaceAll("hd0D0","hMCd0D0");
e047b348 3074 hMCd0D0ptLSCfromDstPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
3075 hMCd0D0ptLSCfromDstPM->SetXTitle("MC Impact parameter [#mum] ");
3076 hMCd0D0ptLSCfromDstPM->SetYTitle("Entries");
3077 flistLsCutsFromDstar->Add(hMCd0D0ptLSCfromDstPM);
624c07ab 3078
3079
3080 strnamept.ReplaceAll("hMCd0D0","hd0D0VtxTrue");
e047b348 3081 hd0D0VtxTrueptLSCfromDstPM = new TH1F(strnamept.Data(),strtitlept.Data(),1000,-1000.,1000.);
3082 hd0D0VtxTrueptLSCfromDstPM->SetXTitle("Impact parameter w.r.t. True Vtx [#mum] ");