// trying to fit to the data
task->GetEnergyFitter().SetMinEntries(1000);
// Set the low cut used for sharing - overrides settings in eloss fits
- // task->GetSharingFilter().SetLowCut(0.4);
+ task->GetSharingFilter().SetLowCut(0.3);
// Set the number of xi's (width of landau peak) to stop at
task->GetSharingFilter().SetNXi(1);
// Set the maximum number of particle to try to reconstruct
task->GetDensityCalculator().SetMaxParticles(2);
// Set the lower multiplicity cut. Overrides setting in energy loss fits.
- // task->GetDensityCalculator().SetMultCut(0.4);
+ task->GetDensityCalculator().SetMultCut(0.3);
+ // Whether to use the merging efficiency correction
+ task->GetCorrections().UseMergingEfficiency(false);
// Set the number of extra bins (beyond the secondary map border)
task->GetHistCollector().SetNCutBins(1);
// Set the correction cut, that is, when bins in the secondary map
#include <TList.h>
#include <TMath.h>
#include "AliForwardCorrectionManager.h"
-// #include "AliFMDAnaParameters.h"
#include "AliLog.h"
#include <TH2D.h>
#include <TROOT.h>
AliFMDCorrections::AliFMDCorrections()
: TNamed(),
fRingHistos(),
+ fUseMergingEfficiency(true),
fDebug(0)
{
// Constructor
AliFMDCorrections::AliFMDCorrections(const char* title)
: TNamed("fmdCorrections", title),
fRingHistos(),
+ fUseMergingEfficiency(true),
fDebug(0)
{
// Constructor
AliFMDCorrections::AliFMDCorrections(const AliFMDCorrections& o)
: TNamed(o),
fRingHistos(),
+ fUseMergingEfficiency(o.fUseMergingEfficiency),
fDebug(o.fDebug)
{
// Copy constructor
fDebug = o.fDebug;
fRingHistos.Delete();
+ fUseMergingEfficiency = o.fUseMergingEfficiency;
TIter next(&o.fRingHistos);
TObject* obj = 0;
while ((obj = next())) fRingHistos.Add(obj);
// Divide by the event selection efficiency
h->Divide(ef);
-
- // if(!pars->SharingEffPresent()) {
- // AliWarning("No sharing efficiencies");
- // continue;
- // }
- // TH1F* sf = pars->GetSharingEfficiencyTrVtx(d,r,vtxbin);
- if (!fcm.GetMergingEfficiency()) {
- AliWarning("No merging efficiencies");
- continue;
- }
- TH1D* sf = fcm.GetMergingEfficiency()->GetCorrection(d,r,uvb);
- if (!fcm.GetMergingEfficiency()->GetCorrection(d,r,uvb)) {
- AliWarning(Form("No merging efficiency for FMD%d%c at vertex bin %d",
- d, r, uvb));
- continue;
- }
-
-
- for (Int_t ieta = 1; ieta <= h->GetNbinsX(); ieta++) {
- Float_t c = sf->GetBinContent(ieta);
- Float_t ec = sf->GetBinError(ieta);
+ if (fUseMergingEfficiency) {
+ if (!fcm.GetMergingEfficiency()) {
+ AliWarning("No merging efficiencies");
+ continue;
+ }
+ TH1D* sf = fcm.GetMergingEfficiency()->GetCorrection(d,r,uvb);
+ if (!fcm.GetMergingEfficiency()->GetCorrection(d,r,uvb)) {
+ AliWarning(Form("No merging efficiency for FMD%d%c at vertex bin %d",
+ d, r, uvb));
+ continue;
+ }
- if (c == 0) continue;
-
- for (Int_t iphi = 1; iphi <= h->GetNbinsY(); iphi++) {
- Double_t m = h->GetBinContent(ieta, iphi) / c;
- Double_t em = h->GetBinError(ieta, iphi);
+
+ for (Int_t ieta = 1; ieta <= h->GetNbinsX(); ieta++) {
+ Float_t c = sf->GetBinContent(ieta);
+ Float_t ec = sf->GetBinError(ieta);
+
+ if (c == 0) continue;
- Double_t e = TMath::Sqrt(em * em + (m * ec) * (m * ec));
+ for (Int_t iphi = 1; iphi <= h->GetNbinsY(); iphi++) {
+ Double_t m = h->GetBinContent(ieta, iphi) / c;
+ Double_t em = h->GetBinError(ieta, iphi);
- h->SetBinContent(ieta,iphi,m);
- h->SetBinError(ieta,iphi,e);
+ Double_t e = TMath::Sqrt(em * em + (m * ec) * (m * ec));
+
+ h->SetBinContent(ieta,iphi,m);
+ h->SetBinError(ieta,iphi,e);
+ }
}
}
-
rh->fDensity->Add(h);
}
}
* @param dbg Debug level
*/
void SetDebug(Int_t dbg=1) { fDebug = dbg; }
+ void UseMergingEfficiency(Bool_t use=true) { fUseMergingEfficiency = use; }
/**
* Print information
*
*/
RingHistos* GetRingHistos(UShort_t d, Char_t r) const;
- TList fRingHistos; // List of histogram containers
- Int_t fDebug; // Debug level
+ TList fRingHistos; // List of histogram containers
+ Bool_t fUseMergingEfficiency; // Whether to use the merging efficiency
+ Int_t fDebug; // Debug level
- ClassDef(AliFMDCorrections,1); // Calculate Nch density
+ ClassDef(AliFMDCorrections,2); // Calculate Nch density
};
#endif