- Methods to use AliJetFinder together with a TSelector have been implemented.
// a jet, if n,positive, it was assiged to jet n
// if n, negative, it is within cone of jet n, but
// it did not passed the user cuts. filled in by AliJetFinder
-
if (fNInput>0) fInJet.Set(fNInput, j);
}
h->SetMarkerColor(2);
h->SetXTitle(x);
h->SetYTitle(y);
- h->Sumw2();
+ // h->Sumw2();
}
fChain = new TChain("esdTree");
// get directory and pattern name from the header
- const char* dirName=fReaderHeader->GetDirectory();
- const char* pattern=fReaderHeader->GetPattern();
+ const char* dirName=fReaderHeader->GetDirectory();
+ const char* pattern=fReaderHeader->GetPattern();
- // Add files matching patters to the chain
- void *dir = gSystem->OpenDirectory(dirName);
- const char *name = 0x0;
- int nesd = fReaderHeader->GetNesd();
- int a = 0;
- while ((name = gSystem->GetDirEntry(dir))){
- if (a>=nesd) continue;
- if (strstr(name,pattern)){
- printf("Adding %s\n",name);
- char path[256];
- sprintf(path,"%s/%s",dirName,name);
- fChain->AddFile(path,-1);
- a++;
- }
- }
- printf("%d ESDs added\n",a);
+// // Add files matching patters to the chain
+
+ void *dir = gSystem->OpenDirectory(dirName);
+ const char *name = 0x0;
+ int nesd = fReaderHeader->GetNesd();
+ int a = 0;
+ while ((name = gSystem->GetDirEntry(dir))){
+ if (a>=nesd) continue;
+
+ if (strstr(name,pattern)){
+ char path[256];
+ sprintf(path,"%s/%s/AliESDs.root",dirName,name);
+ fChain->AddFile(path);
+ a++;
+ }
+ }
gSystem->FreeDirectory(dir);
+
+
+ fESD = 0;
fChain->SetBranchAddress("ESD", &fESD);
int nMax = fChain->GetEntries();
+
printf("\nTotal number of events in chain= %d",nMax);
// set number of events in header
}
}
+void AliJetESDReader::ConnectTree(TTree* tree) {
+ fChain = (TChain*) tree;
+
+ fChain->SetBranchAddress("ESD", &fESD);
+ Int_t nMax = fChain->GetEntries();
+ printf("\nTotal number of events in chain= %5d", nMax);
+ // set number of events in header
+ if (fReaderHeader->GetLastEvent() == -1)
+ fReaderHeader->SetLastEvent(nMax);
+ else {
+ Int_t nUsr = fReaderHeader->GetLastEvent();
+ fReaderHeader->SetLastEvent(TMath::Min(nMax,nUsr));
+ }
+}
+
//____________________________________________________________________________
-void AliJetESDReader::FillMomentumArray(Int_t event)
+Bool_t AliJetESDReader::FillMomentumArray(Int_t event)
{
// Fill momentum array
TVector3 p3;
// clear momentum array
- ClearArray();
+ ClearArray();
// get event from chain
- fChain->GetEntry(event);
+ fChain->GetTree()->GetEntry(event);
+
+ if (!fESD) {
+ return kFALSE;
+ }
// get number of tracks in event (for the loop)
nt = fESD->GetNumberOfTracks();
-
// temporary storage of signal and pt cut flag
Int_t* sflag = new Int_t[nt];
Int_t* cflag = new Int_t[nt];
// get cuts set by user
- Float_t ptMin = fReaderHeader->GetPtCut();
+ Float_t ptMin = fReaderHeader->GetPtCut();
Float_t etaMin = fReaderHeader->GetFiducialEtaMin();
Float_t etaMax = fReaderHeader->GetFiducialEtaMax();
//loop over tracks
for (Int_t it = 0; it < nt; it++) {
- AliESDtrack *track = fESD->GetTrack(it);
- UInt_t status = track->GetStatus();
-
- Double_t mom[3];
- track->GetPxPyPz(mom);
- p3.SetXYZ(mom[0],mom[1],mom[2]);
- pt = p3.Pt();
- if ((status & AliESDtrack::kTPCrefit) == 0) continue; // quality check
- //if ((status & AliESDtrack::kITSrefit) == 0) continue; // quality check
- if (((AliJetESDReaderHeader*) fReaderHeader)->ReadSignalOnly()
- && TMath::Abs(track->GetLabel()) > 10000) continue; // quality check
- if (((AliJetESDReaderHeader*) fReaderHeader)->ReadBkgdOnly()
- && TMath::Abs(track->GetLabel()) < 10000) continue; // quality check
- eta = p3.Eta();
- if ( (eta > etaMax) || (eta < etaMin)) continue; // checking eta cut
-
- new ((*fMomentumArray)[goodTrack]) TLorentzVector(p3,p3.Mag());
- sflag[goodTrack]=0;
- if (TMath::Abs(track->GetLabel()) < 10000) sflag[goodTrack]=1;
- cflag[goodTrack]=0;
- if (pt > ptMin) cflag[goodTrack]=1; // pt cut
- goodTrack++;
+ AliESDtrack *track = fESD->GetTrack(it);
+ UInt_t status = track->GetStatus();
+
+ Double_t mom[3];
+ track->GetPxPyPz(mom);
+ p3.SetXYZ(mom[0],mom[1],mom[2]);
+ pt = p3.Pt();
+ if ((status & AliESDtrack::kTPCrefit) == 0) continue; // quality check
+ if ((status & AliESDtrack::kITSrefit) == 0) continue; // quality check
+ if (((AliJetESDReaderHeader*) fReaderHeader)->ReadSignalOnly()
+ && TMath::Abs(track->GetLabel()) > 10000) continue; // quality check
+ if (((AliJetESDReaderHeader*) fReaderHeader)->ReadBkgdOnly()
+ && TMath::Abs(track->GetLabel()) < 10000) continue; // quality check
+ eta = p3.Eta();
+ if ( (eta > etaMax) || (eta < etaMin)) continue; // checking eta cut
+
+ new ((*fMomentumArray)[goodTrack]) TLorentzVector(p3,p3.Mag());
+ sflag[goodTrack]=0;
+ if (TMath::Abs(track->GetLabel()) < 10000) sflag[goodTrack]=1;
+ cflag[goodTrack]=0;
+ if (pt > ptMin) cflag[goodTrack]=1; // pt cut
+ goodTrack++;
}
// set the signal flags
fSignalFlag.Set(goodTrack,sflag);
fCutFlag.Set(goodTrack,cflag);
+ return kTRUE;
}
+
+
Int_t GetTrackSign() const {return fSign;} // returns sign of the track
// Setters
- void FillMomentumArray(Int_t event);
- void OpenInputFiles();
-
+ Bool_t FillMomentumArray(Int_t event);
+ void OpenInputFiles();
+ void ConnectTree(TTree* tree);
+
protected:
Float_t fMass; // Particle mass
Int_t fSign; // Particle sign
//---------------------------------------------------------------------
// Jet finder base class
// manages the search for jets
-// Author: jgcn@mda.cinvestav.mx
+// Authors: jgcn@mda.cinvestav.mx
+// andreas.morsch@cern.ch
//---------------------------------------------------------------------
#include <Riostream.h>
#include <TFile.h>
-#include "AliGenPythiaEventHeader.h"
#include "AliJetFinder.h"
#include "AliJet.h"
#include "AliJetReader.h"
#include "AliJetReaderHeader.h"
#include "AliJetControlPlots.h"
#include "AliLeading.h"
-#include "AliHeader.h"
ClassImp(AliJetFinder)
-
AliJetFinder::AliJetFinder():
- fPlotMode(kFALSE),
- fJets(0),
- fGenJets(0),
- fLeading(0),
- fReader(0x0),
- fPlots(0x0),
- fOut(0x0)
-
+ fPlotMode(kFALSE),
+ fJets(0),
+ fGenJets(0),
+ fLeading(0),
+ fReader(0x0),
+ fPlots(0x0),
+ fOut(0x0)
+
{
// Constructor
- //fOut = 0x0;
fJets = new AliJet();
fGenJets = new AliJet();
fLeading = new AliLeading();
- //fReader = 0x0;
- //fPlots = 0x0;
- //SetPlotMode(kFALSE);
}
////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////
-void AliJetFinder::GetGenJets()
-{
- // Get the generated jet information from mc header
- AliHeader* alih = fReader->GetAliHeader();
- if (alih == 0) return;
- AliGenEventHeader * genh = alih->GenEventHeader();
- if (genh == 0) return;
- Int_t nj =((AliGenPythiaEventHeader*)genh)->NTriggerJets();
- Int_t* m = new Int_t[nj];
- Int_t* k = new Int_t[nj];
- for (Int_t i=0; i< nj; i++) {
- Float_t p[4];
- ((AliGenPythiaEventHeader*)genh)->TriggerJet(i,p);
- fGenJets->AddJet(p[0],p[1],p[2],p[3]);
- m[i]=1;
- k[i]=i;
- }
- fGenJets->SetNinput(nj);
- fGenJets->SetMultiplicities(m);
- fGenJets->SetInJet(k);
-}
-
-////////////////////////////////////////////////////////////////////////
void AliJetFinder::Run()
{
- // do some initialization
+ // Do some initialization
Init();
-
// connect files
fReader->OpenInputFiles();
// write headers
- if (fOut) {
- fOut->cd();
- WriteRHeaderToFile();
- WriteJHeaderToFile();
- }
+ WriteHeaders();
// loop over events
Int_t nFirst,nLast;
nFirst = fReader->GetReaderHeader()->GetFirstEvent();
for (Int_t i=nFirst;i<nLast;i++) {
fReader->FillMomentumArray(i);
fLeading->FindLeading(fReader);
- GetGenJets();
+ fReader->GetGenJets(fGenJets);
FindJets();
if (fOut) WriteJetsToFile(i);
if (fPlots) fPlots->FillHistos(fJets);
fOut->Close();
}
}
+
+
+//
+// The following methods have been added to allow for event steering from the outside
+//
+
+void AliJetFinder::ConnectTree(TTree* tree)
+{
+ // Connect the input file
+ fReader->ConnectTree(tree);
+}
+
+void AliJetFinder::WriteHeaders()
+{
+ // Write the Headers
+ if (fOut) {
+ fOut->cd();
+ WriteRHeaderToFile();
+ WriteJHeaderToFile();
+ }
+}
+
+
+Bool_t AliJetFinder::ProcessEvent(Long64_t entry)
+{
+//
+// Process one event
+//
+ printf("<<<<< Processing Event %5d >>>>> \n", (Int_t) entry);
+ Bool_t ok = fReader->FillMomentumArray(entry);
+ if (!ok) return kFALSE;
+ fLeading->FindLeading(fReader);
+ FindJets();
+ if (fOut) WriteJetsToFile(entry);
+ if (fPlots) fPlots->FillHistos(fJets);
+ fLeading->Reset();
+ fGenJets->ClearJets();
+ Reset();
+ return kTRUE;
+}
+
+void AliJetFinder::FinishRun()
+{
+ // Finish a run
+ if (fPlots) {
+ fPlots->Normalize();
+ fPlots->PlotHistos();
+ }
+ if (fOut) {
+ fOut->cd();
+ fPlots->Write();
+ fOut->Close();
+ }
+}
+
//---------------------------------------------------------------------
// Jet finder base class
// manages the search for jets
-// Author: jgcn@mda.cinvestav.mx
+// Authors: jgcn@mda.cinvestav.mx
+// andreas.morsch@cern.ch
//---------------------------------------------------------------------
#include <TObject.h>
+#include <AliJetHeader.h>
class TFile;
+class TTree;
class AliJet;
class AliJetReader;
class AliJetControlPlots;
class AliJetFinder : public TObject
{
public:
-
AliJetFinder();
virtual ~AliJetFinder();
virtual void SetPlotMode(Bool_t b);
virtual void SetOutputFile(const char *name="jets.root");
virtual void SetJetReader(AliJetReader* r) {fReader=r;}
+ virtual void SetJetHeader(AliJetHeader* h) {fHeader=h;}
// others
- virtual void PrintJets();
- virtual void Run();
- virtual void WriteJetsToFile(Int_t i);
- virtual void WriteRHeaderToFile();
+ virtual void PrintJets();
+ virtual void Run();
+ virtual void WriteJetsToFile(Int_t i);
+ virtual void WriteRHeaderToFile();
// the following have to be implemented for each specific finder
- virtual void Init() { }
+ virtual void Init() {}
virtual void Reset() { }
virtual void FindJets() { }
virtual void WriteJHeaderToFile() { }
- virtual void GetGenJets();
+ // some methods to allow steering from the outside
+ virtual Bool_t ProcessEvent(Long64_t entry);
+ virtual void FinishRun();
+ virtual void ConnectTree(TTree* tree);
+ virtual void WriteHeaders();
protected:
AliJetFinder(const AliJetFinder& rJetFinder);
Bool_t fPlotMode; // do you want control plots?
AliJet* fJets; // pointer to jet class
AliJet* fGenJets; // pointer to generated jets
- AliLeading* fLeading; // pointer to leading particle data
+ AliLeading* fLeading; // pointer to leading particle data
AliJetReader* fReader; // pointer to reader
+ AliJetHeader* fHeader; // pointer to header
AliJetControlPlots* fPlots; // pointer to control plots
TFile* fOut; // output file
-
- ClassDef(AliJetFinder,1)
+ ClassDef(AliJetFinder,2)
};
#endif
fArrayMC(0),
fESD(0),
fReaderHeader(0),
- fAliHeader(0),
fSignalFlag(0),
fCutFlag(0)
delete fChain;
delete fChainMC;
delete fESD;
- delete fAliHeader;
if (fMomentumArray) {
fMomentumArray->Delete();
delete fMomentumArray;
#include <TObject.h>
#include <TChain.h>
#include <TArrayI.h>
-
+class TTree;
class TClonesArray;
class AliJetReaderHeader;
class AliESD;
-class AliHeader;
+class AliJet;
class AliJetReader : public TObject
{
virtual TClonesArray *GetMomentumArray() {return fMomentumArray;}
virtual Int_t GetChainEntries() {return fChain->GetEntries();}
virtual AliJetReaderHeader* GetReaderHeader() { return fReaderHeader;}
- virtual AliHeader* GetAliHeader() {return fAliHeader;}
virtual Int_t GetSignalFlag(Int_t i) const {return fSignalFlag[i];}
virtual Int_t GetCutFlag(Int_t i) const {return fCutFlag[i];}
-
+
// Setters
- virtual void FillMomentumArray(Int_t) {}
- virtual void SetReaderHeader(AliJetReaderHeader* header)
+ virtual Bool_t FillMomentumArray(Int_t) {return kTRUE;}
+ virtual void SetReaderHeader(AliJetReaderHeader* header)
{fReaderHeader = header;}
- // others
- virtual void OpenInputFiles() {}
+ // Others
+ virtual void OpenInputFiles() {}
+ virtual void ConnectTree(TTree* /*tree*/) {}
+ virtual Bool_t GetGenJets(AliJet* /*genJets*/) {return kFALSE;}
+
void ClearArray();
protected:
TClonesArray *fArrayMC; // array of mc particles
AliESD *fESD; // pointer to esd
AliJetReaderHeader *fReaderHeader; // pointer to header
- AliHeader *fAliHeader; // pointer to event header
TArrayI fSignalFlag; // to flag if a particle comes from pythia or
// from the underlying event
TArrayI fCutFlag; // to flag if a particle passed the pt cut or not
//5) fill AliJet list
// transform input to pt,eta,phi plus lego
+
+ AliUA1JetHeaderV1* header = (AliUA1JetHeaderV1*) fHeader;
TClonesArray *lvArray = fReader->GetMomentumArray();
Int_t nIn = lvArray->GetEntries();
if (nIn == 0) return;
Int_t* multJet = new Int_t[30];
Int_t nJets; // to hold number of jets found by algorithm
Int_t nj; // number of jets accepted
- Float_t prec = fHeader->GetPrecBg();
+ Float_t prec = header->GetPrecBg();
Float_t bgprec = 1;
while(bgprec > prec){
//reset jet arrays in memory
//run cone algorithm finder
RunAlgoritm(etbgTotal,dEtTotal,nJets,etJet,etaJet,phiJet,etallJet,ncellsJet);
//run background subtraction
- if(nJets > fHeader->GetNAcceptJets()) // limited number of accepted jets per event
- nj = fHeader->GetNAcceptJets();
+ if(nJets > header->GetNAcceptJets()) // limited number of accepted jets per event
+ nj = header->GetNAcceptJets();
else
nj = nJets;
//subtract background
Float_t etbgTotalN = 0.0; //new background
- if(fHeader->GetBackgMode() == 1) // standar
+ if(header->GetBackgMode() == 1) // standar
SubtractBackg(nIn,nj,etbgTotalN,ptT,etaT,phiT,etJet,etaJet,phiJet,etsigJet,multJet,injet);
- if(fHeader->GetBackgMode() == 2) //cone
+ if(header->GetBackgMode() == 2) //cone
SubtractBackgCone(nIn,nj,etbgTotalN,ptT,etaT,phiT,etJet,etaJet,phiJet,etsigJet,multJet,injet);
- if(fHeader->GetBackgMode() == 3) //ratio
+ if(header->GetBackgMode() == 3) //ratio
SubtractBackgRatio(nIn,nj,etbgTotalN,ptT,etaT,phiT,etJet,etaJet,phiJet,etsigJet,multJet,injet);
- if(fHeader->GetBackgMode() == 4) //statistic
+ if(header->GetBackgMode() == 4) //statistic
SubtractBackgStat(nIn,nj,etbgTotalN,ptT,etaT,phiT,etJet,etaJet,phiJet,etsigJet,multJet,injet);
//calc precision
if(etbgTotalN != 0.0)
Int_t* idxjets = new Int_t[nj];
Int_t nselectj = 0;
for(Int_t kj=0; kj<nj; kj++){
- if ((etaJet[kj] > (fHeader->GetJetEtaMax())) ||
- (etaJet[kj] < (fHeader->GetJetEtaMin())) ||
- (etJet[kj] < fHeader->GetMinJetEt())) continue; // acceptance eta range and etmin
+ if ((etaJet[kj] > (header->GetJetEtaMax())) ||
+ (etaJet[kj] < (header->GetJetEtaMin())) ||
+ (etJet[kj] < header->GetMinJetEt())) continue; // acceptance eta range and etmin
Float_t px, py,pz,en; // convert to 4-vector
px = etJet[kj] * TMath::Cos(phiJet[kj]);
py = etJet[kj] * TMath::Sin(phiJet[kj]);
fJets->SetEtaIn(etaT);
fJets->SetPhiIn(phiT);
fJets->SetPtIn(ptT);
- fJets->SetEtAvg(etbgTotal/(4*(fHeader->GetLegoEtaMax())*TMath::Pi()));
+ fJets->SetEtAvg(etbgTotal/(4*(header->GetLegoEtaMax())*TMath::Pi()));
//delete
//dump lego
// check enough space! *to be done*
+ AliUA1JetHeaderV1* header = (AliUA1JetHeaderV1*) fHeader;
Float_t etCell[60000]; //! Cell Energy
Float_t etaCell[60000]; //! Cell eta
Float_t phiCell[60000]; //! Cell phi
TAxis* xaxis = fLego->GetXaxis();
TAxis* yaxis = fLego->GetYaxis();
Float_t e = 0.0;
- for (Int_t i = 1; i <= fHeader->GetLegoNbinEta(); i++) {
- for (Int_t j = 1; j <= fHeader->GetLegoNbinPhi(); j++) {
+ for (Int_t i = 1; i <= header->GetLegoNbinEta(); i++) {
+ for (Int_t j = 1; j <= header->GetLegoNbinPhi(); j++) {
e = fLego->GetBinContent(i,j);
if (e < 0.0) continue; // don't include this cells
Float_t eta = xaxis->GetBinCenter(i);
}
// Parameters from header
- Float_t minmove = fHeader->GetMinMove();
- Float_t maxmove = fHeader->GetMaxMove();
- Float_t rc = fHeader->GetRadius();
- Float_t etseed = fHeader->GetEtSeed();
- //Float_t etmin = fHeader->GetMinJetEt();
+ Float_t minmove = header->GetMinMove();
+ Float_t maxmove = header->GetMaxMove();
+ Float_t rc = header->GetRadius();
+ Float_t etseed = header->GetEtSeed();
+ //Float_t etmin = header->GetMinJetEt();
//flag cells in Rc, estimate total energy in cone
Float_t etCone = 0.0;
Int_t nCellIn = 0;
- rc = fHeader->GetRadius();
+ rc = header->GetRadius();
for(Int_t ncell =0; ncell < nCell; ncell++){
if(flagCell[ncell] != 0) continue; // cell used before
//calculate dr
//background subtraction using cone method but without correction in dE/deta distribution
//calculate energy inside and outside cones
- Float_t rc= fHeader->GetRadius();
+ AliUA1JetHeaderV1* header = (AliUA1JetHeaderV1*) fHeader;
+ Float_t rc= header->GetRadius();
Float_t etIn[30];
Float_t etOut = 0;
for(Int_t jpart = 0; jpart < nIn; jpart++){ // loop for all particles in array
//estimate jets and background areas
Float_t areaJet[30];
- Float_t areaOut = 4*(fHeader->GetLegoEtaMax())*TMath::Pi();
+ Float_t areaOut = 4*(header->GetLegoEtaMax())*TMath::Pi();
for(Int_t k=0; k<nJ; k++){
Float_t detamax = etaJet[k] + rc;
Float_t detamin = etaJet[k] - rc;
Float_t accmax = 0.0; Float_t accmin = 0.0;
- if(detamax > fHeader->GetLegoEtaMax()){ // sector outside etamax
- Float_t h = fHeader->GetLegoEtaMax() - etaJet[k];
+ if(detamax > header->GetLegoEtaMax()){ // sector outside etamax
+ Float_t h = header->GetLegoEtaMax() - etaJet[k];
accmax = rc*rc*TMath::ACos(h/rc) - h*TMath::Sqrt(rc*rc - h*h);
}
- if(detamin < fHeader->GetLegoEtaMin()){ // sector outside etamin
- Float_t h = fHeader->GetLegoEtaMax() + etaJet[k];
+ if(detamin < header->GetLegoEtaMin()){ // sector outside etamin
+ Float_t h = header->GetLegoEtaMax() + etaJet[k];
accmin = rc*rc*TMath::ACos(h/rc) - h*TMath::Sqrt(rc*rc - h*h);
}
areaJet[k] = rc*rc*TMath::Pi() - accmax - accmin;
}
// estimate new total background
- Float_t areaT = 4*(fHeader->GetLegoEtaMax())*TMath::Pi();
+ Float_t areaT = 4*(header->GetLegoEtaMax())*TMath::Pi();
etbgTotalN = etOut*areaT/areaOut;
{
//background subtraction using statistical method
-
- Float_t etbgStat = fHeader->GetBackgStat(); // pre-calculated background
+ AliUA1JetHeaderV1* header = (AliUA1JetHeaderV1*) fHeader;
+ Float_t etbgStat = header->GetBackgStat(); // pre-calculated background
//calculate energy inside
- Float_t rc= fHeader->GetRadius();
+ Float_t rc= header->GetRadius();
Float_t etIn[30];
for(Int_t jpart = 0; jpart < nIn; jpart++){ // loop for all particles in array
//calc jets areas
Float_t areaJet[30];
- Float_t areaOut = 4*(fHeader->GetLegoEtaMax())*TMath::Pi();
+ Float_t areaOut = 4*(header->GetLegoEtaMax())*TMath::Pi();
for(Int_t k=0; k<nJ; k++){
Float_t detamax = etaJet[k] + rc;
Float_t detamin = etaJet[k] - rc;
Float_t accmax = 0.0; Float_t accmin = 0.0;
- if(detamax > fHeader->GetLegoEtaMax()){ // sector outside etamax
- Float_t h = fHeader->GetLegoEtaMax() - etaJet[k];
+ if(detamax > header->GetLegoEtaMax()){ // sector outside etamax
+ Float_t h = header->GetLegoEtaMax() - etaJet[k];
accmax = rc*rc*TMath::ACos(h/rc) - h*TMath::Sqrt(rc*rc - h*h);
}
- if(detamin < fHeader->GetLegoEtaMin()){ // sector outside etamin
- Float_t h = fHeader->GetLegoEtaMax() + etaJet[k];
+ if(detamin < header->GetLegoEtaMin()){ // sector outside etamin
+ Float_t h = header->GetLegoEtaMax() + etaJet[k];
accmin = rc*rc*TMath::ACos(h/rc) - h*TMath::Sqrt(rc*rc - h*h);
}
areaJet[k] = rc*rc*TMath::Pi() - accmax - accmin;
Int_t* multJet, Int_t* injet)
{
// Cone background subtraction method taking into acount dEt/deta distribution
-
+ AliUA1JetHeaderV1* header = (AliUA1JetHeaderV1*) fHeader;
//general
- Float_t rc= fHeader->GetRadius();
- Float_t etamax = fHeader->GetLegoEtaMax();
- Float_t etamin = fHeader->GetLegoEtaMin();
+ Float_t rc= header->GetRadius();
+ Float_t etamax = header->GetLegoEtaMax();
+ Float_t etamin = header->GetLegoEtaMin();
Int_t ndiv = 100;
// jet energy and area arrays
// calc background total
Double_t etOut = hEtBackg->Integral();
Double_t areaOut = hAreaBackg->Integral();
- Float_t areaT = 4*(fHeader->GetLegoEtaMax())*TMath::Pi();
+ Float_t areaT = 4*(header->GetLegoEtaMax())*TMath::Pi();
etbgTotalN = etOut*areaT/areaOut;
//delete
Int_t* multJet, Int_t* injet)
{
// Ratio background subtraction method taking into acount dEt/deta distribution
-
+ AliUA1JetHeaderV1* header = (AliUA1JetHeaderV1*) fHeader;
//factor F calc before
- Float_t bgRatioCut = fHeader->GetBackgCutRatio();
+ Float_t bgRatioCut = header->GetBackgCutRatio();
//general
- Float_t rc= fHeader->GetRadius();
- Float_t etamax = fHeader->GetLegoEtaMax();
- Float_t etamin = fHeader->GetLegoEtaMin();
+ Float_t rc= header->GetRadius();
+ Float_t etamax = header->GetLegoEtaMax();
+ Float_t etamin = header->GetLegoEtaMin();
Int_t ndiv = 100;
// jet energy and area arrays
// calc background total
Double_t etOut = hEtBackg->Integral();
Double_t areaOut = hAreaBackg->Integral();
- Float_t areaT = 4*(fHeader->GetLegoEtaMax())*TMath::Pi();
+ Float_t areaT = 4*(header->GetLegoEtaMax())*TMath::Pi();
etbgTotalN = etOut*areaT/areaOut;
//delete
void AliUA1JetFinderV1::WriteJHeaderToFile()
{
+ AliUA1JetHeaderV1* header = (AliUA1JetHeaderV1*) fHeader;
fOut->cd();
- fHeader->Write();
+ header->Write();
}
////////////////////////////////////////////////////////////////////////
void AliUA1JetFinderV1::Init()
{
// initializes some variables
-
+ AliUA1JetHeaderV1* header = (AliUA1JetHeaderV1*) fHeader;
// book lego
fLego = new
TH2F("legoH","eta-phi",
- fHeader->GetLegoNbinEta(), fHeader->GetLegoEtaMin(),
- fHeader->GetLegoEtaMax(), fHeader->GetLegoNbinPhi(),
- fHeader->GetLegoPhiMin(), fHeader->GetLegoPhiMax());
+ header->GetLegoNbinEta(), header->GetLegoEtaMin(),
+ header->GetLegoEtaMax(), header->GetLegoNbinPhi(),
+ header->GetLegoPhiMin(), header->GetLegoPhiMax());
}
AliUA1JetFinderV1();
~AliUA1JetFinderV1();
- // getters
-
- // setters
- void SetJetHeader(AliUA1JetHeaderV1* h) {fHeader= h;}
// others
void FindJets();
void RunAlgoritm(Float_t EtbgTotal, Double_t dEtTotal, Int_t& nJets,
protected:
AliUA1JetFinderV1(const AliUA1JetFinderV1& rJetF1);
AliUA1JetFinderV1& operator = (const AliUA1JetFinderV1& rhsf);
-
- AliUA1JetHeaderV1* fHeader; // pointer to jet header
TH2F * fLego; //! Lego Histo
ClassDef(AliUA1JetFinderV1,1)