@@ -39,7 +39,7 @@ using SelectedClusters = o2::soa::Filtered<o2::aod::EMCALClusters>;
3939using TrackEle = o2::soa::Filtered<o2::soa::Join<o2::aod::Tracks, o2::aod::FullTracks, o2::aod::TracksExtra_001, o2::aod::TracksDCA, o2::aod::TrackSelection, o2::aod::pidTPCFullEl>>;
4040
4141// pp
42- // using TrackEle = o2::soa::Filtered<o2::soa::Join<o2::aod::Tracks, o2::aod::FullTracks, o2::aod::TracksDCA, o2::aod::TrackSelection, o2::aod::pidTPCEl, o2::aod::pidTOFEl>>;
42+ // using TrackEle = o2::soa::Filtered<o2::soa::Join<o2::aod::Tracks, o2::aod::FullTracks, o2::aod::TracksDCA, o2::aod::TrackSelection, o2::aod::pidTPCEl, o2::aod::pidTOFEl>>;
4343
4444struct HfTaskElectronWeakBoson {
4545
@@ -74,13 +74,13 @@ struct HfTaskElectronWeakBoson {
7474
7575 // cluster cut
7676 Configurable<int > mClusterDefinition {" clusterDefinition" , 10 , " cluster definition to be selected, e.g. 10=kV3Default" };
77- Configurable<float > minTime{" minTime" , -25 ., " Minimum cluster time for time cut" };
78- Configurable<float > maxTime{" maxTime" , +20 ., " Maximum cluster time for time cut" };
79- Configurable<float > minM02{" minM02" , 0.1 , " Minimum M02 for M02 cut" };
80- Configurable<float > maxM02{" maxM02" , 0.9 , " Maximum M02 for M02 cut" };
81- Configurable<float > minM20{" minM20" , 0.1 , " Minimum M20 for M20 cut" };
82- Configurable<float > maxM20{" maxM20" , 0.6 , " Maximum M20 for M20 cut" };
83- Configurable<float > MatchR_cut{" MatchR_cut" , 0.1 , " cluster - track matching cut" };
77+ Configurable<float > minTime{" minTime" , -25 ., " Minimum cluster time for time cut" };
78+ Configurable<float > maxTime{" maxTime" , +20 ., " Maximum cluster time for time cut" };
79+ Configurable<float > minM02{" minM02" , 0.1 , " Minimum M02 for M02 cut" };
80+ Configurable<float > maxM02{" maxM02" , 0.9 , " Maximum M02 for M02 cut" };
81+ Configurable<float > minM20{" minM20" , 0.1 , " Minimum M20 for M20 cut" };
82+ Configurable<float > maxM20{" maxM20" , 0.6 , " Maximum M20 for M20 cut" };
83+ Configurable<float > MatchR_cut{" MatchR_cut" , 0.1 , " cluster - track matching cut" };
8484
8585 Filter clusterDefinitionSelection = (o2::aod::emcalcluster::definition == mClusterDefinition ) && (o2::aod::emcalcluster::time >= minTime) && (o2::aod::emcalcluster::time <= maxTime) && (o2::aod::emcalcluster::m02 > minM02) && (o2::aod::emcalcluster::m02 < maxM02);
8686
@@ -130,15 +130,14 @@ struct HfTaskElectronWeakBoson {
130130 histos.add (" EMCtimeHistogram" , " EMCtimeHistogram" , kTH1F , {axisEMCtime});
131131 }
132132
133- // void process(soa::Filtered<aod::Collisions>::iterator const& collision, selectedClusters const& clusters, TrackEle const& tracks, o2::aod::EMCALMatchedTracks const& matchedtracks)
134133 void process (soa::Filtered<aod::Collisions>::iterator const & collision, selectedClusters const & emcClusters, TrackEle const & tracks, o2::aod::EMCALMatchedTracks const & matchedtracks)
135134 {
136- histos.fill (HIST (" hEventCounter" ),0.5 );
135+ histos.fill (HIST (" hEventCounter" ), 0.5 );
137136
138- // LOGF(info, "Collision index : %d", collision.index());
139- // LOGF(info, "Number of tracks: %d", tracks.size());
140- // LOGF(info, "Number of clusters: %d", clusters.size());
141- // LOGF(info, "Number of clusters: %d", emcClusters.size());
137+ // LOGF(info, "Collision index : %d", collision.index());
138+ // LOGF(info, "Number of tracks: %d", tracks.size());
139+ // LOGF(info, "Number of clusters: %d", clusters.size());
140+ // LOGF(info, "Number of clusters: %d", emcClusters.size());
142141
143142 histos.fill (HIST (" ZvtxHistogram" ), collision.posZ ());
144143
@@ -151,56 +150,65 @@ struct HfTaskElectronWeakBoson {
151150 histos.fill (HIST (" ITS_NCls_Hist" ), track.itsNCls ());
152151 histos.fill (HIST (" TPC_NClsCrossedRows_Hist" ), track.tpcNClsCrossedRows ());
153152
154- if (std::abs (track.eta ())>0.6 )continue ;
155- if (track.tpcNClsCrossedRows ()<tpcNclCr_cut)continue ;
156- if (std::abs (track.dcaXY ())>dcaxy_cut)continue ;
157- if (track.itsChi2NCl () > itschi2_cut) continue ;
158- if (track.tpcChi2NCl () > tpcchi2_cut) continue ;
159- if (track.tpcNClsFound () < tpcNcl_cut) continue ;
160- if (track.itsNCls ()<itsNcl_cut)continue ;
161- if (track.pt ()<mimpT_cut)continue ;
153+ if (std::abs (track.eta ()) > 0.6 )
154+ continue ;
155+ if (track.tpcNClsCrossedRows () < tpcNclCr_cut)
156+ continue ;
157+ if (std::abs (track.dcaXY ()) > dcaxy_cut)
158+ continue ;
159+ if (track.itsChi2NCl () > itschi2_cut)
160+ continue ;
161+ if (track.tpcChi2NCl () > tpcchi2_cut)
162+ continue ;
163+ if (track.tpcNClsFound () < tpcNcl_cut)
164+ continue ;
165+ if (track.itsNCls () < itsNcl_cut)
166+ continue ;
167+ if (track.pt () < mimpT_cut)
168+ continue ;
162169 histos.fill (HIST (" ptHistogram" ), track.pt ());
163- histos.fill (HIST (" TPCElHistogram" ), track.p (),track.tpcNSigmaEl ());
170+ histos.fill (HIST (" TPCElHistogram" ), track.p (), track.tpcNSigmaEl ());
164171
165172 // track - match
166173
167- if (emcClusters.size ()<1 )continue ;
168- if (track.phi ()<1.39 || track.phi ()>3.265 )continue ;
169- auto tracksofcluster = matchedtracks.sliceBy (perClusterMatchedTracks, track.globalIndex ());
174+ if (emcClusters.size () < 1 )
175+ continue ;
176+ if (track.phi () < 1.39 || track.phi () > 3.265 )
177+ continue ;
178+ auto tracksofcluster = matchedtracks.sliceBy (perClusterMatchedTracks, track.globalIndex ());
170179
171- // LOGF(info, "Number of matched track: %d", tracksofcluster.size());
180+ // LOGF(info, "Number of matched track: %d", tracksofcluster.size());
172181
173182 double Rmim = 999.9 ;
174183 double dPhi_mim = 999.9 ;
175184 double dEta_mim = 999.9 ;
176185
177- if (tracksofcluster.size ()>0 )
178- {
186+ if (tracksofcluster.size () > 0 ) {
179187 int nmatch = 0 ;
180- for (const auto & match : tracksofcluster)
181- {
182- if (match.emcalcluster_as <selectedClusters>().time ()<minTime || match.emcalcluster_as <selectedClusters>().time ()>maxTime)continue ;
183- if (match.emcalcluster_as <selectedClusters>().m02 ()<minM02 || match.emcalcluster_as <selectedClusters>().m02 ()>maxM02)continue ;
188+ for (const auto & match : tracksofcluster) {
189+ if (match.emcalcluster_as <selectedClusters>().time () < minTime || match.emcalcluster_as <selectedClusters>().time () > maxTime)
190+ continue ;
191+ if (match.emcalcluster_as <selectedClusters>().m02 () < minM02 || match.emcalcluster_as <selectedClusters>().m02 () > maxM02)
192+ continue ;
184193
185194 double emc_m20 = match.emcalcluster_as <selectedClusters>().m20 ();
186195 double emc_m02 = match.emcalcluster_as <selectedClusters>().m02 ();
187196 double emc_energy = match.emcalcluster_as <selectedClusters>().energy ();
188197 double emc_phi = match.emcalcluster_as <selectedClusters>().phi ();
189198 double emc_eta = match.emcalcluster_as <selectedClusters>().eta ();
190199 double emc_time = match.emcalcluster_as <selectedClusters>().time ();
191- // LOG(info) << "tr phi0 = " << match.track_as<TrackEle>().phi();
192- // LOG(info) << "tr phi1 = " << track.phi();
193- // LOG(info) << "emc phi = " << emc_phi;
194- if (nmatch==0 )
195- {
200+ // LOG(info) << "tr phi0 = " << match.track_as<TrackEle>().phi();
201+ // LOG(info) << "tr phi1 = " << track.phi();
202+ // LOG(info) << "emc phi = " << emc_phi;
203+ if (nmatch==0 ) {
196204 double dPhi = match.track_as <TrackEle>().phi () - emc_phi;
197205 double dEta = match.track_as <TrackEle>().eta () - emc_eta;
198206
199- histos.fill (HIST (" MatchPhiHistogram" ),emc_phi,match.track_as <TrackEle>().phi ());
200- histos.fill (HIST (" MatchEtaHistogram" ),emc_eta,match.track_as <TrackEle>().eta ());
207+ histos.fill (HIST (" MatchPhiHistogram" ), emc_phi,match.track_as <TrackEle>().phi ());
208+ histos.fill (HIST (" MatchEtaHistogram" ), emc_eta,match.track_as <TrackEle>().eta ());
201209
202- double R = sqrt (pow (dPhi,2 )+pow (dEta,2 ));
203- if (R< Rmim)
210+ double R = sqrt (pow (dPhi, 2 )+pow (dEta, 2 ));
211+ if (R < Rmim)
204212 {
205213 Rmim = R;
206214 dPhi_mim = dPhi;
@@ -209,14 +217,15 @@ struct HfTaskElectronWeakBoson {
209217 histos.fill (HIST (" TrMatchHistogram" ), dPhi, dEta);
210218 histos.fill (HIST (" EMCtimeHistogram" ), emc_time);
211219
212- if (R < MatchR_cut)continue ;
220+ if (R < MatchR_cut)
221+ continue ;
213222
214- double eop = emc_energy/ match.track_as <TrackEle>().p ();
215- // LOG(info) << "E/p" << eop;
223+ double eop = emc_energy / match.track_as <TrackEle>().p ();
224+ // LOG(info) << "E/p" << eop;
216225 histos.fill (HIST (" EopNsigTPCHistogram" ), match.track_as <TrackEle>().tpcNSigmaEl (), eop);
217- histos.fill (HIST (" M02Histogram" ), match.track_as <TrackEle>().tpcNSigmaEl (),emc_m02);
218- histos.fill (HIST (" M20Histogram" ), match.track_as <TrackEle>().tpcNSigmaEl (),emc_m20);
219- if (match.track_as <TrackEle>().tpcNSigmaEl ()> -1.0 && match.track_as <TrackEle>().tpcNSigmaEl ()<3 )
226+ histos.fill (HIST (" M02Histogram" ), match.track_as <TrackEle>().tpcNSigmaEl (), emc_m02);
227+ histos.fill (HIST (" M20Histogram" ), match.track_as <TrackEle>().tpcNSigmaEl (), emc_m20);
228+ if (match.track_as <TrackEle>().tpcNSigmaEl () > -1.0 && match.track_as <TrackEle>().tpcNSigmaEl () <3 )
220229 {
221230 histos.fill (HIST (" EopHistogram" ), match.track_as <TrackEle>().pt (), eop);
222231 }
@@ -225,12 +234,12 @@ struct HfTaskElectronWeakBoson {
225234
226235 nmatch++;
227236 }
228- }
237+ }
229238
230239
231- if (Rmim< 10.0 )
240+ if (Rmim < 10.0 )
232241 {
233- // LOG(info) << "R mim = " << Rmim;
242+ // LOG(info) << "R mim = " << Rmim;
234243 histos.fill (HIST (" TrMatchHistogram_mim" ), dPhi_mim, dEta_mim);
235244 }
236245
0 commit comments