Adds new classes to the AliFemto package that are "AOD aware"
authorakisiel <akisiel@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 18 Feb 2008 10:57:59 +0000 (10:57 +0000)
committerakisiel <akisiel@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 18 Feb 2008 10:57:59 +0000 (10:57 +0000)
Provides a class that reads in the AOD for femtoscopic analysis
both in the local and "Analysis Task" environment
Provides a track cut that works on the AOD information only
All the classes are able to handle PWG2-specific AOD
Updates PWG2 library makefiles

PWG2/FEMTOSCOPY/AliFemto/AliFemtoAODTrackCut.cxx [new file with mode: 0644]
PWG2/FEMTOSCOPY/AliFemto/AliFemtoAODTrackCut.h [new file with mode: 0644]
PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderAOD.cxx [new file with mode: 0644]
PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderAOD.h [new file with mode: 0644]
PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderAODChain.cxx [new file with mode: 0644]
PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderAODChain.h [new file with mode: 0644]
PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderESD.h
PWG2/PWG2femtoscopyLinkDef.h
PWG2/libPWG2femtoscopy.pkg

diff --git a/PWG2/FEMTOSCOPY/AliFemto/AliFemtoAODTrackCut.cxx b/PWG2/FEMTOSCOPY/AliFemto/AliFemtoAODTrackCut.cxx
new file mode 100644 (file)
index 0000000..f96d05a
--- /dev/null
@@ -0,0 +1,374 @@
+/***************************************************************************
+ *
+ * $Id: AliFemtoAODTrackCut.cxx 23733 2008-02-05 16:51:41Z akisiel $ 
+ *
+ * 
+ ***************************************************************************
+ *
+ * 
+ *              
+ *
+ ***************************************************************************
+ *
+ * $Log$
+ * Revision 1.3  2007/05/22 09:01:42  akisiel
+ * Add the possibiloity to save cut settings in the ROOT file
+ *
+ * Revision 1.2  2007/05/21 10:38:25  akisiel
+ * More coding rule conformance
+ *
+ * Revision 1.1  2007/05/16 10:25:06  akisiel
+ * Making the directory structure of AliFemtoUser flat. All files go into one common directory
+ *
+ * Revision 1.4  2007/05/03 09:46:10  akisiel
+ * Fixing Effective C++ warnings
+ *
+ * Revision 1.3  2007/04/27 07:25:59  akisiel
+ * Make revisions needed for compilation from the main AliRoot tree
+ *
+ * Revision 1.1.1.1  2007/04/25 15:38:41  panos
+ * Importing the HBT code dir
+ *
+ * Revision 1.4  2007-04-03 16:00:08  mchojnacki
+ * Changes to iprove memory managing
+ *
+ * Revision 1.3  2007/03/13 15:30:03  mchojnacki
+ * adding reader for simulated data
+ *
+ * Revision 1.2  2007/03/08 14:58:03  mchojnacki
+ * adding some alice stuff
+ *
+ * Revision 1.1.1.1  2007/03/07 10:14:49  mchojnacki
+ * First version on CVS
+ *
+ **************************************************************************/
+
+#include "AliFemtoAODTrackCut.h"
+#include <cstdio>
+
+#ifdef __ROOT__ 
+ClassImp(AliFemtoAODTrackCut)
+#endif
+
+
+// electron
+// 0.13 - 1.8
+// 0       7.594129e-02    8.256141e-03
+// 1       -5.535827e-01   8.170825e-02
+// 2       1.728591e+00    3.104210e-01
+// 3       -2.827893e+00   5.827802e-01
+// 4       2.503553e+00    5.736207e-01
+// 5       -1.125965e+00   2.821170e-01
+// 6       2.009036e-01    5.438876e-02
+
+// pion
+// 0.13 - 2.0
+// 0       1.063457e+00    8.872043e-03
+// 1       -4.222208e-01   2.534402e-02
+// 2       1.042004e-01    1.503945e-02
+
+// kaon
+// 0.18 - 2.0
+// 0       -7.289406e-02   1.686074e-03
+// 1       4.415666e-01    1.143939e-02
+// 2       -2.996790e-01   1.840964e-02
+// 3       6.704652e-02    7.783990e-03
+
+// proton
+// 0.26 - 2.0
+// 0       -3.730200e-02   2.347311e-03
+// 1       1.163684e-01    1.319316e-02
+// 2       8.354116e-02    1.997948e-02
+// 3       -4.608098e-02   8.336400e-03
+
+
+AliFemtoAODTrackCut::AliFemtoAODTrackCut() :
+    fCharge(0),
+    fLabel(0),
+    fMaxchiNdof(1000.0),
+    fMaxSigmaToVertex(1000.0),
+    fNTracksPassed(0),
+    fNTracksFailed(0),
+    fMostProbable(0)
+{
+  // Default constructor
+  fNTracksPassed = fNTracksFailed = 0;
+  fCharge = 0;  // takes both charges 0
+  fPt[0]=0.0;              fPt[1] = 100.0;//100
+  fRapidity[0]=-2;       fRapidity[1]=2;//-2 2
+  fPidProbElectron[0]=-1;fPidProbElectron[1]=2;
+  fPidProbPion[0]=-1;    fPidProbPion[1]=2;
+  fPidProbKaon[0]=-1;fPidProbKaon[1]=2;
+  fPidProbProton[0]=-1;fPidProbProton[1]=2;
+  fPidProbMuon[0]=-1;fPidProbMuon[1]=2;
+  fLabel=false;
+}
+//------------------------------
+AliFemtoAODTrackCut::~AliFemtoAODTrackCut(){
+  /* noop */
+}
+//------------------------------
+bool AliFemtoAODTrackCut::Pass(const AliFemtoTrack* track)
+{
+  // test the particle and return 
+  // true if it meets all the criteria
+  // false if it doesn't meet at least one of the criteria
+  float tMost[5];
+  
+  if (((track->ITSchi2() + track->TPCchi2())/(track->ITSncls() + track->TPCncls())) > fMaxchiNdof) {
+    return false;
+  }
+
+  if (fMaxSigmaToVertex < track->SigmaToVertex()) {
+    return false;
+  }
+  
+  if (fLabel)
+    {
+      //cout<<"labels"<<endl;
+      if(track->Label()<0)
+       {
+         fNTracksFailed++;
+         //   cout<<"No Go Through the cut"<<endl;
+         //  cout<<fLabel<<" Label="<<track->Label()<<endl;
+         return false;
+       }    
+    }
+  if (fCharge!=0)
+    {              
+      //cout<<"AliFemtoESD  cut ch "<<endl;
+      //cout<<fCharge<<" Charge="<<track->Charge()<<endl;
+      if (track->Charge()!= fCharge)   
+       {
+         fNTracksFailed++;
+         //  cout<<"No Go Through the cut"<<endl;
+         // cout<<fCharge<<" Charge="<<track->Charge()<<endl;
+         return false;
+       }
+    }
+  float tEnergy = ::sqrt(track->P().mag2()+fMass*fMass);
+  float tRapidity = 0.5*::log((tEnergy+track->P().z())/(tEnergy-track->P().z()));
+  float tPt = ::sqrt((track->P().x())*(track->P().x())+(track->P().y())*(track->P().y()));
+  if ((tRapidity<fRapidity[0])||(tRapidity>fRapidity[1]))
+    {
+      fNTracksFailed++;
+      //cout<<"No Go Through the cut"<<endl;   
+      //cout<<fRapidity[0]<<" < Rapidity ="<<tRapidity<<" <"<<fRapidity[1]<<endl;
+      return false;
+    }
+  if ((tPt<fPt[0])||(tPt>fPt[1]))
+    {
+      fNTracksFailed++;
+      //cout<<"No Go Through the cut"<<endl;
+      //cout<<fPt[0]<<" < Pt ="<<Pt<<" <"<<fPt[1]<<endl;
+      return false;
+    }
+
+    
+  if ((track->PidProbElectron()<fPidProbElectron[0])||(track->PidProbElectron()>fPidProbElectron[1]))
+    {
+      fNTracksFailed++;
+      //cout<<"No Go Through the cut"<<endl;
+      //cout<<fPidProbElectron[0]<<" < e ="<<track->PidProbElectron()<<" <"<<fPidProbElectron[1]<<endl;
+      return false;
+    }
+  if ((track->PidProbPion()<fPidProbPion[0])||(track->PidProbPion()>fPidProbPion[1]))
+    {
+      fNTracksFailed++;
+      //cout<<"No Go Through the cut"<<endl;
+      //cout<<fPidProbPion[0]<<" < pi ="<<track->PidProbPion()<<" <"<<fPidProbPion[1]<<endl;
+      return false;
+    }
+  if ((track->PidProbKaon()<fPidProbKaon[0])||(track->PidProbKaon()>fPidProbKaon[1]))
+    {
+      fNTracksFailed++;
+      //cout<<"No Go Through the cut"<<endl;
+      //cout<<fPidProbKaon[0]<<" < k ="<<track->PidProbKaon()<<" <"<<fPidProbKaon[1]<<endl;
+      return false;
+    }
+  if ((track->PidProbProton()<fPidProbProton[0])||(track->PidProbProton()>fPidProbProton[1]))
+    {
+      fNTracksFailed++;
+      //cout<<"No Go Through the cut"<<endl;
+      //cout<<fPidProbProton[0]<<" < p  ="<<track->PidProbProton()<<" <"<<fPidProbProton[1]<<endl;
+      return false;
+    }
+  if ((track->PidProbMuon()<fPidProbMuon[0])||(track->PidProbMuon()>fPidProbMuon[1]))
+    {
+      fNTracksFailed++;
+      //cout<<"No Go Through the cut"<<endl;
+      //cout<<fPidProbMuon[0]<<" <  mi="<<track->PidProbMuon()<<" <"<<fPidProbMuon[1]<<endl;
+      return false;
+    }
+
+  if (fMostProbable) {
+    tMost[0] = track->PidProbElectron()*PidFractionElectron(track->P().mag());
+    tMost[1] = 0.0;
+    tMost[2] = track->PidProbPion()*PidFractionPion(track->P().mag());
+    tMost[3] = track->PidProbKaon()*PidFractionKaon(track->P().mag());
+    tMost[4] = track->PidProbProton()*PidFractionProton(track->P().mag());
+    int imost=0;
+    float ipidmax = 0.0;
+    for (int ip=0; ip<5; ip++)
+      if (tMost[ip] > ipidmax) { ipidmax = tMost[ip]; imost = ip; };
+    if (imost != fMostProbable) return false;
+  }
+  
+  // cout<<"Go Through the cut"<<endl;
+  // cout<<fLabel<<" Label="<<track->Label()<<endl;
+  // cout<<fCharge<<" Charge="<<track->Charge()<<endl;
+  // cout<<fPt[0]<<" < Pt ="<<Pt<<" <"<<fPt[1]<<endl;
+  //cout<<fRapidity[0]<<" < Rapidity ="<<tRapidity<<" <"<<fRapidity[1]<<endl;
+  //cout<<fPidProbElectron[0]<<" <  e="<<track->PidProbElectron()<<" <"<<fPidProbElectron[1]<<endl;
+  //cout<<fPidProbPion[0]<<" <  pi="<<track->PidProbPion()<<" <"<<fPidProbPion[1]<<endl;
+  //cout<<fPidProbKaon[0]<<" <  k="<<track->PidProbKaon()<<" <"<<fPidProbKaon[1]<<endl;
+  //cout<<fPidProbProton[0]<<" <  p="<<track->PidProbProton()<<" <"<<fPidProbProton[1]<<endl;
+  //cout<<fPidProbMuon[0]<<" <  mi="<<track->PidProbMuon()<<" <"<<fPidProbMuon[1]<<endl;
+  fNTracksPassed++ ;
+  return true;
+    
+    
+}
+//------------------------------
+AliFemtoString AliFemtoAODTrackCut::Report()
+{
+  // Prepare report from the execution
+  string tStemp;
+  char tCtemp[100];
+  sprintf(tCtemp,"Particle mass:\t%E\n",this->Mass());
+  tStemp=tCtemp;
+  sprintf(tCtemp,"Particle charge:\t%d\n",fCharge);
+  tStemp+=tCtemp;
+  sprintf(tCtemp,"Particle pT:\t%E - %E\n",fPt[0],fPt[1]);
+  tStemp+=tCtemp;
+  sprintf(tCtemp,"Particle rapidity:\t%E - %E\n",fRapidity[0],fRapidity[1]);
+  tStemp+=tCtemp;
+  sprintf(tCtemp,"Number of tracks which passed:\t%ld  Number which failed:\t%ld\n",fNTracksPassed,fNTracksFailed);
+  tStemp += tCtemp;
+  AliFemtoString returnThis = tStemp;
+  return returnThis;
+}
+TList *AliFemtoAODTrackCut::ListSettings()
+{
+  // return a list of settings in a writable form
+  TList *tListSetttings = new TList();
+  char buf[200];
+  snprintf(buf, 200, "AliFemtoAODTrackCut.mass=%lf", this->Mass());
+  tListSetttings->AddLast(new TObjString(buf));
+
+  snprintf(buf, 200, "AliFemtoAODTrackCut.charge=%i", fCharge);
+  tListSetttings->AddLast(new TObjString(buf));
+  snprintf(buf, 200, "AliFemtoAODTrackCut.pidprobpion.minimum=%lf", fPidProbPion[0]);
+  tListSetttings->AddLast(new TObjString(buf));
+  snprintf(buf, 200, "AliFemtoAODTrackCut.pidprobpion.maximum=%lf", fPidProbPion[1]);
+  tListSetttings->AddLast(new TObjString(buf));
+  snprintf(buf, 200, "AliFemtoAODTrackCut.pidprobkaon.minimum=%lf", fPidProbKaon[0]);
+  tListSetttings->AddLast(new TObjString(buf));
+  snprintf(buf, 200, "AliFemtoAODTrackCut.pidprobkaon.maximum=%lf", fPidProbKaon[1]);
+  tListSetttings->AddLast(new TObjString(buf));
+  snprintf(buf, 200, "AliFemtoAODTrackCut.pidprobproton.minimum=%lf", fPidProbProton[0]);
+  tListSetttings->AddLast(new TObjString(buf));
+  snprintf(buf, 200, "AliFemtoAODTrackCut.pidprobproton.maximum=%lf", fPidProbProton[1]);
+  tListSetttings->AddLast(new TObjString(buf));
+  snprintf(buf, 200, "AliFemtoAODTrackCut.pidprobelectron.minimum=%lf", fPidProbElectron[0]);
+  tListSetttings->AddLast(new TObjString(buf));
+  snprintf(buf, 200, "AliFemtoAODTrackCut.pidprobelectron.maximum=%lf", fPidProbElectron[1]);
+  tListSetttings->AddLast(new TObjString(buf));
+  snprintf(buf, 200, "AliFemtoAODTrackCut.pidprobMuon.minimum=%lf", fPidProbMuon[0]);
+  tListSetttings->AddLast(new TObjString(buf));
+  snprintf(buf, 200, "AliFemtoAODTrackCut.pidprobMuon.maximum=%lf", fPidProbMuon[1]);
+  tListSetttings->AddLast(new TObjString(buf));
+  snprintf(buf, 200, "AliFemtoAODTrackCut.pt.minimum=%lf", fPt[0]);
+  tListSetttings->AddLast(new TObjString(buf));
+  snprintf(buf, 200, "AliFemtoAODTrackCut.pt.maximum=%lf", fPt[1]);
+  tListSetttings->AddLast(new TObjString(buf));
+  snprintf(buf, 200, "AliFemtoAODTrackCut.rapidity.minimum=%lf", fRapidity[0]);
+  tListSetttings->AddLast(new TObjString(buf));
+  snprintf(buf, 200, "AliFemtoAODTrackCut.rapidity.maximum=%lf", fRapidity[1]);
+  tListSetttings->AddLast(new TObjString(buf));
+  snprintf(buf, 200, "AliFemtoAODTrackCut.maxchindof=%lf", fMaxchiNdof);
+  tListSetttings->AddLast(new TObjString(buf));
+  snprintf(buf, 200, "AliFemtoAODTrackCut.maxsigmatovertex=%lf", fMaxSigmaToVertex);
+  tListSetttings->AddLast(new TObjString(buf));
+  if (fMostProbable) {
+    if (fMostProbable == 2)
+      snprintf(buf, 200, "AliFemtoAODTrackCut.mostprobable=%s", "Pion");
+    if (fMostProbable == 3)
+      snprintf(buf, 200, "AliFemtoAODTrackCut.mostprobable=%s", "Kaon");
+    if (fMostProbable == 4)
+      snprintf(buf, 200, "AliFemtoAODTrackCut.mostprobable=%s", "Proton");
+    tListSetttings->AddLast(new TObjString(buf));
+  }
+  return tListSetttings;
+}
+                           // electron
+// 0.13 - 1.8
+// 0       7.594129e-02    8.256141e-03
+// 1       -5.535827e-01   8.170825e-02
+// 2       1.728591e+00    3.104210e-01
+// 3       -2.827893e+00   5.827802e-01
+// 4       2.503553e+00    5.736207e-01
+// 5       -1.125965e+00   2.821170e-01
+// 6       2.009036e-01    5.438876e-02
+float AliFemtoAODTrackCut::PidFractionElectron(float mom) const
+{
+  // Provide a parameterized fraction of electrons dependent on momentum
+  if (mom<0.13) return 0.0;
+  if (mom>1.8) return 0.0;
+  return (7.594129e-02 
+         -5.535827e-01*mom        
+         +1.728591e+00*mom*mom    
+         -2.827893e+00*mom*mom*mom 
+         +2.503553e+00*mom*mom*mom*mom    
+         -1.125965e+00*mom*mom*mom*mom*mom      
+         +2.009036e-01*mom*mom*mom*mom*mom*mom);   
+}
+
+// pion
+// 0.13 - 2.0
+// 0       1.063457e+00    8.872043e-03
+// 1       -4.222208e-01   2.534402e-02
+// 2       1.042004e-01    1.503945e-02
+float AliFemtoAODTrackCut::PidFractionPion(float mom) const
+{
+  // Provide a parameterized fraction of pions dependent on momentum
+  if (mom<0.13) return 0.0;
+  if (mom>2.0) return 0.0;
+  return ( 1.063457e+00
+          -4.222208e-01*mom
+          +1.042004e-01*mom*mom);
+}
+
+// kaon
+// 0.18 - 2.0
+// 0       -7.289406e-02   1.686074e-03
+// 1       4.415666e-01    1.143939e-02
+// 2       -2.996790e-01   1.840964e-02
+// 3       6.704652e-02    7.783990e-03
+float AliFemtoAODTrackCut::PidFractionKaon(float mom) const
+{
+  // Provide a parameterized fraction of kaons dependent on momentum
+  if (mom<0.18) return 0.0;
+  if (mom>2.0) return 0.0;
+  return (-7.289406e-02
+         +4.415666e-01*mom        
+         -2.996790e-01*mom*mom    
+         +6.704652e-02*mom*mom*mom);
+}
+
+// proton
+// 0.26 - 2.0
+// 0       -3.730200e-02   2.347311e-03
+// 1       1.163684e-01    1.319316e-02
+// 2       8.354116e-02    1.997948e-02
+// 3       -4.608098e-02   8.336400e-03
+float AliFemtoAODTrackCut::PidFractionProton(float mom) const
+{
+  // Provide a parameterized fraction of protons dependent on momentum
+  if (mom<0.26) return  0.0;
+  if (mom>2.0) return 0.0;
+  return (-3.730200e-02  
+         +1.163684e-01*mom           
+         +8.354116e-02*mom*mom       
+         -4.608098e-02*mom*mom*mom);  
+}
diff --git a/PWG2/FEMTOSCOPY/AliFemto/AliFemtoAODTrackCut.h b/PWG2/FEMTOSCOPY/AliFemto/AliFemtoAODTrackCut.h
new file mode 100644 (file)
index 0000000..4d7454c
--- /dev/null
@@ -0,0 +1,94 @@
+///////////////////////////////////////////////////////////////////////////
+//                                                                       //
+// AliFemtoAODTrackCut: A basic track cut that used information from     //
+// ALICE AOD to accept or reject the track.                              //  
+// Enables the selection on charge, transverse momentum, rapidity,       //
+// pid probabilities, number of ITS and TPC clusters                     //
+// Author: Adam Kisiel (WUT, OSU), Adam.Kisiel@cern.ch                   //
+//                                                                       //
+///////////////////////////////////////////////////////////////////////////
+
+#ifndef ALIFEMTOAODTRACKCUT_H
+#define ALIFEMTOAODTRACKCUT_H
+
+//#ifndef StMaker_H
+//#include "StMaker.h"
+//#endif
+
+#include "AliFemtoTrackCut.h"
+
+class AliFemtoAODTrackCut : public AliFemtoTrackCut 
+{
+
+ public:
+  AliFemtoAODTrackCut();
+  virtual ~AliFemtoAODTrackCut();
+
+  virtual bool Pass(const AliFemtoTrack* aTrack);
+
+  virtual AliFemtoString Report();
+  virtual TList *ListSettings();
+  virtual AliFemtoParticleType Type(){return hbtTrack;}
+
+  void SetPt(const float& lo, const float& hi);
+  void SetRapidity(const float& lo, const float& hi);
+  void SetCharge(const int& ch);
+  void SetPidProbElectron(const float& lo, const float& hi);
+  void SetPidProbPion(const float& lo, const float& hi);
+  void SetPidProbKaon(const float& lo, const float& hi);
+  void SetPidProbProton(const float& lo, const float& hi);
+  void SetPidProbMuon(const float& lo, const float& hi);
+  void SetLabel(const bool& flag);
+  void SetMaxChiNdof(const float& maxchi);
+  void SetMaxSigmaToVertex(const float& maxsig);
+  void SetMostProbablePion();
+  void SetMostProbableKaon();
+  void SetMostProbableProton();
+  void SetNoMostProbable(); 
+
+ private:   // here are the quantities I want to cut on...
+
+  int               fCharge;             // particle charge
+  float             fPt[2];              // bounds for transverse momentum
+  float             fRapidity[2];        // bounds for rapidity
+  float             fPidProbElectron[2]; // bounds for electron probability
+  float             fPidProbPion[2];     // bounds for pion probability
+  float             fPidProbKaon[2];     // bounds for kaon probability
+  float             fPidProbProton[2];   // bounds for proton probability
+  float             fPidProbMuon[2];     // bounds for muon probability 
+  bool              fLabel;              // if true label<0 will not pass throught 
+  float             fMaxchiNdof;         // maximum allowed chi2/ndof for TPC clusters
+  float             fMaxSigmaToVertex;   // maximum allowed sigma to primary vertex
+  long              fNTracksPassed;      // passed tracks count
+  long              fNTracksFailed;      // failed tracks count
+  int               fMostProbable;       // this particle type is required to be most probable
+
+  float PidFractionElectron(float mom) const;
+  float PidFractionPion(float mom) const;
+  float PidFractionKaon(float mom) const;
+  float PidFractionProton(float mom) const;
+
+#ifdef __ROOT__ 
+  ClassDef(AliFemtoAODTrackCut, 1)
+#endif
+    };
+
+
+inline void AliFemtoAODTrackCut::SetPt(const float& lo, const float& hi){fPt[0]=lo; fPt[1]=hi;}
+inline void AliFemtoAODTrackCut::SetRapidity(const float& lo,const float& hi){fRapidity[0]=lo; fRapidity[1]=hi;}
+inline void AliFemtoAODTrackCut::SetCharge(const int& ch){fCharge = ch;}
+inline void AliFemtoAODTrackCut::SetPidProbElectron(const float& lo,const float& hi){fPidProbElectron[0]=lo; fPidProbElectron[1]=hi;}
+inline void AliFemtoAODTrackCut::SetPidProbPion(const float& lo,const float& hi){fPidProbPion[0]=lo; fPidProbPion[1]=hi;}
+inline void AliFemtoAODTrackCut::SetPidProbKaon(const float& lo,const float& hi){fPidProbKaon[0]=lo; fPidProbKaon[1]=hi;}
+inline void AliFemtoAODTrackCut::SetPidProbProton(const float& lo,const float& hi){fPidProbProton[0]=lo; fPidProbProton[1]=hi;}
+inline void AliFemtoAODTrackCut::SetPidProbMuon(const float& lo,const float& hi){fPidProbMuon[0]=lo; fPidProbMuon[1]=hi;}
+inline void AliFemtoAODTrackCut::SetLabel(const bool& flag){fLabel=flag;}
+inline void AliFemtoAODTrackCut::SetMostProbablePion() { fMostProbable = 2; }
+inline void AliFemtoAODTrackCut::SetMostProbableKaon() { fMostProbable = 3; }
+inline void AliFemtoAODTrackCut::SetMostProbableProton() { fMostProbable = 4; }
+inline void AliFemtoAODTrackCut::SetNoMostProbable() { fMostProbable = 0; }
+inline void AliFemtoAODTrackCut::SetMaxChiNdof(const float& maxchi) { fMaxchiNdof = maxchi; }
+inline void AliFemtoAODTrackCut::SetMaxSigmaToVertex(const float& maxsig) { fMaxSigmaToVertex = maxsig; }
+
+#endif
+
diff --git a/PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderAOD.cxx b/PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderAOD.cxx
new file mode 100644 (file)
index 0000000..7e96322
--- /dev/null
@@ -0,0 +1,396 @@
+////////////////////////////////////////////////////////////////////////////////
+//                                                                            //
+// AliFemtoEventReaderAOD - the reader class for the Alice AOD                //
+// Reads in AOD information and converts it into internal AliFemtoEvent       //
+// Authors: Marek Chojnacki mchojnacki@knf.pw.edu.pl                          //
+//          Adam Kisiel kisiel@mps.ohio-state.edu                             //
+//                                                                            //
+////////////////////////////////////////////////////////////////////////////////
+
+#include "AliFemtoEventReaderAOD.h"
+
+#include "TFile.h"
+#include "TTree.h"
+#include "AliAODEvent.h"
+#include "AliAODTrack.h"
+#include "AliAODVertex.h"
+
+#include "AliFmPhysicalHelixD.h"
+#include "AliFmThreeVectorF.h"
+
+#include "SystemOfUnits.h"
+
+#include "AliFemtoEvent.h"
+#include "AliFemtoModelHiddenInfo.h"
+
+ClassImp(AliFemtoEventReaderAOD)
+
+#if !(ST_NO_NAMESPACES)
+  using namespace units;
+#endif
+
+using namespace std;
+//____________________________
+//constructor with 0 parameters , look at default settings 
+AliFemtoEventReaderAOD::AliFemtoEventReaderAOD():
+  fInputFile(" "),
+  fFileName(" "),
+  fNumberofEvent(0),
+  fCurEvent(0),
+  fTree(0x0),
+  fAodFile(0x0),
+  fEvent(0x0),
+  fAllTrue(160),
+  fAllFalse(160),
+  fFilterBit(0),
+  fPWG2AODTracks(0x0)
+{
+  // default constructor
+  fAllTrue.ResetAllBits(kTRUE);
+  fAllFalse.ResetAllBits(kFALSE);
+}
+
+AliFemtoEventReaderAOD::AliFemtoEventReaderAOD(const AliFemtoEventReaderAOD &aReader) :
+  fInputFile(" "),
+  fFileName(" "),
+  fNumberofEvent(0),
+  fCurEvent(0),
+  fTree(0x0),
+  fAodFile(0x0),
+  fEvent(0x0),
+  fAllTrue(160),
+  fAllFalse(160),
+  fFilterBit(0),
+  fPWG2AODTracks(0x0)
+{
+  // copy constructor
+  fInputFile = aReader.fInputFile;
+  fFileName  = aReader.fFileName;
+  fNumberofEvent = aReader.fNumberofEvent;
+  fCurEvent = aReader.fCurEvent;
+  fEvent = new AliAODEvent();
+  fAodFile = new TFile(aReader.fAodFile->GetName());
+  fAllTrue.ResetAllBits(kTRUE);
+  fAllFalse.ResetAllBits(kFALSE);
+  fFilterBit = aReader.fFilterBit;
+  fPWG2AODTracks = aReader.fPWG2AODTracks;
+}
+//__________________
+//Destructor
+AliFemtoEventReaderAOD::~AliFemtoEventReaderAOD()
+{
+  // destructor
+  delete fTree;
+  delete fEvent;
+  delete fAodFile;
+  if (fPWG2AODTracks) {
+    fPWG2AODTracks->Delete();
+    delete fPWG2AODTracks;
+  }
+}
+
+//__________________
+AliFemtoEventReaderAOD& AliFemtoEventReaderAOD::operator=(const AliFemtoEventReaderAOD& aReader)
+{
+  // assignment operator
+  if (this == &aReader)
+    return *this;
+
+  fInputFile = aReader.fInputFile;
+  fFileName  = aReader.fFileName;
+  fNumberofEvent = aReader.fNumberofEvent;
+  fCurEvent = aReader.fCurEvent;
+  if (fTree) delete fTree;
+  if (fEvent) delete fEvent;
+  fEvent = new AliAODEvent();
+  if (fAodFile) delete fAodFile;
+  fAodFile = new TFile(aReader.fAodFile->GetName());
+  fAllTrue.ResetAllBits(kTRUE);
+  fAllFalse.ResetAllBits(kFALSE);
+  fFilterBit = aReader.fFilterBit;
+  fPWG2AODTracks = aReader.fPWG2AODTracks;
+
+  return *this;
+}
+//__________________
+AliFemtoString AliFemtoEventReaderAOD::Report()
+{
+  // create reader report
+  AliFemtoString temp = "\n This is the AliFemtoEventReaderAOD\n";
+  return temp;
+}
+
+//__________________
+void AliFemtoEventReaderAOD::SetInputFile(const char* inputFile)
+{
+  //setting the name of file where names of AOD file are written 
+  //it takes only this files which have good trees
+  char buffer[256];
+  fInputFile=string(inputFile);
+  cout<<"Input File set on "<<fInputFile<<endl;
+  ifstream infile(inputFile);
+
+  fTree = new TChain("aodTree");
+
+  if(infile.good()==true)
+    { 
+      //checking if all give files have good tree inside
+      while (infile.eof()==false)
+       {
+         infile.getline(buffer,256);
+         TFile *aodFile=TFile::Open(buffer,"READ");
+         if (aodFile!=0x0)
+           {   
+             TTree* tree = (TTree*) aodFile->Get("aodTree");
+             if (tree!=0x0)
+               {
+                 cout<<"putting file  "<<string(buffer)<<" into analysis"<<endl;
+                 fTree->AddFile(buffer);
+                 delete tree;
+               }
+             aodFile->Close(); 
+           }
+         delete aodFile;
+       }
+    }
+}
+
+AliFemtoEvent* AliFemtoEventReaderAOD::ReturnHbtEvent()
+{
+  // read in a next hbt event from the chain
+  // convert it to AliFemtoEvent and return
+  // for further analysis
+  AliFemtoEvent *hbtEvent = 0;
+
+  if (fCurEvent==fNumberofEvent)//open next file  
+    {
+      if(fNumberofEvent==0)    
+       {
+         fEvent=new AliAODEvent();
+         fEvent->ReadFromTree(fTree);
+
+         // Check for the existence of the additional information
+         fPWG2AODTracks = (TClonesArray *) fEvent->GetList()->FindObject("pwg2aodtracks");
+
+         if (fPWG2AODTracks) {
+           cout << "Found additional PWG2 specific information in the AOD!" << endl;
+           cout << "Reading only tracks with the additional information" << endl;
+         }
+
+         fNumberofEvent=fTree->GetEntries();
+         cout<<"Number of Entries in file "<<fNumberofEvent<<endl;
+         fCurEvent=0;
+       }
+      else //no more data to read
+       {
+         cout<<"no more files "<<hbtEvent<<endl;
+         fReaderStatus=1;
+         return hbtEvent; 
+       }
+    }          
+
+  cout<<"starting to read event "<<fCurEvent<<endl;
+  fTree->GetEvent(fCurEvent);//getting next event
+  cout << "Read event " << fEvent << " from file " << fTree << endl;
+       
+  hbtEvent = new AliFemtoEvent;
+
+  CopyAODtoFemtoEvent(hbtEvent);
+
+  fCurEvent++; 
+
+  return hbtEvent; 
+}
+
+void AliFemtoEventReaderAOD::CopyAODtoFemtoEvent(AliFemtoEvent *tEvent)
+{
+  // A function that reads in the AOD event
+  // and transfers the neccessary information into
+  // the internal AliFemtoEvent
+
+  // setting global event characteristics
+  tEvent->SetRunNumber(fEvent->GetRunNumber());
+  tEvent->SetMagneticField(fEvent->GetMagneticField()*kilogauss);//to check if here is ok
+  tEvent->SetZDCN1Energy(fEvent->GetZDCN1Energy());
+  tEvent->SetZDCP1Energy(fEvent->GetZDCP1Energy());
+  tEvent->SetZDCN2Energy(fEvent->GetZDCN2Energy());
+  tEvent->SetZDCP2Energy(fEvent->GetZDCP2Energy());
+  tEvent->SetZDCEMEnergy(fEvent->GetZDCEMEnergy(0));
+  tEvent->SetZDCParticipants(-1);
+  tEvent->SetTriggerMask(fEvent->GetTriggerMask());
+  tEvent->SetTriggerCluster(fEvent->GetTriggerCluster());
+       
+  // Primary Vertex position
+  double fV1[3];
+  fEvent->GetPrimaryVertex()->GetPosition(fV1);
+
+  AliFmThreeVectorF vertex(fV1[0],fV1[1],fV1[2]);
+  tEvent->SetPrimVertPos(vertex);
+       
+  //starting to reading tracks
+  int nofTracks=0;  //number of reconstructed tracks in event
+
+  // Check to see whether the additional info exists
+  if (fPWG2AODTracks)
+    nofTracks=fPWG2AODTracks->GetEntries();
+  else
+    nofTracks=fEvent->GetNumberOfTracks();
+
+  int realnofTracks=0;   // number of track which we use in a analysis
+  cout << "Event has " << nofTracks << " tracks " << endl;
+
+  for (int i=0;i<nofTracks;i++)
+    {
+      AliFemtoTrack* trackCopy = new AliFemtoTrack();  
+
+      if (fPWG2AODTracks) {
+       // Read tracks from the additional pwg2 specific AOD part
+       // if they exist
+       // Note that in that case all the AOD tracks without the 
+       // additional information will be ignored !
+       AliPWG2AODTrack *pwg2aodtrack = (AliPWG2AODTrack *) fPWG2AODTracks->At(i);
+
+       // Getting the AOD track through the ref of the additional info
+       AliAODTrack *aodtrack = pwg2aodtrack->GetRefAODTrack(); 
+       if (!aodtrack->TestFilterBit(fFilterBit))
+         continue;
+       
+       CopyAODtoFemtoTrack(aodtrack, trackCopy, pwg2aodtrack);
+       
+       double pxyz[3];
+       aodtrack->PxPyPz(pxyz);//reading noconstarined momentum
+       const AliFmThreeVectorD ktP(pxyz[0],pxyz[1],pxyz[2]);
+       // Check the sanity of the tracks - reject zero momentum tracks
+       if (ktP.mag() == 0) {
+         delete trackCopy;
+         continue;
+       }
+      }
+      else {
+       // No additional information exists
+       // Read in the normal AliAODTracks 
+       const AliAODTrack *aodtrack=fEvent->GetTrack(i); // getting the AODtrack directly
+       
+       if (!aodtrack->TestFilterBit(fFilterBit))
+         continue;
+       
+       CopyAODtoFemtoTrack(aodtrack, trackCopy, 0);
+       
+       double pxyz[3];
+       aodtrack->PxPyPz(pxyz);//reading noconstarined momentum
+       const AliFmThreeVectorD ktP(pxyz[0],pxyz[1],pxyz[2]);
+       // Check the sanity of the tracks - reject zero momentum tracks
+       if (ktP.mag() == 0) {
+         delete trackCopy;
+         continue;
+       }
+      }
+
+
+      tEvent->TrackCollection()->push_back(trackCopy);//adding track to analysis
+      realnofTracks++;//real number of tracks          
+    }
+
+  tEvent->SetNumberOfTracks(realnofTracks);//setting number of track which we read in event    
+
+  cout<<"end of reading nt "<<nofTracks<<" real number "<<realnofTracks<<endl;
+}
+
+void AliFemtoEventReaderAOD::CopyAODtoFemtoTrack(const AliAODTrack *tAodTrack, 
+                                                AliFemtoTrack *tFemtoTrack, 
+                                                AliPWG2AODTrack *tPWG2AODTrack)
+{
+  // Copy the track information from the AOD into the internal AliFemtoTrack
+  // If it exists, use the additional information from the PWG2 AOD
+
+  // Primary Vertex position
+  double fV1[3];
+  fEvent->GetPrimaryVertex()->GetPosition(fV1);
+
+  tFemtoTrack->SetCharge(tAodTrack->Charge());
+  
+  //in aliroot we have AliPID 
+  //0-electron 1-muon 2-pion 3-kaon 4-proton 5-photon 6-pi0 7-neutron 8-kaon0 9-eleCon   
+  //we use only 5 first
+
+  // AOD pid has 10 components
+  double aodpid[10];
+  tAodTrack->GetPID(aodpid);
+  tFemtoTrack->SetPidProbElectron(aodpid[0]);
+  tFemtoTrack->SetPidProbMuon(aodpid[1]);
+  tFemtoTrack->SetPidProbPion(aodpid[2]);
+  tFemtoTrack->SetPidProbKaon(aodpid[3]);
+  tFemtoTrack->SetPidProbProton(aodpid[4]);
+                                               
+  double pxyz[3];
+  tAodTrack->PxPyPz(pxyz);//reading noconstrained momentum
+  AliFemtoThreeVector v(pxyz[0],pxyz[1],pxyz[2]);
+  tFemtoTrack->SetP(v);//setting momentum
+  tFemtoTrack->SetPt(sqrt(pxyz[0]*pxyz[0]+pxyz[1]*pxyz[1]));
+  const AliFmThreeVectorD kOrigin(fV1[0],fV1[1],fV1[2]);
+  //setting track helix 
+  const AliFmThreeVectorD ktP(pxyz[0],pxyz[1],pxyz[2]);
+  AliFmPhysicalHelixD helix(ktP,kOrigin,(double)(fEvent->GetMagneticField())*kilogauss,(double)(tFemtoTrack->Charge())); 
+  tFemtoTrack->SetHelix(helix);
+               
+  // Flags
+  tFemtoTrack->SetTrackId(tAodTrack->GetID());
+  tFemtoTrack->SetFlags(1);
+  tFemtoTrack->SetLabel(tAodTrack->GetLabel());
+               
+  // Track quality information 
+  float covmat[6];
+  tAodTrack->GetCovMatrix(covmat);
+  tFemtoTrack->SetImpactD(covmat[0]);
+  tFemtoTrack->SetImpactZ(covmat[2]);
+  tFemtoTrack->SetCdd(covmat[3]);
+  tFemtoTrack->SetCdz(covmat[4]);
+  tFemtoTrack->SetCzz(covmat[5]);
+  // This information is only available in the ESD
+  // We put in fake values or reasonable estimates
+  tFemtoTrack->SetITSchi2(tAodTrack->Chi2perNDF());    
+  tFemtoTrack->SetITSncls(1);     
+  tFemtoTrack->SetTPCchi2(tAodTrack->Chi2perNDF());       
+  tFemtoTrack->SetTPCncls(1);       
+  tFemtoTrack->SetTPCnclsF(-1);      
+  tFemtoTrack->SetTPCsignalN(-1); 
+  tFemtoTrack->SetTPCsignalS(-1); 
+
+  if (tPWG2AODTrack) {
+    // Copy the PWG2 specific information if it exists
+    tFemtoTrack->SetTPCClusterMap(tPWG2AODTrack->GetTPCClusterMap());
+    tFemtoTrack->SetTPCSharedMap(tPWG2AODTrack->GetTPCSharedMap());
+    
+    double xtpc[3] = {0,0,0};
+    tPWG2AODTrack->GetTPCNominalEntrancePoint(xtpc);
+    tFemtoTrack->SetNominalTPCEntrancePoint(xtpc);
+    tPWG2AODTrack->GetTPCNominalExitPoint(xtpc);
+    tFemtoTrack->SetNominalTPCExitPoint(xtpc);
+  }
+  else {
+    // If not use dummy values
+    tFemtoTrack->SetTPCClusterMap(fAllTrue);
+    tFemtoTrack->SetTPCSharedMap(fAllFalse);
+    
+    double xtpc[3] = {0,0,0};
+    tFemtoTrack->SetNominalTPCEntrancePoint(xtpc);
+    tFemtoTrack->SetNominalTPCExitPoint(xtpc);
+  }
+
+  int indexes[3];
+  for (int ik=0; ik<3; ik++) {
+    indexes[ik] = 0;
+  }
+  tFemtoTrack->SetKinkIndexes(indexes);
+}
+
+void AliFemtoEventReaderAOD::SetFilterBit(UInt_t ibit)
+{
+  fFilterBit = (1 << (ibit));
+}
+
+
+
+
+
+
diff --git a/PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderAOD.h b/PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderAOD.h
new file mode 100644 (file)
index 0000000..2804f36
--- /dev/null
@@ -0,0 +1,69 @@
+////////////////////////////////////////////////////////////////////////////////
+//                                                                            //
+// AliFemtoEventReaderAOD - the reader class for the Alice AOD                //
+// Reads in AOD information and converts it into internal AliFemtoEvent       //
+// Authors: Adam Kisiel kisiel@mps.ohio-state.edu                             //
+//                                                                            //
+////////////////////////////////////////////////////////////////////////////////
+
+#ifndef ALIFEMTOEVENTREADERAOD_H
+#define ALIFEMTOEVENTREADERAOD_H
+#include "AliFemtoEventReader.h"
+#include "AliFemtoEnumeration.h"
+
+#include <string>
+#include <vector>
+#include "TTree.h"
+#include "TChain.h"
+#include "TBits.h"
+#include "AliAODEvent.h"
+#include <list>
+#include "AliPWG2AODTrack.h"
+
+class AliFemtoEvent;
+class AliFemtoTrack;
+
+class AliFemtoEventReaderAOD : public AliFemtoEventReader 
+{
+ public:
+  AliFemtoEventReaderAOD();
+  AliFemtoEventReaderAOD(const AliFemtoEventReaderAOD &aReader);
+  virtual ~AliFemtoEventReaderAOD();
+
+  AliFemtoEventReaderAOD& operator=(const AliFemtoEventReaderAOD& aReader);
+
+  virtual AliFemtoEvent* ReturnHbtEvent();
+  AliFemtoString Report();
+  void SetInputFile(const char* inputFile);
+  void SetFilterBit(UInt_t ibit);
+
+ protected:
+  virtual void CopyAODtoFemtoEvent(AliFemtoEvent *tEvent);
+  virtual void CopyAODtoFemtoTrack(const AliAODTrack *tAodTrack, 
+                                  AliFemtoTrack *tFemtoTrack, 
+                                  AliPWG2AODTrack *tPWG2AODTrack);
+
+  int            fNumberofEvent;    // number of Events in AOD file
+  int            fCurEvent;         // number of current event
+  AliAODEvent*   fEvent;            // AOD event
+  TBits          fAllTrue;          // Bit set with all true bits
+  TBits          fAllFalse;         // Bit set with all false bits
+  UInt_t         fFilterBit;        // Bitmap bit for AOD filters
+  TClonesArray*  fPWG2AODTracks;    // Link to PWG2 specific AOD information (if it exists)
+
+ private:
+
+  string         fInputFile;        // name of input file with AOD filenames
+  string         fFileName;         // name of current AOD file
+  TChain*        fTree;             // AOD tree
+  TFile*         fAodFile;          // AOD file 
+
+#ifdef __ROOT__
+  ClassDef(AliFemtoEventReaderAOD, 11)
+#endif
+
+    };
+  
+#endif
+
+
diff --git a/PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderAODChain.cxx b/PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderAODChain.cxx
new file mode 100644 (file)
index 0000000..37a59cf
--- /dev/null
@@ -0,0 +1,108 @@
+////////////////////////////////////////////////////////////////////////////////
+//                                                                            //
+// AliFemtoEventReaderAODChain - the reader class for the Alice AOD from Chain//
+// Reads in AOD information and converts it into internal AliFemtoEvent       //
+// Authors: Adam Kisiel kisiel@mps.ohio-state.edu                             //
+//                                                                            //
+////////////////////////////////////////////////////////////////////////////////
+
+#include "AliFemtoEventReaderAODChain.h"
+
+#include "TFile.h"
+#include "TTree.h"
+#include "AliAODEvent.h"
+#include "AliAODTrack.h"
+#include "AliAODVertex.h"
+
+#include "AliFmPhysicalHelixD.h"
+#include "AliFmThreeVectorF.h"
+
+#include "SystemOfUnits.h"
+
+#include "AliFemtoEvent.h"
+#include "AliFemtoModelHiddenInfo.h"
+
+ClassImp(AliFemtoEventReaderAODChain)
+
+#if !(ST_NO_NAMESPACES)
+  using namespace units;
+#endif
+
+using namespace std;
+//____________________________
+//constructor with 0 parameters , look at default settings 
+AliFemtoEventReaderAODChain::AliFemtoEventReaderAODChain():
+  AliFemtoEventReaderAOD()
+{
+  // default constructor
+}
+
+AliFemtoEventReaderAODChain::AliFemtoEventReaderAODChain(const AliFemtoEventReaderAODChain &aReader) :
+  AliFemtoEventReaderAOD(aReader)
+{
+  // copy constructor
+}
+//__________________
+//Destructor
+AliFemtoEventReaderAODChain::~AliFemtoEventReaderAODChain()
+{
+  // destructor
+}
+
+//__________________
+AliFemtoEventReaderAODChain& AliFemtoEventReaderAODChain::operator=(const AliFemtoEventReaderAODChain& aReader)
+{
+  // assignment operator
+  if (this == &aReader)
+    return *this;
+
+  *this = aReader;
+
+  return *this;
+}
+//__________________
+AliFemtoString AliFemtoEventReaderAODChain::Report()
+{
+  // create reader report
+  AliFemtoString temp = "\n This is the AliFemtoEventReaderAODChain\n";
+  return temp;
+}
+
+AliFemtoEvent* AliFemtoEventReaderAODChain::ReturnHbtEvent()
+{
+  // read in a next hbt event from the chain
+  // convert it to AliFemtoEvent and return
+  // for further analysis
+  if (!fEvent) return 0;
+
+  AliFemtoEvent *hbtEvent = 0;
+
+  // Get the PWG2 specific information if it exists
+  fPWG2AODTracks = (TClonesArray *) fEvent->GetList()->FindObject("pwg2aodtracks");
+  
+  if (fPWG2AODTracks) {
+    cout << "Found additional PWG2 specific information in the AOD!" << endl;
+    cout << "Reading only tracks with the additional information" << endl;
+  }
+
+  cout<<"starting to read event "<<fCurEvent<<endl;
+       
+  hbtEvent = new AliFemtoEvent;
+
+  CopyAODtoFemtoEvent(hbtEvent);
+
+  fCurEvent++; 
+  return hbtEvent; 
+}
+
+//___________________
+void AliFemtoEventReaderAODChain::SetAODSource(AliAODEvent *aAOD)
+{
+  // The chain loads the AOD for us
+  // You must provide the address where it can be found
+  fEvent = aAOD;
+}
+
+
+
+
diff --git a/PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderAODChain.h b/PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderAODChain.h
new file mode 100644 (file)
index 0000000..05d18b0
--- /dev/null
@@ -0,0 +1,51 @@
+////////////////////////////////////////////////////////////////////////////////
+//                                                                            //
+// AliFemtoEventReaderAODChain - the reader class for the Alice AOD in Chain  //
+// Reads in AOD information and converts it into internal AliFemtoEvent       //
+// Authors: Adam Kisiel kisiel@mps.ohio-state.edu                             //
+//                                                                            //
+////////////////////////////////////////////////////////////////////////////////
+#ifndef ALIFEMTOEVENTREADERAODCHAIN_H
+#define ALIFEMTOEVENTREADERAODCHAIN_H
+#include "AliFemtoEventReader.h"
+#include "AliFemtoEnumeration.h"
+
+#include <string>
+#include <vector>
+#include "TTree.h"
+#include "TChain.h"
+#include "TBits.h"
+#include "AliAODEvent.h"
+#include <list>
+#include "AliPWG2AODTrack.h"
+#include "AliFemtoEventReaderAOD.h"
+
+class AliFemtoEvent;
+class AliFemtoTrack;
+
+class AliFemtoEventReaderAODChain : public AliFemtoEventReaderAOD 
+{
+ public:
+  AliFemtoEventReaderAODChain();
+  AliFemtoEventReaderAODChain(const AliFemtoEventReaderAODChain &aReader);
+  virtual ~AliFemtoEventReaderAODChain();
+
+  AliFemtoEventReaderAODChain& operator=(const AliFemtoEventReaderAODChain& aReader);
+
+  virtual AliFemtoEvent* ReturnHbtEvent();
+  AliFemtoString Report();
+  void SetAODSource(AliAODEvent *aAOD);
+
+ protected:
+
+ private:
+
+#ifdef __ROOT__
+  ClassDef(AliFemtoEventReaderAODChain, 1)
+#endif
+
+    };
+  
+#endif
+
+
index c83d9c5..36567aa 100644 (file)
@@ -48,7 +48,7 @@ class AliFemtoEventReaderESD : public AliFemtoEventReader
  public:
   AliFemtoEventReaderESD();
   AliFemtoEventReaderESD(const AliFemtoEventReaderESD &aReader);
-  ~AliFemtoEventReaderESD();
+  virtual ~AliFemtoEventReaderESD();
 
   AliFemtoEventReaderESD& operator=(const AliFemtoEventReaderESD& aReader);
 
index 4246072..b2ff4e9 100644 (file)
@@ -39,3 +39,6 @@
 #pragma link C++ class AliFemtoModelCorrFctn;
 #pragma link C++ class AliFemtoModelWeightGeneratorLednicky;
 #pragma link C++ class AliFemtoCutMonitorParticleYPt;
+#pragma link C++ class AliFemtoEventReaderAOD;
+#pragma link C++ class AliFemtoEventReaderAODChain;
+#pragma link C++ class AliFemtoAODTrackCut;
index 07ae089..0fbc748 100644 (file)
@@ -36,7 +36,10 @@ SRCS= FEMTOSCOPY/AliFemto/AliFemtoSimpleAnalysis.cxx \
       FEMTOSCOPY/AliFemto/AliFemtoModelWeightGeneratorLednicky.cxx \
       FEMTOSCOPY/AliFemto/AliFemtoCutMonitorParticleYPt.cxx \
       FEMTOSCOPY/AliFemto/AliFemtoKTPairCut.cxx \
-      FEMTOSCOPY/AliFemto/AliFemtoCorrFctnNonIdDR.cxx
+      FEMTOSCOPY/AliFemto/AliFemtoCorrFctnNonIdDR.cxx \
+      FEMTOSCOPY/AliFemto/AliFemtoEventReaderAOD.cxx \
+      FEMTOSCOPY/AliFemto/AliFemtoEventReaderAODChain.cxx \
+      FEMTOSCOPY/AliFemto/AliFemtoAODTrackCut.cxx
       
 
 HDRS= $(SRCS:.cxx=.h) 
@@ -57,5 +60,5 @@ DHDR:= PWG2femtoscopyLinkDef.h
 
 EXPORT:=
 
-EINCLUDE:= PWG2/FEMTOSCOPY/AliFemto 
+EINCLUDE:= PWG2/FEMTOSCOPY/AliFemto PWG2/AOD