diff --git a/PWGMM/UE/Tasks/dedxAnalysis.cxx b/PWGMM/UE/Tasks/dedxAnalysis.cxx index c25bb3ff092..72d566d6b93 100644 --- a/PWGMM/UE/Tasks/dedxAnalysis.cxx +++ b/PWGMM/UE/Tasks/dedxAnalysis.cxx @@ -34,11 +34,8 @@ using namespace o2::framework; using namespace constants::physics; using PIDTracks = soa::Join< - aod::Tracks, aod::TracksExtra, aod::TracksDCA, aod::pidTOFbeta, - aod::pidTOFmass, aod::TrackSelection, aod::TrackSelectionExtension, - aod::pidTPCFullPi, aod::pidTPCFullKa, aod::pidTPCFullPr, aod::pidTPCFullDe, - aod::pidTPCFullTr, aod::pidTPCFullHe, aod::pidTOFFullPi, aod::pidTOFFullKa, - aod::pidTOFFullPr, aod::pidTOFFullDe, aod::pidTOFFullTr, aod::pidTOFFullHe, aod::pidTOFFullEl>; + aod::Tracks, aod::TracksExtra, aod::TrackSelectionExtension, + aod::pidTOFFullPi, aod::pidTOFFullPr, aod::pidTOFFullEl>; using SelectedCollisions = soa::Join; @@ -85,11 +82,18 @@ struct DedxAnalysis { Configurable maxDCAxy{"maxDCAxy", 0.1f, "maxDCAxy"}; Configurable maxDCAz{"maxDCAz", 0.1f, "maxDCAz"}; Configurable eventSelection{"eventSelection", true, "event selection"}; - Configurable calibrationMode{"calibrationMode", false, "calibration mode"}; + Configurable calibrationMode{"calibrationMode", true, "calibration mode"}; // Histograms names - static constexpr std::string_view kDedxvsMomentum[4] = {"dEdx_vs_Momentum_all", "dEdx_vs_Momentum_Pi_v0", "dEdx_vs_Momentum_Pr_v0", "dEdx_vs_Momentum_El_v0"}; + static constexpr std::string_view kDedxvsMomentumPos[4] = {"dEdx_vs_Momentum_all_Pos", "dEdx_vs_Momentum_Pi_v0_Pos", "dEdx_vs_Momentum_Pr_v0_Pos", "dEdx_vs_Momentum_El_v0_Pos"}; + static constexpr std::string_view kDedxvsMomentumNeg[4] = {"dEdx_vs_Momentum_all_Neg", "dEdx_vs_Momentum_Pi_v0_Neg", "dEdx_vs_Momentum_Pr_v0_Neg", "dEdx_vs_Momentum_El_v0_Neg"}; static constexpr double EtaCut[9] = {-0.8, -0.6, -0.4, -0.2, 0.0, 0.2, 0.4, 0.6, 0.8}; - static constexpr double Correction[8] = {56.0452, 56.632, 57.2627, 57.8265, 57.8403, 57.5441, 57.2386, 56.7532}; + static constexpr double Correction[8] = {54.5281, 54.6548, 54.6513, 54.6781, 54.6167, 54.7384, 55.0047, 54.9592}; +<<<<<<< HEAD + ConfigurableAxis binP{"binP", {0.1, 0.12, 0.14, 0.16, 0.18, 0.2, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5, 0.55, 0.6, 0.65, 0.7, 0.75, 0.8, 0.85, 0.9, 0.95, 1.0, 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 1.8, 1.9, 2.0, 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.9, 3.0, 3.2, 3.4, 3.6, 3.8, 4.0, 4.5, 5.0, 5.5, 6.0, 6.5, 7.0, 8.0, 9.0, 10.0, 11.0, 12.0, 13.0, 14.0, 15.0, 16.0, 18.0, 20.0}, ""}; + AxisSpec pAxis = {binP, "#it{p}/Z (GeV/c)"}; +======= + ConfigurableAxis binP{"binP", {VARIABLE_WIDTH, 0.1, 0.12, 0.14, 0.16, 0.18, 0.2, 0.25, 0.3, 0.35, 0.4, 0.45, 0.5, 0.55, 0.6, 0.65, 0.7, 0.75, 0.8, 0.85, 0.9, 0.95, 1.0, 1.1, 1.2, 1.3, 1.4, 1.5, 1.6, 1.7, 1.8, 1.9, 2.0, 2.1, 2.2, 2.3, 2.4, 2.5, 2.6, 2.7, 2.8, 2.9, 3.0, 3.2, 3.4, 3.6, 3.8, 4.0, 4.5, 5.0, 5.5, 6.0, 6.5, 7.0, 8.0, 9.0, 10.0, 11.0, 12.0, 13.0, 14.0, 15.0, 16.0, 18.0, 20.0}, ""}; +>>>>>>> c200e0ce0 (AxisSpec was moved inside init()) void init(InitContext const&) { @@ -103,6 +107,8 @@ struct DedxAnalysis { {{100, 0.0, 6.4, "#phi"}, {100, 0.0, 600.0, "dE/dx MIP (a. u.)"}}); } else { + AxisSpec pAxis = {binP, "#it{p}/Z (GeV/c)"}; + registryDeDx.add( "hdEdxMIP_vs_eta_calibrated", "dE/dx", HistType::kTH2F, {{8, -0.8, 0.8, "#eta"}, {10, 30.0, 70.0, "dE/dx MIP (a. u.)"}}); @@ -112,8 +118,15 @@ struct DedxAnalysis { // De/Dx for ch and v0 particles for (int i = 0; i < 4; ++i) { +<<<<<<< HEAD registryDeDx.add(kDedxvsMomentum[i].data(), "dE/dx", HistType::kTH3F, - {{100, -20, 20, "#it{p}/Z (GeV/c)"}, {100, 0.0, 600.0, "dE/dx (a. u.)"}, {8, -0.8, 0.8, "#eta"}}); + {{pAxis}, {100, 0.0, 600.0, "dE/dx (a. u.)"}, {8, -0.8, 0.8, "#eta"}}); +======= + registryDeDx.add(kDedxvsMomentumPos[i].data(), "dE/dx", HistType::kTH3F, + {{pAxis}, {100, 0.0, 600.0, "dE/dx (a. u.)"}, {8, -0.8, 0.8, "#eta"}}); + registryDeDx.add(kDedxvsMomentumNeg[i].data(), "dE/dx", HistType::kTH3F, + {{pAxis}, {100, 0.0, 600.0, "dE/dx (a. u.)"}, {8, -0.8, 0.8, "#eta"}}); +>>>>>>> c200e0ce0 (AxisSpec was moved inside init()) } } // Event Counter @@ -306,7 +319,7 @@ struct DedxAnalysis { float signedP = trk.sign() * trk.tpcInnerParam(); // MIP for pions - if (trk.tpcInnerParam() >= 0.25 && trk.tpcInnerParam() <= 0.35) { + if (trk.tpcInnerParam() >= 0.35 && trk.tpcInnerParam() <= 0.45) { if (calibrationMode) { registryDeDx.fill(HIST("hdEdxMIP_vs_eta"), trk.eta(), trk.tpcSignal()); registryDeDx.fill(HIST("hdEdxMIP_vs_phi"), trk.phi(), trk.tpcSignal()); @@ -323,7 +336,11 @@ struct DedxAnalysis { if (!calibrationMode) { for (int i = 0; i < 8; ++i) { if (trk.eta() > EtaCut[i] && trk.eta() < EtaCut[i + 1]) { - registryDeDx.fill(HIST(kDedxvsMomentum[0]), signedP, trk.tpcSignal() * 50 / Correction[i], trk.eta()); + if (signedP > 0) { + registryDeDx.fill(HIST(kDedxvsMomentumPos[0]), signedP, trk.tpcSignal() * 50 / Correction[i], trk.eta()); + }else{ + registryDeDx.fill(HIST(kDedxvsMomentumNeg[0]), std::abs(signedP), trk.tpcSignal() * 50 / Correction[i], trk.eta()); + } } } } @@ -378,11 +395,11 @@ struct DedxAnalysis { for (int i = 0; i < 8; ++i) { if (negTrack.eta() > EtaCut[i] && negTrack.eta() < EtaCut[i + 1]) { - registryDeDx.fill(HIST(kDedxvsMomentum[1]), signedPneg, negTrack.tpcSignal() * 50 / Correction[i], negTrack.eta()); + registryDeDx.fill(HIST(kDedxvsMomentumNeg[1]), std::abs(signedPneg), negTrack.tpcSignal() * 50 / Correction[i], negTrack.eta()); } if (posTrack.eta() > EtaCut[i] && posTrack.eta() < EtaCut[i + 1]) { - registryDeDx.fill(HIST(kDedxvsMomentum[1]), signedPpos, posTrack.tpcSignal() * 50 / Correction[i], posTrack.eta()); + registryDeDx.fill(HIST(kDedxvsMomentumPos[1]), signedPpos, posTrack.tpcSignal() * 50 / Correction[i], posTrack.eta()); } } } @@ -402,11 +419,11 @@ struct DedxAnalysis { for (int i = 0; i < 8; ++i) { if (negTrack.eta() > EtaCut[i] && negTrack.eta() < EtaCut[i + 1]) { - registryDeDx.fill(HIST(kDedxvsMomentum[1]), signedPneg, negTrack.tpcSignal() * 50 / Correction[i], negTrack.eta()); + registryDeDx.fill(HIST(kDedxvsMomentumNeg[1]), std::abs(signedPneg), negTrack.tpcSignal() * 50 / Correction[i], negTrack.eta()); } if (posTrack.eta() > EtaCut[i] && posTrack.eta() < EtaCut[i + 1]) { - registryDeDx.fill(HIST(kDedxvsMomentum[2]), signedPpos, posTrack.tpcSignal() * 50 / Correction[i], posTrack.eta()); + registryDeDx.fill(HIST(kDedxvsMomentumPos[2]), signedPpos, posTrack.tpcSignal() * 50 / Correction[i], posTrack.eta()); } } } @@ -426,11 +443,11 @@ struct DedxAnalysis { for (int i = 0; i < 8; ++i) { if (negTrack.eta() > EtaCut[i] && negTrack.eta() < EtaCut[i + 1]) { - registryDeDx.fill(HIST(kDedxvsMomentum[2]), signedPneg, negTrack.tpcSignal() * 50 / Correction[i], negTrack.eta()); + registryDeDx.fill(HIST(kDedxvsMomentumNeg[2]), std::abs(signedPneg), negTrack.tpcSignal() * 50 / Correction[i], negTrack.eta()); } if (posTrack.eta() > EtaCut[i] && posTrack.eta() < EtaCut[i + 1]) { - registryDeDx.fill(HIST(kDedxvsMomentum[1]), signedPpos, posTrack.tpcSignal() * 50 / Correction[i], posTrack.eta()); + registryDeDx.fill(HIST(kDedxvsMomentumPos[1]), signedPpos, posTrack.tpcSignal() * 50 / Correction[i], posTrack.eta()); } } } @@ -450,11 +467,11 @@ struct DedxAnalysis { for (int i = 0; i < 8; ++i) { if (negTrack.eta() > EtaCut[i] && negTrack.eta() < EtaCut[i + 1]) { - registryDeDx.fill(HIST(kDedxvsMomentum[3]), signedPneg, negTrack.tpcSignal() * 50 / Correction[i], negTrack.eta()); + registryDeDx.fill(HIST(kDedxvsMomentumNeg[3]), std::abs(signedPneg), negTrack.tpcSignal() * 50 / Correction[i], negTrack.eta()); } if (posTrack.eta() > EtaCut[i] && posTrack.eta() < EtaCut[i + 1]) { - registryDeDx.fill(HIST(kDedxvsMomentum[3]), signedPpos, posTrack.tpcSignal() * 50 / Correction[i], posTrack.eta()); + registryDeDx.fill(HIST(kDedxvsMomentumPos[3]), signedPpos, posTrack.tpcSignal() * 50 / Correction[i], posTrack.eta()); } } }