Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 23 additions & 4 deletions PWGCF/JCorran/Tasks/jEPFlowAnalysis.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,11 @@ struct jEPFlowAnalysis {
return;
}

if (cfgEffCor) {
auto bc = coll.bc_as<aod::BCsWithTimestamps>();
effMap = ccdb->getForTimeStamp<THnT<float>>(cfgEffCorDir, bc.timestamp());
}

float cent = coll.cent();
epFlowHistograms.fill(HIST("hCentrality"), cent);
epFlowHistograms.fill(HIST("hVertex"), coll.posZ());
Expand Down Expand Up @@ -287,6 +292,13 @@ struct jEPFlowAnalysis {

float weight = 1.0;

qx_shifted[0] = coll.qvecRe()[4 * detId + harmInd];
qy_shifted[0] = coll.qvecIm()[4 * detId + harmInd];
qx_shifted[1] = coll.qvecRe()[4 * refAId + harmInd];
qy_shifted[1] = coll.qvecIm()[4 * refAId + harmInd];
qx_shifted[2] = coll.qvecRe()[4 * refBId + harmInd];
qy_shifted[2] = coll.qvecIm()[4 * refBId + harmInd];

if (cfgManShiftCorr) {
constexpr int kShiftBins = 10;
for (int ishift = 1; ishift <= kShiftBins; ishift++) {
Expand Down Expand Up @@ -334,14 +346,21 @@ struct jEPFlowAnalysis {
epFlowHistograms.fill(HIST("EpResQvecRefARefBxy"), i + 2, cent, qx_shifted[2] * qy_shifted[1] - qx_shifted[1] * qy_shifted[2]);

for (const auto& track : tracks) {
if (trackSel(track))
continue;

if (cfgEffCor) {
weight /= getEfficiencyCorrection(effMap, track.eta(), track.pt(), cent, coll.posZ());
}

float vn = std::cos((i + 2) * (track.phi() - eps[0]));
float vnSin = std::sin((i + 2) * (track.phi() - eps[0]));

epFlowHistograms.fill(HIST("vncos"), i + 2, cent, track.pt(), vn * weight);
epFlowHistograms.fill(HIST("vnsin"), i + 2, cent, track.pt(), vnSin * weight);
epFlowHistograms.fill(HIST("vncos"), i + 2, cent, track.pt(), vn, weight);
epFlowHistograms.fill(HIST("vnsin"), i + 2, cent, track.pt(), vnSin, weight);

epFlowHistograms.fill(HIST("SPvnxx"), i + 2, cent, track.pt(), (std::cos(track.phi() * static_cast<float>(i + 2)) * qx_shifted[0] + std::sin(track.phi() * static_cast<float>(i + 2)) * qy_shifted[0]) * weight);
epFlowHistograms.fill(HIST("SPvnxy"), i + 2, cent, track.pt(), (std::sin(track.phi() * static_cast<float>(i + 2)) * qx_shifted[0] - std::cos(track.phi() * static_cast<float>(i + 2)) * qy_shifted[0]) * weight);
epFlowHistograms.fill(HIST("SPvnxx"), i + 2, cent, track.pt(), (std::cos(track.phi() * static_cast<float>(i + 2)) * qx_shifted[0] + std::sin(track.phi() * static_cast<float>(i + 2)) * qy_shifted[0]), weight);
epFlowHistograms.fill(HIST("SPvnxy"), i + 2, cent, track.pt(), (std::sin(track.phi() * static_cast<float>(i + 2)) * qx_shifted[0] - std::cos(track.phi() * static_cast<float>(i + 2)) * qy_shifted[0]), weight);
}
}
}
Expand Down
Loading