1515// / \since 01/07/2024
1616
1717#include " PWGLF/DataModel/LFResonanceTables.h"
18+
1819#include " Common/DataModel/Centrality.h"
1920#include " Common/DataModel/EventSelection.h"
2021#include " Common/DataModel/PIDResponse.h"
22+
2123#include " CommonConstants/MathConstants.h"
2224#include " CommonConstants/PhysicsConstants.h"
2325#include " DataFormatsParameters/GRPObject.h"
2426#include " Framework/ASoAHelpers.h"
25- #include " Framework/AnalysisTask.h"
2627#include " Framework/AnalysisHelpers.h"
28+ #include " Framework/AnalysisTask.h"
2729#include " Framework/runDataProcessing.h"
2830#include < Framework/Configurable.h>
29- # include " TVector2.h "
31+
3032#include " Math/LorentzVector.h"
3133#include " Math/Vector4D.h"
34+ #include " TVector2.h"
3235#include < TLorentzVector.h>
36+
3337#include < vector>
3438
3539using namespace o2 ;
@@ -42,7 +46,7 @@ using namespace o2::soa;
4246struct f0980analysis {
4347 SliceCache cache;
4448 HistogramRegistry histos{" histos" , {}, OutputObjHandlingPolicy::AnalysisObject};
45-
49+
4650 // Event selections
4751 Configurable<float > cfgMinpT{" cfgMinpT" , 0.15 , " Minimum transverse momentum for charged track" };
4852 Configurable<float > cfgMaxEta{" cfgMaxEta" , 0.8 , " Maximum pseudorapidiy for charged track" };
@@ -53,16 +57,16 @@ struct f0980analysis {
5357 Configurable<bool > cfgFindRT{" cfgFindRT" , false , " boolean for RT analysis" };
5458
5559 // Track selections
56- Configurable<bool > cfgPrimaryTrack{" cfgPrimaryTrack" , true , " Primary track selection" }; // kGoldenChi2 | kDCAxy | kDCAz
57- Configurable<bool > cfgGlobalTrack{" cfgGlobalTrack" , false , " Global track selection" }; // kGoldenChi2 | kDCAxy | kDCAz
60+ Configurable<bool > cfgPrimaryTrack{" cfgPrimaryTrack" , true , " Primary track selection" }; // kGoldenChi2 | kDCAxy | kDCAz
61+ Configurable<bool > cfgGlobalTrack{" cfgGlobalTrack" , false , " Global track selection" }; // kGoldenChi2 | kDCAxy | kDCAz
5862 Configurable<bool > cfgGlobalWoDCATrack{" cfgGlobalWoDCATrack" , true , " Global track selection without DCA" }; // kQualityTracks (kTrackType |
59- // kTPCNCls | kTPCCrossedRows |
60- // kTPCCrossedRowsOverNCls |
61- // kTPCChi2NDF | kTPCRefit |
62- // kITSNCls | kITSChi2NDF |
63- // kITSRefit | kITSHits) |
64- // kInAcceptanceTracks (kPtRange |
65- // kEtaRange)
63+ // kTPCNCls | kTPCCrossedRows |
64+ // kTPCCrossedRowsOverNCls |
65+ // kTPCChi2NDF | kTPCRefit |
66+ // kITSNCls | kITSChi2NDF |
67+ // kITSRefit | kITSHits) |
68+ // kInAcceptanceTracks (kPtRange |
69+ // kEtaRange)
6670 Configurable<bool > cfgPVContributor{" cfgPVContributor" , true , " PV contributor track selection" };
6771 Configurable<bool > cfgUseTPCRefit{" cfgUseTPCRefit" , false , " Require TPC Refit" };
6872 Configurable<bool > cfgUseITSRefit{" cfgUseITSRefit" , false , " Require ITS Refit" };
@@ -81,29 +85,29 @@ struct f0980analysis {
8185 ConfigurableAxis pTAxis{" pTAxis" , {VARIABLE_WIDTH, 0.0 , 0.1 , 0.2 , 0.3 , 0.4 , 0.5 , 0.6 , 0.8 , 1.0 , 1.5 , 2.0 , 2.5 , 3.0 , 3.5 , 4.0 , 4.5 , 5.0 , 6.0 , 7.0 , 8.0 , 10.0 , 13.0 , 20.0 }, " Transverse momentum Binning" };
8286 ConfigurableAxis centAxis{" centAxis" , {VARIABLE_WIDTH, 0.0 , 1.0 , 5.0 , 10.0 , 15.0 , 20.0 , 25.0 , 30.0 , 35.0 , 40.0 , 45.0 , 50.0 , 55.0 , 60.0 , 65.0 , 70.0 , 75.0 , 80.0 , 95.0 , 100.0 , 105.0 , 110.0 }, " Centrality Binning" };
8387
84- void init (o2::framework::InitContext&) {
88+ void init (o2::framework::InitContext&)
89+ {
8590 std::vector<double > lptBinning = {0 , 5.0 , 13.0 , 20.0 , 50.0 , 1000.0 };
86-
91+
8792 AxisSpec rtAxis = {3 , 0 , 3 };
88- AxisSpec lptAxis = {lptBinning}; // Minimum leading hadron pT selection
93+ AxisSpec lptAxis = {lptBinning}; // Minimum leading hadron pT selection
8994
9095 AxisSpec pidqaAxis = {60 , -6 , 6 };
9196 AxisSpec pTqaAxis = {200 , 0 , 20 };
92- AxisSpec phiqaAxis = {72 , 0 , o2::constants::math::TwoPI}; // Azimuthal angle axis
97+ AxisSpec phiqaAxis = {72 , 0 , o2::constants::math::TwoPI}; // Azimuthal angle axis
9398
94- AxisSpec epAxis = {10 , 0 , o2::constants::math::PI}; // Event Plane
99+ AxisSpec epAxis = {10 , 0 , o2::constants::math::PI}; // Event Plane
95100 AxisSpec epqaAxis = {200 , -o2::constants::math::PI, o2::constants::math::PI};
96101 AxisSpec epResAxis = {200 , -2 , 2 };
97102
98103 if (cfgFindRT) {
99104 histos.add (" hInvMass_f0980_US" , " unlike invariant mass" , {HistType::kTHnSparseF , {massAxis, pTAxis, centAxis, rtAxis, lptAxis}});
100105 histos.add (" hInvMass_f0980_LSpp" , " ++ invariant mass" , {HistType::kTHnSparseF , {massAxis, pTAxis, centAxis, rtAxis, lptAxis}});
101106 histos.add (" hInvMass_f0980_LSmm" , " -- invariant mass" , {HistType::kTHnSparseF , {massAxis, pTAxis, centAxis, rtAxis, lptAxis}});
102- }
103- else {
107+ } else {
104108 histos.add (" hInvMass_f0980_US_EPA" , " unlike invariant mass" , {HistType::kTHnSparseF , {massAxis, pTAxis, centAxis, epAxis}});
105109 histos.add (" hInvMass_f0980_LSpp_EPA" , " ++ invariant mass" , {HistType::kTHnSparseF , {massAxis, pTAxis, centAxis, epAxis}});
106- histos.add (" hInvMass_f0980_LSmm_EPA" , " -- invariant mass" , {HistType::kTHnSparseF , {massAxis, pTAxis, centAxis, epAxis}});
110+ histos.add (" hInvMass_f0980_LSmm_EPA" , " -- invariant mass" , {HistType::kTHnSparseF , {massAxis, pTAxis, centAxis, epAxis}});
107111 }
108112
109113 histos.add (" QA/EPhist" , " " , {HistType::kTH2F , {centAxis, epqaAxis}});
@@ -118,7 +122,7 @@ struct f0980analysis {
118122 histos.add (" QA/Nsigma_TPC_TOF" , " " , {HistType::kTH2F , {pidqaAxis, pidqaAxis}});
119123
120124 if (doprocessMCLight) {
121- histos.add (" MCL/hpT_f0980_GEN" , " generated f0 signals" , HistType::kTH1F ,{pTqaAxis});
125+ histos.add (" MCL/hpT_f0980_GEN" , " generated f0 signals" , HistType::kTH1F , {pTqaAxis});
122126 histos.add (" MCL/hpT_f0980_REC" , " reconstructed f0 signals" , HistType::kTH3F , {massAxis, pTqaAxis, centAxis});
123127 }
124128
@@ -146,7 +150,8 @@ struct f0980analysis {
146150 }
147151
148152 template <typename TrackType>
149- bool selTrack (const TrackType track) {
153+ bool selTrack (const TrackType track)
154+ {
150155 if (std::abs (track.pt ()) < cfgMinpT)
151156 return false ;
152157 if (std::fabs (track.eta ()) > cfgMaxEta)
@@ -176,7 +181,8 @@ struct f0980analysis {
176181 }
177182
178183 template <typename TrackType>
179- bool selPion (const TrackType track) {
184+ bool selPion (const TrackType track)
185+ {
180186 switch (selectType) {
181187 case 0 :
182188 if (std::fabs (track.tpcNSigmaPi ()) >= cMaxTPCnSigmaPion || std::fabs (track.tofNSigmaPi ()) >= cMaxTOFnSigmaPion)
@@ -191,8 +197,7 @@ struct f0980analysis {
191197 if (track.hasTOF ()) {
192198 if (std::fabs (track.tpcNSigmaPi ()) >= cMaxTPCnSigmaPion || std::fabs (track.tofNSigmaPi ()) >= cMaxTOFnSigmaPion)
193199 return false ;
194- }
195- else {
200+ } else {
196201 if (std::fabs (track.tpcNSigmaPi ()) >= cMaxTPCnSigmaPionWoTOF)
197202 return false ;
198203 }
@@ -201,7 +206,8 @@ struct f0980analysis {
201206 }
202207
203208 template <bool IsMC, typename CollisionType, typename TracksType>
204- void fillHistograms (const CollisionType& collision, const TracksType& dTracks) {
209+ void fillHistograms (const CollisionType& collision, const TracksType& dTracks)
210+ {
205211 double lhpT = 0 .;
206212 double lhphi = 0 .;
207213 double relphi = 0 .;
@@ -265,7 +271,7 @@ struct f0980analysis {
265271 if (cfgFindRT) {
266272 histos.fill (HIST (" hInvMass_f0980_LSmm" ), reco.M (), reco.Pt (), collision.cent (), rtIndex (reco.Phi (), lhphi), lhpT);
267273 }
268- histos.fill (HIST (" hInvMass_f0980_LSmm_EPA" ), reco.M (), reco.Pt (), collision.cent (), relphi);
274+ histos.fill (HIST (" hInvMass_f0980_LSmm_EPA" ), reco.M (), reco.Pt (), collision.cent (), relphi);
269275 }
270276 }
271277 }
0 commit comments