FEMTOSCOPY/AliFemto/AliTwoTrackRes.cxx
FEMTOSCOPY/AliFemto/AliFemtoMCTrackCut.cxx
FEMTOSCOPY/AliFemto/AliFemtoEventReaderKinematicsChain.cxx
+ FEMTOSCOPY/AliFemto/AliFemtoV0PairCut.cxx
+ FEMTOSCOPY/AliFemto/AliFemtoV0TrackCut.cxx
+ FEMTOSCOPY/AliFemto/AliFemtoCutMonitorV0.cxx
+ FEMTOSCOPY/AliFemto/AliFemtoV0TrackPairCut.cxx
+ FEMTOSCOPY/AliFemto/AliFemtoCutMonitorCollections.cxx
)
string ( REPLACE ".cxx" ".h" HDRS "${SRCS}" )
FEMTOSCOPY/AliFemto/AliFemtoPicoEventCollectionVector.h
FEMTOSCOPY/AliFemto/AliFemtoEventWriter.h
FEMTOSCOPY/AliFemto/AliFemtoEventWriterCollection.h
+ FEMTOSCOPY/AliFemto/AliFemtoMCTrackCut.h
+ FEMTOSCOPY/AliFemto/AliFemtoEventReaderKinematicsChain.h
)
set ( FSRCS FEMTOSCOPY/AliFemto/AliFemtoFsiTools.F FEMTOSCOPY/AliFemto/AliFemtoFsiWeightLednicky.F)
#include "TFile.h"
#include "TInterpreter.h"
-#include "AliAnalysisTask.h"
+//#include "AliAnalysisTask.h"
+#include "AliAnalysisTaskSE.h"
#include "AliESDEvent.h"
//________________________________________________________________________
AliAnalysisTaskFemto::AliAnalysisTaskFemto(const char *name, const char *aConfigMacro, const char *aConfigParams):
- AliAnalysisTask(name,""),
+ AliAnalysisTaskSE(name), //AliAnalysisTask(name,""),
fESD(0),
fESDpid(0),
fAOD(0),
}
//________________________________________________________________________
AliAnalysisTaskFemto::AliAnalysisTaskFemto(const char *name, const char *aConfigMacro="ConfigFemtoAnalysis.C"):
- AliAnalysisTask(name,""),
+ AliAnalysisTaskSE(name), //AliAnalysisTask(name,""),
fESD(0),
fESDpid(0),
fAOD(0),
}
AliAnalysisTaskFemto::AliAnalysisTaskFemto(const AliAnalysisTaskFemto& aFemtoTask):
- AliAnalysisTask(aFemtoTask),
+ AliAnalysisTaskSE(aFemtoTask), //AliAnalysisTask(aFemtoTask),
fESD(0),
fESDpid(0),
fAOD(0),
#include "AliAODEvent.h"
#include "AliMCEvent.h"
-#include "AliAnalysisTask.h"
+//#include "AliAnalysisTask.h"
+#include "AliAnalysisTaskSE.h"
#include "AliAnalysisManager.h"
#include "AliAnalysisDataContainer.h"
#include "AliAODpidUtil.h"
-class AliAnalysisTaskFemto : public AliAnalysisTask {
+class AliAnalysisTaskFemto : public AliAnalysisTaskSE { //AliAnalysisTask
public:
- AliAnalysisTaskFemto() : AliAnalysisTask(), fESD(0), fESDpid(0), fAOD(0), fAODpidUtil(0), fStack(0), fOutputList(0), fReader(0x0), fManager(0x0), fAnalysisType(0), fConfigMacro(0), fConfigParams(0) {}
+ AliAnalysisTaskFemto() : AliAnalysisTaskSE(), fESD(0), fESDpid(0), fAOD(0), fAODpidUtil(0), fStack(0), fOutputList(0), fReader(0x0), fManager(0x0), fAnalysisType(0), fConfigMacro(0), fConfigParams(0) {}
AliAnalysisTaskFemto(const char *name, const char *aConfigMacro, const char *aConfigParams);
AliAnalysisTaskFemto(const char *name, const char *aConfigMacro);
AliAnalysisTaskFemto(const AliAnalysisTaskFemto& aFemtoTask);
// Default destructor
}
//------------------------------
-bool AliFemtoBasicEventCut::Pass(const AliFemtoEvent* event){
+bool AliFemtoBasicEventCut::Pass(const AliFemtoEvent* event){
// Pass events if they fall within the multiplicity and z-vertex
// position range. Fail otherwise
// int mult = event->NumberOfTracks();
cout << " *** no user defined Fill(const AliFemtoEvent*,const AliFemtoParticleCollection*), take from base class" << endl;
#endif
}
-
+inline void AliFemtoCutMonitor::Fill(const AliFemtoParticleCollection* /* aCollection */,const AliFemtoParticleCollection* /* aCollection */) {
+ // cut event and particle collection
+ #ifdef STHBTDEBUG
+ cout << " *** no user defined Fill(const AliFemtoParticleCollection*,const AliFemtoParticleCollection*), take from base class" << endl;
+ #endif
+}
virtual void Fill(const AliFemtoPair* aPair);
virtual void Fill(const AliFemtoParticleCollection* aCollection);
virtual void Fill(const AliFemtoEvent* aEvent,const AliFemtoParticleCollection* aCollection);
+ virtual void Fill(const AliFemtoParticleCollection* aCollection1,const AliFemtoParticleCollection* aCollection2);
virtual void Finish() {
#ifdef STHBTDEBUG
cout << " *** no user defined Finish(), take from base class" << endl;
--- /dev/null
+////////////////////////////////////////////////////////////////////////////////
+// //
+// AliFemtoCutMonitorCollections - the cut monitor for particles to study //
+// the difference between reconstructed and true momentum //
+// //
+////////////////////////////////////////////////////////////////////////////////
+#include "AliFemtoCutMonitorCollections.h"
+#include "AliFemtoModelHiddenInfo.h"
+#include "AliFemtoEvent.h"
+#include <TH1D.h>
+#include <TH2D.h>
+#include <TList.h>
+
+AliFemtoCutMonitorCollections::AliFemtoCutMonitorCollections():
+ fCollection1Mult(0),
+ fCollection2Mult(0)
+{
+ // Default constructor
+ fCollection1Mult = new TH1D("Coll1Mult", "Collection 1 Multiplicity", 5001, -0.5, 5000.5);
+ fCollection2Mult = new TH1D("Coll2Mult","Collection 2 Multiplicity",5001,-0.5,5000.5);
+}
+
+AliFemtoCutMonitorCollections::AliFemtoCutMonitorCollections(const char *aName):
+ fCollection1Mult(0),
+ fCollection2Mult(0)
+{
+ // Normal constructor
+ char name[200];
+ snprintf(name, 200, "Coll1Mult%s", aName);
+ fCollection1Mult = new TH1D(name, "Collection 1 Multiplicity", 5001, -0.5, 5000.5);
+
+ snprintf(name, 200, "Coll2Mult%s", aName);
+ fCollection2Mult = new TH1D(name, "Collection 2 Multiplicity", 5001, -0.5, 5000.5);
+}
+
+AliFemtoCutMonitorCollections::AliFemtoCutMonitorCollections(const AliFemtoCutMonitorCollections &aCut):
+ fCollection1Mult(0),
+ fCollection2Mult(0)
+{
+ // copy constructor
+ if (fCollection1Mult) delete fCollection1Mult;
+ fCollection1Mult = new TH1D(*aCut.fCollection1Mult);
+
+ if (fCollection2Mult) delete fCollection2Mult;
+ fCollection2Mult = new TH1D(*aCut.fCollection2Mult);
+}
+
+AliFemtoCutMonitorCollections::~AliFemtoCutMonitorCollections()
+{
+ // Destructor
+ delete fCollection1Mult;
+ delete fCollection2Mult;
+}
+
+AliFemtoCutMonitorCollections& AliFemtoCutMonitorCollections::operator=(const AliFemtoCutMonitorCollections& aCut)
+{
+ // assignment operator
+ if (this == &aCut)
+ return *this;
+
+ if (fCollection1Mult) delete fCollection1Mult;
+ fCollection1Mult = new TH1D(*aCut.fCollection1Mult);
+
+ if (fCollection2Mult) delete fCollection2Mult;
+ fCollection2Mult = new TH1D(*aCut.fCollection2Mult);
+
+ return *this;
+}
+
+AliFemtoString AliFemtoCutMonitorCollections::Report(){
+ // Prepare report from the execution
+ string stemp = "*** AliFemtoCutMonitorCollections report";
+ AliFemtoString returnThis = stemp;
+ return returnThis;
+}
+
+void AliFemtoCutMonitorCollections::Fill(const AliFemtoParticleCollection* aCollection1,const AliFemtoParticleCollection* aCollection2)
+{
+ // Fill in the monitor histograms with the values from the current event
+ //cout<<"Monitor collection sizes: "<<aCollection1->size()<<" "<<aCollection2->size()<<endl;
+ fCollection1Mult->Fill(aCollection1->size());
+ fCollection2Mult->Fill(aCollection2->size());
+
+
+}
+
+void AliFemtoCutMonitorCollections::Write()
+{
+ // Write out the relevant histograms
+ fCollection1Mult->Write();
+ fCollection2Mult->Write();
+
+}
+
+TList *AliFemtoCutMonitorCollections::GetOutputList()
+{
+ TList *tOutputList = new TList();
+ tOutputList->Add(fCollection1Mult);
+ tOutputList->Add(fCollection2Mult);
+
+ return tOutputList;
+}
+
+
--- /dev/null
+////////////////////////////////////////////////////////////////////////////////
+/// ///
+/// AliFemtoCutMonitorCollections - the cut monitor for events to study ///
+/// the multiplicity distribution of events ///
+/// ///
+////////////////////////////////////////////////////////////////////////////////
+#ifndef AliFemtoCutMonitorCollections_hh
+#define AliFemtoCutMonitorCollections_hh
+
+class AliFemtoEvent;
+class AliFemtoTrack;
+class AliFemtoV0;
+class AliFemtoKink;
+class AliFemtoPair;
+class TH1D;
+class TList;
+#include "AliFemtoString.h"
+#include "AliFemtoParticleCollection.h"
+#include "AliFemtoCutMonitor.h"
+
+class AliFemtoCutMonitorCollections : public AliFemtoCutMonitor{
+
+ public:
+ AliFemtoCutMonitorCollections();
+ AliFemtoCutMonitorCollections(const char *aName);
+ AliFemtoCutMonitorCollections(const AliFemtoCutMonitorCollections &aCut);
+ virtual ~AliFemtoCutMonitorCollections();
+
+ AliFemtoCutMonitorCollections& operator=(const AliFemtoCutMonitorCollections& aCut);
+
+ virtual AliFemtoString Report();
+ virtual void Fill(const AliFemtoEvent* aEvent) {AliFemtoCutMonitor::Fill(aEvent);}
+ virtual void Fill(const AliFemtoTrack* aTrack) {AliFemtoCutMonitor::Fill(aTrack);}
+ virtual void Fill(const AliFemtoV0* aV0) {AliFemtoCutMonitor::Fill(aV0);}
+ virtual void Fill(const AliFemtoKink* aKink) {AliFemtoCutMonitor::Fill(aKink);}
+ virtual void Fill(const AliFemtoPair* aPair) {AliFemtoCutMonitor::Fill(aPair);}
+ virtual void Fill(const AliFemtoParticleCollection* aCollection) {AliFemtoCutMonitor::Fill(aCollection);}
+ virtual void Fill(const AliFemtoEvent* aEvent,const AliFemtoParticleCollection* aCollection){AliFemtoCutMonitor::Fill(aEvent, aCollection);}
+ virtual void Fill(const AliFemtoParticleCollection* aCollection1,const AliFemtoParticleCollection* aCollection2);
+
+ void Write();
+
+ virtual TList *GetOutputList();
+
+ private:
+ TH1D *fCollection1Mult; // Collection 1 multiplicity distribution
+ TH1D *fCollection2Mult; // Collection 2 multiplicity distribution
+
+
+};
+
+#endif
snprintf(name, 200, "EvMultTotPt%s", aName);
fMultSumPt = new TH2D(name,"Event Multiplicity vs Total pT",501,-0.5,500.5,1000,0.0,100.0);
+
+
if(faddhists)
{
snprintf(name, 200, "EvMultEstITSTPC%s", aName);
if (fEst3Norm) delete fEst3Norm;
fEst3Norm = new TH2D(*aCut.fEst3Norm);
}
+
}
AliFemtoCutMonitorEventMult::~AliFemtoCutMonitorEventMult()
delete fEst1Norm;
delete fEst2Norm;
delete fEst3Norm;
- }
+ }
}
AliFemtoCutMonitorEventMult& AliFemtoCutMonitorEventMult::operator=(const AliFemtoCutMonitorEventMult& aCut)
tOutputList->Add(fEst2Norm);
tOutputList->Add(fEst3Norm);
}
-
return tOutputList;
}
virtual void Fill(const AliFemtoKink* aKink) {AliFemtoCutMonitor::Fill(aKink);}
virtual void Fill(const AliFemtoPair* aPair) {AliFemtoCutMonitor::Fill(aPair);}
virtual void Fill(const AliFemtoParticleCollection* aCollection) {AliFemtoCutMonitor::Fill(aCollection);}
- virtual void Fill(const AliFemtoEvent* aEvent,const AliFemtoParticleCollection* aCollection)
- {AliFemtoCutMonitor::Fill(aEvent, aCollection);}
+ virtual void Fill(const AliFemtoEvent* aEvent,const AliFemtoParticleCollection* aCollection) {AliFemtoCutMonitor::Fill(aEvent, aCollection);}
+ virtual void Fill(const AliFemtoParticleCollection* aCollection1,const AliFemtoParticleCollection* aCollection2) {AliFemtoCutMonitor::Fill(aCollection1, aCollection2);}
void SetReadMC(Bool_t mc);
void AdditionalMultHistsOn(Bool_t addhists);
virtual void Fill(const AliFemtoParticleCollection* aCollection) {AliFemtoCutMonitor::Fill(aCollection);}
virtual void Fill(const AliFemtoEvent* aEvent,const AliFemtoParticleCollection* aCollection)
{AliFemtoCutMonitor::Fill(aEvent, aCollection);}
+ virtual void Fill(const AliFemtoParticleCollection* aCollection1,const AliFemtoParticleCollection* aCollection2) {AliFemtoCutMonitor::Fill(aCollection1, aCollection2);}
void Write();
// ------------------------------------Gael/19/06/02-------------------------
void AliFemtoCutMonitorHandler::FillCutMonitor(const AliFemtoEvent* event,const AliFemtoParticleCollection* partColl) {
// Fill event particle collection
- cout<<"In AliFemtoCutMonitorHandler::FillCutMonitor(const AliFemtoEvent* event, AliFemtoPicoEvent* picoEvent)"<<endl;
+ //cout<<"In AliFemtoCutMonitorHandler::FillCutMonitor(const AliFemtoEvent* event, AliFemtoPicoEvent* picoEvent)"<<endl;
if (fCollectionsEmpty) return;
AliFemtoCutMonitorIterator iter;
AliFemtoCutMonitor* tCM;
tCM->Fill(event,partColl);
}
}
+
+void AliFemtoCutMonitorHandler::FillCutMonitor(const AliFemtoParticleCollection* partColl1, const AliFemtoParticleCollection* partColl2) {
+ // Fill event particle collection
+ //cout<<"***In AliFemtoCutMonitorHandler::FillCutMonitor(const AliFemtoEvent* event, AliFemtoPicoEvent* picoEvent)"<<endl;
+ if (fCollectionsEmpty) return;
+ AliFemtoCutMonitorIterator iter;
+ AliFemtoCutMonitor* tCM;
+
+ for (iter=fPassColl->begin(); iter!=fPassColl->end(); iter++){
+ tCM = *iter;
+ tCM->Fill(partColl1,partColl2);
+ }
+}
+
// ---------------------------------------------------------------------------
void AliFemtoCutMonitorHandler::Finish() {
// Perform finish operations on cut monitors
void FillCutMonitor(const AliFemtoPair* pair, bool pass);//Gael 11/04/02
void FillCutMonitor(const AliFemtoParticleCollection* partColl);// Gael 19/06/02
void FillCutMonitor(const AliFemtoEvent* event, const AliFemtoParticleCollection* partColl);// Gael 19/06/02
+ void FillCutMonitor(const AliFemtoParticleCollection* partColl1, const AliFemtoParticleCollection* partColl2);
void Finish();
virtual TList *GetOutputList();
virtual void Fill(const AliFemtoParticleCollection* aCollection) {AliFemtoCutMonitor::Fill(aCollection);}
virtual void Fill(const AliFemtoEvent* aEvent,const AliFemtoParticleCollection* aCollection)
{AliFemtoCutMonitor::Fill(aEvent, aCollection);}
-
+ virtual void Fill(const AliFemtoParticleCollection* aCollection1,const AliFemtoParticleCollection* aCollection2) {AliFemtoCutMonitor::Fill(aCollection1, aCollection2);}
void SetTOFParticle(Int_t ipart);
void Write();
virtual void Fill(const AliFemtoParticleCollection* aCollection) {AliFemtoCutMonitor::Fill(aCollection);}
virtual void Fill(const AliFemtoEvent* aEvent,const AliFemtoParticleCollection* aCollection)
{AliFemtoCutMonitor::Fill(aEvent, aCollection);}
+ virtual void Fill(const AliFemtoParticleCollection* aCollection1,const AliFemtoParticleCollection* aCollection2) {AliFemtoCutMonitor::Fill(aCollection1, aCollection2);}
void Write();
virtual void Fill(const AliFemtoParticleCollection* aCollection) {AliFemtoCutMonitor::Fill(aCollection);}
virtual void Fill(const AliFemtoEvent* aEvent,const AliFemtoParticleCollection* aCollection)
{AliFemtoCutMonitor::Fill(aEvent, aCollection);}
-
+ virtual void Fill(const AliFemtoParticleCollection* aCollection1,const AliFemtoParticleCollection* aCollection2) {AliFemtoCutMonitor::Fill(aCollection1, aCollection2);}
void Write();
--- /dev/null
+////////////////////////////////////////////////////////////////////////////////
+// //
+// AliFemtoCutMonitorV0 //
+// //
+////////////////////////////////////////////////////////////////////////////////
+#include "AliFemtoCutMonitorV0.h"
+#include <TH1D.h>
+#include <TH2D.h>
+#include <TH3D.h>
+#include <TList.h>
+#include "AliFemtoModelHiddenInfo.h"
+
+AliFemtoCutMonitorV0::AliFemtoCutMonitorV0():
+ fLambdaMass(0),
+ fAntiLambdaMass(0),
+ fK0ShortMass(0),
+ fDcaDaughters(0),
+ fDcaV0ToPrimVertex(0),
+ fCosPointingAngle(0),
+ fEtaV0(0),
+ fPtV0(0),
+ fPtPosDaughter(0),
+ fPtNegDaughter(0)
+{
+ // Default constructor
+ fLambdaMass = new TH1F("LambdaMass", "Mass Assuming Lambda Hypothesis", 10000, 0, 5);
+ fAntiLambdaMass = new TH1F("AntiLambdaMass", "Mass Assuming AntiLambda Hypothesis", 10000, 0, 5);
+ fK0ShortMass= new TH1F("K0ShortMass", "Mass Assuming K0 short Hypothesis", 500, 0, 5);
+ fDcaDaughters = new TH1F("DcaDaughters", "DCA Daughters", 500, 0, 2);
+ fDcaV0ToPrimVertex = new TH1F("DcaV0ToPrimVertex", "DCA V0 to primary vertex", 500, 0, 3);
+ fCosPointingAngle = new TH1F("CosPointingAngle","Cosinus Pointing Angle",500,0,1);
+ fEtaV0 = new TH1F("EtaV0", "|Eta| distribution of V0s", 500, 0.0, 8.);
+ fPtV0 = new TH1F("PtV0", "Pt distribution of V0s", 500, 0.0, 8.);
+ fPtPosDaughter = new TH1F("PtPosDaughter", "Pt distribution of positive daughters", 500, 0.0, 5.);
+ fPtNegDaughter = new TH1F("PtNegDaughter", "Pt distribution of negative daughters", 500, 0.0, 5.);
+
+
+ fLambdaMass->Sumw2();
+ fAntiLambdaMass->Sumw2();
+ fK0ShortMass->Sumw2();
+ fDcaDaughters->Sumw2();
+ fDcaV0ToPrimVertex->Sumw2();
+ fCosPointingAngle->Sumw2();
+ fEtaV0->Sumw2();
+ fPtPosDaughter->Sumw2();
+ fPtNegDaughter->Sumw2();
+
+}
+
+AliFemtoCutMonitorV0::AliFemtoCutMonitorV0(const char *aName):
+ AliFemtoCutMonitor(),
+ fLambdaMass(0),
+ fAntiLambdaMass(0),
+ fK0ShortMass(0),
+ fDcaDaughters(0),
+ fDcaV0ToPrimVertex(0),
+ fCosPointingAngle(0),
+ fEtaV0(0),
+ fPtV0(0),
+ fPtPosDaughter(0),
+ fPtNegDaughter(0)
+{
+ // Normal constructor
+ char name[200];
+ snprintf(name, 200, "LambdaMass%s", aName);
+ fLambdaMass = new TH1F(name, "Mass Assuming Lambda Hypothesis", 10000, 0, 5);
+ snprintf(name, 200, "AntiLambdaMass%s", aName);
+ fAntiLambdaMass = new TH1F(name, "Mass Assuming AntiLambda Hypothesis", 10000, 0, 5);
+ snprintf(name, 200, "K0ShortMass%s", aName);
+ fK0ShortMass = new TH1F(name, "Mass Assuming K0 short Hypothesis", 500, 0, 5);
+ snprintf(name, 200, "DcaDaughters%s", aName);
+ fDcaDaughters = new TH1F(name, "DCA Daughters", 500, 0, 2);
+ snprintf(name, 200, "DcaV0ToPrimVertex%s", aName);
+ fDcaV0ToPrimVertex = new TH1F(name, "DCA V0 to primary vertex", 500, 0, 3);
+ snprintf(name, 200, "CosPointingAngle%s", aName);
+ fCosPointingAngle = new TH1F(name,"Cosinus Pointing Angle",500,0,1);
+ snprintf(name, 200, "EtaV0%s", aName);
+ fEtaV0 = new TH1F(name, "|Eta| distribution of V0s", 500, 0.0, 1.);
+ snprintf(name, 200, "PtV0%s", aName);
+ fPtV0 = new TH1F(name, "Pt distribution of V0s", 500, 0.0, 8.);
+ snprintf(name, 200, "fPtPosDaughter%s", aName);
+ fPtPosDaughter = new TH1F(name, "Pt distribution of positive daughters", 500, 0.0, 5.);
+ snprintf(name, 200, "fPtNegDaughter%s", aName);
+ fPtNegDaughter = new TH1F(name, "Pt distribution of negative daughters", 500, 0.0, 5.);
+
+ fLambdaMass->Sumw2();
+ fAntiLambdaMass->Sumw2();
+ fK0ShortMass->Sumw2();
+ fDcaDaughters->Sumw2();
+ fDcaV0ToPrimVertex->Sumw2();
+ fCosPointingAngle->Sumw2();
+ fEtaV0->Sumw2();
+ fPtPosDaughter->Sumw2();
+ fPtNegDaughter->Sumw2();
+}
+
+AliFemtoCutMonitorV0::AliFemtoCutMonitorV0(const AliFemtoCutMonitorV0 &aCut):
+ AliFemtoCutMonitor(),
+ fLambdaMass(0),
+ fAntiLambdaMass(0),
+ fK0ShortMass(0),
+ fDcaDaughters(0),
+ fDcaV0ToPrimVertex(0),
+ fCosPointingAngle(0),
+ fEtaV0(0),
+ fPtV0(0),
+ fPtPosDaughter(0),
+ fPtNegDaughter(0)
+{
+ // copy constructor
+ if (fLambdaMass) delete fLambdaMass;
+ fLambdaMass = new TH1F(*aCut.fLambdaMass);
+ if (fAntiLambdaMass) delete fAntiLambdaMass;
+ fAntiLambdaMass = new TH1F(*aCut.fAntiLambdaMass);
+ if (fK0ShortMass) delete fK0ShortMass;
+ fK0ShortMass = new TH1F(*aCut.fK0ShortMass);
+ if (fDcaDaughters) delete fDcaDaughters;
+ fDcaDaughters = new TH1F(*aCut.fDcaDaughters);
+ if (fDcaV0ToPrimVertex) delete fDcaV0ToPrimVertex;
+ fDcaV0ToPrimVertex = new TH1F(*aCut.fDcaV0ToPrimVertex);
+ if(fCosPointingAngle) delete fCosPointingAngle;
+ fCosPointingAngle = new TH1F(*aCut.fCosPointingAngle);
+ if(fEtaV0) delete fEtaV0;
+ fEtaV0 = new TH1F(*aCut.fEtaV0);
+ if(fPtV0) delete fPtV0;
+ fPtV0 = new TH1F(*aCut.fPtV0);
+ if(fPtPosDaughter) delete fPtPosDaughter;
+ fPtPosDaughter = new TH1F(*aCut.fPtPosDaughter);
+ if(fPtNegDaughter) delete fPtNegDaughter;
+ fPtNegDaughter = new TH1F(*aCut.fPtNegDaughter);
+
+ fLambdaMass->Sumw2();
+ fAntiLambdaMass->Sumw2();
+ fK0ShortMass->Sumw2();
+ fDcaDaughters->Sumw2();
+ fDcaV0ToPrimVertex->Sumw2();
+ fCosPointingAngle->Sumw2();
+ fEtaV0->Sumw2();
+ fPtPosDaughter->Sumw2();
+ fPtNegDaughter->Sumw2();
+}
+
+AliFemtoCutMonitorV0::~AliFemtoCutMonitorV0()
+{
+ // Destructor
+ delete fLambdaMass;
+ delete fAntiLambdaMass;
+ delete fK0ShortMass;
+ delete fDcaDaughters;
+ delete fDcaV0ToPrimVertex;
+ delete fCosPointingAngle;
+ delete fEtaV0;
+ delete fPtV0;
+ delete fPtPosDaughter;
+ delete fPtNegDaughter;
+}
+
+AliFemtoCutMonitorV0& AliFemtoCutMonitorV0::operator=(const AliFemtoCutMonitorV0& aCut)
+{
+ // assignment operator
+ if (this == &aCut)
+ return *this;
+
+ if (fLambdaMass) delete fLambdaMass;
+ fLambdaMass = new TH1F(*aCut.fLambdaMass);
+ if (fAntiLambdaMass) delete fAntiLambdaMass;
+ fAntiLambdaMass = new TH1F(*aCut.fAntiLambdaMass);
+ if (fK0ShortMass) delete fK0ShortMass;
+ fK0ShortMass = new TH1F(*aCut.fK0ShortMass);
+ if (fDcaDaughters) delete fDcaDaughters;
+ fDcaDaughters = new TH1F(*aCut.fDcaDaughters);
+ if (fDcaV0ToPrimVertex) delete fDcaV0ToPrimVertex;
+ fDcaV0ToPrimVertex = new TH1F(*aCut.fDcaV0ToPrimVertex);
+ if(fCosPointingAngle) delete fCosPointingAngle;
+ fCosPointingAngle = new TH1F(*aCut.fCosPointingAngle);
+ if(fEtaV0) delete fEtaV0;
+ fEtaV0 = new TH1F(*aCut.fEtaV0);
+ if(fPtV0) delete fPtV0;
+ fPtV0 = new TH1F(*aCut.fPtV0);
+ if(fPtPosDaughter) delete fPtPosDaughter;
+ fPtPosDaughter = new TH1F(*aCut.fPtPosDaughter);
+ if(fPtNegDaughter) delete fPtNegDaughter;
+ fPtNegDaughter = new TH1F(*aCut.fPtNegDaughter);
+
+ fLambdaMass->Sumw2();
+ fAntiLambdaMass->Sumw2();
+ fK0ShortMass->Sumw2();
+ fDcaDaughters->Sumw2();
+ fDcaV0ToPrimVertex->Sumw2();
+ fCosPointingAngle->Sumw2();
+ fEtaV0->Sumw2();
+ fPtPosDaughter->Sumw2();
+ fPtNegDaughter->Sumw2();
+
+ return *this;
+}
+
+AliFemtoString AliFemtoCutMonitorV0::Report(){
+ // Prepare report from the execution
+ string stemp = "*** AliFemtoCutMonitorV0 report";
+ AliFemtoString returnThis = stemp;
+ return returnThis;
+}
+
+void AliFemtoCutMonitorV0::Fill(const AliFemtoV0* aV0)
+{
+ // Fill momentum resolution histograms for the particle
+ fLambdaMass->Fill(aV0->MassLambda());
+ fAntiLambdaMass->Fill(aV0->MassAntiLambda());
+ fK0ShortMass->Fill(aV0->MassK0Short());
+ fDcaDaughters->Fill(aV0->DcaV0Daughters());
+ fDcaV0ToPrimVertex->Fill(aV0->DcaV0ToPrimVertex());
+ fCosPointingAngle->Fill(aV0->CosPointingAngle());
+ fEtaV0->Fill(aV0->EtaV0());
+ fPtV0->Fill(aV0->PtV0());
+ fPtPosDaughter->Fill(aV0->PtPos());
+ fPtNegDaughter->Fill(aV0->PtNeg());
+}
+
+void AliFemtoCutMonitorV0::Write()
+{
+ // Write out the relevant histograms
+ fLambdaMass->Write();
+ fAntiLambdaMass->Write();
+ fK0ShortMass->Write();
+ fDcaDaughters->Write();
+ fDcaV0ToPrimVertex->Write();
+ fCosPointingAngle->Write();
+ fEtaV0->Write();
+ fPtV0->Write();
+ fPtPosDaughter->Write();
+ fPtNegDaughter->Write();
+}
+
+TList *AliFemtoCutMonitorV0::GetOutputList()
+{
+ // Get the list of histograms to write
+ TList *tOutputList = new TList();
+ tOutputList->Add(fLambdaMass);
+ tOutputList->Add(fAntiLambdaMass);
+ tOutputList->Add(fK0ShortMass);
+ tOutputList->Add(fDcaDaughters);
+ tOutputList->Add(fDcaV0ToPrimVertex);
+ tOutputList->Add(fCosPointingAngle);
+ tOutputList->Add(fEtaV0);
+ tOutputList->Add(fPtV0);
+ tOutputList->Add(fPtPosDaughter);
+ tOutputList->Add(fPtNegDaughter);
+
+ return tOutputList;
+}
--- /dev/null
+////////////////////////////////////////////////////////////////////////////////
+// //
+// AliFemtoCutMonitorV0 - //
+// //
+////////////////////////////////////////////////////////////////////////////////
+#ifndef AliFemtoCutMonitorV0_H
+#define AliFemtoCutMonitorV0_H
+
+class AliFemtoEvent;
+class AliFemtoTrack;
+class AliFemtoV0;
+class AliFemtoKink;
+class AliFemtoPair; // Gael 12/04/02
+class TH1F;
+class TList;
+#include "AliFemtoString.h"
+#include "AliFemtoParticleCollection.h"
+#include "AliFemtoCutMonitor.h"
+
+class AliFemtoCutMonitorV0 : public AliFemtoCutMonitor{
+
+public:
+ AliFemtoCutMonitorV0();
+ AliFemtoCutMonitorV0(const char *aName);
+ AliFemtoCutMonitorV0(const AliFemtoCutMonitorV0 &aCut);
+ virtual ~AliFemtoCutMonitorV0();
+
+ AliFemtoCutMonitorV0& operator=(const AliFemtoCutMonitorV0& aCut);
+
+ virtual AliFemtoString Report();
+ virtual void Fill(const AliFemtoEvent* aEvent) {AliFemtoCutMonitor::Fill(aEvent);}
+ virtual void Fill(const AliFemtoTrack* aTrack){AliFemtoCutMonitor::Fill(aTrack);}
+ virtual void Fill(const AliFemtoV0* aV0);
+ virtual void Fill(const AliFemtoKink* aKink) {AliFemtoCutMonitor::Fill(aKink);}
+ virtual void Fill(const AliFemtoPair* aPair) {AliFemtoCutMonitor::Fill(aPair);}
+ virtual void Fill(const AliFemtoParticleCollection* aCollection) {AliFemtoCutMonitor::Fill(aCollection);}
+ virtual void Fill(const AliFemtoEvent* aEvent,const AliFemtoParticleCollection* aCollection)
+ {AliFemtoCutMonitor::Fill(aEvent, aCollection);}
+ virtual void Fill(const AliFemtoParticleCollection* aCollection1,const AliFemtoParticleCollection* aCollection2) {AliFemtoCutMonitor::Fill(aCollection1, aCollection2);}
+ void Write();
+
+ virtual TList *GetOutputList();
+
+private:
+ TH1F *fLambdaMass; // Mass assuming lambda hypothesis
+ TH1F *fAntiLambdaMass; // Mass assuming antilambda hypothesis
+ TH1F *fK0ShortMass; // Mass assuming k-short hypothesis
+ TH1F *fDcaDaughters; // DCA of v0 daughters at Decay vertex
+ TH1F *fDcaV0ToPrimVertex;// DCA of v0 to primary vertex
+ TH1F *fCosPointingAngle;
+ TH1F *fEtaV0;
+ TH1F *fPtV0;
+ TH1F *fPtPosDaughter;
+ TH1F *fPtNegDaughter;
+};
+
+#endif
float AliFemtoEvent::ReactionPlaneAngle() const { return fReactionPlaneAngle; }
void AliFemtoEvent::SetEP(AliEventplane* ep) { fEP = ep;}
AliEventplane* AliFemtoEvent::EP() const {return fEP; }
-
+ //fV0perEvent->Sumw2();
//----------------------------- below here is only for star
int AliFemtoEvent::UncorrectedNumberOfNegativePrimaries() const
return fSPDMult;
}
+int AliFemtoEvent::NumberOfV0s() const
+{
+ return V0Collection()->size();
+}
+
int AliFemtoEvent::UncorrectedNumberOfPrimaries() const
{
if (fNormalizedMult < -1) {
int UncorrectedNumberOfNegativePrimaries() const;
int UncorrectedNumberOfPrimaries() const;
int SPDMultiplicity() const;
+ int NumberOfV0s() const;
unsigned short MultiplicityEstimateITSTPC() const;
unsigned short MultiplicityEstimateTracklets() const;
#endif
using namespace std;
+
+double fV1[3];
+
//____________________________
//constructor with 0 parameters , look at default settings
AliFemtoEventReaderAOD::AliFemtoEventReaderAOD():
fFilterBit(0),
// fPWG2AODTracks(0x0),
fReadMC(0),
+ fReadV0(0),
fUsePreCent(0),
+ fNoCentrality(0),
fAODpidUtil(0),
fInputFile(" "),
fFileName(" "),
fFilterBit(0),
// fPWG2AODTracks(0x0),
fReadMC(0),
+ fReadV0(0),
fUsePreCent(0),
+ fNoCentrality(0),
fAODpidUtil(0),
fInputFile(" "),
fFileName(" "),
fAodFile(0x0)
{
// copy constructor
+ fReadMC = aReader.fReadMC;
+ fReadV0 = aReader.fReadV0;
fInputFile = aReader.fInputFile;
fFileName = aReader.fFileName;
fNumberofEvent = aReader.fNumberofEvent;
fAODpidUtil = aReader.fAODpidUtil;
fCentRange[0] = aReader.fCentRange[0];
fCentRange[1] = aReader.fCentRange[1];
+ fNoCentrality = aReader.fNoCentrality;
+ fUsePreCent = aReader.fUsePreCent;
}
//__________________
//Destructor
fAODpidUtil = aReader.fAODpidUtil;
fCentRange[0] = aReader.fCentRange[0];
fCentRange[1] = aReader.fCentRange[1];
+ fUsePreCent = aReader.fUsePreCent;
+ fNoCentrality = aReader.fNoCentrality;
return *this;
}
}
// Primary Vertex position
- double fV1[3];
+ // double fV1[3];
fEvent->GetPrimaryVertex()->GetPosition(fV1);
AliFmThreeVectorF vertex(fV1[0],fV1[1],fV1[2]);
nofTracks=fEvent->GetNumberOfTracks();
cout<<"nofTracks: "<<nofTracks<<endl;
- AliCentrality *cent = fEvent->GetCentrality();
+ if (!fNoCentrality)
+ AliCentrality *cent = fEvent->GetCentrality();
- if (cent && fUsePreCent) {
+ if (!fNoCentrality && cent && fUsePreCent) {
if ((cent->GetCentralityPercentile("V0M")*10 < fCentRange[0]) ||
(cent->GetCentralityPercentile("V0M")*10 > fCentRange[1]))
{
for (int i=0;i<nofTracks;i++) {
const AliAODTrack *aodtrack=fEvent->GetTrack(i);
if (!aodtrack->TestFilterBit(fFilterBit)) {
+ if(aodtrack->GetID() < 0) continue;
labels[aodtrack->GetID()] = i;
}
}
delete trackCopy;
continue;
}
-
+
CopyAODtoFemtoTrack(aodtrack, trackCopy);
// copying PID information from the correspondent track
// const AliAODTrack *aodtrackpid = fEvent->GetTrack(labels[-1-fEvent->GetTrack(i)->GetID()]);
AliAODTrack *aodtrackpid = fEvent->GetTrack(labels[-1-fEvent->GetTrack(i)->GetID()]);
CopyPIDtoFemtoTrack(aodtrackpid, trackCopy);
-
+
if (mcP) {
// Fill the hidden information with the simulated data
// Int_t pLabel = aodtrack->GetLabel();
tEvent->SetNumberOfTracks(realnofTracks);//setting number of track which we read in event
tEvent->SetNormalizedMult(tracksPrim);
- // AliCentrality *cent = fEvent->GetCentrality();
- if (cent) tEvent->SetNormalizedMult(lrint(10*cent->GetCentralityPercentile("V0M")));
- // if (cent) tEvent->SetNormalizedMult((int) cent->GetCentralityPercentile("V0M"));
-
- if (cent) {
- tEvent->SetCentralityV0(cent->GetCentralityPercentile("V0M"));
- // tEvent->SetCentralityFMD(cent->GetCentralityPercentile("FMD"));
- tEvent->SetCentralitySPD1(cent->GetCentralityPercentile("CL1"));
- // tEvent->SetCentralityTrk(cent->GetCentralityPercentile("TRK"));
+ if (!fNoCentrality) {
+ // AliCentrality *cent = fEvent->GetCentrality();
+ if (cent) tEvent->SetNormalizedMult(lrint(10*cent->GetCentralityPercentile("V0M")));
+ // if (cent) tEvent->SetNormalizedMult((int) cent->GetCentralityPercentile("V0M"));
+
+ if (cent) {
+ tEvent->SetCentralityV0(cent->GetCentralityPercentile("V0M"));
+ // tEvent->SetCentralityFMD(cent->GetCentralityPercentile("FMD"));
+ tEvent->SetCentralitySPD1(cent->GetCentralityPercentile("CL1"));
+ // tEvent->SetCentralityTrk(cent->GetCentralityPercentile("TRK"));
+ }
}
-
if (mcP) delete [] motherids;
cout<<"end of reading nt "<<nofTracks<<" real number "<<realnofTracks<<endl;
+
+ if(fReadV0)
+ {
+
+ for (Int_t i = 0; i < fEvent->GetNumberOfV0s(); i++) {
+ AliAODv0* aodv0 = fEvent->GetV0(i);
+ if (!aodv0) continue;
+ if(aodv0->GetNDaughters()>2) continue;
+ if(aodv0->GetNProngs()>2) continue;
+ if(aodv0->GetCharge()!=0) continue;
+ if(aodv0->ChargeProng(0)==aodv0->ChargeProng(1)) continue;
+ AliFemtoV0* trackCopyV0 = new AliFemtoV0();
+ CopyAODtoFemtoV0(aodv0, trackCopyV0);
+ tEvent->V0Collection()->push_back(trackCopyV0);
+ //cout<<"Pushback v0 to v0collection"<<endl;
+ }
+ }
+
}
void AliFemtoEventReaderAOD::CopyAODtoFemtoTrack(AliAODTrack *tAodTrack,
// If it exists, use the additional information from the PWG2 AOD
// Primary Vertex position
- double fV1[3];
+
fEvent->GetPrimaryVertex()->GetPosition(fV1);
// fEvent->GetPrimaryVertex()->GetXYZ(fV1);
}
else {
tFemtoTrack->SetImpactD(impact[0]);
- tFemtoTrack->SetImpactZ(impact[1]);
+ tFemtoTrack->SetImpactZ(impact[1]+fV1[2]);
}
// if (TMath::Abs(tAodTrack->Xv()) > 0.00000000001)
tFemtoTrack->SetCdd(covmat[0]);
tFemtoTrack->SetCdz(covmat[1]);
tFemtoTrack->SetCzz(covmat[2]);
- tFemtoTrack->SetITSchi2(tAodTrack->Chi2perNDF());
- tFemtoTrack->SetITSncls(tAodTrack->GetITSNcls());
- tFemtoTrack->SetTPCchi2(tAodTrack->Chi2perNDF());
- tFemtoTrack->SetTPCncls(tAodTrack->GetTPCNcls());
- tFemtoTrack->SetTPCnclsF(tAodTrack->GetTPCNcls());
+ tFemtoTrack->SetITSchi2(tAodTrack->Chi2perNDF());
+ tFemtoTrack->SetITSncls(tAodTrack->GetITSNcls());
+ tFemtoTrack->SetTPCchi2(tAodTrack->Chi2perNDF());
+ tFemtoTrack->SetTPCncls(tAodTrack->GetTPCNcls());
+ tFemtoTrack->SetTPCnclsF(tAodTrack->GetTPCNcls());
tFemtoTrack->SetTPCsignalN(1);
tFemtoTrack->SetTPCsignalS(1);
tFemtoTrack->SetTPCsignal(tAodTrack->GetTPCsignal());
tFemtoTrack->SetKinkIndexes(indexes);
}
+void AliFemtoEventReaderAOD::CopyAODtoFemtoV0(AliAODv0 *tAODv0, AliFemtoV0 *tFemtoV0)
+{
+ //tFemtoV0->SetdecayLengthV0(tAODv0->DecayLengthV0()); //wrocic do tego
+ tFemtoV0->SetdecayVertexV0X(tAODv0->DecayVertexV0X());
+ tFemtoV0->SetdecayVertexV0Y(tAODv0->DecayVertexV0Y());
+ tFemtoV0->SetdecayVertexV0Z(tAODv0->DecayVertexV0Z());
+ AliFemtoThreeVector decayvertex(tAODv0->DecayVertexV0X(),tAODv0->DecayVertexV0Y(),tAODv0->DecayVertexV0Z());
+ tFemtoV0->SetdecayVertexV0(decayvertex);
+ tFemtoV0->SetdcaV0Daughters(tAODv0->DcaV0Daughters());
+ tFemtoV0->SetdcaV0ToPrimVertex(tAODv0->DcaV0ToPrimVertex());
+ tFemtoV0->SetdcaPosToPrimVertex(tAODv0->DcaPosToPrimVertex());
+ tFemtoV0->SetdcaNegToPrimVertex(tAODv0->DcaNegToPrimVertex());
+ tFemtoV0->SetmomPosX(tAODv0->MomPosX());
+ tFemtoV0->SetmomPosY(tAODv0->MomPosY());
+ tFemtoV0->SetmomPosZ(tAODv0->MomPosZ());
+ AliFemtoThreeVector mompos(tAODv0->MomPosX(),tAODv0->MomPosY(),tAODv0->MomPosZ());
+ tFemtoV0->SetmomPos(mompos);
+ tFemtoV0->SetmomNegX(tAODv0->MomNegX());
+ tFemtoV0->SetmomNegY(tAODv0->MomNegY());
+ tFemtoV0->SetmomNegZ(tAODv0->MomNegZ());
+ AliFemtoThreeVector momneg(tAODv0->MomNegX(),tAODv0->MomNegY(),tAODv0->MomNegZ());
+ tFemtoV0->SetmomNeg(momneg);
+
+ //jest cos takiego w AliFemtoV0.h czego nie ma w AliAODv0.h
+ //void SettpcHitsPos(const int& i);
+ //void SettpcHitsNeg(const int& i);
+
+ //void SetTrackTopologyMapPos(unsigned int word, const unsigned long& m);
+ //void SetTrackTopologyMapNeg(unsigned int word, const unsigned long& m);
+
+ tFemtoV0->SetmomV0X(tAODv0->MomV0X());
+ tFemtoV0->SetmomV0Y(tAODv0->MomV0Y());
+ tFemtoV0->SetmomV0Z(tAODv0->MomV0Z());
+ AliFemtoThreeVector momv0(tAODv0->MomV0X(),tAODv0->MomV0Y(),tAODv0->MomV0Z());
+ tFemtoV0->SetmomV0(momv0);
+ tFemtoV0->SetalphaV0(tAODv0->AlphaV0());
+ tFemtoV0->SetptArmV0(tAODv0->PtArmV0());
+ tFemtoV0->SeteLambda(tAODv0->ELambda());
+ tFemtoV0->SeteK0Short(tAODv0->EK0Short());
+ tFemtoV0->SetePosProton(tAODv0->EPosProton());
+ tFemtoV0->SeteNegProton(tAODv0->ENegProton());
+ tFemtoV0->SetmassLambda(tAODv0->MassLambda());
+ tFemtoV0->SetmassAntiLambda(tAODv0->MassAntiLambda());
+ tFemtoV0->SetmassK0Short(tAODv0->MassK0Short());
+ tFemtoV0->SetrapLambda(tAODv0->RapLambda());
+ tFemtoV0->SetrapK0Short(tAODv0->RapK0Short());
+
+ //void SetcTauLambda( float x);
+ //void SetcTauK0Short( float x);
+
+ tFemtoV0->SetptV0(::sqrt(tAODv0->Pt2V0())); //!
+ tFemtoV0->SetptotV0(::sqrt(tAODv0->Ptot2V0()));
+ tFemtoV0->SetptPos(::sqrt(tAODv0->MomPosX()*tAODv0->MomPosX()+tAODv0->MomPosY()*tAODv0->MomPosY()));
+ tFemtoV0->SetptotPos(::sqrt(tAODv0->Ptot2Pos()));
+ tFemtoV0->SetptNeg(::sqrt(tAODv0->MomNegX()*tAODv0->MomNegX()+tAODv0->MomNegY()*tAODv0->MomNegY()));
+ tFemtoV0->SetptotNeg(::sqrt(tAODv0->Ptot2Neg()));
+
+ tFemtoV0->SetidNeg(tAODv0->GetNegID());
+ //cout<<"tAODv0->GetNegID(): "<<tAODv0->GetNegID()<<endl;
+ //cout<<"tFemtoV0->IdNeg(): "<<tFemtoV0->IdNeg()<<endl;
+ tFemtoV0->SetidPos(tAODv0->GetPosID());
+
+ tFemtoV0->SetEtaV0(tAODv0->Eta());
+ tFemtoV0->SetPhiV0(tAODv0->Phi());
+ tFemtoV0->SetCosPointingAngle(tAODv0->CosPointingAngle(fV1));
+ //tFemtoV0->SetYV0(tAODv0->Y());
+
+ //void SetdedxNeg(float x);
+ //void SeterrdedxNeg(float x);//Gael 04Fev2002
+ //void SetlendedxNeg(float x);//Gael 04Fev2002
+ //void SetdedxPos(float x);
+ //void SeterrdedxPos(float x);//Gael 04Fev2002
+ //void SetlendedxPos(float x);//Gael 04Fev2002
+
+ tFemtoV0->SetEtaPos(tAODv0->PseudoRapPos());
+ tFemtoV0->SetEtaNeg(tAODv0->PseudoRapNeg());
+
+ AliAODTrack *trackpos = (AliAODTrack*)tAODv0->GetDaughter(0);
+ AliAODTrack *trackneg = (AliAODTrack*)tAODv0->GetDaughter(1);
+
+ if(trackpos && trackneg)
+ {
+ //tFemtoV0->SetEtaPos(trackpos->Eta()); //tAODv0->PseudoRapPos()
+ //tFemtoV0->SetEtaNeg(trackneg->Eta()); //tAODv0->PseudoRapNeg()
+ tFemtoV0->SetTPCNclsPos(trackpos->GetTPCNcls());
+ tFemtoV0->SetTPCNclsNeg(trackneg->GetTPCNcls());
+ tFemtoV0->SetTPCclustersPos(trackpos->GetTPCClusterMap());
+ tFemtoV0->SetTPCclustersNeg(trackneg->GetTPCClusterMap());
+ tFemtoV0->SetTPCsharingPos(trackpos->GetTPCSharedMap());
+ tFemtoV0->SetTPCsharingNeg(trackneg->GetTPCSharedMap());
+ tFemtoV0->SetNdofPos(trackpos->Chi2perNDF());
+ tFemtoV0->SetNdofNeg(trackneg->Chi2perNDF());
+ tFemtoV0->SetStatusPos(trackpos->GetStatus());
+ tFemtoV0->SetStatusNeg(trackneg->GetStatus());
+
+ tFemtoV0->SetPosNSigmaTPCK(fAODpidUtil->NumberOfSigmasTPC(trackpos,AliPID::kKaon));
+ tFemtoV0->SetNegNSigmaTPCK(fAODpidUtil->NumberOfSigmasTPC(trackneg,AliPID::kKaon));
+ tFemtoV0->SetPosNSigmaTPCP(fAODpidUtil->NumberOfSigmasTPC(trackpos,AliPID::kProton));
+ tFemtoV0->SetNegNSigmaTPCP(fAODpidUtil->NumberOfSigmasTPC(trackneg,AliPID::kProton));
+ tFemtoV0->SetPosNSigmaTPCPi(fAODpidUtil->NumberOfSigmasTPC(trackpos,AliPID::kPion));
+ tFemtoV0->SetNegNSigmaTPCPi(fAODpidUtil->NumberOfSigmasTPC(trackneg,AliPID::kPion));
+
+
+ if((tFemtoV0->StatusPos()&AliESDtrack::kTOFpid)==0 || (tFemtoV0->StatusPos()&AliESDtrack::kTIME)==0 || (tFemtoV0->StatusPos()&AliESDtrack::kTOFout)==0 || (tFemtoV0->StatusPos()&AliESDtrack::kTOFmismatch)>0)
+ {
+ if((tFemtoV0->StatusNeg()&AliESDtrack::kTOFpid)==0 || (tFemtoV0->StatusNeg()&AliESDtrack::kTIME)==0 || (tFemtoV0->StatusNeg()&AliESDtrack::kTOFout)==0 || (tFemtoV0->StatusNeg()&AliESDtrack::kTOFmismatch)>0)
+ {
+ tFemtoV0->SetPosNSigmaTOFK(-9999);
+ tFemtoV0->SetNegNSigmaTOFK(-9999);
+ tFemtoV0->SetPosNSigmaTOFP(-9999);
+ tFemtoV0->SetNegNSigmaTOFP(-9999);
+ tFemtoV0->SetPosNSigmaTOFPi(-9999);
+ tFemtoV0->SetNegNSigmaTOFPi(-9999);
+ }
+ }
+ else
+ {
+ tFemtoV0->SetPosNSigmaTOFK(fAODpidUtil->NumberOfSigmasTOF(trackpos,AliPID::kKaon));
+ tFemtoV0->SetNegNSigmaTOFK(fAODpidUtil->NumberOfSigmasTOF(trackneg,AliPID::kKaon));
+ tFemtoV0->SetPosNSigmaTOFP(fAODpidUtil->NumberOfSigmasTOF(trackpos,AliPID::kProton));
+ tFemtoV0->SetNegNSigmaTOFP(fAODpidUtil->NumberOfSigmasTOF(trackneg,AliPID::kProton));
+ tFemtoV0->SetPosNSigmaTOFPi(fAODpidUtil->NumberOfSigmasTOF(trackpos,AliPID::kPion));
+ tFemtoV0->SetNegNSigmaTOFPi(fAODpidUtil->NumberOfSigmasTOF(trackneg,AliPID::kPion));
+ }
+ }
+ else
+ {
+ tFemtoV0->SetStatusPos(999);
+ tFemtoV0->SetStatusNeg(999);
+ }
+ tFemtoV0->SetOnFlyStatusV0(tAODv0->GetOnFlyStatus());
+}
+
void AliFemtoEventReaderAOD::SetFilterBit(UInt_t ibit)
{
fFilterBit = (1 << (ibit));
fReadMC = a;
}
+
+void AliFemtoEventReaderAOD::SetReadV0(unsigned char a)
+{
+ fReadV0 = a;
+}
+
AliAODMCParticle* AliFemtoEventReaderAOD::GetParticleWithLabel(TClonesArray *mcP, Int_t aLabel)
{
if (aLabel < 0) return 0;
{
fCentRange[0] = min; fCentRange[1] = max;
fUsePreCent = 1;
+ fNoCentrality = 0;
}
+void AliFemtoEventReaderAOD::SetNoCentrality(bool anocent)
+{
+ fNoCentrality = anocent;
+ if (fNoCentrality) fUsePreCent = 0;
+}
void AliFemtoEventReaderAOD::SetAODpidUtil(AliAODpidUtil *aAODpidUtil)
{
#include <list>
//#include "AliPWG2AODTrack.h"
#include "AliAODMCParticle.h"
-
+#include "AliFemtoV0.h"
#include "AliAODpidUtil.h"
class AliFemtoEvent;
void SetInputFile(const char* inputFile);
void SetFilterBit(UInt_t ibit);
void SetReadMC(unsigned char a);
+ void SetReadV0(unsigned char a);
void SetCentralityPreSelection(double min, double max);
+ void SetNoCentrality(bool anocent);
void SetAODpidUtil(AliAODpidUtil *aAODpidUtil);
protected:
AliFemtoTrack *tFemtoTrack
// AliPWG2AODTrack *tPWG2AODTrack
);
+ virtual void CopyAODtoFemtoV0(AliAODv0 *tAODv0, AliFemtoV0 *tFemtoV0);
virtual void CopyPIDtoFemtoTrack( AliAODTrack *tAodTrack,
AliFemtoTrack *tFemtoTrack);
// TClonesArray* fPWG2AODTracks; // Link to PWG2 specific AOD information (if it exists)
unsigned char fReadMC; // Attempt to read the MC information from the AOD
+ unsigned char fReadV0; // Read V0 information from the AOD and put it into V0Collection
unsigned char fUsePreCent; // Use centrality pre-selection to speed up analysis
double fCentRange[2]; // Centrality pre-selection range
+ unsigned char fNoCentrality; // Do not use centrality determination (for pp)
AliAODpidUtil* fAODpidUtil;
private:
#endif
using namespace std;
+
//____________________________
AliFemtoEventReaderESDChain::AliFemtoEventReaderESDChain():
fFileName(" "),
fEstEventMult(kITSTPC),
fEventTrig(AliVEvent::kMB), //trigger
fESDpid(0),
- fIsPidOwner(0)
+ fIsPidOwner(0),
+ fReadV0(0)
{
//constructor with 0 parameters , look at default settings
// fClusterPerPadrow = (list<Int_t> **) malloc(sizeof(list<Int_t> *) * AliESDfriendTrack::kMaxTPCcluster);
fEstEventMult(kITSTPC),
fEventTrig(AliVEvent::kMB), //trigger
fESDpid(0),
- fIsPidOwner(0)
+ fIsPidOwner(0),
+ fReadV0(0)
{
// Copy constructor
fConstrained = aReader.fConstrained;
fEstEventMult = aReader.fEstEventMult;
fUsePhysicsSel = aReader.fUsePhysicsSel;
+ fReadV0 = aReader.fReadV0;
if (aReader.fUsePhysicsSel)
fSelect = new AliPhysicsSelection();
// fEventFriend = aReader.fEventFriend;
hbtEvent->SetReactionPlaneAngle(ep->GetEventplane("Q"));
}
+ //V0
+ if(fReadV0)
+ {
+ for (Int_t i = 0; i < fEvent->GetNumberOfV0s(); i++) {
+ AliESDv0* esdv0 = fEvent->GetV0(i);
+ if (!esdv0) continue;
+ //if(esdv0->GetNDaughters()>2) continue;
+ //if(esdv0->GetNProngs()>2) continue;
+ if(esdv0->Charge()!=0) continue;
+ AliESDtrack *trackPos = fEvent->GetTrack(esdv0->GetPindex());
+ if(!trackPos) continue;
+ AliESDtrack *trackNeg = fEvent->GetTrack(esdv0->GetNindex());
+ if(!trackNeg) continue;
+ if(trackPos->Charge()==trackNeg->Charge()) continue;
+ AliFemtoV0* trackCopyV0 = new AliFemtoV0();
+ CopyESDtoFemtoV0(esdv0, trackCopyV0, fEvent);
+ hbtEvent->V0Collection()->push_back(trackCopyV0);
+ //cout<<"Pushback v0 to v0collection"<<endl;
+ }
+ }
+
+
fCurEvent++;
if (Debug()>1) cout<<"end of reading nt "<<nofTracks<<" real number "<<realnofTracks<<endl;
return d;
}
+
+
+
+void AliFemtoEventReaderESDChain::CopyESDtoFemtoV0(AliESDv0 *tESDv0, AliFemtoV0 *tFemtoV0, AliESDEvent *tESDevent)
+{
+ AliESDtrack *pTrack = tESDevent->GetTrack(tESDv0->GetPindex());
+ AliESDtrack *nTrack = tESDevent->GetTrack(tESDv0->GetNindex());
+
+ //tFemtoV0->SetdecayLengthV0(tESDv0->DecayLengthV0()); //wrocic do tego
+ //tFemtoV0->SetdecayVertexV0X(tESDv0->DecayVertexV0X());
+ //tFemtoV0->SetdecayVertexV0Y(tESDv0->DecayVertexV0Y());
+ //tFemtoV0->SetdecayVertexV0Z(tESDv0->DecayVertexV0Z()); //nie ma w AliESDv0
+ //AliFemtoThreeVector decayvertex(tESDv0->DecayVertexV0X(),tESDv0->DecayVertexV0Y(),tESDv0->DecayVertexV0Z());
+ //tFemtoV0->SetdecayVertexV0(decayvertex);
+ tFemtoV0->SetdcaV0Daughters(tESDv0->GetDcaV0Daughters());
+ double fPrimaryVtxPosition[3];
+ tESDevent->GetPrimaryVertex()->GetXYZ(fPrimaryVtxPosition);
+ tFemtoV0->SetdcaV0ToPrimVertex(tESDv0->GetD(fPrimaryVtxPosition[0],fPrimaryVtxPosition[1],fPrimaryVtxPosition[2]));
+ tFemtoV0->SetdcaPosToPrimVertex(TMath::Abs(pTrack->GetD(fPrimaryVtxPosition[0],fPrimaryVtxPosition[1],tESDevent->GetMagneticField())));
+ tFemtoV0->SetdcaNegToPrimVertex(TMath::Abs(pTrack->GetD(fPrimaryVtxPosition[0],fPrimaryVtxPosition[1],tESDevent->GetMagneticField())));
+ double MomPos[3];
+ pTrack->PxPyPz(MomPos);
+ tFemtoV0->SetmomPosX(MomPos[0]);
+ tFemtoV0->SetmomPosY(MomPos[1]);
+ tFemtoV0->SetmomPosZ(MomPos[2]);
+ AliFemtoThreeVector mompos(MomPos[0],MomPos[1],MomPos[2]);
+ tFemtoV0->SetmomPos(mompos);
+ double MomNeg[3];
+ nTrack->PxPyPz(MomNeg);
+ tFemtoV0->SetmomNegX(MomNeg[0]);
+ tFemtoV0->SetmomNegY(MomNeg[1]);
+ tFemtoV0->SetmomNegZ(MomNeg[2]);
+ AliFemtoThreeVector momneg(MomNeg[0],MomNeg[1],MomNeg[2]);
+ tFemtoV0->SetmomNeg(momneg);
+
+ //jest cos takiego w AliFemtoV0.h czego nie ma w AliAODv0.h
+ //void SettpcHitsPos(const int& i);
+ //void SettpcHitsNeg(const int& i);
+
+ //void SetTrackTopologyMapPos(unsigned int word, const unsigned long& m);
+ //void SetTrackTopologyMapNeg(unsigned int word, const unsigned long& m);
+
+ tFemtoV0->SetmomV0X(tESDv0->Px());
+ tFemtoV0->SetmomV0Y(tESDv0->Py());
+ tFemtoV0->SetmomV0Z(tESDv0->Pz());
+ AliFemtoThreeVector momv0(tESDv0->Px(),tESDv0->Py(),tESDv0->Pz());
+ tFemtoV0->SetmomV0(momv0);
+ tFemtoV0->SetalphaV0(tESDv0->AlphaV0());
+ tFemtoV0->SetptArmV0(tESDv0->PtArmV0());
+ //tFemtoV0->SeteLambda(tESDv0->ELambda());
+ //tFemtoV0->SeteK0Short(tESDv0->EK0Short());
+ //tFemtoV0->SetePosProton(tESDv0->EPosProton());
+ //tFemtoV0->SeteNegProton(tESDv0->ENegProton());
+ tFemtoV0->SetmassLambda(tESDv0->GetEffMass(4,2));
+ tFemtoV0->SetmassAntiLambda(tESDv0->GetEffMass(2,4));
+ tFemtoV0->SetmassK0Short(tESDv0->GetEffMass(2,2));
+ //tFemtoV0->SetrapLambda(tESDv0->RapLambda());
+ //tFemtoV0->SetrapK0Short(tESDv0->RapK0Short());
+
+ //void SetcTauLambda( float x);
+ //void SetcTauK0Short( float x);
+
+ tFemtoV0->SetptV0(tESDv0->Pt());
+ tFemtoV0->SetptotV0(tESDv0->P());
+ tFemtoV0->SetptPos(pTrack->Pt());
+ tFemtoV0->SetptotPos(pTrack->P());
+ tFemtoV0->SetptNeg(nTrack->Pt());
+ tFemtoV0->SetptotNeg(nTrack->P());
+
+ tFemtoV0->SetidNeg(nTrack->GetID());
+ //cout<<"tESDv0->GetNegID(): "<<tESDv0->GetNegID()<<endl;
+ //cout<<"tFemtoV0->IdNeg(): "<<tFemtoV0->IdNeg()<<endl;
+ tFemtoV0->SetidPos(pTrack->GetID());
+
+ tFemtoV0->SetEtaV0(tESDv0->Eta());
+ tFemtoV0->SetPhiV0(tESDv0->Phi());
+ tFemtoV0->SetCosPointingAngle(tESDv0->GetV0CosineOfPointingAngle(fPrimaryVtxPosition[0],fPrimaryVtxPosition[1], fPrimaryVtxPosition[2]));
+ //tFemtoV0->SetYV0(tESDv0->Y());
+
+ //void SetdedxNeg(float x);
+ //void SeterrdedxNeg(float x);//Gael 04Fev2002
+ //void SetlendedxNeg(float x);//Gael 04Fev2002
+ //void SetdedxPos(float x);
+ //void SeterrdedxPos(float x);//Gael 04Fev2002
+ //void SetlendedxPos(float x);//Gael 04Fev2002
+
+ tFemtoV0->SetEtaPos(pTrack->Eta());
+ tFemtoV0->SetEtaNeg(nTrack->Eta());
+
+ //AliAODTrack *trackpos = (AliAODTrack*)tESDv0->GetDaughter(0);
+ //AliAODTrack *trackneg = (AliAODTrack*)tESDv0->GetDaughter(1);
+
+ if(pTrack && nTrack)
+ {
+ tFemtoV0->SetEtaPos(pTrack->Eta()); //tESDv0->PseudoRapPos()
+ tFemtoV0->SetEtaNeg(nTrack->Eta()); //tESDv0->PseudoRapNeg()
+ tFemtoV0->SetTPCNclsPos(pTrack->GetTPCNcls());
+ tFemtoV0->SetTPCNclsNeg(nTrack->GetTPCNcls());
+ tFemtoV0->SetTPCclustersPos(pTrack->GetTPCClusterMap());
+ tFemtoV0->SetTPCclustersNeg(nTrack->GetTPCClusterMap());
+ tFemtoV0->SetTPCsharingPos(pTrack->GetTPCSharedMap());
+ tFemtoV0->SetTPCsharingNeg(nTrack->GetTPCSharedMap());
+ tFemtoV0->SetNdofPos(pTrack->GetTPCchi2()/pTrack->GetTPCNcls());
+ tFemtoV0->SetNdofNeg(nTrack->GetTPCchi2()/nTrack->GetTPCNcls());
+ tFemtoV0->SetStatusPos(pTrack->GetStatus());
+ tFemtoV0->SetStatusNeg(nTrack->GetStatus());
+
+ tFemtoV0->SetPosNSigmaTPCK(fESDpid->NumberOfSigmasTPC(pTrack,AliPID::kKaon));
+ tFemtoV0->SetNegNSigmaTPCK(fESDpid->NumberOfSigmasTPC(nTrack,AliPID::kKaon));
+ tFemtoV0->SetPosNSigmaTPCP(fESDpid->NumberOfSigmasTPC(pTrack,AliPID::kProton));
+ tFemtoV0->SetNegNSigmaTPCP(fESDpid->NumberOfSigmasTPC(nTrack,AliPID::kProton));
+ tFemtoV0->SetPosNSigmaTPCPi(fESDpid->NumberOfSigmasTPC(pTrack,AliPID::kPion));
+ tFemtoV0->SetNegNSigmaTPCPi(fESDpid->NumberOfSigmasTPC(nTrack,AliPID::kPion));
+
+
+ if((tFemtoV0->StatusPos()&AliESDtrack::kTOFpid)==0 || (tFemtoV0->StatusPos()&AliESDtrack::kTIME)==0 || (tFemtoV0->StatusPos()&AliESDtrack::kTOFout)==0 || (tFemtoV0->StatusPos()&AliESDtrack::kTOFmismatch)>0)
+ {
+ if((tFemtoV0->StatusNeg()&AliESDtrack::kTOFpid)==0 || (tFemtoV0->StatusNeg()&AliESDtrack::kTIME)==0 || (tFemtoV0->StatusNeg()&AliESDtrack::kTOFout)==0 || (tFemtoV0->StatusNeg()&AliESDtrack::kTOFmismatch)>0)
+ {
+ tFemtoV0->SetPosNSigmaTOFK(-9999);
+ tFemtoV0->SetNegNSigmaTOFK(-9999);
+ tFemtoV0->SetPosNSigmaTOFP(-9999);
+ tFemtoV0->SetNegNSigmaTOFP(-9999);
+ tFemtoV0->SetPosNSigmaTOFPi(-9999);
+ tFemtoV0->SetNegNSigmaTOFPi(-9999);
+ }
+ }
+ else
+ {
+ tFemtoV0->SetPosNSigmaTOFK(fESDpid->NumberOfSigmasTOF(pTrack,AliPID::kKaon));
+ tFemtoV0->SetNegNSigmaTOFK(fESDpid->NumberOfSigmasTOF(nTrack,AliPID::kKaon));
+ tFemtoV0->SetPosNSigmaTOFP(fESDpid->NumberOfSigmasTOF(pTrack,AliPID::kProton));
+ tFemtoV0->SetNegNSigmaTOFP(fESDpid->NumberOfSigmasTOF(nTrack,AliPID::kProton));
+ tFemtoV0->SetPosNSigmaTOFPi(fESDpid->NumberOfSigmasTOF(pTrack,AliPID::kPion));
+ tFemtoV0->SetNegNSigmaTOFPi(fESDpid->NumberOfSigmasTOF(nTrack,AliPID::kPion));
+ }
+ }
+ else
+ {
+ tFemtoV0->SetStatusPos(999);
+ tFemtoV0->SetStatusNeg(999);
+ }
+ tFemtoV0->SetOnFlyStatusV0(tESDv0->GetOnFlyStatus());
+}
+
+
+
+
void AliFemtoEventReaderESDChain::SetReadTrackType(ReadTrackType aType)
{
fTrackType = aType;
fEventTrig = eventtrig;
}
+//V0 reading
+void AliFemtoEventReaderESDChain::SetReadV0(bool a)
+{
+ fReadV0 = a;
+}
#include "AliFemtoEventReader.h"
#include "AliFemtoEnumeration.h"
+#include "AliFemtoV0.h"
+#include "AliESDv0.h"
#include <string>
#include <vector>
void SetReadTPCInner(const bool readinner);
void SetUseTPCOnly(const bool usetpconly);
+ virtual void CopyESDtoFemtoV0(AliESDv0 *tESDv0, AliFemtoV0 *tFemtoV0, AliESDEvent *fESDevent);
+ void SetReadV0(bool a);
+
void SetUsePhysicsSelection(const bool usephysics);
void SetUseMultiplicity(EstEventMult aType);
void SetEventTrigger(UInt_t eventtrig); //trigger
EstEventMult fEstEventMult; // Type of the event multiplicity estimator
UInt_t fEventTrig; //event trigger
+
/* list<Int_t> **fSharedList; //! Table (one list per padrow) of clusters which are shared */
/* list<Int_t> **fClusterPerPadrow; //! Table (one list per padrow) of clusters in each padrow */
AliESDpid *fESDpid;
Bool_t fIsPidOwner;
+ bool fReadV0; // Read V0 information from the AOD and put it into V0Collection
#ifdef __ROOT__
ClassDef(AliFemtoEventReaderESDChain, 1)
int tNormMult = 0;
for (int i=0;i<nofTracks;i++)
{
-
//take only primaries
if(!fStack->IsPhysicalPrimary(i)) {continue;}
AliFemtoThreeVector v(pxyz[0],pxyz[1],pxyz[2]);
if (v.Mag() < 0.0001) {
- // cout << "Found 0 momentum ???? " << pxyz[0] << " " << pxyz[1] << " " << pxyz[2] << endl;
+ //cout << "Found 0 momentum ???? " << pxyz[0] << " " << pxyz[1] << " " << pxyz[2] << endl;
delete trackCopy;
continue;
}
const AliFmThreeVectorD kOrigin(fV1[0],fV1[1],fV1[2]);
//label
- trackCopy->SetLabel(i);
+ trackCopy->SetLabel(i);
hbtEvent->TrackCollection()->push_back(trackCopy);//adding track to analysis
-
+ //cout<<"Track added: "<<i<<endl;
}
hbtEvent->SetNormalizedMult(tNormMult);
fCurEvent++;
+
+ //V0 analysis code - no V0 finder for Kinematics, we can only check if it is primary and if it has at least 2 daughters.
+
+ for (int i=0;i<nofTracks;i++)
+ {
+ //do not take primaries
+ if(!fStack->IsPhysicalPrimary(i)) {continue;}
+ //getting next track
+ TParticle *kinetrack= fStack->Particle(i);
+ if (!kinetrack) continue;
+
+ if(kinetrack->GetPDG()->Charge()!=0) continue; //charge - neutral
+ //if(kinetrack->GetPDG()->Stable()==1) continue; //particle is not stable
+ if(kinetrack->GetDaughter(0)<1) continue; //has 1'st daughter
+ if(kinetrack->GetDaughter(1)<1) continue; //has 2'nd daughter
+
+ //we want one positive, one negative particle. Or two neutral.
+ // if((fStack->Particle(kinetrack->GetDaughter(0)))->GetPDG()->Charge()>=0)
+ // if((fStack->Particle(kinetrack->GetDaughter(1)))->GetPDG()->Charge()>0)
+ // continue;
+ // if((fStack->Particle(kinetrack->GetDaughter(0)))->GetPDG()->Charge()<=0)
+ // if((fStack->Particle(kinetrack->GetDaughter(0)))->GetPDG()->Charge()<0)
+ // continue;
+
+ if(kinetrack->Pt()<0.00001)
+ continue;
+
+ AliFemtoV0* trackCopyV0 = new AliFemtoV0();
+ CopyAODtoFemtoV0(kinetrack, trackCopyV0);
+ hbtEvent->V0Collection()->push_back(trackCopyV0);
+ //cout<<"Pushback v0 to v0collection"<<endl;
+ }
+
+
+ cout<<"Number of tracks: "<<realnofTracks<<endl;
+
return hbtEvent;
}
d = TMath::ErfInverse(1 - TMath::Exp(-d * d / 2)) * TMath::Sqrt(2);
return d;
}
+
+
+
+ void AliFemtoEventReaderKinematicsChain::CopyAODtoFemtoV0(TParticle *tv0, AliFemtoV0 *tFemtoV0 )
+{
+ tFemtoV0->SetEtaV0(tv0->Eta());
+ tFemtoV0->SetEtaV0(tv0->Phi());
+ tFemtoV0->SetptV0(tv0->Pt());
+ tFemtoV0->SetptotV0(tv0->P());
+
+ tFemtoV0->SetmomV0X(tv0->Px());
+ tFemtoV0->SetmomV0Y(tv0->Py());
+ tFemtoV0->SetmomV0Z(tv0->Pz());
+ AliFemtoThreeVector momv0(tv0->Px(),tv0->Py(),tv0->Pz());
+ tFemtoV0->SetmomV0(momv0);
+
+
+ TParticle *trackpos;
+ TParticle *trackneg;
+
+ //daughters
+ if(fStack->Particle(tv0->GetDaughter(0))->GetPDG()->Charge()>=0) //first positive, second negative
+ {
+ trackpos = (TParticle*)(fStack->Particle(tv0->GetDaughter(0)));
+ trackneg = (TParticle*)(fStack->Particle(tv0->GetDaughter(1)));
+ tFemtoV0->SetidPos(tv0->GetDaughter(0));
+ tFemtoV0->SetidNeg(tv0->GetDaughter(1));
+ }
+ else //first negative, second positive
+ {
+ trackpos = (TParticle*)(fStack->Particle(tv0->GetDaughter(1)));
+ trackneg = (TParticle*)(fStack->Particle(tv0->GetDaughter(0)));
+ tFemtoV0->SetidPos(tv0->GetDaughter(1));
+ tFemtoV0->SetidNeg(tv0->GetDaughter(0));
+ }
+
+ tFemtoV0->SetEtaPos(trackpos->Eta());
+ tFemtoV0->SetEtaNeg(trackneg->Eta());
+
+ tFemtoV0->SetptPos(trackpos->Pt());
+ tFemtoV0->SetptNeg(trackneg->Pt());
+
+ tFemtoV0->SetptotPos(trackpos->P());
+ tFemtoV0->SetptotNeg(trackneg->P());
+
+ tFemtoV0->SetmomPosX(trackpos->Px());
+ tFemtoV0->SetmomPosY(trackpos->Py());
+ tFemtoV0->SetmomPosZ(trackpos->Pz());
+ AliFemtoThreeVector mompos(trackpos->Px(),trackpos->Py(),trackpos->Pz());
+ tFemtoV0->SetmomPos(mompos);
+
+ tFemtoV0->SetmomNegX(trackneg->Px());
+ tFemtoV0->SetmomNegY(trackneg->Py());
+ tFemtoV0->SetmomNegZ(trackneg->Pz());
+ AliFemtoThreeVector momneg(trackneg->Px(),trackneg->Py(),trackneg->Pz());
+ tFemtoV0->SetmomNeg(momneg);
+
+
+ tFemtoV0->SetmassLambda(tv0->GetMass());
+ tFemtoV0->SetmassAntiLambda(tv0->GetMass());
+ tFemtoV0->SetmassK0Short(tv0->GetMass());
+
+ tFemtoV0->SetYV0(tv0->Y());
+
+ tFemtoV0->SetdecayVertexV0X(trackpos->Vx()); //vertex of the decay is set as the vertex of creation of daughters
+ tFemtoV0->SetdecayVertexV0Y(trackpos->Vy());
+ tFemtoV0->SetdecayVertexV0Z(trackpos->Vz());
+ AliFemtoThreeVector decayvertex(trackpos->Vx(),trackpos->Vy(),trackpos->Vz());
+ tFemtoV0->SetdecayVertexV0(decayvertex);
+
+ tFemtoV0->SetdcaV0Daughters(0);
+ tFemtoV0->SetCosPointingAngle(1);
+
+
+ tFemtoV0->SetStatusPos(1);
+ tFemtoV0->SetStatusNeg(1);
+
+
+ if(trackpos->GetPdgCode()==2212) //proton
+ {
+ tFemtoV0->SetPosNSigmaTPCK(1000);
+ tFemtoV0->SetPosNSigmaTPCPi(1000);
+ tFemtoV0->SetPosNSigmaTPCP(0);
+ }
+ if(trackneg->GetPdgCode()==-2212) //antiproton
+ {
+ tFemtoV0->SetNegNSigmaTPCK(1000);
+ tFemtoV0->SetNegNSigmaTPCPi(1000);
+ tFemtoV0->SetNegNSigmaTPCP(0);
+ }
+ if(trackpos->GetPdgCode()==211) //pion plus
+ {
+ tFemtoV0->SetPosNSigmaTPCK(1000);
+ tFemtoV0->SetPosNSigmaTPCPi(0);
+ tFemtoV0->SetPosNSigmaTPCP(1000);
+ }
+ if(trackneg->GetPdgCode()==-211) //pion minus
+ {
+ tFemtoV0->SetNegNSigmaTPCK(1000);
+ tFemtoV0->SetNegNSigmaTPCPi(0);
+ tFemtoV0->SetNegNSigmaTPCP(1000);
+ }
+ if(trackpos->GetPdgCode()==321) //K+
+ {
+ tFemtoV0->SetPosNSigmaTPCK(0);
+ tFemtoV0->SetPosNSigmaTPCPi(1000);
+ tFemtoV0->SetPosNSigmaTPCP(1000);
+ }
+ if(trackneg->GetPdgCode()==-321) //K-
+ {
+ tFemtoV0->SetNegNSigmaTPCK(0);
+ tFemtoV0->SetNegNSigmaTPCPi(1000);
+ tFemtoV0->SetNegNSigmaTPCP(1000);
+ }
+
+
+}
#include "AliFemtoEventReader.h"
#include "AliFemtoEnumeration.h"
+#include "AliFemtoV0.h"
#include <string>
#include <vector>
void SetStackSource(AliStack *aStack);
void SetGenEventHeader(AliGenEventHeader *aGenHeader);
void SetRotateToEventPlane(short dorotate);
+ void CopyAODtoFemtoV0(TParticle *tv0, AliFemtoV0 *tFemtoV0 );
protected:
double pz1 = fTrack1->FourMomentum().vect().z();
double pE1 = fTrack1->FourMomentum().e();
double tParticle1Mass = ::sqrt(pE1*pE1 - px1*px1 - py1*py1 - pz1*pz1);
+
double px2 = fTrack2->FourMomentum().vect().x();
double py2 = fTrack2->FourMomentum().vect().y();
double pz2 = fTrack2->FourMomentum().vect().z();
unsigned long TopologyMap(const int word) const;
int NumberOfHits() const;
- unsigned long TrackId() const; // only for particles from tracks
- unsigned short NegTrackId() const; // only for particles from v0
- unsigned short PosTrackId() const; // only for particles from v0
+ int TrackId() const; // only for particles from tracks
+ int NegTrackId() const; // only for particles from v0
+ int PosTrackId() const; // only for particles from v0
AliFemtoTrack* Track() const;
AliFemtoV0* V0() const;
};
inline AliFemtoTrack* AliFemtoParticle::Track() const { return fTrack; }
-inline unsigned long AliFemtoParticle::TrackId() const { return fTrack->TrackId(); }
+inline int AliFemtoParticle::TrackId() const { return fTrack->TrackId(); }
inline const AliFemtoLorentzVector& AliFemtoParticle::FourMomentum() const {return fFourMomentum;}
inline AliFmPhysicalHelixD& AliFemtoParticle::Helix() {return fHelix;}
//inline unsigned long AliFemtoParticle::TopologyMap(const int word) const {return fMap[word];}
inline int AliFemtoParticle::NumberOfHits() const {return 1;}
inline AliFemtoV0* AliFemtoParticle::V0() const { return fV0; }
-inline unsigned short AliFemtoParticle::NegTrackId() const { return fV0->IdNeg(); }
-inline unsigned short AliFemtoParticle::PosTrackId() const { return fV0->IdPos(); }
+inline int AliFemtoParticle::NegTrackId() const { return fV0->IdNeg(); }
+inline int AliFemtoParticle::PosTrackId() const { return fV0->IdPos(); }
inline const AliFemtoThreeVector AliFemtoParticle::DecayVertexPosition() const {return fV0->DecayVertexV0(); }
// ***
inline AliFemtoHiddenInfo* AliFemtoParticle::GetHiddenInfo() const
}
}
pCut->FillCutMonitor(hbtEvent,partCollection);// Gael 19/06/02
+
break;
}
case hbtKink: // cut is cutting on Kinks -- mal 25May2001
cout << "#particles in Collection 1, 2: " <<
fPicoEvent->FirstParticleCollection()->size() << " " <<
fPicoEvent->SecondParticleCollection()->size() << endl;
+
+ fEventCut->FillCutMonitor(fPicoEvent->FirstParticleCollection(),fPicoEvent->SecondParticleCollection()); //MJ!
+
// mal - implement a switch which allows only using events with ParticleCollections containing a minimum
// number of entries (jun2002)
fShared(159),
fNominalTpcEntrancePoint(0,0,0),
fNominalTpcExitPoint(0,0,0),
+ fXatDCA(0),
+ fYatDCA(0),
+ fZatDCA(0),
fHiddenInfo(0)
{
// Default constructor
fShared(159),
fNominalTpcEntrancePoint(0,0,0),
fNominalTpcExitPoint(0,0,0),
+ fXatDCA(0),
+ fYatDCA(0),
+ fZatDCA(0),
fHiddenInfo(0)
{
// copy constructor
fKinkIndexes[0] = t.fKinkIndexes[0];
fKinkIndexes[1] = t.fKinkIndexes[1];
fKinkIndexes[2] = t.fKinkIndexes[2];
+
+ fXatDCA=t.fXatDCA;
+ fYatDCA=t.fYatDCA;
+ fZatDCA=t.fZatDCA;
+
// cout << "Created track " << this << endl;
}
fKinkIndexes[0] = aTrack.fKinkIndexes[0];
fKinkIndexes[1] = aTrack.fKinkIndexes[1];
fKinkIndexes[2] = aTrack.fKinkIndexes[2];
+
+ fXatDCA=aTrack.fXatDCA;
+ fYatDCA=aTrack.fYatDCA;
+ fZatDCA=aTrack.fZatDCA;
+
if (ValidHiddenInfo())
delete fHiddenInfo;
if (aTrack.ValidHiddenInfo())
void AliFemtoTrack::SetP(const AliFemtoThreeVector& p){fP = p;}
void AliFemtoTrack::SetPt(const float& pt){fPt = pt;}
void AliFemtoTrack::SetHelix(const AliFmPhysicalHelixD& h){fHelix = h;}
-void AliFemtoTrack::SetTrackId(const short & id) { fTrackId=id;}
+void AliFemtoTrack::SetTrackId(const int & id) { fTrackId=id;}
void AliFemtoTrack::SetFlags(const long int &flags) {fFlags=flags;}
void AliFemtoTrack::SetLabel(const int &label) {fLabel=label;}
void AliFemtoTrack::SetImpactD(const float& aImpactD){fImpactD=aImpactD;}
void AliFemtoTrack::SetNSigmaTOFP(const float& aNSigmaTOFP){fNSigmaTOFP=aNSigmaTOFP;}
void AliFemtoTrack::SetSigmaToVertex(const float& aSigma){fSigmaToVertex=aSigma;}
+void AliFemtoTrack::SetXatDCA(const double& x) {fXatDCA=x;}
+void AliFemtoTrack::SetYatDCA(const double& x) {fYatDCA=x;}
+void AliFemtoTrack::SetZatDCA(const double& x) {fZatDCA=x;}
+
short AliFemtoTrack::Charge() const {return fCharge;}
AliFemtoThreeVector AliFemtoTrack::P() const {return fP;}
float AliFemtoTrack::Pt() const {return fPt;}
const AliFmPhysicalHelixD& AliFemtoTrack::Helix() const {return fHelix;}
-short AliFemtoTrack::TrackId() const { return fTrackId; }
+int AliFemtoTrack::TrackId() const { return fTrackId; }
long int AliFemtoTrack::Flags() const {return fFlags;}
int AliFemtoTrack::Label()const {return fLabel;}
float AliFemtoTrack::ImpactD()const{return fImpactD;}
float AliFemtoTrack::TOFkaonTime() const{return fTofKaonTime;}
float AliFemtoTrack::TOFprotonTime() const{return fTofProtonTime;}
+double AliFemtoTrack::XatDCA() const {return fXatDCA;}
+double AliFemtoTrack::YatDCA() const {return fYatDCA;}
+double AliFemtoTrack::ZatDCA() const {return fZatDCA;}
void AliFemtoTrack::SetHiddenInfo(AliFemtoHiddenInfo* aHiddenInfo) {fHiddenInfo=aHiddenInfo;}
bool AliFemtoTrack::ValidHiddenInfo() const { if (fHiddenInfo) return true; else return false; }
AliFemtoThreeVector P() const;
float Pt() const;
const AliFmPhysicalHelixD& Helix() const;
- short TrackId() const;
+ int TrackId() const;
long int Flags() const;
int Label()const;
float ImpactD()const;
float TOFkaonTime() const;
float TOFprotonTime() const;
+ double XatDCA() const;
+ double YatDCA() const;
+ double ZatDCA() const;
+
const TBits& TPCclusters() const;
const TBits& TPCsharing() const;
void SetP(const AliFemtoThreeVector& p);
void SetPt(const float& x);
void SetHelix(const AliFmPhysicalHelixD& h);
- void SetTrackId(const short& s);
+ void SetTrackId(const int& s);
void SetFlags(const long int& i);
void SetLabel(const int& i);
void SetImpactD(const float& x);
void SetNominalTPCExitPoint(double *aXTPC);
void SetSigmaToVertex(const float& Sigma);
float SigmaToVertex() const;
+
+ void SetXatDCA(const double& x);
+ void SetYatDCA(const double& x);
+ void SetZatDCA(const double& x);
//Alice stuff
enum {
float fPidProbKaon; // kaon pid
float fPidProbProton; // proton pid
float fPidProbMuon; // muon pid
- unsigned int fTrackId; // track unique id
+ int fTrackId; // track unique id
float fTofPionTime; // TOF time - pion expected time
float fTofKaonTime; // TOF time - kaon expected time
float fTofProtonTime; // TOF time - proton expected time
AliFemtoThreeVector fNominalTpcEntrancePoint; // Nominal track entrance point into TPC
AliFemtoThreeVector fNominalTpcExitPoint; // Nominal track exit point from TPC
+
+
int fKinkIndexes[3]; // Kink Index list
+
+ double fXatDCA;
+ double fYatDCA;
+ double fZatDCA;
/* Th stuff */
// Fab private : add mutable
// mutable
fDcaV0Daughters(0), fDcaV0ToPrimVertex(0),
fDcaPosToPrimVertex(0), fDcaNegToPrimVertex(0),
fMomPos(0), fMomNeg(0),
- fTpcHitsPos(0), fTpcHitsNeg(0),
- fChi2V0(0), fClV0(0), fChi2Pos(0), fClPos(0), fChi2Neg(0), fClNeg(0),
+ fTpcHitsPos(0), fTpcHitsNeg(0), fOnFlyStatusV0(0),
+ fChi2V0(0), fClV0(0), fChi2Pos(0), fClPos(0), fChi2Neg(0), fClNeg(0), fCosPointingAngle(0),
fDedxPos(0), fErrDedxPos(0), fLenDedxPos(0),
fDedxNeg(0), fErrDedxNeg(0), fLenDedxNeg(0),
fNufDedxPos(0), fNufDedxNeg(0),
fHelixPos(), fHelixNeg(),
- fMomV0(0),
+ fMomV0(0), fEtaV0(0), fPhiV0(0), fYV0(0),
fAlphaV0(0), fPtArmV0(0),
fELambda(0), fEK0Short(0),
fEPosProton(0), fEPosPion(0),
fCTauK0Short(0), fPtV0(0), fPtotV0(0),
fPtPos(0), fPtotPos(0),
fPtNeg(0), fPtotNeg(0),
+ fEtaPos(0), fEtaNeg(0), fTPCNclsPos(0), fTPCNclsNeg(0), fClustersPos(0), fClustersNeg(0), fSharingPos(0), fSharingNeg(0), fNdofPos(0), fNdofNeg(0), fStatusPos(0), fStatusNeg(0),
+ fPosNSigmaTPCK(0), fPosNSigmaTPCPi(0), fPosNSigmaTPCP(0), fNegNSigmaTPCK(0), fNegNSigmaTPCPi(0), fNegNSigmaTPCP(0),
+ fPosNSigmaTOFK(0), fPosNSigmaTOFPi(0), fPosNSigmaTOFP(0), fNegNSigmaTOFK(0), fNegNSigmaTOFPi(0), fNegNSigmaTOFP(0),
fKeyNeg(0), fKeyPos(0),
+ fNominalTpcEntrancePointPos(0,0,0),fNominalTpcExitPointPos(0,0,0),
+ fNominalTpcEntrancePointNeg(0,0,0),fNominalTpcExitPointNeg(0,0,0),
fHiddenInfo(0) /***/
{
// Default empty constructor
fTrackTopologyMapPos[1] = 0;
fTrackTopologyMapNeg[0] = 0;
fTrackTopologyMapNeg[1] = 0;
-
}
// -----------------------------------------------------------------------
AliFemtoV0::AliFemtoV0(const AliFemtoV0& v) :
fDcaV0Daughters(0), fDcaV0ToPrimVertex(0),
fDcaPosToPrimVertex(0), fDcaNegToPrimVertex(0),
fMomPos(0), fMomNeg(0),
- fTpcHitsPos(0), fTpcHitsNeg(0),
- fChi2V0(0), fClV0(0), fChi2Pos(0), fClPos(0), fChi2Neg(0), fClNeg(0),
+ fTpcHitsPos(0), fTpcHitsNeg(0), fOnFlyStatusV0(0),
+ fChi2V0(0), fClV0(0), fChi2Pos(0), fClPos(0), fChi2Neg(0), fClNeg(0), fCosPointingAngle(0),
fDedxPos(0), fErrDedxPos(0), fLenDedxPos(0),
fDedxNeg(0), fErrDedxNeg(0), fLenDedxNeg(0),
fNufDedxPos(0), fNufDedxNeg(0),
fHelixPos(), fHelixNeg(),
- fMomV0(0),
+ fMomV0(0), fEtaV0(0), fPhiV0(0), fYV0(0),
fAlphaV0(0), fPtArmV0(0),
fELambda(0), fEK0Short(0),
fEPosProton(0), fEPosPion(0),
fCTauK0Short(0), fPtV0(0), fPtotV0(0),
fPtPos(0), fPtotPos(0),
fPtNeg(0), fPtotNeg(0),
+ fEtaPos(0), fEtaNeg(0), fTPCNclsPos(0), fTPCNclsNeg(0), fClustersPos(0), fClustersNeg(0), fSharingPos(0), fSharingNeg(0), fNdofPos(0), fNdofNeg(0), fStatusPos(0), fStatusNeg(0),
+ fPosNSigmaTPCK(0), fPosNSigmaTPCPi(0), fPosNSigmaTPCP(0), fNegNSigmaTPCK(0), fNegNSigmaTPCPi(0), fNegNSigmaTPCP(0),
+ fPosNSigmaTOFK(0), fPosNSigmaTOFPi(0), fPosNSigmaTOFP(0), fNegNSigmaTOFK(0), fNegNSigmaTOFPi(0), fNegNSigmaTOFP(0),
fKeyNeg(0), fKeyPos(0),
+ fNominalTpcEntrancePointPos(0,0,0),fNominalTpcExitPointPos(0,0,0),
+ fNominalTpcEntrancePointNeg(0,0,0),fNominalTpcExitPointNeg(0,0,0),
fHiddenInfo(0) /***/
{
// copy constructor
fMomPos = v.fMomPos;
fMomNeg = v.fMomNeg;
+ fEtaV0 = v.fEtaV0;
+ fPhiV0 = v.fPhiV0;
+ fYV0 = v.fYV0;
+ fCosPointingAngle = v.fCosPointingAngle;
+
fTrackTopologyMapPos[0] = v.fTrackTopologyMapPos[0];
fTrackTopologyMapPos[1] = v.fTrackTopologyMapPos[1];
fTrackTopologyMapNeg[0] = v.fTrackTopologyMapNeg[0];
fKeyPos = v.fKeyPos;
fKeyNeg = v.fKeyNeg;
-
+ fEtaPos = v.fEtaPos;
+ fEtaNeg = v.fEtaNeg;
+ fTPCNclsPos = v.fTPCNclsPos;
+ fTPCNclsNeg = v.fTPCNclsNeg;
+ fClustersPos = v.fClustersPos;
+ fClustersNeg = v.fClustersNeg;
+ fSharingPos = v.fSharingPos;
+ fSharingNeg = v.fSharingNeg;
+ fNdofPos = v.fNdofPos;
+ fNdofNeg = v.fNdofNeg;
+ fStatusPos = v.fStatusPos;
+ fStatusNeg = v.fStatusNeg;
+ fOnFlyStatusV0 = v.fOnFlyStatusV0;
+
+ fPosNSigmaTPCK = v.fPosNSigmaTPCK;
+ fPosNSigmaTPCPi = v.fPosNSigmaTPCPi ;
+ fPosNSigmaTPCP = v.fPosNSigmaTPCP ;
+ fNegNSigmaTPCK = v.fNegNSigmaTPCK ;
+ fNegNSigmaTPCPi = v.fNegNSigmaTPCPi ;
+ fNegNSigmaTPCP = v.fNegNSigmaTPCP ;
+ fPosNSigmaTOFK = v.fPosNSigmaTOFK ;
+ fPosNSigmaTOFPi = v.fPosNSigmaTOFPi ;
+ fPosNSigmaTOFP = v.fPosNSigmaTOFP ;
+ fNegNSigmaTOFK = v.fNegNSigmaTOFK ;
+ fNegNSigmaTOFPi = v.fNegNSigmaTOFPi ;
+ fNegNSigmaTOFP = v.fNegNSigmaTOFP ;
+
+
fTpcHitsPos = v.fTpcHitsPos;
fTpcHitsNeg = v.fTpcHitsNeg;
fHelixPos = v.fHelixPos;// Gael 12 Sept
fHelixNeg = v.fHelixNeg;// Gael 12 Sept
+
+ fNominalTpcEntrancePointPos = v.fNominalTpcEntrancePointPos;
+ fNominalTpcExitPointPos = v.fNominalTpcExitPointPos;
+ fNominalTpcEntrancePointNeg = v.fNominalTpcEntrancePointNeg;
+ fNominalTpcExitPointNeg = v.fNominalTpcExitPointNeg;
+
fHiddenInfo = v.fHiddenInfo? v.fHiddenInfo->Clone() : 0;// GR 11 DEC 02
UpdateV0();
}
fKeyPos = aV0.fKeyPos;
fKeyNeg = aV0.fKeyNeg;
+
+ fEtaPos = aV0.fEtaPos;
+ fEtaNeg = aV0.fEtaNeg;
+ fTPCNclsPos = aV0.fTPCNclsPos;
+ fTPCNclsNeg = aV0.fTPCNclsNeg;
+ fClustersPos = aV0.fClustersPos;
+ fClustersNeg = aV0.fClustersNeg;
+ fSharingPos = aV0.fSharingPos;
+ fSharingNeg = aV0.fSharingNeg;
+ fNdofPos = aV0.fNdofPos;
+ fNdofNeg = aV0.fNdofNeg;
+ fStatusPos = aV0.fStatusPos;
+ fStatusNeg = aV0.fStatusNeg;
+ fOnFlyStatusV0 = aV0.fOnFlyStatusV0;
+
+ fPosNSigmaTPCK = aV0.fPosNSigmaTPCK;
+ fPosNSigmaTPCPi = aV0.fPosNSigmaTPCPi ;
+ fPosNSigmaTPCP = aV0.fPosNSigmaTPCP ;
+ fNegNSigmaTPCK = aV0.fNegNSigmaTPCK ;
+ fNegNSigmaTPCPi = aV0.fNegNSigmaTPCPi ;
+ fNegNSigmaTPCP = aV0.fNegNSigmaTPCP ;
+ fPosNSigmaTOFK = aV0.fPosNSigmaTOFK ;
+ fPosNSigmaTOFPi = aV0.fPosNSigmaTOFPi ;
+ fPosNSigmaTOFP = aV0.fPosNSigmaTOFP ;
+ fNegNSigmaTOFK = aV0.fNegNSigmaTOFK ;
+ fNegNSigmaTOFPi = aV0.fNegNSigmaTOFPi ;
+ fNegNSigmaTOFP = aV0.fNegNSigmaTOFP ;
+
+ fEtaV0 = aV0.fEtaV0;
+ fPhiV0 = aV0.fPhiV0;
+ fYV0 = aV0.fYV0;
+ fCosPointingAngle = aV0.fCosPointingAngle;
fTpcHitsPos = aV0.fTpcHitsPos;
fTpcHitsNeg = aV0.fTpcHitsNeg;
fHelixPos = aV0.fHelixPos;// Gael 12 Sept
fHelixNeg = aV0.fHelixNeg;// Gael 12 Sept
+
+ fNominalTpcEntrancePointPos = aV0.fNominalTpcEntrancePointPos;
+ fNominalTpcExitPointPos = aV0.fNominalTpcExitPointPos;
+ fNominalTpcEntrancePointPos = aV0.fNominalTpcEntrancePointPos;
+ fNominalTpcExitPointPos = aV0.fNominalTpcExitPointPos;
+ fNominalTpcEntrancePointNeg = aV0.fNominalTpcEntrancePointNeg;
+ fNominalTpcExitPointNeg = aV0.fNominalTpcExitPointNeg;
+
if (fHiddenInfo) delete fHiddenInfo;
fHiddenInfo = aV0.fHiddenInfo? aV0.fHiddenInfo->Clone() : 0;// GR 11 DEC 02
UpdateV0();
tMomNegAlongV0 = fMomNeg*fMomV0 / ::sqrt(::pow(fPtotV0,2));
tMomPosAlongV0 = fMomPos*fMomV0 / ::sqrt(::pow(fPtotV0,2));
+ if(tMomPosAlongV0+tMomNegAlongV0!=0)
fAlphaV0 = (tMomPosAlongV0-tMomNegAlongV0)/(tMomPosAlongV0+tMomNegAlongV0);
- fPtArmV0 = ::sqrt(fPtotPos*fPtotPos - tMomPosAlongV0*tMomPosAlongV0);
+
+ //printf("%1.15f\n",fPtotPos);
+ //printf("%1.15f\n",tMomPosAlongV0);
+
+ if(fPtotPos<tMomPosAlongV0) fPtArmV0=0; else
+ {
+ fPtArmV0 = ::sqrt(fPtotPos*fPtotPos - tMomPosAlongV0*tMomPosAlongV0);
+ }
fMassLambda = ::sqrt(::pow(fEPosProton+fENegPion,2)-::pow(fPtotV0,2));
fMassAntiLambda = ::sqrt(::pow(fENegProton+fEPosPion,2)-::pow(fPtotV0,2));
fMassK0Short = ::sqrt(::pow(fENegPion+fEPosPion,2)-::pow(fPtotV0,2));
-
fRapLambda = 0.5*::log( (fELambda+fMomV0.z()) / (fELambda-fMomV0.z()) );
+
fCTauLambda = kMLAMBDA*(fDecayLengthV0) / ::sqrt( ::pow((double)fMomV0.Mag(),2.) );
fRapK0Short = 0.5*::log( (fEK0Short+fMomV0.z()) / (fEK0Short-fMomV0.z()) );
#include "AliFemtoTypes.h" //same as in AliFemtoTrack.h
#include "AliFmPhysicalHelixD.h" // Gael 12 Sept 02
+#include "AliFemtoThreeVector.h"
+#include "TBits.h"
#ifdef __ROOT__
#ifndef __NO_STAR_DEPENDENCE_ALLOWED__
#include "StStrangeMuDstMaker/StV0MuDst.h"
float MomNegX() const; // Momentum components of neg. daughter
float MomNegY() const; // Momentum components of neg. daughter
float MomNegZ() const; // Momentum components of neg. daughter
-
+
+ float EtaPos() const;//Pseudorapidity V0
+ float EtaNeg() const; //Pseudorapidity V0
+ int TPCNclsPos() const;
+ int TPCNclsNeg() const;
+ const TBits& TPCclustersPos() const;
+ const TBits& TPCclustersNeg() const;
+ const TBits& TPCsharingPos() const;
+ const TBits& TPCsharingNeg() const;
+ int NdofPos() const;
+ int NdofNeg() const;
+ ulong StatusPos() const;
+ ulong StatusNeg() const;
+
+
int TpcHitsPos() const; // Number of TPC hits on pos. daughter
int TpcHitsNeg() const; // Number of TPC hits on neg. daughter
unsigned long TrackTopologyMapPos(unsigned int word) const;
unsigned long TrackTopologyMapNeg(unsigned int word) const;
- AliFemtoThreeVector MomV0() const ; // Momentum components of V0
+ AliFemtoThreeVector MomV0() const ; // Momentum components of V0
+ double EtaV0() const ;// Pseudorapidity V0
+ double PhiV0() const ;// Phi V0
+
+ double YV0() const;
float MomV0X() const ; // Momentum components of V0
float MomV0Y() const ; // Momentum components of V0
float MomV0Z() const ; // Momentum components of V0
float CTauLambda() const ; // Lifetime (ctau) const assuming (anti) constlambda
float CTauK0Short() const ; // Lifetime (ctau) const assuming k-short
float PtV0() const ; // Transverse momentum
- float PtotV0() const ; // Total momentum
+ float PtotV0() const ; // Total momentum
+ double CosPointingAngle() const;
float PtPos() const ; // Transverse momentum of pos. daughter
float PtotPos() const ; // Total momentum of pos. daughter
float DedxPos() const; // dedx of Positive track
float PseudoRapNeg() const;
// Length of dE/dX track of neg. daughter--Gael04Fev 2002
- unsigned short IdNeg() const; // Id of negative track
- unsigned short IdPos() const; // Id of positive track
- unsigned short KeyNeg() const; // Id of negative track
- unsigned short KeyPos() const; // Id of positive track
+ int IdNeg() const; // Id of negative track
+ int IdPos() const; // Id of positive track
+ int KeyNeg() const; // Id of negative track
+ int KeyPos() const; // Id of positive track
+
+ float PosNSigmaTPCK() const ;
+ float PosNSigmaTPCPi() const ;
+ float PosNSigmaTPCP() const ;
+ float NegNSigmaTPCK() const ;
+ float NegNSigmaTPCPi() const ;
+ float NegNSigmaTPCP() const ;
+
+ float PosNSigmaTOFK() const ;
+ float PosNSigmaTOFPi() const ;
+ float PosNSigmaTOFP() const ;
+ float NegNSigmaTOFK() const ;
+ float NegNSigmaTOFPi() const ;
+ float NegNSigmaTOFP() const ;
+
+
+
+ bool OnFlyStatusV0() const;
const AliFmPhysicalHelixD& HelixPos() const; // Gael 12 Sept 02
- const AliFmPhysicalHelixD& HelixNeg() const; // Gael 12 Sept 02
+ const AliFmPhysicalHelixD& HelixNeg() const; // Gael 12 Sept 02
+
+
+ AliFemtoThreeVector NominalTpcEntrancePointPos() const;
+ AliFemtoThreeVector NominalTpcExitPointPos() const;
+ AliFemtoThreeVector NominalTpcEntrancePointNeg() const;
+ AliFemtoThreeVector NominalTpcExitPointNeg() const;
void UpdateV0(); // Fills derived info
void SetdecayLengthV0(const float x);
void SetmomNegY(const float x);
void SetmomNegZ(const float x);
+ void SetEtaPos(const float x);
+ void SetEtaNeg(const float x);
+ void SetTPCNclsPos(const int x);
+ void SetTPCNclsNeg(const int x);
+ void SetTPCclustersPos(const TBits& x);
+ void SetTPCclustersNeg(const TBits& x);
+ void SetTPCsharingPos(const TBits& x);
+ void SetTPCsharingNeg(const TBits& x);
+ void SetNdofPos(const int x);
+ void SetNdofNeg(const int x);
+ void SetStatusPos(const ulong x);
+ void SetStatusNeg(const ulong x);
+
void SettpcHitsPos(const int& i);
void SettpcHitsNeg(const int& i);
void SetTrackTopologyMapNeg(unsigned int word, const unsigned long& m);
void SetmomV0( AliFemtoThreeVector v);
+ void SetEtaV0 (double x);
+ void SetPhiV0 (double x);
+ void SetYV0(double x);
void SetmomV0X( float x);
void SetmomV0Y( float x);
void SetmomV0Z( float x);
void SetptotPos( float x);
void SetptNeg( float x);
void SetptotNeg( float x);
- void SetidNeg(const unsigned short& i);
- void SetidPos(const unsigned short& i);
+ void SetidNeg(const int& i);
+ void SetidPos(const int& i);
void SetdedxNeg(float x);
void SeterrdedxNeg(float x);//Gael 04Fev2002
void SetlendedxNeg(float x);//Gael 04Fev2002
void SeterrdedxPos(float x);//Gael 04Fev2002
void SetlendedxPos(float x);//Gael 04Fev2002
void SetpseudoRapPos(float x);//Gael 04Fev2002
- void SetkeyNeg(const unsigned short& i);
- void SetkeyPos(const unsigned short& i);
+ void SetkeyNeg(const int& i);
+ void SetkeyPos(const int& i);
+ void SetCosPointingAngle(double x);
+ void SetOnFlyStatusV0(bool x);
void SetHelixPos(const AliFmPhysicalHelixD& h); // Gael 12 Sept 02
void SetHelixNeg(const AliFmPhysicalHelixD& h); // Gael 12 Sept 02
+ void SetPosNSigmaTPCK(float x);
+ void SetPosNSigmaTPCPi(float x);
+ void SetPosNSigmaTPCP(float x);
+ void SetNegNSigmaTPCK(float x);
+ void SetNegNSigmaTPCPi(float x);
+ void SetNegNSigmaTPCP(float x);
+
+ void SetPosNSigmaTOFK(float x);
+ void SetPosNSigmaTOFPi(float x);
+ void SetPosNSigmaTOFP(float x);
+ void SetNegNSigmaTOFK(float x);
+ void SetNegNSigmaTOFPi(float x);
+ void SetNegNSigmaTOFP(float x);
+
+ void SetNominalTpcEntrancePointPos(AliFemtoThreeVector x);
+ void SetNominalTpcExitPointPos(AliFemtoThreeVector x);
+ void SetNominalTpcEntrancePointNeg(AliFemtoThreeVector x);
+ void SetNominalTpcExitPointNeg(AliFemtoThreeVector x);
+
void SetprimaryVertex(const AliFemtoThreeVector v);//Gael 24 Sept 02
/* Th stuff */
void SetHiddenInfo(AliFemtoHiddenInfo* aHiddenInfo);
/***/
protected:
-
float fDecayLengthV0; // 3-d decay distance \\ V0 decay length
AliFemtoThreeVector fDecayVertexV0; // Coordinates of decay vertex
AliFemtoThreeVector fPrimaryVertex; // Coordinates of primary vertex
int fTpcHitsPos; // Number of TPC hits for positive daughter
int fTpcHitsNeg; // Number of TPC hits for negative daughter
+ bool fOnFlyStatusV0;
float fChi2V0; // Fit quality for V0
float fClV0; // Confidence level for V0
float fChi2Pos; // Fit quality for positive daughter
float fClPos; // Confidence level for positive daughter
float fChi2Neg; // Fit quality for negative daughter
float fClNeg; // Confidence level for negative daughter
+ double fCosPointingAngle;
float fDedxPos; // dEdx positive daughter
float fErrDedxPos; // dEdx error positive daughter
AliFmPhysicalHelixD fHelixNeg; // Helix for negative
AliFemtoThreeVector fMomV0; // Momentum of the V0
+ double fEtaV0; // Pseudorapidity of the V0
+ double fPhiV0; // Phi angle of the V0
+ double fYV0; // Rapidity of the V0;
float fAlphaV0; // Armenteros-Podolanski variable
float fPtArmV0; // Armenteros-Podolanski variable
float fELambda; // Energy assuming lambda hypothesis
float fPtPos; // Transverse momentum of pos. daughter
float fPtotPos; // Total momentum of pos. daughter
float fPtNeg; // Transverse momentum of neg. daughter
- float fPtotNeg; // Total momentum of neg. daughter
+ float fPtotNeg; // Total momentum of neg. daughter
+
+ float fEtaPos; // Eta of positive daughter
+ float fEtaNeg; // Eta of neg. daughter
+ int fTPCNclsPos; // No. of cls of pos daughter
+ int fTPCNclsNeg; // No. of cls of neg daughter
+ TBits fClustersPos;
+ TBits fClustersNeg;
+ TBits fSharingPos;
+ TBits fSharingNeg;
+ int fNdofPos; // No. of degrees of freedom of the pos. daughter track
+ int fNdofNeg; // No. of degrees of freedom of the neg. daughter track
+ unsigned long fStatusPos; // Status (tpc refit, its refit...)
+ unsigned long fStatusNeg; // Status (tpc refit, its refit...)
+
+ float fPosNSigmaTPCK;
+ float fPosNSigmaTPCPi;
+ float fPosNSigmaTPCP;
+ float fNegNSigmaTPCK;
+ float fNegNSigmaTPCPi;
+ float fNegNSigmaTPCP;
+
+ float fPosNSigmaTOFK;
+ float fPosNSigmaTOFPi;
+ float fPosNSigmaTOFP;
+ float fNegNSigmaTOFK;
+ float fNegNSigmaTOFPi;
+ float fNegNSigmaTOFP;
- unsigned short fKeyNeg; // Unique key negative
- unsigned short fKeyPos; // Unique key positive
+ int fKeyNeg; // Unique key negative
+ int fKeyPos; // Unique key positive
+
+ AliFemtoThreeVector fNominalTpcEntrancePointPos; // Nominal positive daugther track entrance point into TPC
+ AliFemtoThreeVector fNominalTpcExitPointPos; // Nominal positive daughter track exit point from TPC
+ AliFemtoThreeVector fNominalTpcEntrancePointNeg; // Nominal positive daugther track entrance point into TPC
+ AliFemtoThreeVector fNominalTpcExitPointNeg; // Nominal positive daughter track exit point from TPC
+
+
/* Th stuff */
// Fab private : add mutable
mutable AliFemtoHiddenInfo* fHiddenInfo; //! Hidden info
inline float AliFemtoV0::MomNegY() const { return fMomNeg.y(); }
inline float AliFemtoV0::MomNegZ() const { return fMomNeg.z(); }
inline AliFemtoThreeVector AliFemtoV0::MomV0() const { return fMomV0; }
+inline double AliFemtoV0::EtaV0() const {return fEtaV0;}
+inline double AliFemtoV0::PhiV0() const {return fPhiV0;}
+inline double AliFemtoV0::YV0() const {return fYV0;}
+inline double AliFemtoV0::CosPointingAngle() const {return fCosPointingAngle;}
inline float AliFemtoV0::MomV0X() const { return fMomV0.x(); }
inline float AliFemtoV0::MomV0Y() const { return fMomV0.y(); }
inline float AliFemtoV0::MomV0Z() const { return fMomV0.z(); }
inline float AliFemtoV0::ErrdedxPos() const {return fErrDedxPos;} //Gael 04Fev2002
inline float AliFemtoV0::LendedxPos() const {return fLenDedxPos;} //Gael 04Fev2002
inline float AliFemtoV0::PseudoRapPos() const {return fMomPos.PseudoRapidity();} //Gael 04Fev2002
-
+inline float AliFemtoV0::EtaPos() const {return fEtaPos;}
+inline float AliFemtoV0::EtaNeg() const {return fEtaNeg;}
+inline int AliFemtoV0::TPCNclsPos() const {return fTPCNclsPos;}
+inline int AliFemtoV0::TPCNclsNeg() const {return fTPCNclsNeg;}
+inline const TBits& AliFemtoV0::TPCclustersPos() const {return fClustersPos;}
+inline const TBits& AliFemtoV0::TPCclustersNeg() const {return fClustersNeg;}
+inline const TBits& AliFemtoV0::TPCsharingPos() const {return fSharingPos;}
+inline const TBits& AliFemtoV0::TPCsharingNeg() const {return fSharingNeg;}
+inline int AliFemtoV0::NdofPos() const {return fNdofPos;}
+inline int AliFemtoV0::NdofNeg() const {return fNdofNeg;}
+inline unsigned long AliFemtoV0::StatusPos() const {return fStatusPos;}
+inline unsigned long AliFemtoV0::StatusNeg() const {return fStatusNeg;}
inline unsigned long AliFemtoV0::TrackTopologyMapPos(unsigned int word) const { return fTrackTopologyMapPos[word]; }
inline unsigned long AliFemtoV0::TrackTopologyMapNeg(unsigned int word) const { return fTrackTopologyMapNeg[word]; }
-inline unsigned short AliFemtoV0::IdNeg() const { return fKeyNeg; }
-inline unsigned short AliFemtoV0::KeyNeg() const { return fKeyNeg; }
-inline unsigned short AliFemtoV0::IdPos() const { return fKeyPos; }
-inline unsigned short AliFemtoV0::KeyPos() const { return fKeyPos; }
+inline int AliFemtoV0::IdNeg() const { return fKeyNeg; }
+inline int AliFemtoV0::KeyNeg() const { return fKeyNeg; }
+inline int AliFemtoV0::IdPos() const { return fKeyPos; }
+inline int AliFemtoV0::KeyPos() const { return fKeyPos; }
+inline bool AliFemtoV0::OnFlyStatusV0() const {return fOnFlyStatusV0;}
+inline float AliFemtoV0::PosNSigmaTPCK() const { return fPosNSigmaTPCK; }
+inline float AliFemtoV0::PosNSigmaTPCPi() const { return fPosNSigmaTPCPi; }
+inline float AliFemtoV0::PosNSigmaTPCP() const { return fPosNSigmaTPCP; }
+inline float AliFemtoV0::NegNSigmaTPCK() const { return fNegNSigmaTPCK; }
+inline float AliFemtoV0::NegNSigmaTPCPi() const { return fNegNSigmaTPCPi; }
+inline float AliFemtoV0::NegNSigmaTPCP() const { return fNegNSigmaTPCP; }
+
+inline float AliFemtoV0::PosNSigmaTOFK() const { return fPosNSigmaTOFK; }
+inline float AliFemtoV0::PosNSigmaTOFPi() const { return fPosNSigmaTOFPi; }
+inline float AliFemtoV0::PosNSigmaTOFP() const { return fPosNSigmaTOFP; }
+inline float AliFemtoV0::NegNSigmaTOFK() const { return fNegNSigmaTOFK; }
+inline float AliFemtoV0::NegNSigmaTOFPi() const { return fNegNSigmaTOFPi; }
+inline float AliFemtoV0::NegNSigmaTOFP() const { return fNegNSigmaTOFP; }
+
+inline AliFemtoThreeVector AliFemtoV0::NominalTpcEntrancePointPos() const {return fNominalTpcEntrancePointPos;}
+inline AliFemtoThreeVector AliFemtoV0::NominalTpcExitPointPos() const {return fNominalTpcExitPointPos;}
+inline AliFemtoThreeVector AliFemtoV0::NominalTpcEntrancePointNeg() const {return fNominalTpcEntrancePointNeg;}
+inline AliFemtoThreeVector AliFemtoV0::NominalTpcExitPointNeg() const {return fNominalTpcExitPointNeg;}
inline void AliFemtoV0::SetdecayLengthV0(const float x){ fDecayLengthV0= x;}
inline void AliFemtoV0::SetdecayVertexV0X(const float x){ fDecayVertexV0.SetX(x);}
inline void AliFemtoV0::SetdcaPosToPrimVertex(const float x){fDcaPosToPrimVertex = x;}
inline void AliFemtoV0::SetdcaNegToPrimVertex(const float x){fDcaNegToPrimVertex = x;}
inline void AliFemtoV0::SetmomPos(const AliFemtoThreeVector v){fMomPos = v; }
+inline void AliFemtoV0::SetEtaV0(const double x){fEtaV0=x;}
+inline void AliFemtoV0::SetPhiV0(const double x){fPhiV0=x;}
+inline void AliFemtoV0::SetYV0(const double x){fYV0=x;}
+inline void AliFemtoV0::SetCosPointingAngle(const double x){fCosPointingAngle = x;}
inline void AliFemtoV0::SetmomPosX(const float x){fMomPos.SetX(x);}
inline void AliFemtoV0::SetmomPosY(const float x){fMomPos.SetY(x);}
inline void AliFemtoV0::SetmomPosZ(const float x){fMomPos.SetZ(x);}
inline void AliFemtoV0::SetptotPos( float x){fPtotPos = x;}
inline void AliFemtoV0::SetptNeg( float x){ fPtNeg= x;}
inline void AliFemtoV0::SetptotNeg( float x){ fPtotNeg= x;}
-inline void AliFemtoV0::SetidNeg(const unsigned short& s){ fKeyNeg= s;}
-inline void AliFemtoV0::SetidPos(const unsigned short& s){ fKeyPos= s;}
-inline void AliFemtoV0::SetkeyNeg(const unsigned short& s){ fKeyNeg= s;}
-inline void AliFemtoV0::SetkeyPos(const unsigned short& s){ fKeyPos= s;}
+inline void AliFemtoV0::SetidNeg(const int& s){ fKeyNeg= s;}
+inline void AliFemtoV0::SetidPos(const int& s){ fKeyPos= s;}
+inline void AliFemtoV0::SetkeyNeg(const int& s){ fKeyNeg= s;}
+inline void AliFemtoV0::SetkeyPos(const int& s){ fKeyPos= s;}
inline void AliFemtoV0::SettpcHitsPos(const int& i){fTpcHitsPos=i;}
inline void AliFemtoV0::SettpcHitsNeg(const int& i){fTpcHitsNeg=i;}
inline void AliFemtoV0::SetdedxNeg(float x){fDedxNeg=x;}
inline void AliFemtoV0::SeterrdedxPos(float x){fErrDedxPos=x;}//Gael 04Fev2002
inline void AliFemtoV0::SetlendedxPos(float x){fLenDedxPos=x;}//Gael 04Fev2002
inline void AliFemtoV0::SetprimaryVertex(const AliFemtoThreeVector v) { fPrimaryVertex = v; }//Gael 24 Sept 02
+
+inline void AliFemtoV0::SetEtaPos(float x) {fEtaPos=x;}
+inline void AliFemtoV0::SetEtaNeg(float x) {fEtaNeg=x;}
+inline void AliFemtoV0::SetTPCNclsPos(int x) {fTPCNclsPos=x;}
+inline void AliFemtoV0::SetTPCNclsNeg(int x) {fTPCNclsNeg=x;}
+inline void AliFemtoV0::SetTPCclustersPos(const TBits& x) {fClustersPos=x;}
+inline void AliFemtoV0::SetTPCclustersNeg(const TBits& x) {fClustersNeg=x;}
+inline void AliFemtoV0::SetTPCsharingPos(const TBits& x) {fSharingPos=x;}
+inline void AliFemtoV0::SetTPCsharingNeg(const TBits& x) {fSharingNeg=x;}
+inline void AliFemtoV0::SetNdofPos(int x) {fNdofPos=x;}
+inline void AliFemtoV0::SetNdofNeg(int x) {fNdofNeg=x;}
+inline void AliFemtoV0::SetStatusPos(unsigned long x) {fStatusPos=x;}
+inline void AliFemtoV0::SetStatusNeg(unsigned long x) {fStatusNeg=x;}
+inline void AliFemtoV0::SetOnFlyStatusV0(bool x) {fOnFlyStatusV0=x;}
+
+inline void AliFemtoV0::SetPosNSigmaTPCK(float x){ fPosNSigmaTPCK = x; }
+inline void AliFemtoV0::SetPosNSigmaTPCPi(float x){ fPosNSigmaTPCPi = x; }
+inline void AliFemtoV0::SetPosNSigmaTPCP(float x) { fPosNSigmaTPCP = x; }
+inline void AliFemtoV0::SetNegNSigmaTPCK(float x) { fNegNSigmaTPCK = x; }
+inline void AliFemtoV0::SetNegNSigmaTPCPi(float x){ fNegNSigmaTPCPi = x; }
+inline void AliFemtoV0::SetNegNSigmaTPCP(float x) { fNegNSigmaTPCP = x; }
+
+inline void AliFemtoV0::SetPosNSigmaTOFK(float x) { fPosNSigmaTOFK = x; }
+inline void AliFemtoV0::SetPosNSigmaTOFPi(float x) { fPosNSigmaTOFPi = x; }
+inline void AliFemtoV0::SetPosNSigmaTOFP(float x) { fPosNSigmaTOFP = x; }
+inline void AliFemtoV0::SetNegNSigmaTOFK(float x) { fNegNSigmaTOFK = x; }
+inline void AliFemtoV0::SetNegNSigmaTOFPi(float x) {fNegNSigmaTOFPi = x; }
+inline void AliFemtoV0::SetNegNSigmaTOFP(float x) { fNegNSigmaTOFP = x; }
+
+inline void AliFemtoV0::SetNominalTpcEntrancePointPos(AliFemtoThreeVector x) {fNominalTpcEntrancePointPos=x;}
+inline void AliFemtoV0::SetNominalTpcExitPointPos(AliFemtoThreeVector x) {fNominalTpcExitPointPos=x;}
+inline void AliFemtoV0::SetNominalTpcEntrancePointNeg(AliFemtoThreeVector x) {fNominalTpcEntrancePointNeg=x;}
+inline void AliFemtoV0::SetNominalTpcExitPointNeg(AliFemtoThreeVector x) {fNominalTpcExitPointNeg=x;}
+
#endif
--- /dev/null
+/////////////////////////////////////////////////////////////////////////////
+// //
+// AliFemtoShareQualityPairCut - a pair cut which checks for some pair //
+// qualities that attempt to identify slit/doubly reconstructed tracks //
+// //
+/////////////////////////////////////////////////////////////////////////////
+/***************************************************************************
+ *
+ * $Id: AliFemtoShareQualityPairCut.cxx 50722 2011-07-21 15:18:38Z akisiel $
+ *
+ * Author: Adam Kisiel, Ohio State, kisiel@mps.ohio-state.edu
+ ***************************************************************************
+ *
+ * Description: part of STAR HBT Framework: AliFemtoMaker package
+ * a cut to remove "shared" and "split" pairs
+ *
+ ***************************************************************************
+ *
+ *
+ **************************************************************************/
+
+#include "AliFemtoV0PairCut.h"
+#include <string>
+#include <cstdio>
+
+#ifdef __ROOT__
+ClassImp(AliFemtoV0PairCut)
+#endif
+
+//__________________
+AliFemtoV0PairCut::AliFemtoV0PairCut():
+ fNPairsPassed(0),
+ fNPairsFailed(0),
+ fV0Max(1.0),
+ fShareFractionMax(1.0),
+ fRemoveSameLabel(0)
+{
+ // Default constructor
+ // Nothing to do
+}
+//__________________
+AliFemtoV0PairCut::~AliFemtoV0PairCut(){
+ /* no-op */
+}
+//__________________
+bool AliFemtoV0PairCut::Pass(const AliFemtoPair* pair){
+ // Check for pairs that are possibly shared/double reconstruction
+
+ bool temp = true;
+
+ /*cout<<"pair->Track1(): "<<pair->Track1()<<endl;
+ cout<<"pair->Track2(): "<<pair->Track2()<<endl;
+ cout<<"pair->Track1()->V0(): "<<pair->Track1()->V0()<<endl;
+ cout<<"pair->Track2()->V0(): "<<pair->Track2()->V0()<<endl;
+ cout<<"pair->Track1()->V0()->IdNeg(): "<<pair->Track1()->V0()->IdNeg()<<endl;
+ cout<<"pair->Track2()->V0()->IdNeg(): "<<pair->Track2()->V0()->IdNeg()<<endl;
+ cout<<"pair->Track1()->V0()->IdPos(): "<<pair->Track1()->V0()->IdPos()<<endl;
+ cout<<"pair->Track2()->V0()->IdPos(): "<<pair->Track2()->V0()->IdPos()<<endl;*/
+
+ if(!(pair->Track1()->V0() && pair->Track2()->V0()))
+ {
+ return false;
+ }
+ if(pair->Track1()->V0()->IdNeg()==pair->Track2()->V0()->IdNeg() || pair->Track1()->V0()->IdPos()==pair->Track2()->V0()->IdPos())
+ {
+
+ return false;
+ }
+
+
+ return temp;
+}
+//__________________
+AliFemtoString AliFemtoV0PairCut::Report(){
+ // Prepare the report from the execution
+ string stemp = "AliFemtoV0 Pair Cut - remove shared and split pairs\n"; char ctemp[100];
+ snprintf(ctemp , 100, "Number of pairs which passed:\t%ld Number which failed:\t%ld\n",fNPairsPassed,fNPairsFailed);
+ stemp += ctemp;
+ AliFemtoString returnThis = stemp;
+ return returnThis;}
+//__________________
+
+void AliFemtoV0PairCut::SetV0Max(Double_t aV0Max) {
+ fV0Max = aV0Max;
+}
+
+Double_t AliFemtoV0PairCut::GetAliFemtoV0Max() const {
+ return fV0Max;
+}
+
+
+TList *AliFemtoV0PairCut::ListSettings()
+{
+ // return a list of settings in a writable form
+ TList *tListSetttings = new TList();
+ char buf[200];
+ snprintf(buf, 200, "AliFemtoV0PairCut.sharequalitymax=%f", fV0Max);
+ snprintf(buf, 200, "AliFemtoV0PairCut.sharefractionmax=%f", fShareFractionMax);
+ tListSetttings->AddLast(new TObjString(buf));
+
+ return tListSetttings;
+}
+
+void AliFemtoV0PairCut::SetRemoveSameLabel(Bool_t aRemove)
+{
+ fRemoveSameLabel = aRemove;
+}
--- /dev/null
+/////////////////////////////////////////////////////////////////////////////
+// //
+// AliFemtoShareQualityPairCut - a pair cut which checks for some pair //
+// qualities that attempt to identify slit/doubly reconstructed tracks //
+// //
+/////////////////////////////////////////////////////////////////////////////
+/***************************************************************************
+ *
+ * $Id: AliFemtoShareQualityPairCut.h 24360 2008-03-10 09:48:27Z akisiel $
+ *
+ * Author: Adam Kisiel, Ohio State University, kisiel@mps.ohio-state.edu
+ ***************************************************************************
+ *
+ * Description: part of STAR HBT Framework: AliFemtoMaker package
+ * a cut to remove "shared" and "split" pairs
+ *
+ ***************************************************************************
+ *
+ *
+ **************************************************************************/
+
+
+#ifndef ALIFEMTOV0PAIRCUT_H
+#define ALIFEMTOV0PAIRCUT_H
+
+// do I need these lines ?
+//#ifndef StMaker_H
+//#include "StMaker.h"
+//#endif
+
+#include "AliFemtoPairCut.h"
+
+class AliFemtoV0PairCut : public AliFemtoPairCut{
+public:
+ AliFemtoV0PairCut();
+ AliFemtoV0PairCut(const AliFemtoV0PairCut& cut);
+ virtual ~AliFemtoV0PairCut();
+
+ virtual bool Pass(const AliFemtoPair* pair);
+ virtual AliFemtoString Report();
+ virtual TList *ListSettings();
+ virtual AliFemtoPairCut* Clone();
+ void SetV0Max(Double_t aAliFemtoV0Max);
+ Double_t GetAliFemtoV0Max() const;
+ void SetRemoveSameLabel(Bool_t aRemove);
+
+ protected:
+ long fNPairsPassed; // Number of pairs consideered that passed the cut
+ long fNPairsFailed; // Number of pairs consideered that failed the cut
+
+ private:
+ Double_t fV0Max; // Maximum allowed pair quality
+ Double_t fShareFractionMax; // Maximum allowed share fraction
+ Bool_t fRemoveSameLabel; // If 1 pairs with two tracks with the same label will be removed
+
+
+#ifdef __ROOT__
+ ClassDef(AliFemtoV0PairCut, 0)
+#endif
+};
+
+inline AliFemtoV0PairCut::AliFemtoV0PairCut(const AliFemtoV0PairCut& c) :
+ AliFemtoPairCut(c),
+ fNPairsPassed(0),
+ fNPairsFailed(0),
+ fV0Max(1.0),
+ fShareFractionMax(1.0),
+ fRemoveSameLabel(0)// no cut
+{ /* no-op */ }
+
+inline AliFemtoPairCut* AliFemtoV0PairCut::Clone() { AliFemtoV0PairCut* c = new AliFemtoV0PairCut(*this); return c;}
+
+#endif
--- /dev/null
+#include "AliFemtoV0TrackCut.h"
+#include "AliESDtrack.h"
+#include <cstdio>
+
+#ifdef __ROOT__
+ClassImp(AliFemtoV0TrackCut)
+#endif
+
+
+
+AliFemtoV0TrackCut::AliFemtoV0TrackCut() :
+fInvMassLambdaMin(0),fInvMassLambdaMax(99),fMinDcaDaughtersToVert(0),fMaxDcaV0Daughters(99),fMaxDcaV0(99), fMaxCosPointingAngle(0), fParticleType(99), fEta(0.8), fPtMin(0), fPtMax(100), fOnFlyStatus(kFALSE), fMaxEtaDaughters(100), fTPCNclsDaughters(0), fNdofDaughters(10), fStatusDaughters(0), fPtMinDaughters(0), fPtMaxDaughters(99)
+{
+ // Default constructor
+ }
+ //------------------------------
+AliFemtoV0TrackCut::~AliFemtoV0TrackCut(){
+ /* noop */
+}
+//------------------------------
+bool AliFemtoV0TrackCut::Pass(const AliFemtoV0* aV0)
+{
+ // 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_t pt = aV0->PtV0();
+ Float_t eta = aV0->EtaV0();
+
+ //kinematic cuts
+ if(TMath::Abs(eta) > fEta) return false; //put in kinematic cuts by hand
+ if(pt < fPtMin) return false;
+ if(pt > fPtMax) return false;
+ if(TMath::Abs(aV0->EtaPos()) > fMaxEtaDaughters) return false;
+ if(TMath::Abs(aV0->EtaNeg()) > fMaxEtaDaughters) return false;
+
+ if(aV0->PtPos()< fPtMinDaughters) return false;
+ if(aV0->PtNeg()< fPtMinDaughters) return false;
+ if(aV0->PtPos()> fPtMaxDaughters) return false;
+ if(aV0->PtNeg()> fPtMaxDaughters) return false;
+
+ //V0 from kinematics information
+ if (fParticleType == kLambdaMC ) {
+ if(!(aV0->MassLambda()>fInvMassLambdaMin && aV0->MassLambda()<fInvMassLambdaMax) || !(aV0->PosNSigmaTPCP()==0))
+ return false;
+ else
+ {
+ return true;
+ }
+ }
+ else if (fParticleType == kAntiLambdaMC) {
+ if(!(aV0->MassLambda()>fInvMassLambdaMin &&aV0->MassLambda()<fInvMassLambdaMax) || !(aV0->NegNSigmaTPCP()==0))
+ return false;
+ else
+ {
+ return true;
+ }
+ }
+
+ //quality cuts
+ if(fOnFlyStatus) if(aV0->OnFlyStatusV0()) return false;
+ if(aV0->StatusNeg() == 999 || aV0->StatusPos() == 999) return false;
+ if(aV0->TPCNclsPos()<fTPCNclsDaughters) return false;
+ if(aV0->TPCNclsNeg()<fTPCNclsDaughters) return false;
+ if(aV0->NdofPos()>fNdofDaughters) return false;
+ if(aV0->NdofNeg()>fNdofDaughters) return false;
+ if(!(aV0->StatusNeg()&fStatusDaughters)) return false;
+ if(!(aV0->StatusPos()&fStatusDaughters)) return false;
+
+ //DCA between daughter particles
+ if(TMath::Abs(aV0->DcaV0Daughters())>fMaxDcaV0Daughters)
+ return false;
+
+ //DCA of daughters to primary vertex
+ if(TMath::Abs(aV0->DcaPosToPrimVertex())<fMinDcaDaughtersToVert || TMath::Abs(aV0->DcaNegToPrimVertex())<fMinDcaDaughtersToVert)
+ return false;
+
+ //DCA V0 to prim vertex
+ if(TMath::Abs(aV0->DcaV0ToPrimVertex())>fMaxDcaV0)
+ return false;
+
+ //cos pointing angle
+ if(aV0->CosPointingAngle()<fMaxCosPointingAngle)
+ return false;
+
+ if(fParticleType == kAll)
+ return true;
+
+ bool pid_check=false;
+ // Looking for lambdas = proton + pim
+ if (fParticleType == 0 ) {
+ if (IsProtonNSigma(aV0->PtotPos(), aV0->PosNSigmaTPCP(), aV0->PosNSigmaTOFP())) //proton
+ if (IsPionNSigma(aV0->PtotNeg(), aV0->NegNSigmaTPCPi(), aV0->NegNSigmaTOFPi())) //pion
+ {
+ pid_check=true;
+ //invariant mass lambda
+ if(aV0->MassLambda()<fInvMassLambdaMin || aV0->MassLambda()>fInvMassLambdaMax)
+ return false;
+ }
+
+ }//Looking for antilambdas = antiproton + pip
+ else if (fParticleType == 1) {
+ if (IsProtonNSigma(aV0->PtotNeg(), aV0->NegNSigmaTPCP(), aV0->NegNSigmaTOFP())) //proton
+ if (IsPionNSigma(aV0->PtotPos(), aV0->PosNSigmaTPCPi(), aV0->PosNSigmaTOFPi())) //pion
+ {
+ pid_check=true;
+ //invariant mass antilambda
+ if(aV0->MassAntiLambda()<fInvMassLambdaMin || aV0->MassAntiLambda()>fInvMassLambdaMax)
+ return false;
+ }
+ }
+
+
+ if(!pid_check) return false;
+
+
+
+ return true;
+
+
+}
+//------------------------------
+AliFemtoString AliFemtoV0TrackCut::Report()
+{
+ // Prepare report from the execution
+ string tStemp;
+ char tCtemp[100];
+ snprintf(tCtemp , 100, "Minimum of Invariant Mass assuming Lambda:\t%lf\n",fInvMassLambdaMin);
+ tStemp+=tCtemp;
+ snprintf(tCtemp , 100, "Maximum of Invariant Mass assuming Lambda:\t%lf\n",fInvMassLambdaMax);
+ tStemp+=tCtemp;
+ snprintf(tCtemp , 100, "Minimum DCA of daughters to primary vertex:\t%lf\n",fMinDcaDaughtersToVert);
+ tStemp+=tCtemp;
+ snprintf(tCtemp , 100, "Max DCA of daughters:\t%lf\n",fMaxDcaV0Daughters);
+ tStemp+=tCtemp;
+
+
+
+ AliFemtoString returnThis = tStemp;
+ return returnThis;
+}
+TList *AliFemtoV0TrackCut::ListSettings()
+{
+ // return a list of settings in a writable form
+ TList *tListSetttings = new TList();
+ char buf[200];
+ snprintf(buf, 200, "AliFemtoV0TrackCut.InvMassLambdaMin=%lf", fInvMassLambdaMin);
+ tListSetttings->AddLast(new TObjString(buf));
+ return tListSetttings;
+}
+
+void AliFemtoV0TrackCut::SetMinDaughtersToPrimVertex(double min)
+{
+ fMinDcaDaughtersToVert=min;
+}
+
+void AliFemtoV0TrackCut::SetMaxDcaV0Daughters(double max)
+{
+ fMaxDcaV0Daughters=max;
+};
+
+void AliFemtoV0TrackCut::SetMaxDcaV0(double max)
+{
+ fMaxDcaV0=max;
+};
+
+void AliFemtoV0TrackCut::SetMaxCosPointingAngle(double max)
+{
+ fMaxCosPointingAngle = max;
+}
+
+void AliFemtoV0TrackCut::SetParticleType(short x)
+{
+ fParticleType = x;
+}
+
+void AliFemtoV0TrackCut::SetEta(double x){
+ fEta = x;
+}
+
+void AliFemtoV0TrackCut::SetPt(double min, double max){
+ fPtMin = min;
+ fPtMax = max;
+}
+
+void AliFemtoV0TrackCut::SetEtaDaughters(float x)
+{
+ fMaxEtaDaughters = x;
+}
+void AliFemtoV0TrackCut::SetTPCnclsDaughters(int x)
+{
+ fTPCNclsDaughters = x;
+}
+void AliFemtoV0TrackCut::SetNdofDaughters(int x)
+{
+ fNdofDaughters=x;
+}
+void AliFemtoV0TrackCut::SetStatusDaughters(unsigned long x)
+{
+ fStatusDaughters=x;
+}
+void AliFemtoV0TrackCut::SetPtDaughters(float min,float max)
+{
+ fPtMinDaughters = min;
+ fPtMaxDaughters = max;
+}
+
+void AliFemtoV0TrackCut::SetOnFlyStatus(bool x)
+{
+ fOnFlyStatus = x;
+}
+
+void AliFemtoV0TrackCut::SetInvariantMassLambda(double min, double max)
+{
+ fInvMassLambdaMin = min;
+ fInvMassLambdaMax = max;
+
+}
+
+//---------------------PID n Sigma ---------------------------------//
+bool AliFemtoV0TrackCut::IsKaonTPCdEdxNSigma(float mom, float nsigmaK)
+{
+ cout<<" AliFemtoV0TrackCut::IsKaonTPCdEdxNSigma "<<mom<<" "<<nsigmaK<<endl;
+
+
+ if(mom<0.35 && TMath::Abs(nsigmaK)<5.0)return true;
+ if(mom>=0.35 && mom<0.5 && TMath::Abs(nsigmaK)<3.0)return true;
+ if(mom>=0.5 && mom<0.7 && TMath::Abs(nsigmaK)<2.0)return true;
+
+ return false;
+}
+
+
+bool AliFemtoV0TrackCut::IsKaonTOFNSigma(float mom, float nsigmaK)
+{
+ cout<<" AliFemtoV0TrackCut::IsKaonTPCdEdxNSigma "<<mom<<" "<<nsigmaK<<endl;
+ if(mom>=1.5 && TMath::Abs(nsigmaK)<2.0)return true;
+ return false;
+}
+
+bool AliFemtoV0TrackCut::IsKaonNSigma(float mom, float nsigmaTPCK, float nsigmaTOFK)
+{
+
+ if(TMath::Abs(nsigmaTOFK)<3.0 && mom<=1.5 && TMath::Abs(nsigmaTPCK)<3.0)return true;
+ if(TMath::Abs(nsigmaTOFK)<2.0 && mom>1.5 && TMath::Abs(nsigmaTPCK)<3.0)return true;
+
+ //no TOF signal
+
+ if(nsigmaTOFK<=-9999){
+ //cout <<"/////////////// AliFemtoV0TrackCut::IsKaonNSigma NO TOF SIGNAL ////////////" <<endl;
+ if(TMath::Abs(nsigmaTPCK)<2.0) return true;
+ /*if(mom<0.4 && TMath::Abs(nsigmaTPCK)<1.0)return true;
+ if(mom>=0.4 && mom<0.5 && TMath::Abs(nsigmaTPCK)<2.0)return true;
+ if(mom>=0.5 && mom<0.6 && TMath::Abs(nsigmaTPCK)<2.0)return true;*/
+ }
+
+ return false;
+}
+
+
+
+bool AliFemtoV0TrackCut::IsPionNSigma(float mom, float nsigmaTPCPi, float nsigmaTOFPi)
+{
+ mom = 1; //because of warning in the compilation
+ nsigmaTOFPi = 1;
+ // cout<<" AliFemtoV0TrackCut::IsKaonNSigma "<<mom<<" tpc "<<nsigmaTPCK<<" tof "<<nsigmaTOFK<<endl;
+
+ //TOF signal
+ // if(TMath::Abs(nsigmaTOFPi)<2.0 && mom<=1.5 && TMath::Abs(nsigmaTPCPi)<2.0)return true;
+ // if(TMath::Abs(nsigmaTOFPi)<2.0 && mom>1.5 && TMath::Abs(nsigmaTPCPi)<2.0)return true;
+
+
+ //no TOF signal
+ // if(nsigmaTOFPi<=-9999){
+ // if(TMath::Abs(nsigmaTPCPi)<2.0) return true;
+ /*if(mom<0.35 && TMath::Abs(nsigmaTPCPi)<2.0)return true;
+ if(mom>=0.35 && mom<0.5 && TMath::Abs(nsigmaTPCPi)<2.0)return true;
+ if(mom>=0.5 && TMath::Abs(nsigmaTPCPi)<2.0)return true;*/
+ // }
+
+ if( TMath::Abs(nsigmaTPCPi)<3.0) return true;
+
+ return false;
+}
+
+
+bool AliFemtoV0TrackCut::IsProtonNSigma(float mom, float nsigmaTPCP, float nsigmaTOFP)
+{
+ mom = 1; //because of warning in the compilation
+ nsigmaTOFP = 1;
+ // cout<<" AliFemtoV0TrackCut::IsKaonNSigma "<<mom<<" tpc "<<nsigmaTPCK<<" tof "<<nsigmaTOFK<<endl;
+
+ //TOF signal
+ // if(TMath::Abs(nsigmaTOFP)<2.0 && mom<=1.5 && TMath::Abs(nsigmaTPCP)<2.0)return true;
+ // if(TMath::Abs(nsigmaTOFP)<2.0 && mom>1.5 && TMath::Abs(nsigmaTPCP)<2.0)return true;
+
+ //no TOF signal
+ // if(nsigmaTOFP<=-9999){
+ // if(TMath::Abs(nsigmaTPCP)<2.0) return true;
+ /*if(mom<0.5 && TMath::Abs(nsigmaTPCP)<2.0)return true;
+ if(mom>=0.5 && mom<0.8 && TMath::Abs(nsigmaTPCP)<2.0)return true;*/
+ // }
+
+ if( TMath::Abs(nsigmaTPCP)<3.0) return true;
+
+ return false;
+}
--- /dev/null
+///////////////////////////////////////////////////////////////////////////
+// //
+// AliFemtoESDTrackCut: A basic track cut that used information from //
+// ALICE ESD to accept or reject the track. //
+// Enables the selection on charge, transverse momentum, rapidity, //
+// pid probabilities, number of ITS and TPC clusters //
+// Author: Marek Chojnacki (WUT), mchojnacki@knf.pw.edu.pl //
+// //
+///////////////////////////////////////////////////////////////////////////
+
+#ifndef ALIFEMTOV0TRACKCUT_H
+#define ALIFEMTOV0TRACKCUT_H
+
+#include "AliFemtoTrackCut.h"
+
+class AliFemtoV0TrackCut : public AliFemtoParticleCut
+{
+ public:
+ enum V0Type {kLambda = 0, kAntiLambda=1, kAll=99, kLambdaMC=101, kAntiLambdaMC=102};
+ typedef enum V0Type AliFemtoV0Type;
+
+
+ AliFemtoV0TrackCut();
+ virtual ~AliFemtoV0TrackCut();
+
+ virtual bool Pass(const AliFemtoV0* aV0);
+
+ virtual AliFemtoString Report();
+ virtual TList *ListSettings();
+ virtual AliFemtoParticleType Type(){return hbtV0;}
+
+ void SetInvariantMassLambda(double,double);
+ void SetMinDaughtersToPrimVertex(double);
+ void SetMaxDcaV0Daughters(double);
+ void SetMaxDcaV0(double);
+ void SetMaxCosPointingAngle(double);
+ void SetParticleType(short);
+ void SetEta(double);
+ void SetPt(double,double);
+ void SetEtaDaughters(float);
+ void SetTPCnclsDaughters(int);
+ void SetNdofDaughters(int);
+ void SetStatusDaughters(unsigned long);
+ void SetPtDaughters(float,float);
+ void SetOnFlyStatus(bool);
+
+ //----n sigma----
+ bool IsKaonTPCdEdxNSigma(float mom, float nsigmaK);
+ bool IsKaonTOFNSigma(float mom, float nsigmaK);
+ bool IsKaonNSigma(float mom, float nsigmaTPCK, float nsigmaTOFK);
+ bool IsPionNSigma(float mom, float nsigmaTPCPi, float nsigmaTOFPi);
+ bool IsProtonNSigma(float mom, float nsigmaTPCP, float nsigmaTOFP);
+
+ private: // here are the quantities I want to cut on...
+
+ double fInvMassLambdaMin; //invariant mass lambda min
+ double fInvMassLambdaMax; //invariant mass lambda max
+ double fMinDcaDaughtersToVert; //DCA of daughters to primary vertex
+ double fMaxDcaV0Daughters; //Max DCA of v0 daughters at Decay vertex
+ double fMaxDcaV0;
+
+ double fMaxCosPointingAngle;
+ short fParticleType; //0-lambda
+ double fEta;
+ double fPtMin;
+ double fPtMax;
+ bool fOnFlyStatus;
+
+ float fMaxEtaDaughters; // Eta of positive daughter
+ int fTPCNclsDaughters; // No. of cls of pos daughter
+ int fNdofDaughters; // No. of degrees of freedom of the pos. daughter track
+ unsigned long fStatusDaughters; // Status (tpc refit, its refit...)
+ float fPtMinDaughters;
+ float fPtMaxDaughters;
+
+#ifdef __ROOT__
+ ClassDef(AliFemtoV0TrackCut, 1)
+#endif
+
+};
+
+
+#endif
+
--- /dev/null
+/////////////////////////////////////////////////////////////////////////////
+// //
+// AliFemtoShareQualityPairCut - a pair cut which checks for some pair //
+// qualities that attempt to identify slit/doubly reconstructed tracks //
+// //
+/////////////////////////////////////////////////////////////////////////////
+/***************************************************************************
+ *
+ * $Id: AliFemtoShareQualityPairCut.cxx 50722 2011-07-21 15:18:38Z akisiel $
+ *
+ * Author: Adam Kisiel, Ohio State, kisiel@mps.ohio-state.edu
+ ***************************************************************************
+ *
+ * Description: part of STAR HBT Framework: AliFemtoMaker package
+ * a cut to remove "shared" and "split" pairs
+ *
+ ***************************************************************************
+ *
+ *
+ **************************************************************************/
+
+#include "AliFemtoV0TrackPairCut.h"
+#include <string>
+#include <cstdio>
+
+#ifdef __ROOT__
+ClassImp(AliFemtoV0TrackPairCut)
+#endif
+
+//__________________
+AliFemtoV0TrackPairCut::AliFemtoV0TrackPairCut():
+ fNPairsPassed(0),
+ fNPairsFailed(0),
+ fV0Max(1.0),
+ fShareQualityMax(1.0),
+ fShareFractionMax(1.0),
+ fRemoveSameLabel(0),
+ fTrackTPCOnly(0)
+{
+ // Default constructor
+ // Nothing to do
+}
+//__________________
+AliFemtoV0TrackPairCut::~AliFemtoV0TrackPairCut(){
+ /* no-op */
+}
+//__________________
+bool AliFemtoV0TrackPairCut::Pass(const AliFemtoPair* pair){
+ // Check for pairs that are possibly shared/double reconstruction
+
+ bool temp = true;
+ //Track1 - V0
+ //Track2 - track
+
+ //!!!!!USUN MNIE!!!!
+ /*if(pair->KStar()>0.15)
+ {
+ return false;
+ }*/
+ //!!!!!!!!
+
+
+ if(!(pair->Track1()->V0() && pair->Track2()->Track()))
+ {
+ return false;
+ }
+ if(fTrackTPCOnly)
+ {
+ if( (-(pair->Track1()->V0()->IdNeg()+1)) ==pair->Track2()->TrackId() || (-(pair->Track1()->V0()->IdPos()+1)) ==pair->Track2()->TrackId())
+ {
+ return false;
+ }
+ }
+ else
+ {
+ if(pair->Track1()->V0()->IdNeg()==pair->Track2()->TrackId() || pair->Track1()->V0()->IdPos()==pair->Track2()->TrackId())
+ {
+ return false;
+ }
+ }
+
+
+
+ //reject merged trakcs in TPC
+
+
+ //temp = dist > fDTPCMin;
+ //koniec kopii
+ //if(!temp)
+ //return false;
+
+ //kopia z AliFemtoShareQualityPairCut.cxx
+ Int_t nh = 0;
+ Int_t an = 0;
+ Int_t ns = 0;
+
+
+
+ if ((fShareFractionMax < 1.0) && ( fShareQualityMax < 1.0)) {
+ for (unsigned int imap=0; imap<pair->Track1()->V0()->TPCclustersPos().GetNbits(); imap++) {
+ // If both have clusters in the same row
+ if (pair->Track1()->V0()->TPCclustersPos().TestBitNumber(imap) &&
+ pair->Track2()->Track()->TPCclusters().TestBitNumber(imap)) {
+ // Do they share it ?
+ if (pair->Track1()->V0()->TPCsharingPos().TestBitNumber(imap) &&
+ pair->Track2()->Track()->TPCsharing().TestBitNumber(imap))
+ {
+ // cout << "A shared cluster !!!" << endl;
+ // cout << "imap idx1 idx2 "
+ // << imap << " "
+ // << tP1idx[imap] << " " << tP2idx[imap] << endl;
+ an++;
+ nh+=2;
+ ns+=2;
+ }
+
+ // Different hits on the same padrow
+ else {
+ an--;
+ nh+=2;
+ }
+ }
+ else if (pair->Track1()->V0()->TPCclustersPos().TestBitNumber(imap) ||
+ pair->Track2()->Track()->TPCclusters().TestBitNumber(imap)) {
+ // One track has a hit, the other does not
+ an++;
+ nh++;
+ }
+ }
+
+ Float_t hsmval = 0.0;
+ Float_t hsfval = 0.0;
+
+ if (nh >0) {
+ hsmval = an*1.0/nh;
+ hsfval = ns*1.0/nh;
+ }
+ // if (hsmval > -0.4) {
+ // cout << "Pair quality: " << hsmval << " " << an << " " << nh << " "
+ // << (pair->Track1()->Track()) << " "
+ // << (pair->Track2()->Track()) << endl;
+ // cout << "Bits: " << pair->Track1()->Track()->TPCclusters().GetNbits() << endl;
+ // }
+ // if (hsfval > 0.0) {
+ // cout << "Pair sharity: " << hsfval << " " << ns << " " << nh << " " << hsmval << " " << an << " " << nh << endl;
+ // }
+
+ temp = (hsmval < fShareQualityMax) && (hsfval < fShareFractionMax);
+ if(!temp) return false;
+
+ nh = 0;
+ an = 0;
+ ns = 0;
+
+ for (unsigned int imap=0; imap<pair->Track1()->V0()->TPCclustersNeg().GetNbits(); imap++) {
+ // If both have clusters in the same row
+ if (pair->Track1()->V0()->TPCclustersNeg().TestBitNumber(imap) &&
+ pair->Track2()->Track()->TPCclusters().TestBitNumber(imap)) {
+ // Do they share it ?
+ if (pair->Track1()->V0()->TPCsharingNeg().TestBitNumber(imap) &&
+ pair->Track2()->Track()->TPCsharing().TestBitNumber(imap))
+ {
+ // cout << "A shared cluster !!!" << endl;
+ // cout << "imap idx1 idx2 "
+ // << imap << " "
+ // << tP1idx[imap] << " " << tP2idx[imap] << endl;
+ an++;
+ nh+=2;
+ ns+=2;
+ }
+
+ // Different hits on the same padrow
+ else {
+ an--;
+ nh+=2;
+ }
+ }
+ else if (pair->Track1()->V0()->TPCclustersNeg().TestBitNumber(imap) ||
+ pair->Track2()->Track()->TPCclusters().TestBitNumber(imap)) {
+ // One track has a hit, the other does not
+ an++;
+ nh++;
+ }
+ }
+
+ hsmval = 0.0;
+ hsfval = 0.0;
+
+ if (nh >0) {
+ hsmval = an*1.0/nh;
+ hsfval = ns*1.0/nh;
+ }
+ // if (hsmval > -0.4) {
+ // cout << "Pair quality: " << hsmval << " " << an << " " << nh << " "
+ // << (pair->Track1()->Track()) << " "
+ // << (pair->Track2()->Track()) << endl;
+ // cout << "Bits: " << pair->Track1()->Track()->TPCclusters().GetNbits() << endl;
+ // }
+ // if (hsfval > 0.0) {
+ // cout << "Pair sharity: " << hsfval << " " << ns << " " << nh << " " << hsmval << " " << an << " " << nh << endl;
+ // }
+
+ temp = (hsmval < fShareQualityMax) && (hsfval < fShareFractionMax);
+
+
+ }
+ else
+ temp = true;
+ //koniec kopii
+
+
+
+
+
+ return temp;
+}
+//__________________
+AliFemtoString AliFemtoV0TrackPairCut::Report(){
+ // Prepare the report from the execution
+ string stemp = "AliFemtoV0 Pair Cut - remove shared and split pairs\n"; char ctemp[100];
+ snprintf(ctemp , 100, "Number of pairs which passed:\t%ld Number which failed:\t%ld\n",fNPairsPassed,fNPairsFailed);
+ stemp += ctemp;
+ AliFemtoString returnThis = stemp;
+ return returnThis;}
+//__________________
+
+void AliFemtoV0TrackPairCut::SetV0Max(Double_t aV0Max) {
+ fV0Max = aV0Max;
+}
+
+Double_t AliFemtoV0TrackPairCut::GetAliFemtoV0Max() const {
+ return fV0Max;
+}
+
+
+TList *AliFemtoV0TrackPairCut::ListSettings()
+{
+ // return a list of settings in a writable form
+ TList *tListSetttings = new TList();
+ char buf[200];
+ snprintf(buf, 200, "AliFemtoV0TrackPairCut.sharequalitymax=%f", fV0Max);
+ snprintf(buf, 200, "AliFemtoV0TrackPairCut.sharefractionmax=%f", fShareFractionMax);
+ tListSetttings->AddLast(new TObjString(buf));
+
+ return tListSetttings;
+}
+
+void AliFemtoV0TrackPairCut::SetRemoveSameLabel(Bool_t aRemove)
+{
+ fRemoveSameLabel = aRemove;
+}
+
+void AliFemtoV0TrackPairCut::SetTPCOnly(Bool_t tpconly)
+{
+ fTrackTPCOnly = tpconly;
+}
+
+void AliFemtoV0TrackPairCut::SetShareQualityMax(Double_t aShareQualityMax) {
+ fShareQualityMax = aShareQualityMax;
+}
+
+void AliFemtoV0TrackPairCut::SetShareFractionMax(Double_t aShareFractionMax) {
+ fShareFractionMax = aShareFractionMax;
+}
--- /dev/null
+/////////////////////////////////////////////////////////////////////////////
+// //
+// AliFemtoShareQualityPairCut - a pair cut which checks for some pair //
+// qualities that attempt to identify slit/doubly reconstructed tracks //
+// //
+/////////////////////////////////////////////////////////////////////////////
+/***************************************************************************
+ *
+ * $Id: AliFemtoShareQualityPairCut.h 24360 2008-03-10 09:48:27Z akisiel $
+ *
+ * Author: Adam Kisiel, Ohio State University, kisiel@mps.ohio-state.edu
+ ***************************************************************************
+ *
+ * Description: part of STAR HBT Framework: AliFemtoMaker package
+ * a cut to remove "shared" and "split" pairs
+ *
+ ***************************************************************************
+ *
+ *
+ **************************************************************************/
+
+
+#ifndef ALIFEMTOV0TRACKPAIRCUT_H
+#define ALIFEMTOV0TRACKPAIRCUT_H
+
+// do I need these lines ?
+//#ifndef StMaker_H
+//#include "StMaker.h"
+//#endif
+
+#include "AliFemtoPairCut.h"
+
+class AliFemtoV0TrackPairCut : public AliFemtoPairCut{
+public:
+ AliFemtoV0TrackPairCut();
+ AliFemtoV0TrackPairCut(const AliFemtoV0TrackPairCut& cut);
+ virtual ~AliFemtoV0TrackPairCut();
+
+ virtual bool Pass(const AliFemtoPair* pair);
+ virtual AliFemtoString Report();
+ virtual TList *ListSettings();
+ virtual AliFemtoPairCut* Clone();
+ void SetV0Max(Double_t aAliFemtoV0Max);
+ Double_t GetAliFemtoV0Max() const;
+ void SetRemoveSameLabel(Bool_t aRemove);
+ void SetTPCOnly(Bool_t tpconly);
+ void SetShareQualityMax(Double_t aShareQualityMax);
+ void SetShareFractionMax(Double_t aShareFractionMax);
+
+ protected:
+ long fNPairsPassed; // Number of pairs consideered that passed the cut
+ long fNPairsFailed; // Number of pairs consideered that failed the cut
+
+ private:
+ Double_t fV0Max; // Maximum allowed pair quality
+ Double_t fShareQualityMax;
+ Double_t fShareFractionMax; // Maximum allowed share fraction
+ Bool_t fRemoveSameLabel; // If 1 pairs with two tracks with the same label will be removed
+ Bool_t fTrackTPCOnly;
+
+
+#ifdef __ROOT__
+ ClassDef(AliFemtoV0TrackPairCut, 0)
+#endif
+};
+
+inline AliFemtoV0TrackPairCut::AliFemtoV0TrackPairCut(const AliFemtoV0TrackPairCut& c) :
+ AliFemtoPairCut(c),
+ fNPairsPassed(0),
+ fNPairsFailed(0),
+ fV0Max(1.0),
+ fShareQualityMax(1.0),
+ fShareFractionMax(1.0),
+ fRemoveSameLabel(0),
+ fTrackTPCOnly(0)
+{ /* no-op */ }
+
+inline AliFemtoPairCut* AliFemtoV0TrackPairCut::Clone() { AliFemtoV0TrackPairCut* c = new AliFemtoV0TrackPairCut(*this); return c;}
+
+#endif
fDPhiPtNumerator(0),
fDPhiPtDenominator(0),
fDCosPtNumerator(0),
- fDCosPtDenominator(0)
+ fDCosPtDenominator(0),
+ fPhi(0),
+ fEta(0)
{
// set up numerator
char tTitNumD[101] = "NumDPhiDEta";
strncat(tTitDenDCos,title, 100);
fDCosDenominator = new TH1D(tTitDenDCos,title,aPhiBins*2,-1.0,1.0);
+ char tTitPhi[101] = "Phi";
+ strncat(tTitPhi,title, 100);
+ fPhi = new TH1D(tTitPhi,title,90,-TMath::Pi(),TMath::Pi());
+
+ char tTitEta[101] = "Eta";
+ strncat(tTitEta,title, 100);
+ fEta = new TH1D(tTitEta,title,90,-1.2,1.2);
+
+
// to enable error bar calculation...
fDPhiDEtaNumerator->Sumw2();
fDPhiDEtaDenominator->Sumw2();
fDPhiDenominator->Sumw2();
fDCosNumerator->Sumw2();
fDCosDenominator->Sumw2();
+ fPhi->Sumw2();
+ fEta->Sumw2();
}
//____________________________
fDPhiPtNumerator(0),
fDPhiPtDenominator(0),
fDCosPtNumerator(0),
- fDCosPtDenominator(0)
+ fDCosPtDenominator(0),
+ fPhi(0),
+ fEta(0)
{
// copy constructor
if (aCorrFctn.fDPhiDEtaNumerator)
fDCosPtDenominator = new TH2D(*aCorrFctn.fDCosPtDenominator);
else
fDCosPtDenominator = 0;
+ if (aCorrFctn.fPhi)
+ fPhi = new TH1D(*aCorrFctn.fPhi);
+ else
+ fPhi = 0;
+ if (aCorrFctn.fEta)
+ fEta = new TH1D(*aCorrFctn.fEta);
+ else
+ fEta = 0;
}
//____________________________
delete fDCosPtNumerator;
delete fDCosPtDenominator;
}
+ delete fPhi;
+ delete fEta;
}
//_________________________
AliFemtoCorrFctnDEtaDPhi& AliFemtoCorrFctnDEtaDPhi::operator=(const AliFemtoCorrFctnDEtaDPhi& aCorrFctn)
fDCosPtDenominator = new TH2D(*aCorrFctn.fDCosPtDenominator);
else
fDCosPtDenominator = 0;
+ if (aCorrFctn.fPhi)
+ fPhi = new TH1D(*aCorrFctn.fPhi);
+ else
+ fPhi = 0;
+ if (aCorrFctn.fEta)
+ fEta = new TH1D(*aCorrFctn.fEta);
+ else
+ fEta = 0;
return *this;
}
if (fPairCut)
if (!fPairCut->Pass(pair)) return;
- double phi1 = pair->Track1()->Track()->P().Phi();
+ /*double phi1 = pair->Track1()->Track()->P().Phi();
double phi2 = pair->Track2()->Track()->P().Phi();
double eta1 = pair->Track1()->Track()->P().PseudoRapidity();
- double eta2 = pair->Track2()->Track()->P().PseudoRapidity();
+ double eta2 = pair->Track2()->Track()->P().PseudoRapidity();*/
+
+ double phi1 = pair->Track1()->FourMomentum().Phi();
+ double phi2 = pair->Track2()->FourMomentum().Phi();
+ double eta1 = pair->Track1()->FourMomentum().PseudoRapidity();
+ double eta2 = pair->Track2()->FourMomentum().PseudoRapidity();
double dphi = phi1 - phi2;
while (dphi<-PIH) dphi+=PIT;
// fDCosPtNumerator->Fill(cosphi, ptmin);
}
+ fPhi->Fill(phi1);
+ fEta->Fill(eta1);
+
}
//____________________________
void AliFemtoCorrFctnDEtaDPhi::AddMixedPair( AliFemtoPair* pair){
if (fPairCut)
if (!fPairCut->Pass(pair)) return;
- double phi1 = pair->Track1()->Track()->P().Phi();
+ /*double phi1 = pair->Track1()->Track()->P().Phi();
double phi2 = pair->Track2()->Track()->P().Phi();
double eta1 = pair->Track1()->Track()->P().PseudoRapidity();
- double eta2 = pair->Track2()->Track()->P().PseudoRapidity();
+ double eta2 = pair->Track2()->Track()->P().PseudoRapidity();*/
+
+ double phi1 = pair->Track1()->FourMomentum().Phi();
+ double phi2 = pair->Track2()->FourMomentum().Phi();
+ double eta1 = pair->Track1()->FourMomentum().PseudoRapidity();
+ double eta2 = pair->Track2()->FourMomentum().PseudoRapidity();
double dphi = phi1 - phi2;
while (dphi<-PIH) dphi+=PIT;
// Write out result histograms
fDPhiDEtaNumerator->Write();
fDPhiDEtaDenominator->Write();
- fDPhiNumerator->Write();
+ /*fDPhiNumerator->Write();
fDPhiDenominator->Write();
fDCosNumerator->Write();
fDCosDenominator->Write();
fDPhiPtDenominator->Write();
fDCosPtNumerator->Write();
fDCosPtDenominator->Write();
- }
+ }*/
+ fPhi->Write();
+ fEta->Write();
}
TList* AliFemtoCorrFctnDEtaDPhi::GetOutputList()
tOutputList->Add(fDPhiDEtaNumerator);
tOutputList->Add(fDPhiDEtaDenominator);
- tOutputList->Add(fDPhiNumerator);
+ /*tOutputList->Add(fDPhiNumerator);
tOutputList->Add(fDPhiDenominator);
tOutputList->Add(fDCosNumerator);
tOutputList->Add(fDCosDenominator);
tOutputList->Add(fDPhiPtDenominator);
tOutputList->Add(fDCosPtNumerator);
tOutputList->Add(fDCosPtDenominator);
- }
+ }*/
+ tOutputList->Add(fPhi);
+ tOutputList->Add(fEta);
return tOutputList;
TH2D *fDCosPtNumerator; // Numerator of colinearity correlation vs. Pt min
TH2D *fDCosPtDenominator; // Denominator of colinearity correlation vs. Pt min
+ TH1D *fPhi;
+ TH1D *fEta;
+
#ifdef __ROOT__
ClassDef(AliFemtoCorrFctnDEtaDPhi, 1)
#endif
virtual void Fill(const AliFemtoParticleCollection* aCollection) {AliFemtoCutMonitor::Fill(aCollection);}
virtual void Fill(const AliFemtoEvent* aEvent,const AliFemtoParticleCollection* aCollection)
{AliFemtoCutMonitor::Fill(aEvent, aCollection);}
+ virtual void Fill(const AliFemtoParticleCollection* aCollection1,const AliFemtoParticleCollection* aCollection2) {AliFemtoCutMonitor::Fill(aCollection1, aCollection2);}
void Write();
virtual void Fill(const AliFemtoParticleCollection* aCollection) {AliFemtoCutMonitor::Fill(aCollection);}
virtual void Fill(const AliFemtoEvent* aEvent,const AliFemtoParticleCollection* aCollection)
{AliFemtoCutMonitor::Fill(aEvent, aCollection);}
+ virtual void Fill(const AliFemtoParticleCollection* aCollection1,const AliFemtoParticleCollection* aCollection2) {AliFemtoCutMonitor::Fill(aCollection1, aCollection2);}
void Write();
virtual TList *GetOutputList();
virtual void Fill(const AliFemtoParticleCollection* aCollection) {AliFemtoCutMonitor::Fill(aCollection);}
virtual void Fill(const AliFemtoEvent* aEvent,const AliFemtoParticleCollection* aCollection)
{AliFemtoCutMonitor::Fill(aEvent, aCollection);}
+ virtual void Fill(const AliFemtoParticleCollection* aCollection1,const AliFemtoParticleCollection* aCollection2) {AliFemtoCutMonitor::Fill(aCollection1, aCollection2);}
void Write();
virtual void Fill(const AliFemtoParticleCollection* aCollection) {AliFemtoCutMonitor::Fill(aCollection);}
virtual void Fill(const AliFemtoEvent* aEvent,const AliFemtoParticleCollection* aCollection)
{AliFemtoCutMonitor::Fill(aEvent, aCollection);}
+ virtual void Fill(const AliFemtoParticleCollection* aCollection1,const AliFemtoParticleCollection* aCollection2) {AliFemtoCutMonitor::Fill(aCollection1, aCollection2);}
void Write();
virtual void Fill(const AliFemtoParticleCollection* aCollection) {AliFemtoCutMonitor::Fill(aCollection);}
virtual void Fill(const AliFemtoEvent* aEvent,const AliFemtoParticleCollection* aCollection)
{AliFemtoCutMonitor::Fill(aEvent, aCollection);}
+ virtual void Fill(const AliFemtoParticleCollection* aCollection1,const AliFemtoParticleCollection* aCollection2) {AliFemtoCutMonitor::Fill(aCollection1, aCollection2);}
void Write();
fMaxEEMinv(0.0),
fMaxDTheta(0.0),
fDTPCMin(0),
- fUseAOD(kFALSE)
+ fDataType(kESD)
{
}
//__________________
fMaxEEMinv(0.0),
fMaxDTheta(0.0),
fDTPCMin(0),
- fUseAOD(kFALSE)
+ fDataType(kESD)
{
fMaxEEMinv = c.fMaxEEMinv;
fMaxDTheta = c.fMaxDTheta;
fDTPCMin = c.fDTPCMin;
- fUseAOD = c.fUseAOD;
+ fDataType = c.fDataType;
}
AliFemtoPairCutAntiGamma& AliFemtoPairCutAntiGamma::operator=(const AliFemtoPairCutAntiGamma& c)
fMaxEEMinv = c.fMaxEEMinv;
fMaxDTheta = c.fMaxDTheta;
fDTPCMin = c.fDTPCMin;
- fUseAOD = c.fUseAOD;
+ fDataType = c.fDataType;
}
return *this;
// quality and sharity
bool temp = true;
+ if(fDataType==kKine)
+ return true;
+
double me = 0.000511;
if ((pair->Track1()->Track()->Charge() * pair->Track2()->Track()->Charge()) < 0.0) {
bool tempTPCEntrance = true;
- if(!fUseAOD)
+ if(fDataType==kAOD)
{
double distx = pair->Track1()->Track()->NominalTpcEntrancePoint().x() - pair->Track2()->Track()->NominalTpcEntrancePoint().x();
double disty = pair->Track1()->Track()->NominalTpcEntrancePoint().y() - pair->Track2()->Track()->NominalTpcEntrancePoint().y();
tempTPCEntrance = dist > fDTPCMin;
}
-
+
if (temp && tempTPCEntrance) {
temp = AliFemtoShareQualityPairCut::Pass(pair);
fDTPCMin = dtpc;
}
-void AliFemtoPairCutAntiGamma::SetUseAOD(Bool_t UseAOD)
+void AliFemtoPairCutAntiGamma::SetDataType(AliFemtoDataType type)
{
- fUseAOD = UseAOD;
+ fDataType = type;
}
class AliFemtoPairCutAntiGamma : public AliFemtoShareQualityPairCut{
public:
+ enum DataType {kESD=0, kAOD=1, kKine=2};
+ typedef enum DataType AliFemtoDataType;
+
AliFemtoPairCutAntiGamma();
AliFemtoPairCutAntiGamma(const AliFemtoPairCutAntiGamma& c);
virtual ~AliFemtoPairCutAntiGamma();
void SetMaxEEMinv(Double_t maxeeminv);
void SetMaxThetaDiff(Double_t maxdtheta);
void SetTPCEntranceSepMinimum(double dtpc);
- void SetUseAOD(Bool_t UseAOD);
+ void SetDataType(AliFemtoDataType type);
protected:
Double_t fMaxEEMinv; // Maximum allowed ee Minv
Double_t fMaxDTheta; // Maximum polar angle difference
Double_t fDTPCMin; // Minimum allowed pair nominal separation at the entrance to the TPC
- Bool_t fUseAOD; // Use AODs
-
+ AliFemtoDataType fDataType; //Use ESD / AOD / Kinematics.
#ifdef __ROOT__
ClassDef(AliFemtoPairCutAntiGamma, 0)
#pragma link C++ class AliTwoTrackRes+;
#pragma link C++ class AliFemtoMCTrackCut+;
#pragma link C++ class AliFemtoEventReaderKinematicsChain+;
-
+#pragma link C++ class AliFemtoV0TrackCut+;
+#pragma link C++ class AliFemtoV0PairCut+;
+#pragma link C++ class AliFemtoCutMonitorV0+;
+#pragma link C++ class AliFemtoV0TrackPairCut+;
+#pragma link C++ class AliFemtoCutMonitorCollections+;
#endif