+
/**************************************************************************
* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
* *
/*
$Log$
+Revision 1.6 2002/01/21 12:53:50 morsch
+authors
+
+Revision 1.5 2002/01/21 12:47:47 morsch
+Possibility to include K0long and neutrons.
+
+Revision 1.4 2002/01/21 11:03:21 morsch
+Phi propagation introduced in FillFromTracks.
+
+Revision 1.3 2002/01/18 05:07:56 morsch
+- hadronic correction
+- filling of digits
+- track selection upon EMCAL information
+
*/
-//*-- Author: Andreas Morsch (CERN)
-//* J.L. Klay (LBL)
+//*-- Authors: Andreas Morsch (CERN)
+//* J.L. Klay (LBL)
+//* Aleksei Pavlinov (WSU)
+
// From root ...
#include <TClonesArray.h>
#include <TTree.h>
#include "AliEMCALHadronCorrection.h"
#include "Ecommon.h"
#include "AliRun.h"
+#include "AliMagF.h"
+#include "AliMagFCM.h"
#include "AliEMCAL.h"
#include "AliHeader.h"
+#include "AliPDG.h"
ClassImp(AliEMCALJetFinder)
fEtaT = 0;
fPhiT = 0;
fHadronCorrector = 0;
+//
SetPtCut();
SetMomentumSmearing();
SetEfficiencySim();
SetDebug();
SetHadronCorrection();
SetSamplingFraction();
+ SetIncludeK0andN();
}
if (part < 2) continue;
if (pT == 0 || pT < fPtCut) continue;
+ TParticlePDG* pdgP = 0;
// charged or neutral
if (ich == 0) {
- TParticlePDG* pdgP = MPart->GetPDG();
- if (pdgP->Charge() == 0) continue;
+ pdgP = MPart->GetPDG();
+ if (pdgP->Charge() == 0) {
+ if (!fK0N) {
+ continue;
+ } else {
+ if (mpart != kNeutron &&
+ mpart != kNeutronBar &&
+ mpart != kK0Long) continue;
+ }
+ }
}
// skip partons
if (TMath::Abs(mpart) <= 6 ||
printf("\n sel:%5d %5d %5d %8.2f %8.2f %8.2f",
part, mpart, child1, eta, phi, pT);
//
+//
+// phi propagation
+
+ Bool_t curls = kFALSE;
+ Float_t dphi = PropagatePhi(pT, pdgP->Charge(), curls);
+ if (curls) continue;
+ phi += dphi;
+//
// Momentum smearing goes here ...
//
if (fSmear) {
} // jet loop loop
}
+Float_t AliEMCALJetFinder::PropagatePhi(Float_t pt, Float_t charge, Bool_t& curls)
+{
+// Propagates phi angle to EMCAL radius
+//
+ Float_t dPhi = 0.;
+// Get field
+ Float_t b = ((AliMagFCM*) gAlice->Field())->SolenoidField();
+// Get EMCAL radius
+ Float_t rEMCAL = AliEMCALGeometry::GetInstance()->GetIPDistance();
+//
+//
+// bending radies
+ Float_t rB = 333.56 * pt / b;
+
+//
+// check if particle is curling below EMCAL
+ if (2.*rB < rEMCAL) {
+ curls = kTRUE;
+ return dPhi;
+ }
+//
+// if not calculate delta phi
+ Float_t phi = TMath::ACos(1.-rEMCAL*rEMCAL/(2.*rB*rB));
+ dPhi = TMath::ATan2(1.-TMath::Cos(phi), TMath::Sin(phi));
+ dPhi = TMath::Sign(dPhi, charge);
+//
+ return dPhi;
+
+}
+
+
void hf1(Int_t& id, Float_t& x, Float_t& wgt)
{
// dummy for hbook calls