Int_t vL = Int_t(fVtxAxis->GetBinLowEdge(v));
Int_t vH = Int_t(fVtxAxis->GetBinUpEdge(v));
fBinsFMD.Add(new VertexBin(vL, vH, n, "FMD", (fgDispVtx ? kFALSE : kTRUE), fFMDCut));
- fBinsSPD.Add(new VertexBin(vL, vH, n, "SPD", kFALSE, fSPDCut));
+// fBinsSPD.Add(new VertexBin(vL, vH, n, "SPD", kFALSE, fSPDCut));
+ fBinsSPD.Add(new VertexBin(vL, vH, n, "SPD", kTRUE, fSPDCut));
}
}
Int_t nVtxBins = fVtxAxis->GetNbins();
while ((bin = static_cast<VertexBin*>(list.At(vtx+(nVtxBins*i))))) {
- if (!bin->FillHists(h, fCent)) return kFALSE;
+ if (!bin->FillHists(h, fCent)) return kFALSE;
bin->CumulantsAccumulate(fCent);
i++;
}
fCumuRef = new TH2D(Form("%s_v%d_%d_%d_ref", fType.Data(), fMoment, fVzMin, fVzMax),
Form("%s_v%d_%d_%d_ref", fType.Data(), fMoment, fVzMin, fVzMax),
48, -6., 6., 5, 0.5, 5.5);
- TFile acc("$ALICE_ROOT/PWGLF/FORWARD/corrections/FlowCorrections/FlowAccMap.root", "READ");
- TH1D* accMap = (TH1D*)acc.Get(Form("%saccVertex_%d_%d", fType.Data(), fVzMin, fVzMax));
+/* TFile* acc = TFile::Open("$ALICE_ROOT/PWGLF/FORWARD/corrections/FlowCorrections/FlowAccMap.root", "READ");
+ TH1D* accMap = 0;
+ if (acc) accMap = (TH1D*)acc->Get(Form("%saccVertex_%d_%d", fType.Data(), fVzMin, fVzMax));
if (accMap && !fType.EqualTo("FMD")) {
Int_t nBins = accMap->GetNbinsX();
Double_t eta[48] = { 0. };
}
eta[n] = 6.;
fCumuRef->GetXaxis()->Set(n, eta);
- } else {
+ } else {*/
fCumuRef->RebinX(24);
- }
- acc.Close();
-
+ /* }
+ acc->Close();
+ delete acc;
+ */
fCumuRef->Sumw2();
//list->Add(fCumuRef);
nCurRefBin = fCumuRef->GetXaxis()->FindBin(eta);
// If we have moved to a new bin in the flow hist, and less than half the eta
// region has been covered by it we cut it away.
- if (!nPrevBin) nPrevBin = nCurBin;
- if (!nPrevRefBin) nPrevRefBin = nCurRefBin;
+ if (!nPrevBin == 0) nPrevBin = nCurBin;
+ if (!nPrevRefBin == 0) nPrevRefBin = nCurRefBin;
if (nCurBin != nPrevBin) {
if (nCurRefBin != nPrevRefBin) {
if (nInBin <= nBins/2) {
else data = kTRUE;
continue;
}
- if (!data) continue;
if (!AliForwardFlowTaskQC::fgDispVtx && (nCurBin == 34 || nCurBin == 35) && (phiBin == 17 || phiBin == 18)) continue;
if ( AliForwardFlowTaskQC::fgDispVtx && eta < 0 && (phiBin == 17 || phiBin == 18)) continue;
phi = dNdetadphi.GetYaxis()->GetBinCenter(phiBin);
Int_t vH = Int_t(fVtxAxis->GetBinUpEdge(v));
fBinsFMDTR.Add(new VertexBin(vL, vH, n, "FMDTR", (fgDispVtx ? kFALSE : kTRUE), fFMDCut));
fBinsSPDTR.Add(new VertexBin(vL, vH, n, "SPDTR", kTRUE, fSPDCut));
- fBinsMC.Add(new VertexBin(vL, vH, n, "MC"));
+ fBinsMC.Add(new VertexBin(vL, vH, n, "MC", kTRUE));
}
}
}
if (fAddFlow.Contains("eta")) flowFlags |= AliForwardFlowWeights::kEta;
if (fAddFlow.Contains("cent")) flowFlags |= AliForwardFlowWeights::kCent;
}
+ Double_t b = -1.;
+ b = header->GetImpactParameter();
// Track loop: chek how many particles will be accepted
Double_t weight = 0;
if (eta > -4. && eta < 5.) {
// Add flow if it is in the argument
if (flowFlags != 0)
- weight = fWeights.CalcWeight(eta, pT, phi, particle->PdgCode(),
+/* weight = fWeights.CalcWeight(eta, pT, phi, particle->PdgCode(),
rp, fCent, fAddType, fAddOrder,
- flowFlags) + 1;
- fdNdedpMC.Fill(eta, phi, weight);
+ flowFlags) + 1;*/
+ weight = fWeights.CalcWeight(eta, pT, phi, particle->PdgCode(),
+ rp, b);
+
+// Printf("%f", weight);
+ fdNdedpMC.Fill(eta, phi, weight);
}
}
Int_t sBin = fdNdedpMC.GetXaxis()->FindBin(-4.);