AliPhysics  1811c8f (1811c8f)
makeTFile4CutsOmegac2eleOmega.C
Go to the documentation of this file.
1 #include <Riostream.h>
2 #include <TFile.h>
4 #include <AliAODPidHF.h>
5 #include <TClonesArray.h>
6 #include <TParameter.h>
7 #include <TF1.h>
8 
10 {
11 
13 
14  RDHFOmegac->SetName("eleOmegaAnalysisCuts");
15  RDHFOmegac->SetTitle("Analysis cuts for eleOmega analysis");
16  RDHFOmegac->SetUsePhysicsSelection(kTRUE);
17  RDHFOmegac->SetTriggerClass("");
18  //RDHFOmegac->SetUseInt7TriggerPP2012();
19  RDHFOmegac->ResetMaskAndEnableMBTrigger();
20  //RDHFOmegac->EnableCentralTrigger();
21  //RDHFOmegac->EnableSemiCentralTrigger();
22 
23  const Int_t nptbins=2;
24  RDHFOmegac->SetNPtBins(nptbins);
25 
26  Float_t* ptbins;
27  ptbins=new Float_t[nptbins+1];
28  ptbins[0]= 0.;
29  ptbins[1]=100.;
30  RDHFOmegac->SetPtBins(nptbins+1,ptbins);
31 
32  const Int_t nvars=2;
33 
34  Float_t** anacutsarray;
35  anacutsarray=new Float_t*[nvars];
36  for(Int_t ic=0;ic<nvars;ic++)
37  {
38  anacutsarray[ic]=new Float_t[nptbins];
39  }
40 
41  for(Int_t ipt2=0;ipt2<nptbins;ipt2++)
42  {
43  anacutsarray[ 0][ipt2]=10.; // Upper limit on Inv Mass
44  anacutsarray[ 1][ipt2]=0.; // Lower limit on cos(Opening angle)
45  }
46 
47  RDHFOmegac->SetCuts(nvars,nptbins,anacutsarray);
48 
49  RDHFOmegac->SetUsePID(kTRUE);
51  AliAODPidHF* pidObj=new AliAODPidHF();
52  //used in kNSigma
53  Double_t sigmaspi[5]={3.,0.,0.,3.,0.};
54  pidObj->SetSigma(sigmaspi);
55  pidObj->SetTPC(kTRUE);
56  pidObj->SetTOF(kTRUE);
57  pidObj->SetMatch(1);
58  //used in kNSigmaCombinedCuts
59  RDHFOmegac->SetSigmaElectronTPCRange(-0.5,3.0);
60  RDHFOmegac->SetSigmaElectronTOFRange(-3.0,3.0);
61  //RDHFOmegac->SetSigmaElectronTPCRange(-99999.,99999.);
63  //used both in kNsigma and kNSigmacustomizedcuts
64  RDHFOmegac->SetPidHF(pidObj);
65  RDHFOmegac->SetExcludePionTPC(kFALSE);
66  RDHFOmegac->SetExcludeProtonTPC(kFALSE);
67  RDHFOmegac->SetExcludeKaonTPC(kFALSE);
68  RDHFOmegac->SetExcludenSigmaPionTPC(3.0);
69  RDHFOmegac->SetExcludenSigmaProtonTPC(3.0);
70  RDHFOmegac->SetExcludenSigmaKaonTPC(3.0);
71  //RDHFOmegac->SetBachelorType(0);//0: electron, 2: pion, 3: kaon, 4: proton (used in PID)
72 
73  RDHFOmegac->SetMaxVtxZ(10.);
74 
75  RDHFOmegac->SetProdUseAODFilterBit(kTRUE);
76  RDHFOmegac->SetProdTrackTPCNclsPIDMin(80);//could not find in esdtrackcutsw
77  RDHFOmegac->SetProdTrackTPCNclsRatioMin(0.6);//could not find in esdtrackcutsw
78 
79  AliESDtrackCuts* esdTrackCuts=new AliESDtrackCuts();
80  esdTrackCuts->SetRequireSigmaToVertex(kFALSE);
81  esdTrackCuts->SetRequireTPCRefit(kTRUE);
82  esdTrackCuts->SetMinNClustersTPC(100);
83  //esdTrackCuts->SetMinNCrossedRowsTPC(70);
84  //esdTrackCuts->SetMinRatioCrossedRowsOverFindableClustersTPC(0.8);
85  esdTrackCuts->SetRequireITSRefit(kTRUE);
86  esdTrackCuts->SetMinNClustersITS(4);
87  esdTrackCuts->SetClusterRequirementITS(AliESDtrackCuts::kSPD,AliESDtrackCuts::kBoth);//kBoth
88  esdTrackCuts->SetMinDCAToVertexXY(0.);
89  esdTrackCuts->SetEtaRange(-0.6,0.6);
90  esdTrackCuts->SetPtRange(0.5,1.e10);
91  esdTrackCuts->SetMaxDCAToVertexXY(1.0);
92  esdTrackCuts->SetMaxDCAToVertexZ(2.0);
93  esdTrackCuts->SetDCAToVertex2D(kTRUE);
94  esdTrackCuts->SetMaxChi2PerClusterITS(36);
95  RDHFOmegac->AddTrackCuts(esdTrackCuts);
96 
97 
98  RDHFOmegac->SetProdMassTolLambda(0.0075);
99  RDHFOmegac->SetProdMassTolOmega(0.015);
100  RDHFOmegac->SetProdMassRejXi(0.000);
101  RDHFOmegac->SetProdRfidMinV0(2.768);
102  RDHFOmegac->SetProdRfidMaxV0(9000.);
103  RDHFOmegac->SetProdRfidMinOmega(0.79);
104  RDHFOmegac->SetProdRfidMaxOmega(9000.);
105  RDHFOmegac->SetProdCascProperDecayLengthMax(999999.);
106  RDHFOmegac->SetProdDcaOmegaDaughtersMax(1.033);
107  RDHFOmegac->SetProdDcaV0DaughtersMax(1.116);
108  RDHFOmegac->SetProdDcaBachToPrimVertexMin(0.049);
109  RDHFOmegac->SetProdDcaV0ToPrimVertexMin(0.088);
110  RDHFOmegac->SetProdDcaV0PrToPrimVertexMin(0.073);
111  RDHFOmegac->SetProdDcaV0PiToPrimVertexMin(0.073);
112  RDHFOmegac->SetProdXiCosineOfPoiningAngleMin(0.9821);
113  RDHFOmegac->SetProdV0CosineOfPoiningAngleXiMin(0.951);
114  RDHFOmegac->SetProdCascNTPCClustersMin(0.);
115 
116  RDHFOmegac->SetUseCascadePID(kTRUE);
117  AliAODPidHF* pidObjcascpi=new AliAODPidHF();
118  Double_t sigmascascpi[5]={4.,0.,0.,0.,0.};
119  pidObjcascpi->SetSigma(sigmascascpi);
120  pidObjcascpi->SetTPC(kTRUE);
121  RDHFOmegac->SetPidCascPi(pidObjcascpi);
122 
123  AliAODPidHF* pidObjcascpr=new AliAODPidHF();
124  Double_t sigmascascpr[5]={4.,0.,0.,0.,0.};
125  pidObjcascpr->SetSigma(sigmascascpr);
126  pidObjcascpr->SetTPC(kTRUE);
127  RDHFOmegac->SetPidCascPr(pidObjcascpr);
128 
129  AliAODPidHF* pidObjcascka=new AliAODPidHF();
130  Double_t sigmascascka[5]={4.,0.,0.,0.,0.};
131  pidObjcascka->SetSigma(sigmascascka);
132  pidObjcascka->SetTPC(kTRUE);
133  RDHFOmegac->SetPidCascKa(pidObjcascka);
134 
135  cout<<"This is the (anal) object I'm going to save:"<<endl;
136  RDHFOmegac->PrintAll();
137  TFile* fout=new TFile("eleOmegaCuts.root","RECREATE");
138  fout->cd();
139  RDHFOmegac->Write();
140  fout->Close();
141  delete fout;
142 
143 }
void SetNPtBins(Int_t nptBins)
Definition: AliRDHFCuts.h:391
double Double_t
Definition: External.C:58
void SetMaxVtxZ(Float_t z=1e6)
Definition: AliRDHFCuts.h:61
void SetUsePhysicsSelection(Bool_t use=kTRUE)
Definition: AliRDHFCuts.h:351
void SetPidHF(AliAODPidHF *pidObj)
see enum below
Definition: AliRDHFCuts.h:215
void SetTOF(Bool_t tof)
Definition: AliAODPidHF.h:95
int Int_t
Definition: External.C:63
void SetCuts(Int_t nVars, Int_t nPtBins, Float_t **cutsRD)
void ResetMaskAndEnableMBTrigger()
Definition: AliRDHFCuts.h:77
float Float_t
Definition: External.C:68
void SetSigma(Double_t *sigma)
Definition: AliAODPidHF.h:39
void SetUsePID(Bool_t flag=kTRUE)
Definition: AliRDHFCuts.h:209
virtual void PrintAll() const
void makeInputAliAnalysisTaskSEOmegac2eleOmega()
void SetPtBins(Int_t nPtBinLimits, Float_t *ptBinLimits)
void SetMatch(Int_t match)
Definition: AliAODPidHF.h:98
void AddTrackCuts(const AliESDtrackCuts *cuts)
Definition: AliRDHFCuts.h:207
void SetTPC(Bool_t tpc)
Definition: AliAODPidHF.h:94
TFile * fout
input train file
void SetTriggerClass(TString trclass0, TString trclass1="")
Definition: AliRDHFCuts.h:197
Int_t nptbins