3 //------------------------------------
4 // Configuration macro example:
6 // Do prompt photon - parton correlation analysis with ESDs
7 // First find photons with AliAnaPhoton, then
8 // isolate them with AliAnaParticleIsolation and finally correlate
9 // them with AliAnaParticlePartonCorrelation
11 // Author : Gustavo Conesa Balbastre (INFN-LNF)
12 //------------------------------------
14 AliAnaPartCorrMaker* ConfigAnalysis()
17 // Configuration goes here
19 printf("======================== \n");
20 printf("ConfigAnalysis() \n");
21 printf("======================== \n");
24 //Detector Fidutial Cuts
25 AliFidutialCut * fidCut = new AliFidutialCut();
26 fidCut->DoCTSFidutialCut(kTRUE) ;
27 fidCut->DoEMCALFidutialCut(kTRUE) ;
28 fidCut->DoPHOSFidutialCut(kTRUE) ;
30 fidCut->SetSimpleCTSFidutialCut(0.9,0.,360.);
31 fidCut->SetSimpleEMCALFidutialCut(0.7,80.,190.);
32 fidCut->SetSimplePHOSFidutialCut(0.13,220.,320.);
36 //-----------------------------------------------------------
38 //-----------------------------------------------------------
39 AliCaloTrackESDReader *reader = new AliCaloTrackESDReader();
42 //Switch on or off the detectors information that you want
43 reader->SwitchOnEMCAL();
44 reader->SwitchOnCTS();
45 reader->SwitchOnPHOS();
48 reader->SetEMCALPtMin(0.5);
49 reader->SetPHOSPtMin(0.5);
50 reader->SetCTSPtMin(0.2);
52 reader->SetFidutialCut(fidCut);
56 //---------------------------------------------------------------------
58 //---------------------------------------------------------------------
59 //<<<< first analysis >>> select the photons
60 //Detector Fidutial Cuts for analysis part
61 AliFidutialCut * fidCut2 = new AliFidutialCut();
62 fidCut2->DoCTSFidutialCut(kFALSE) ;
63 fidCut2->DoEMCALFidutialCut(kTRUE) ;
64 fidCut2->DoPHOSFidutialCut(kFALSE) ;
66 fidCut2->SetSimpleCTSFidutialCut(0.9,0.,360.);
67 fidCut2->SetSimpleEMCALFidutialCut(0.7,80.,190.);
68 fidCut2->SetSimplePHOSFidutialCut(0.13,220.,320.);
71 AliCaloPID * pid = new AliCaloPID();
72 // use selection with simple weights
73 pid->SetPHOSPhotonWeight(0.7); pid->SetPHOSPi0Weight(0.7);
74 pid->SetEMCALPhotonWeight(0.7); pid->SetEMCALPi0Weight(0.7);
78 AliAnaPhoton *anaphoton = new AliAnaPhoton();
79 anaphoton->SetDebug(-1); //10 for lots of messages
80 anaphoton->SetMinPt(0.2);
81 anaphoton->SetMinDistanceToBadChannel(2, 4, 5);
82 anaphoton->SetCaloPID(pid);
83 anaphoton->SetFidutialCut(fidCut2); //More acceptance selections if needed at this level
84 anaphoton->SetCalorimeter("PHOS");
85 anaphoton->SwitchOffDataMC() ;//Access MC stack and fill more histograms
86 anaphoton->SwitchOnCaloPID();
87 anaphoton->SwitchOffCaloPIDRecalculation(); //recommended for EMCAL
88 anaphoton->SwitchOnFidutialCut();
89 anaphoton->SetOutputAODName("Photons");
90 anaphoton->SetOutputAODClassName("AliAODPWG4ParticleCorrelation");
91 //Set Histrograms bins and ranges
92 // anaphoton->SetHistoPtRangeAndNBins(0, 50, 100) ;
93 // anaphoton->SetHistoPhiRangeAndNBins(0, TMath::TwoPi(), 100) ;
94 // anaphoton->SetHistoEtaRangeAndNBins(-0.7, 0.7, 100) ;
97 // >>>> Second Analysis <<<< Isolate the photons
98 AliIsolationCut * ic = new AliIsolationCut();
100 ic->SetPtThreshold(1.);
101 ic->SetICMethod(AliIsolationCut::kPtThresIC);
104 AliAnaParticleIsolation *anaisol = new AliAnaParticleIsolation();
105 anaisol->SetDebug(-1);
106 anaisol->SetMinPt(5);
107 anaisol->SetInputAODName("Photons");
108 anaisol->SetCalorimeter("PHOS");
109 anaisol->SwitchOffDataMC() ;//Access MC stack and fill more histograms
110 //Select clusters with no pair, if both clusters with pi0 mass
111 anaisol->SwitchOffInvariantMass();
112 //anaisol->SetNeutralMesonSelection(nms);
114 anaisol->SetIsolationCut(ic);
115 //Do or not do isolation with previously produced AODs.
116 //No effect if use of SwitchOnSeveralIsolation()
117 anaisol->SwitchOffReIsolation();
119 anaisol->SwitchOffSeveralIsolation() ;
123 //<<<Third analysis>>> Isolated Photon- parton correlation
124 AliAnaParticlePartonCorrelation *anacorr = new AliAnaParticlePartonCorrelation();
125 anacorr->SetInputAODName("Photons");
126 anacorr->SetDebug(-1);
130 //---------------------------------------------------------------------
131 // Set analysis algorithm and reader
132 //---------------------------------------------------------------------
133 maker = new AliAnaPartCorrMaker();
134 maker->SetReader(reader);//pointer to reader
135 maker->AddAnalysis(anaphoton,0);
136 maker->AddAnalysis(anaisol,1);
137 maker->AddAnalysis(anacorr,2);
138 maker->SetAnaDebug(-1) ;
139 maker->SwitchOnHistogramsMaker() ;
140 //maker->SwitchOffHistogramsMaker() ;
141 maker->SwitchOnAODsMaker() ;
142 //maker->SwitchOffAODsMaker() ;
146 printf("======================== \n");
147 printf("END ConfigAnalysis() \n");
148 printf("======================== \n");