AliAnalysisTask *AddTaskHFEnpepPb(){\r
- // Switches\r
- Bool_t kPhotonic = kTRUE;\r
\r
- // Default settings (TOF-TPC 7 TeV pp paper)\r
- const int kDefTPCcl = 120;\r
+ // Default settings (TOF-TPC pPb)\r
+ const int kDefTPCcl = 110;\r
const int kDefTPCclPID = 80;\r
const int kDefITScl = 4;\r
const double kDefDCAr = 1.;\r
const double kDefDCAz = 2.;\r
- const double kDefTPCs = 0.026;\r
- const double kDefTPCu = 2.8;\r
+ const double kDefTPCs = 0.0;\r
+ const double kDefTPCu = 3.0;\r
const double kDefTOFs = 3.;\r
\r
// Default setting for the associated electron for the NonPhotonic Analysis\r
const double kassTPCSminus = -3.0;\r
const double kassTPCSplus = 3.0;\r
\r
+ enum{\r
+ kHFEV0A = 1,\r
+ kHFEV0M = 2,\r
+ kHFECL1 = 3,\r
+ kHFEZNA = 4\r
+ };\r
+\r
//get the current analysis manager\r
AliAnalysisManager *mgr = AliAnalysisManager::GetAnalysisManager();\r
if (!mgr) {\r
\r
//@@ 0 @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@\r
\r
- // Remember: (e.g. for 120 clusters) This is only an example to show how to calculate!\r
- // effective mean m0=-0.113\r
- // width w=1.03\r
- // cut --> nsigma*w + m0\r
- // e.g. 45% 0.122 sigma --> 0.122*1.03-0.113 = 0.013\r
-\r
- if(kPhotonic)\r
- {\r
- // Task for pp @ 7 TeV\r
- //RegisterTaskNPPID2( MCthere, kDefTPCcl, kDefTPCclPID, kDefITScl, kDefDCAr, kDefDCAz, kDefTPCs, kDefTPCu, kDefTOFs, AliHFEextraCuts::kFirst, kTRUE, kassETA, kassITS, kassTPCcl, kassTPCPIDcl, kassDCAr, kassDCAz, kassTPCSminus, kassTPCSplus);\r
-\r
- // task for pPb @ 5.023 TeV\r
- //RegisterTaskNPPID2( MCthere, 110, 80, 3, 1, 2, 0.045, 2.685, 3, AliHFEextraCuts::kBoth, kTRUE, kassETA, kassITS, kassTPCcl, kassTPCPIDcl, kassDCAr, kassDCAz, kassTPCSminus, kassTPCSplus);\r
-\r
- //task for pp @ 2.76 TeV\r
- RegisterTaskNPPID2( MCthere, 110, 80, 3, 1, 2, -1.35, 2.45, 3, AliHFEextraCuts::kBoth, kTRUE, kassETA, kassITS, kassTPCcl, kassTPCPIDcl, kassDCAr, kassDCAz, kassTPCSminus, kassTPCSplus);\r
+ Double_t dEdxlm[12], dEdxhm[12], dEdxaclm[12], dEdxachm[12];\r
+ for(int icent = 0; icent < 12; icent++){\r
+ dEdxlm[icent] = kDefTPCs;\r
+ dEdxhm[icent] = kDefTOFs;\r
+ dEdxaclm[icent] = kassTPCSminus;\r
+ dEdxachm[icent] = kassTPCSplus;\r
}\r
\r
+ RegisterTaskNPEpPb( MCthere, kDefTPCcl, kDefTPCclPID, kDefITScl, kDefDCAr, kDefDCAz, dEdxlm, dEdxhm, kDefTOFs, AliHFEextraCuts::kBoth, kHFEV0A, kassETA, kassITS, kassTPCcl, kassTPCPIDcl, kassDCAr, kassDCAz, dEdxaclm, dEdxachm);\r
+ RegisterTaskNPEpPb( MCthere, kDefTPCcl, kDefTPCclPID, kDefITScl, kDefDCAr, kDefDCAz, dEdxlm, dEdxhm, kDefTOFs, AliHFEextraCuts::kBoth, kHFEV0M, kassETA, kassITS, kassTPCcl, kassTPCPIDcl, kassDCAr, kassDCAz, dEdxaclm, dEdxachm);\r
+ RegisterTaskNPEpPb( MCthere, kDefTPCcl, kDefTPCclPID, kDefITScl, kDefDCAr, kDefDCAz, dEdxlm, dEdxhm, kDefTOFs, AliHFEextraCuts::kBoth, kHFECL1, kassETA, kassITS, kassTPCcl, kassTPCPIDcl, kassDCAr, kassDCAz, dEdxaclm, dEdxachm);\r
+ RegisterTaskNPEpPb( MCthere, kDefTPCcl, kDefTPCclPID, kDefITScl, kDefDCAr, kDefDCAz, dEdxlm, dEdxhm, kDefTOFs, AliHFEextraCuts::kBoth, kHFEZNA, kassETA, kassITS, kassTPCcl, kassTPCPIDcl, kassDCAr, kassDCAz, dEdxaclm, dEdxachm);\r
+\r
return NULL;\r
}\r
\r
//===============================================================================\r
\r
-AliAnalysisTask *RegisterTaskNPPID2( Bool_t useMC, Int_t tpcCls=120, Int_t tpcClsPID=80, Int_t itsCls=4, Double_t dcaxy=1.0, Double_t dcaz=2.0, Double_t tpcs=-0.0113, Double_t tpcu=3.09, Double_t tofs=3., Int_t itshitpixel=0, Bool_t kNoPhotonic=kFALSE, Double_t assETA=0.8, Int_t assITS=2, Int_t assTPCcl=100, Int_t assTPCPIDcl=80, Double_t assDCAr=1.0, Double_t assDCAz=2.0, Double_t assTPCSminus=-3.0, Double_t assTPCSplus=3.0 )\r
+AliAnalysisTask *RegisterTaskNPEpPb(Bool_t useMC, \r
+ Int_t tpcCls=120, Int_t tpcClsPID=80, \r
+ Int_t itsCls=4, Double_t dcaxy=1.0, Double_t dcaz=2.0, \r
+ Double_t *tpcdEdxcutlow=NULL, Double_t *tpcdEdxcuthigh=NULL, \r
+ Double_t tofs=3., Int_t itshitpixel =AliHFEextraCuts::kBoth, Int_t icent=1,\r
+ Double_t assETA=0.8, Int_t assITS=2, Int_t assTPCcl=100, \r
+ Int_t assTPCPIDcl=80, Double_t assDCAr=1.0, Double_t assDCAz=2.0, \r
+ Double_t *assTPCSminus = NULL, Double_t *assTPCSplus=NULL )\r
{\r
+\r
+ Int_t iassETA = (Int_t)(assETA*10);\r
+ Int_t iassDCAr = (Int_t)(assDCAr*10);\r
+ Int_t iassDCAz = (Int_t)(assDCAz*10);\r
+ Int_t iassTPCSminus = assTPCSminus ? (Int_t)(assTPCSminus[0]*10) : 0;\r
+ Int_t iassTPCSplus = assTPCSplus ? (Int_t)(assTPCSplus[0]*10) : 0;\r
+\r
+ if (icent == 2) TString cesti("V0M");\r
+ else if (icent == 3) TString cesti("CL1");\r
+ else if (icent == 4) TString cesti("ZNA");\r
+ else TString cesti("V0A");\r
+\r
+ TString appendix(TString::Format("PhotonicEta%dITS%dTPCcl%dTPCPIDcl%dDCAr%dDCAz%dTPCSminus%dTPCSplus%d%s", iassETA, assITS, assTPCcl, assTPCPIDcl, iassDCAr, iassDCAz, iassTPCSminus, iassTPCSplus, cesti.Data()));\r
+ printf("Add macro appendix %s\n", appendix.Data());\r
+\r
gROOT->LoadMacro("$ALICE_ROOT/PWGHF/hfe/macros/configs/pPb/ConfigHFEnpepPb.C");\r
\r
AliAnalysisManager *mgr = AliAnalysisManager::GetAnalysisManager();\r
AliAnalysisDataContainer *cinput = mgr->GetCommonInputContainer();\r
- AliAnalysisTaskHFE *task = ConfigHFEnpepPb(useMC, tpcCls, tpcClsPID, itsCls, dcaxy, dcaz, tpcs, tpcu, tofs, itshitpixel, kNoPhotonic, assETA, assITS, assTPCcl, assTPCPIDcl, assDCAr, assDCAz, assTPCSminus, assTPCSplus);\r
+ AliAnalysisTaskHFE *task = ConfigHFEnpepPb(useMC, appendix, tpcCls, tpcClsPID, itsCls, dcaxy, dcaz, tpcdEdxcutlow, tpcdEdxcuthigh, tofs, 0, itshitpixel, icent, assETA, assITS, assTPCcl, assTPCPIDcl, assDCAr, assDCAz, assTPCSminus, assTPCSplus);\r
task->SetESDAnalysis();\r
\r
if (useMC) task->SetHasMCData(kTRUE);\r
\r
task->SelectCollisionCandidates(AliVEvent::kINT7);\r
\r
- Int_t idcaxy = (Int_t)(dcaxy*10.);\r
- Int_t idcaz = (Int_t)(dcaz*10.);\r
- Int_t itpcs = (Int_t)(tpcs*1000.);\r
- Int_t itofs = (Int_t)(tofs*10.);\r
- Int_t ipixelany = itshitpixel;\r
-\r
- Int_t iNoPhotonic = 0;\r
- if(kNoPhotonic) iNoPhotonic = 1;\r
-\r
- Int_t iassETA = (Int_t)(assETA*10);\r
- Int_t iassDCAr = (Int_t)(assDCAr*10);\r
- Int_t iassDCAz = (Int_t)(assDCAz*10);\r
- Int_t iassTPCSminus = (Int_t)(assTPCSminus*10);\r
- Int_t iassTPCSplus = (Int_t)(assTPCSplus*10);\r
-\r
- TString appendix(TString::Format("Photonic%dEta%dITS%dTPCcl%dTPCPIDcl%dDCAr%dDCAz%dTPCSminus%dTPCSplus%d", iNoPhotonic, iassETA, assITS, assTPCcl, assTPCPIDcl, iassDCAr, iassDCAz, iassTPCSminus, iassTPCSplus));\r
- //TString appendix(TString::Format("TPCc%dTPCp%dITS%dDCAr%dz%dTPCs%dTOFs%dpa%dNoPhotonic%d",tpcCls,tpcClsPID,itsCls,idcaxy,idcaz,itpcs,itofs,ipixelany,iNoPhotonic));\r
- printf("Add macro appendix %s\n", appendix.Data());\r
-\r
TString containerName = mgr->GetCommonFileName();\r
- containerName += ":HFEpPb";\r
+ containerName += ":HFEtask";\r
containerName += appendix.Data();\r
printf("container name: %s\n", containerName.Data());\r
\r
-AliAnalysisTaskHFE* ConfigHFEnpepPb(Bool_t useMC, UChar_t TPCcl=70, UChar_t TPCclPID = 80, UChar_t ITScl=3, Double_t DCAxy=1000., Double_t DCAz=1000., Double_t TPCs=0., Double_t TPCu=3.09, Double_t TOFs=3., Int_t itshitpixel = 0, Bool_t kNoPhotonic = kFALSE, Double_t assETA=0.8, Int_t assITS=2, Int_t assTPCcl=100, Int_t assTPCPIDcl=80, Double_t assDCAr=1.0, Double_t assDCAz=2.0, Double_t assTPCSminus=-3.0, Double_t assTPCSplus=3.0 )\r
+AliAnalysisTaskHFE* ConfigHFEnpepPb(Bool_t useMC, TString appendix,\r
+ UChar_t TPCcl=70, UChar_t TPCclPID = 80, \r
+ UChar_t ITScl=3, Double_t DCAxy=1000., Double_t DCAz=1000., \r
+ Double_t* tpcdEdxcutlow=NULL, Double_t* tpcdEdxcuthigh=NULL, \r
+ Double_t TOFs=3., Int_t TOFmis=0, \r
+ Int_t itshitpixel = 0, Int_t icent, \r
+ Double_t assETA=0.8, Int_t assITS=2, \r
+ Int_t assTPCcl=100, Int_t assTPCPIDcl=80, \r
+ Double_t assDCAr=1.0, Double_t assDCAz=2.0, \r
+ Double_t *assTPCSminus=NULL, Double_t *assTPCSplus=NULL)\r
{\r
-\r
- //\r
- // HFE task configuration PID2 (TOF-TPC only!)\r
- //\r
-\r
- Bool_t kAnalyseTaggedTracks = kFALSE;\r
- Int_t ptbin = 0;\r
- Double_t IpSig = 3.;\r
- Bool_t prodcut = kFALSE;\r
- Bool_t ipOpp = kFALSE;\r
- Bool_t mcstr = kFALSE;\r
-\r
- Int_t iDCAxy = (Int_t)(DCAxy*10.);\r
- Int_t iDCAz = (Int_t)(DCAz*10.);\r
- Int_t iTPCs = (Int_t)(TPCs*1000.);\r
- Int_t iTOFs = (Int_t)(TOFs*10.);\r
- Int_t iIpSig = (Int_t)(IpSig*10.);\r
- Int_t iIpOpp = 0;\r
- Int_t iProdCut = 1;\r
- Int_t iMCStr = 0;\r
- Int_t iPixelAny = itshitpixel;\r
- Int_t iNoPhotonic = 0;\r
- if(ipOpp)iIpOpp = 1;\r
- if(prodcut) iProdCut = 0;\r
- if(mcstr) iMCStr = 1;\r
- if(kNoPhotonic) iNoPhotonic = 1;\r
-\r
- TString appendixx(TString::Format("t%di%dr%dz%ds%dt%dpa%dptbin%dNoPhotonic%d",TPCcl,ITScl,iDCAxy,iDCAz,iTPCs,iTOFs,iPixelAny,ptbin,iNoPhotonic));\r
- printf("appendixx %s\n", appendixx.Data());\r
-\r
- AliHFEcuts *hfecuts = new AliHFEcuts(Form("hfeCutsPID2%s",appendixx.Data()),"HFE cuts TOF TPC");\r
+ Bool_t kAnalyseTaggedTracks = kTRUE;\r
+ \r
+ //***************************************//\r
+ // Setting up the HFE cuts //\r
+ //***************************************//\r
+ \r
+ AliHFEcuts *hfecuts = new AliHFEcuts(appendix,"HFE cuts pPb");\r
//hfecuts->SetQAOn();\r
hfecuts->CreateStandardCuts();\r
hfecuts->SetMinNClustersTPC(TPCcl);\r
hfecuts->SetCutITSpixel(itshitpixel);\r
hfecuts->SetCheckITSLayerStatus(kFALSE);\r
hfecuts->SetEtaRange(0.8);\r
- Bool_t ipCharge = kFALSE;\r
- if(IpSig<0)ipCharge = kTRUE;\r
-\r
- // beauty\r
- hfecuts->SetIPcutParam(0,0,0,0,kFALSE,ipCharge,ipOpp);\r
- \r
- if(TMath::Abs(IpSig)>100&&TMath::Abs(IpSig)<300){\r
- hfecuts->SetIPcutParam(0.0064,0.078,-0.56,0,kFALSE,ipCharge,ipOpp); // used Carlo's old parameter (new: 0.011+0.077*exp(-0.65*pt))\r
- }\r
- else if(TMath::Abs(IpSig)>300&&TMath::Abs(IpSig)<320){\r
- hfecuts->SetIPcutParam(0.00978806,0.0860193,-0.567707,0,kFALSE,ipCharge,ipOpp);\r
- }\r
- else if(TMath::Abs(IpSig)>320&&TMath::Abs(IpSig)<340){\r
- hfecuts->SetIPcutParam(0.00359394,0.0707044,-0.569791,0,kFALSE,ipCharge,ipOpp);\r
- }\r
- else if(TMath::Abs(IpSig)>340&&TMath::Abs(IpSig)<360){\r
- hfecuts->SetIPcutParam(0.00807899,0.0818196,-0.563656,0,kFALSE,ipCharge,ipOpp);\r
- }\r
- else if(TMath::Abs(IpSig)>360&&TMath::Abs(IpSig)<380){\r
- hfecuts->SetIPcutParam(0.005207,0.0747452,-0.569437,0,kFALSE,ipCharge,ipOpp);\r
- }\r
- else if(TMath::Abs(IpSig)>380&&TMath::Abs(IpSig)<400){\r
- hfecuts->SetIPcutParam(0.011549,0.0899016,-0.573654,0,kFALSE,ipCharge,ipOpp);\r
- }\r
- else if(TMath::Abs(IpSig)>400&&TMath::Abs(IpSig)<420){\r
- hfecuts->SetIPcutParam(0.00166944,0.066695,-0.556119,0,kFALSE,ipCharge,ipOpp);\r
- }\r
- else if(TMath::Abs(IpSig)>420&&TMath::Abs(IpSig)<440){\r
- hfecuts->SetIPcutParam(0.0129519,0.0918703,-0.557745,0,kFALSE,ipCharge,ipOpp);\r
- }\r
- else if(TMath::Abs(IpSig)>440&&TMath::Abs(IpSig)<460){\r
- hfecuts->SetIPcutParam(0.0000824499,0.0629347,-0.554436,0,kFALSE,ipCharge,ipOpp);\r
- }\r
-\r
- if(prodcut) hfecuts->SetProductionVertex(0,100,0,100);\r
- else {\r
- if((iPixelAny==AliHFEextraCuts::kAny) || (iPixelAny==AliHFEextraCuts::kSecond)) hfecuts->SetProductionVertex(0,7,0,7);\r
- }\r
- \r
- //hfecuts->SetSigmaToVertex(DCAsi);\r
hfecuts->SetMaxImpactParam(DCAxy,DCAz);\r
- hfecuts->SetTOFPIDStep(kTRUE);\r
- //hfecuts->SetQAOn();\r
hfecuts->SetUseMixedVertex(kTRUE);\r
hfecuts->SetVertexRange(10.);\r
\r
- AliAnalysisTaskHFE *task = new AliAnalysisTaskHFE(Form("HFEanalysisPID2%s",appendixx.Data()));\r
+ // TOF settings:\r
+ Int_t usetof=0;\r
+ Bool_t kTOFmis=kFALSE;\r
+ if (TOFs>0.){\r
+ usetof = 1;\r
+ printf("CONFIGURATION FILE: TOF is used \n");\r
+ hfecuts->SetTOFPIDStep(kTRUE);\r
+ printf("CONFIGURATION FILE: TOF PID step is requested !!!! \n");\r
+ if (TOFmis>0){\r
+ kTOFmis = kTRUE;\r
+ printf("CONFIGURATION FILE: TOF mismatch rejection is set ON \n");\r
+ }\r
+ }\r
+\r
+ //***************************************//\r
+ // Setting up the task //\r
+ //***************************************//\r
+\r
+ AliAnalysisTaskHFE *task = new AliAnalysisTaskHFE(Form("HFEtask%s",appendix.Data()));\r
printf("task %p\n", task);\r
+ task->SetpPbAnalysis();\r
task->SetHFECuts(hfecuts);\r
- task->SetRemovePileUp(kTRUE);\r
+ task->SetRemovePileUp(kFALSE);\r
task->GetPIDQAManager()->SetHighResolutionHistos();\r
\r
// Setttings for pPb\r
hfecuts -> SetUseCorrelationVertex();\r
hfecuts -> SetSPDVtxResolutionCut();\r
\r
+ //***************************************//\r
+ // Variable manager //\r
+ //***************************************//\r
+\r
// Define Variables\r
- if(ptbin==1){\r
- Double_t ptbinning[19] = {0., 0.1, 0.3, 0.5, 0.7, 0.9, 1.1, 1.3, 1.5, 2., 2.5, 3., 4., 5., 6., 8., 12., 16., 20.};\r
- }\r
- else{\r
- Double_t ptbinning[36] = {0., 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1., 1.1, 1.2, 1.3, 1.4, 1.5, 1.75, 2., 2.25, 2.5, 2.75, 3., 3.5, 4., 4.5, 5., 5.5, 6., 7., 8., 10., 12., 14., 16., 18., 20.};\r
- }\r
+ Double_t ptbinning[36] = {0., 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1., 1.1, 1.2, 1.3, 1.4, 1.5, 1.75, 2., 2.25, 2.5, 2.75, 3., 3.5, 4., 4.5, 5., 5.5, 6., 7., 8., 10., 12., 14., 16., 18., 20.};\r
Double_t etabinning[17] = {-0.8, -0.7, -0.6, -0.5, -0.4, -0.3, -0.2, -0.1, 0., 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8};\r
\r
Int_t sizept=(sizeof(ptbinning)/sizeof(double))-1;\r
vm->AddVariable("phi",21, -0, 2*TMath::Pi());\r
vm->AddVariable("charge");\r
vm->AddVariable("source");\r
- //vm->AddVariable("centrality");\r
-\r
- // Background Subtraction ---------------------------------------------------------------------------------\r
- if(kNoPhotonic)\r
- {\r
- AliHFENonPhotonicElectron *backe = new AliHFENonPhotonicElectron(Form("HFEBackGroundSubtractionPID2%s",appendixx.Data()),"Background subtraction"); //appendix\r
- //Setting the Cuts for the Associated electron-pool\r
-/*\r
- AliESDtrackCuts *hfeBackgroundCuts = new AliESDtrackCuts();\r
- hfeBackgroundCuts->SetAcceptKinkDaughters(kFALSE);\r
- hfeBackgroundCuts->SetRequireTPCRefit(kTRUE);\r
- hfeBackgroundCuts->SetRequireITSRefit(kTRUE);\r
- hfeBackgroundCuts->SetMinNClustersITS(2);\r
- hfeBackgroundCuts->SetEtaRange(-0.8,0.8);\r
- hfeBackgroundCuts->SetRequireSigmaToVertex(kTRUE);\r
- hfeBackgroundCuts->SetMaxChi2PerClusterTPC(4);\r
- hfeBackgroundCuts->SetMinNClustersTPC(100);\r
- hfeBackgroundCuts->SetPtRange(0.1,1e10);\r
-*/\r
- AliHFEcuts *hfeBackgroundCuts = new AliHFEcuts(Form("HFEBackSub%s",appendixx.Data()),"Background sub Cuts");\r
- hfeBackgroundCuts->SetEtaRange(assETA);\r
- hfeBackgroundCuts->SetPtRange(0.1,1e10);\r
-\r
- hfeBackgroundCuts->SetMaxChi2perClusterTPC(4);\r
- hfeBackgroundCuts->SetMinNClustersITS(assITS);\r
- hfeBackgroundCuts->SetMinNClustersTPC(assTPCcl);\r
- hfeBackgroundCuts->SetMinNClustersTPCPID(assTPCPIDcl);\r
-\r
- //hfeBackgroundCuts->SetMaxImpactParam(assDCAr,assDCAz);\r
-\r
- //hfeBackgroundCuts->SetMinRatioTPCclusters(...); //TODO needed ???\r
- //hfeBackgroundCuts->SetRequireSigmaToVertex();\r
- //hfeBackgroundCuts->SetDebugLevel(2);\r
- hfeBackgroundCuts->SetQAOn(); // QA\r
-\r
- AliHFEpid *pidbackground = backe->GetPIDBackground();\r
- if(useMC) pidbackground->SetHasMCData(kTRUE);\r
- //pidbackground->AddDetector("TOF", 0);\r
- pidbackground->AddDetector("TPC", 0);\r
- pidbackground->ConfigureTPCasymmetric(0.,20.,assTPCSminus,assTPCSplus);\r
- //pidbackground->ConfigureTOF(3.);\r
- backe->GetPIDBackgroundQAManager()->SetHighResolutionHistos();\r
- backe->SetHFEBackgroundCuts(hfeBackgroundCuts);\r
-\r
- task->SetHFEBackgroundSubtraction(backe);\r
+ vm->AddVariable("centrality");\r
\r
- }\r
- //-----------------------------------------------------------------------------------------------------------\r
+ // Determine the centrality estimator\r
+ task->SetCentralityEstimator("V0A");\r
+ if (icent == 2) task->SetCentralityEstimator("V0M");\r
+ else if (icent == 3) task->SetCentralityEstimator("CL1");\r
+ else if (icent == 4) task->SetCentralityEstimator("ZNA");\r
\r
- if(!useMC){\r
- // New background model (LHC10d pass2)\r
- TF1 *hBackground = new TF1("hadronicBackgroundFunction", "TMath::Exp(([0]/(x**1.5))+[1])", 0., 20.);\r
- // These settings assume that the default is a cut on .ge.120 TPC clusters (Sep 27, 2011)\r
- hBackground->SetParameter(0, -55.18);\r
- hBackground->SetParameter(1, -0.0026);\r
- if (TPCcl == 100){\r
- hBackground->SetParameter(0, -39.5);\r
- hBackground->SetParameter(1, -0.438);\r
- } elseif (TPCcl == 140){\r
- hBackground->SetParameter(0, -82.11);\r
- hBackground->SetParameter(1, 1.138);\r
- }\r
+ // For the moment, remove the part dedicated to the background subtraction.\r
+ // It will be implemented in a different way, reading it from a root file.\r
+ \r
\r
- task->SetBackGroundFactorsFunction(hBackground);\r
- }\r
+ //***************************************//\r
+ // Configure the PID //\r
+ //***************************************//\r
\r
// Define PID\r
AliHFEpid *pid = task->GetPID();\r
if(useMC) pid->SetHasMCData(kTRUE);\r
- pid->AddDetector("TOF", 0);\r
- pid->AddDetector("TPC", 1);\r
- // HERE PUT THE STRAIGHT CUT\r
- Double_t params[4];\r
- char *cutmodel;\r
- if(useMC){\r
- // Monte-Carlo needs modelling of the falling mean with momentum at low momentum\r
- // for high momentum it is consistent with a flat -0.94\r
- cutmodel = "expo(0)+pol1(2)";//[0]*TMath::Exp([1]*x) + [2] + [3]*x";\r
- Double_t paramsMC[4] = {-1.00625e-01, -2.09446e+00, -4.71247e-01, 1.80301e-02};\r
- for(int ipar = 0; ipar < 4; ipar++) params[ipar] = paramsMC[ipar];\r
+\r
+ if (usetof){\r
+ pid->AddDetector("TOF", 0);\r
+ pid->AddDetector("TPC", 1);\r
} else {\r
- // Data is consistent with a flat constant: (Sep 27, 2011)\r
- // 100 clusters: mean = -0.076, width = 1.035\r
- // 120 clusters: mean = -0.113, width = 1.03\r
- // 140 clusters: mean = -0.093, width = 1.004\r
- cutmodel = "pol0(0)";\r
- params[0] = TPCs;\r
+ pid->AddDetector("TPC", 0);\r
+ }\r
+ \r
+ // Configure TPC PID\r
+ if(!useMC){\r
+ Double_t paramsTPCdEdxcutlow[12] ={0.0, 0.0, 0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0,0.0};\r
+ if(tpcdEdxcutlow) memcpy(paramsTPCdEdxcutlow,tpcdEdxcutlow,sizeof(paramsTPCdEdxcutlow));\r
+\r
+ Double_t paramsTPCdEdxcuthigh[12] ={3.0, 3.0, 3.0,3.0,3.0,3.0,3.0,3.0,3.0,3.0,3.0,3.0};\r
+ if(tpcdEdxcuthigh) memcpy(paramsTPCdEdxcuthigh,tpcdEdxcuthigh,sizeof(paramsTPCdEdxcuthigh));\r
+ \r
+ char *cutmodel;\r
+ cutmodel="pol0";\r
+ \r
+ for(Int_t a=0;a<11;a++)\r
+ {\r
+ // cout << a << " " << paramsTPCdEdxcut[a] << endl;\r
+ Double_t tpcparamlow[1]={paramsTPCdEdxcutlow[a]};\r
+ Float_t tpcparamhigh=paramsTPCdEdxcuthigh[a];\r
+ pid->ConfigureTPCcentralityCut(a,cutmodel,tpcparamlow,tpcparamhigh);\r
+ }\r
+ }\r
\r
+ // Configure TOF PID\r
+ if (usetof){\r
+ pid->ConfigureTOF(TOFs);\r
+ AliHFEpidTOF *tofpid = pid->GetDetPID(AliHFEpid::kTOFpid);\r
+ if (kTOFmis){\r
+ tofpid->SetRejectTOFmismatch();\r
+ }\r
}\r
- pid->ConfigureTOF(TOFs);\r
- pid->ConfigureTPCdefaultCut(cutmodel, params, TPCu);\r
\r
// To make different upper TOF cut to see contamination effect\r
// The below two lines should be removed after this check\r
//AliHFEpidTOF *tofpid = pid->GetDetPID(AliHFEpid::kTOFpid);\r
//if(TOFs<3.) tofpid->SetTOFnSigmaBand(-3,TOFs); //only to check the assymmetric tof cut\r
+ \r
+ //***************************************//\r
+ // Configure NPE plugin //\r
+ //***************************************//\r
+\r
+ AliHFENonPhotonicElectron *backe = new AliHFENonPhotonicElectron(Form("HFEBackGroundSubtractionPID2%s",appendix.Data()),"Background subtraction"); //appendix\r
+ //Setting the Cuts for the Associated electron-pool\r
+ AliHFEcuts *hfeBackgroundCuts = new AliHFEcuts(Form("HFEBackSub%s",appendix.Data()),"Background sub Cuts");\r
+ hfeBackgroundCuts->SetEtaRange(assETA);\r
+ hfeBackgroundCuts->SetPtRange(0.1,1e10);\r
+\r
+ hfeBackgroundCuts->SetMaxChi2perClusterTPC(4);\r
+ hfeBackgroundCuts->SetMinNClustersITS(assITS);\r
+ hfeBackgroundCuts->SetMinNClustersTPC(assTPCcl);\r
+ hfeBackgroundCuts->SetMinNClustersTPCPID(assTPCPIDcl);\r
+ hfeBackgroundCuts->SetQAOn(); // QA\r
+\r
+ AliHFEpid *pidbackground = backe->GetPIDBackground();\r
+ if(useMC) pidbackground->SetHasMCData(kTRUE);\r
+ pidbackground->AddDetector("TPC", 0);\r
+ Double_t paramsTPCdEdxcutlowAssoc[12] ={-3.0,-3.0,-3.0,-3.0,-3.0,-3.0,-3.0,-3.0,-3.0,-3.0,-3.0,-3.0};\r
+ if(assTPCSminus) memcpy(paramsTPCdEdxcutlowAssoc,assTPCSminus,sizeof(paramsTPCdEdxcutlowAssoc));\r
+\r
+ Double_t paramsTPCdEdxcuthighAssoc[12] ={3.0, 3.0, 3.0,3.0,3.0,3.0,3.0,3.0,3.0,3.0,3.0,3.0};\r
+ if(assTPCSplus) memcpy(paramsTPCdEdxcuthighAssoc,assTPCSplus,sizeof(paramsTPCdEdxcuthighAssoc));\r
+ \r
+ char *cutmodelAssoc;\r
+ cutmodelAssoc="pol0";\r
+ for(Int_t a=0;a<11;a++)\r
+ {\r
+ // cout << a << " " << paramsTPCdEdxcut[a] << endl;\r
+ Double_t tpcparamlow[1]={paramsTPCdEdxcutlowAssoc[a]};\r
+ Float_t tpcparamhigh=paramsTPCdEdxcuthighAssoc[a];\r
+ pidbackground->ConfigureTPCcentralityCut(a,cutmodelAssoc,tpcparamlow,tpcparamhigh);\r
+ }\r
+ backe->GetPIDBackgroundQAManager()->SetHighResolutionHistos();\r
+ backe->SetHFEBackgroundCuts(hfeBackgroundCuts);\r
+\r
+ task->SetHFEBackgroundSubtraction(backe);\r
+\r
+ //***************************************//\r
+ // V0 tagged tracks //\r
+ //***************************************//\r
\r
if(kAnalyseTaggedTracks){\r
AliHFEcuts *v0trackCuts = new AliHFEcuts("V0trackCuts", "Track Cuts for tagged track Analysis");\r
printf("task %p\n", task);\r
task->SetQAOn(AliAnalysisTaskHFE::kPIDqa);\r
task->SetQAOn(AliAnalysisTaskHFE::kMCqa);\r
- if(kNoPhotonic) task->SwitchOnPlugin(AliAnalysisTaskHFE::kNonPhotonicElectron);\r
+ task->SwitchOnPlugin(AliAnalysisTaskHFE::kNonPhotonicElectron);\r
task->SwitchOnPlugin(AliAnalysisTaskHFE::kDEstep);\r
- if(useMC && mcstr) task->SetDebugStreaming();\r
\r
printf("*************************************\n");\r
printf("Configuring standard Task:\n");\r