99// granted to it by virtue of its status as an Intergovernmental Organization
1010// or submit itself to any jurisdiction.
1111
12- // / \file Antinucleitask .cxx
12+ // / \file AntinucleiTask .cxx
1313// / \brief A task to analyse Anti-nuclei
1414// / \author Arkaprabha Saha <arkaprabha.saha@cern.ch>
1515
@@ -43,27 +43,31 @@ namespace
4343static const std::vector<std::string> particleName{" d" };
4444static const double kBetheBlochDefault [6 ]{-1 .e32 , -1 .e32 , -1 .e32 , -1 .e32 , -1 .e32 , -1 .e32 };
4545static const std::vector<std::string> betheBlochParNames{" p0" , " p1" , " p2" , " p3" , " p4" , " resolution" };
46+ static const float maxEtaCut = 0 .8f ;
47+ static const int minTpcCrossedRowsCut = 70 ;
48+ static const float maxVertexZCut = 10 .f;
4649} // namespace
4750
48- struct Antinucleitask {
51+ struct AntinucleiTask {
4952 // Histogram registry: for holding histograms
5053 HistogramRegistry histos{" histos" , {}, OutputObjHandlingPolicy::AnalysisObject};
5154
5255 // Configurable track cuts
53- Configurable<float > mtrackNclusTPCcut{" trackNclusTPCcut" , 70 .0f , " min number of TPC clusters" };
54- Configurable<float > mtrackNclusITScut{" trackNclusITScut" , 4 .0f , " min number of ITS clusters" };
55- Configurable<float > mChi2TPC {" Chi2TPC" , 4 .0f , " max chi2 per cluster TPC" };
56- Configurable<float > mChi2ITS {" Chi2ITS" , 36 .0f , " max chi2 per cluster ITS" };
57- Configurable<float > mtrackDCAz{" trackDCAz" , 0 .1f , " maxDCAz" };
58- Configurable<float > mtrackDCAxy{" trackDCAxy" , 0 .1f , " maxDCAxy" };
56+ Configurable<float > trackNclusTPCcut{" trackNclusTPCcut" , 70 .0f , " min number of TPC clusters" };
57+ Configurable<float > trackNclusITScut{" trackNclusITScut" , 4 .0f , " min number of ITS clusters" };
58+ Configurable<float > chi2TPC{" chi2TPC" , 4 .0f , " max chi2 per cluster TPC" };
59+ Configurable<float > chi2ITS{" chi2ITS" , 36 .0f , " max chi2 per cluster ITS" };
60+ Configurable<float > trackDCAz{" trackDCAz" , 0 .1f , " maxDCAz" };
61+ Configurable<float > trackDCAxy{" trackDCAxy" , 0 .1f , " maxDCAxy" };
62+ Configurable<float > tpcNSigmaCut{" tpcNSigmaCut" , 3 .0f , " tpcNSigmaCut" };
5963 Configurable<LabeledArray<double >> cfgBetheBlochParams{" cfgBetheBlochParams" , {kBetheBlochDefault , 1 , 6 , particleName, betheBlochParNames}, " TPC Bethe-Bloch parameterisation for deuteron" };
6064
6165 void init (InitContext const &)
6266 { // Defining the Histogram Axes
6367 ConfigurableAxis etaAxis{" etaAxis" , {16 , -0.8 , +0.8 }, " #eta" };
6468 ConfigurableAxis phiAxis{" phiAxis" , {70 , 0 .f , 7 .f }, " #phi" };
6569 ConfigurableAxis zVtxAxis{" zVtxAxis" , {100 , -20 .f , 20 .f }, " Primary Vertex z (cm)" };
66- ConfigurableAxis NSigmaAxis{ " NSigmaAxis " , {50 , -5 .f , 5 .f }, " N_{#sigma}" };
70+ ConfigurableAxis nSigmaAxis{ " nSigmaAxis " , {50 , -5 .f , 5 .f }, " N_{#sigma}" };
6771 ConfigurableAxis ptAxis{" ptAxis" , {100 , -5 .0f , 5 .0f }, " p_{T} (GeV/c)" };
6872 ConfigurableAxis centAxis{" centAxis" , {100 , 0 , 100 .0f }, " Centrality" };
6973 ConfigurableAxis momAxis{" momAxis" , {5 .e2 , 0 .f , 5 .f }, " momentum axis binning" };
@@ -79,31 +83,31 @@ struct Antinucleitask {
7983 histos.add (" RawPt" , " RawPt" , kTH1F , {{ptAxis, " #it{p}_{T} (GeV/#it{c})" }});
8084 histos.add (" Pt" , " Pt" , kTH1F , {{ptAxis, " #it{p}_{T} (GeV/#it{c})" }});
8185 histos.add (" TpcSignal" , " TpcSignal" , kTH2F , {{momAxis, " #it{p}_{TPC} (GeV/#it{c})" }, {tpcAxis, " d#it{E}/d#it{x}_{TPC}" }});
82- histos.add (" RawtpcNSigma" , " RawtpcNSigma" , kTH3F , {{centAxis, " Centrality" }, {ptAxis, " #it{p}_{T} (GeV/#it{c})" }, {NSigmaAxis , " N_{#sigma}" }});
83- histos.add (" tpcNSigma" , " tpcNSigma" , kTH3F , {{centAxis, " Centrality" }, {ptAxis, " #it{p}_{T} (GeV/#it{c})" }, {NSigmaAxis , " N_{#sigma}" }});
84- histos.add (" RawtofNSigma" , " RawtofNSigma" , kTH3F , {{centAxis, " Centrality" }, {ptAxis, " #it{p}_{T} (GeV/#it{c})" }, {NSigmaAxis , " N_{#sigma}" }});
85- histos.add (" tofNSigma" , " tofNSigma" , kTH3F , {{centAxis, " Centrality" }, {ptAxis, " #it{p}_{T} (GeV/#it{c})" }, {NSigmaAxis , " N_{#sigma}" }});
86+ histos.add (" RawtpcNSigma" , " RawtpcNSigma" , kTH3F , {{centAxis, " Centrality" }, {ptAxis, " #it{p}_{T} (GeV/#it{c})" }, {nSigmaAxis , " N_{#sigma}" }});
87+ histos.add (" tpcNSigma" , " tpcNSigma" , kTH3F , {{centAxis, " Centrality" }, {ptAxis, " #it{p}_{T} (GeV/#it{c})" }, {nSigmaAxis , " N_{#sigma}" }});
88+ histos.add (" RawtofNSigma" , " RawtofNSigma" , kTH3F , {{centAxis, " Centrality" }, {ptAxis, " #it{p}_{T} (GeV/#it{c})" }, {nSigmaAxis , " N_{#sigma}" }});
89+ histos.add (" tofNSigma" , " tofNSigma" , kTH3F , {{centAxis, " Centrality" }, {ptAxis, " #it{p}_{T} (GeV/#it{c})" }, {nSigmaAxis , " N_{#sigma}" }});
8690 }
8791
8892 // Function to apply track cuts
8993 template <typename T>
9094 bool isGoodTrack (const T& track)
9195 {
92- if (track.eta () > 0 . 8f )
96+ if (track.eta () > maxEtaCut )
9397 return false ;
94- if (track.tpcNClsFound () < mtrackNclusTPCcut )
98+ if (track.tpcNClsFound () < trackNclusTPCcut )
9599 return false ;
96- if (track.tpcNClsCrossedRows () < 70 )
100+ if (track.tpcNClsCrossedRows () < minTpcCrossedRowsCut )
97101 return false ;
98- if (track.itsNCls () < mtrackNclusITScut )
102+ if (track.itsNCls () < trackNclusITScut )
99103 return false ;
100- if (track.tpcChi2NCl () > mChi2TPC )
104+ if (track.tpcChi2NCl () > chi2TPC )
101105 return false ;
102- if (track.itsChi2NCl () > mChi2ITS )
106+ if (track.itsChi2NCl () > chi2ITS )
103107 return false ;
104- if (std::abs (track.dcaXY ()) > mtrackDCAxy )
108+ if (std::abs (track.dcaXY ()) > trackDCAxy )
105109 return false ;
106- if (std::abs (track.dcaZ ()) > mtrackDCAz )
110+ if (std::abs (track.dcaZ ()) > trackDCAz )
107111 return false ;
108112
109113 return true ;
@@ -113,7 +117,7 @@ struct Antinucleitask {
113117 void process (CollisionWithEvSel::iterator const & collision, TotalTracks const & tracks)
114118 {
115119 // Event Selection
116- if (std::abs (collision.posZ ()) > 10 . f ) {
120+ if (std::abs (collision.posZ ()) > maxVertexZCut ) {
117121 return ;
118122 }
119123
@@ -129,7 +133,7 @@ struct Antinucleitask {
129133 histos.fill (HIST (" zVtx" ), collision.posZ ());
130134
131135 // Track Selection
132- for (auto & track : tracks) {
136+ for (const auto & track : tracks) {
133137
134138 double expBethe{tpc::BetheBlochAleph (static_cast <double >(track.tpcInnerParam () / o2::constants::physics::MassDeuteron), cfgBetheBlochParams->get (" p0" ), cfgBetheBlochParams->get (" p1" ), cfgBetheBlochParams->get (" p2" ), cfgBetheBlochParams->get (" p3" ), cfgBetheBlochParams->get (" p4" ))};
135139 double expSigma{expBethe * cfgBetheBlochParams->get (" resolution" )};
@@ -151,18 +155,18 @@ struct Antinucleitask {
151155 histos.fill (HIST (" tpcNSigma" ), collision.centFT0C (), pt, tpcNSigmaDeuteron);
152156 histos.fill (HIST (" TpcSignal" ), track.tpcInnerParam (), track.tpcSignal ());
153157
154- if (std::abs (tpcNSigmaDeuteron) < 3 . f ) {
158+ if (std::abs (tpcNSigmaDeuteron) < tpcNSigmaCut ) {
155159 histos.fill (HIST (" tofNSigma" ), collision.centFT0C (), pt, track.tofNSigmaDe ());
156160 }
157161 }
158162 }
159163 }
160164
161- PROCESS_SWITCH (Antinucleitask , process, " process" , true );
165+ PROCESS_SWITCH (AntinucleiTask , process, " process" , true );
162166};
163167
164168WorkflowSpec defineDataProcessing (ConfigContext const & cfgc)
165169{
166170 return WorkflowSpec{
167- adaptAnalysisTask<Antinucleitask >(cfgc)};
171+ adaptAnalysisTask<AntinucleiTask >(cfgc)};
168172}
0 commit comments