new functions added
authorskowron <skowron@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 26 Apr 2004 22:08:00 +0000 (22:08 +0000)
committerskowron <skowron@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 26 Apr 2004 22:08:00 +0000 (22:08 +0000)
HBTAN/AliHBTPIDPurityFctns.cxx
HBTAN/AliHBTPIDPurityFctns.h
HBTAN/HBTAnalysisLinkDef.h

index 3625b3c1dc426b71d478f338c64b586cd1f2ab2e..4b7b913e10973eab9528d3611dbdddbe25be4f56 100644 (file)
@@ -19,6 +19,7 @@
 /******************************************************************/
 /******************************************************************/
 /******************************************************************/
 /******************************************************************/
 /******************************************************************/
 /******************************************************************/
+AliHBTQInvCorrelFctnPerfectPID f;
 
 ClassImp(AliHBTMonPIDPurityVsPtFctn)
 
 
 ClassImp(AliHBTMonPIDPurityVsPtFctn)
 
@@ -102,6 +103,7 @@ void AliHBTMonPIDPurityVsPtFctn::Rename(const Char_t * name)
      fResult->SetName(numstr);
      fResult->SetTitle(numstr);
    }
      fResult->SetName(numstr);
      fResult->SetTitle(numstr);
    }
+   
   if (fGood)
    {
      TString numstr = fName + " Good";
   if (fGood)
    {
      TString numstr = fName + " Good";
@@ -338,6 +340,242 @@ void AliHBTMonPIDContaminationVsPtFctn::Process(AliHBTParticle * track, AliHBTPa
 /******************************************************************/
 /******************************************************************/
 /******************************************************************/
 /******************************************************************/
 /******************************************************************/
 /******************************************************************/
+ClassImp(AliHBTQInvCorrelFctnPerfectPID)
+
+AliHBTQInvCorrelFctnPerfectPID::AliHBTQInvCorrelFctnPerfectPID(Int_t nbins, Double_t maxXval, Double_t minXval):
+ AliHBTTwoPairFctn1D(nbins,maxXval,minXval)
+{
+//ctor
+ fWriteNumAndDen = kTRUE;//change default behaviour
+ Rename("qinvcfprfctpid","Q_{inv} Correlation Function Perfect PID");
+}
+/*************************************************************/
+
+void AliHBTQInvCorrelFctnPerfectPID::ProcessSameEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair)
+{
+//Fills numerator
+  if (trackpair->Particle1()->GetPid() != partpair->Particle1()->GetPid()) return;
+  if (trackpair->Particle2()->GetPid() != partpair->Particle2()->GetPid()) return;
+
+  trackpair  = CheckPair(trackpair);
+  if (trackpair == 0x0) return;
+  partpair  = CheckPair(partpair);
+  if (partpair == 0x0) return;
+
+  fNumerator->Fill(trackpair->GetQInv());
+}
+
+/*************************************************************/
+void AliHBTQInvCorrelFctnPerfectPID::ProcessDiffEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair)
+{
+//Fills numerator
+  if (trackpair->Particle1()->GetPid() != partpair->Particle1()->GetPid()) return;
+  if (trackpair->Particle2()->GetPid() != partpair->Particle2()->GetPid()) return;
+
+  trackpair  = CheckPair(trackpair);
+  if (trackpair == 0x0) return;
+  partpair  = CheckPair(partpair);
+  if (partpair == 0x0) return;
+
+  fDenominator->Fill(trackpair->GetQInv());
+}
+/*************************************************************/
+
+TH1* AliHBTQInvCorrelFctnPerfectPID::GetResult()
+{
+ //returns the scaled ratio
+ delete fRatio;
+ fRatio = GetRatio(Scale());
+ return fRatio;
+}
+/*************************************************************/
+/******************************************************************/
+/******************************************************************/
+/******************************************************************/
+
+ClassImp(AliHBTWeightQInvCorrelFctnPerfectPID)
+
+AliHBTWeightQInvCorrelFctnPerfectPID::AliHBTWeightQInvCorrelFctnPerfectPID(Int_t nbins, Double_t maxXval, Double_t minXval):
+ AliHBTTwoPairFctn1D(nbins,maxXval,minXval)
+{
+//ctor
+ fWriteNumAndDen = kTRUE;//change default behaviour
+ Rename("wqinvcfprfctpid","Q_{inv} Weight Correlation Function Perfect PID");
+}
+/*************************************************************/
+
+void AliHBTWeightQInvCorrelFctnPerfectPID::ProcessSameEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair)
+{
+//Fills numerator
+  if (trackpair->Particle1()->GetPid() != partpair->Particle1()->GetPid()) return;
+  if (trackpair->Particle2()->GetPid() != partpair->Particle2()->GetPid()) return;
+
+  trackpair  = CheckPair(trackpair);
+  if (trackpair == 0x0) return;
+  partpair  = CheckPair(partpair);
+  if (partpair == 0x0) return;
+
+  fNumerator->Fill(trackpair->GetQInv(),partpair->GetWeight());
+}
+
+/*************************************************************/
+void AliHBTWeightQInvCorrelFctnPerfectPID::ProcessDiffEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair)
+{
+//Fills numerator
+  if (trackpair->Particle1()->GetPid() != partpair->Particle1()->GetPid()) return;
+  if (trackpair->Particle2()->GetPid() != partpair->Particle2()->GetPid()) return;
+
+  trackpair  = CheckPair(trackpair);
+  if (trackpair == 0x0) return;
+  partpair  = CheckPair(partpair);
+  if (partpair == 0x0) return;
+  
+  fDenominator->Fill(trackpair->GetQInv());
+}
+/*************************************************************/
+
+TH1* AliHBTWeightQInvCorrelFctnPerfectPID::GetResult()
+{
+ //returns the scaled ratio
+ delete fRatio;
+ fRatio = GetRatio(Scale());
+ return fRatio;
+}
+
+
+/******************************************************************/
+/******************************************************************/
+/******************************************************************/
+
+ClassImp(AliHBTWeightQOutSQideQLongFctnPerfectPID)
+
+AliHBTWeightQOutSQideQLongFctnPerfectPID::AliHBTWeightQOutSQideQLongFctnPerfectPID
+  (Int_t nXbins, Double_t maxXval, Double_t minXval,
+   Int_t nYbins, Double_t maxYval, Double_t minYval,
+   Int_t nZbins, Double_t maxZval, Double_t minZval):
+ AliHBTTwoPairFctn3D(nXbins,maxXval,minXval,nYbins,maxYval,minYval,nZbins,maxZval,minZval)
+{
+  //ctor
+  fWriteNumAndDen = kTRUE;//change default behaviour
+  Rename("wqoslprfctpid","Q_{out}-Q_{side}-Q_{long} Weight Fctn with perfect PID");
+}
+/*************************************************************/
+
+void AliHBTWeightQOutSQideQLongFctnPerfectPID::ProcessSameEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair)
+{
+//Fills numerator
+  if (trackpair->Particle1()->GetPid() != partpair->Particle1()->GetPid()) return;
+  if (trackpair->Particle2()->GetPid() != partpair->Particle2()->GetPid()) return;
+
+  trackpair  = CheckPair(trackpair);
+  if (trackpair == 0x0) return;
+  partpair  = CheckPair(partpair);
+  if (partpair == 0x0) return;
+
+  Double_t weight = partpair->GetWeight();
+  Double_t out = TMath::Abs(trackpair->GetQOutCMSLC());
+  Double_t side = TMath::Abs(trackpair->GetQSideCMSLC());
+  Double_t lon = TMath::Abs(trackpair->GetQLongCMSLC());
+  fNumerator->Fill(out,side,lon,weight);
+}
+/*************************************************************/
+
+void AliHBTWeightQOutSQideQLongFctnPerfectPID::ProcessDiffEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair)
+{
+//Fills numerator
+  if (trackpair->Particle1()->GetPid() != partpair->Particle1()->GetPid()) return;
+  if (trackpair->Particle2()->GetPid() != partpair->Particle2()->GetPid()) return;
+
+  trackpair  = CheckPair(trackpair);
+  if (trackpair == 0x0) return;
+  partpair  = CheckPair(partpair);
+  if (partpair == 0x0) return;
+
+  Double_t out = TMath::Abs(trackpair->GetQOutCMSLC());
+  Double_t side = TMath::Abs(trackpair->GetQSideCMSLC());
+  Double_t lon = TMath::Abs(trackpair->GetQLongCMSLC());
+  fDenominator->Fill(out,side,lon);
+}
+/******************************************************************/
+
+TH1* AliHBTWeightQOutSQideQLongFctnPerfectPID::GetResult()
+{
+ //returns the scaled ratio
+ delete fRatio;
+ fRatio = GetRatio(Scale());
+ return fRatio;
+}
+
+
+/******************************************************************/
+/******************************************************************/
+/******************************************************************/
+
+ClassImp(AliHBTQOutSQideQLongFctnPerfectPID)
+
+AliHBTQOutSQideQLongFctnPerfectPID::AliHBTQOutSQideQLongFctnPerfectPID
+   (Int_t nXbins, Double_t maxXval, Double_t minXval,
+    Int_t nYbins, Double_t maxYval, Double_t minYval,
+    Int_t nZbins, Double_t maxZval, Double_t minZval):
+ AliHBTTwoPairFctn3D(nXbins,maxXval,minXval,nYbins,maxYval,minYval,nZbins,maxZval,minZval)
+{
+  //ctor
+  fWriteNumAndDen = kTRUE;//change default behaviour
+  Rename("qoslprfctpid","Q_{out}-Q_{side}-Q_{long} Fctn with perfect PID");
+}
+/*************************************************************/
+
+void AliHBTQOutSQideQLongFctnPerfectPID::ProcessSameEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair)
+{
+//Fills numerator
+  if (trackpair->Particle1()->GetPid() != partpair->Particle1()->GetPid()) return;
+  if (trackpair->Particle2()->GetPid() != partpair->Particle2()->GetPid()) return;
+
+  trackpair  = CheckPair(trackpair);
+  if (trackpair == 0x0) return;
+  partpair  = CheckPair(partpair);
+  if (partpair == 0x0) return;
+  
+  Double_t out = TMath::Abs(trackpair->GetQOutCMSLC());
+  Double_t side = TMath::Abs(trackpair->GetQSideCMSLC());
+  Double_t lon = TMath::Abs(trackpair->GetQLongCMSLC());
+  fNumerator->Fill(out,side,lon);
+}
+/*************************************************************/
+
+void AliHBTQOutSQideQLongFctnPerfectPID::ProcessDiffEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair)
+{
+//Fills numerator
+  if (trackpair->Particle1()->GetPid() != partpair->Particle1()->GetPid()) return;
+  if (trackpair->Particle2()->GetPid() != partpair->Particle2()->GetPid()) return;
+
+  trackpair  = CheckPair(trackpair);
+  if (trackpair == 0x0) return;
+  partpair  = CheckPair(partpair);
+  if (partpair == 0x0) return;
+  
+  Double_t out = TMath::Abs(trackpair->GetQOutCMSLC());
+  Double_t side = TMath::Abs(trackpair->GetQSideCMSLC());
+  Double_t lon = TMath::Abs(trackpair->GetQLongCMSLC());
+  fDenominator->Fill(out,side,lon);
+}
+/******************************************************************/
+
+TH1* AliHBTQOutSQideQLongFctnPerfectPID::GetResult()
+{
+ //returns the scaled ratio
+ delete fRatio;
+ fRatio = GetRatio(Scale());
+ return fRatio;
+}
+
+/******************************************************************/
+/******************************************************************/
+/******************************************************************/
+
+
 
 ClassImp(AliHBTPairPIDProbVsQInvFctn)
 
 
 ClassImp(AliHBTPairPIDProbVsQInvFctn)
 
@@ -388,7 +626,7 @@ AliHBTPairPIDProbVsQOutSQideQLongFctn::AliHBTPairPIDProbVsQOutSQideQLongFctn(Int
   fWriteNumAndDen = kTRUE;//change default behaviour
   Rename("qoslpidpur","Pair PID Probablilty .vs. Q_{out}-Q_{side}-Q_{long} Fctn");
 }
   fWriteNumAndDen = kTRUE;//change default behaviour
   Rename("qoslpidpur","Pair PID Probablilty .vs. Q_{out}-Q_{side}-Q_{long} Fctn");
 }
-/***************1**********************************************/
+/*************************************************************/
 
 void AliHBTPairPIDProbVsQOutSQideQLongFctn::ProcessSameEventParticles(AliHBTPair* pair)
 {
 
 void AliHBTPairPIDProbVsQOutSQideQLongFctn::ProcessSameEventParticles(AliHBTPair* pair)
 {
index c5f8398778c11c1ec14aeb48e145adf84d06b323..2eaa36973275519e8dbb586dfaa96019c20240aa 100644 (file)
@@ -57,6 +57,86 @@ class AliHBTMonPIDContaminationVsPtFctn: public AliHBTMonTwoParticleFctn1D, publ
 };
 /*************************************************************************************/
 
 };
 /*************************************************************************************/
 
+class AliHBTQInvCorrelFctnPerfectPID: public AliHBTTwoPairFctn1D, public AliHBTCorrelFunction
+{
+//Q Invaraint Correlation Function
+//1D two particle function
+//Fills the function only for correctly reconstructed PID
+//Together with 
+ public:
+   AliHBTQInvCorrelFctnPerfectPID(Int_t nbins = 100, Double_t maxXval = 0.15, Double_t minXval = 0.0);
+   virtual ~AliHBTQInvCorrelFctnPerfectPID(){};
+   void ProcessSameEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair);
+   void ProcessDiffEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair);
+   TH1* GetResult();
+ protected:
+   Double_t GetValue(AliHBTPair* trackpair, AliHBTPair* /*partpair*/) const {return trackpair->GetQInv();}
+ private:
+   ClassDef(AliHBTQInvCorrelFctnPerfectPID,1)
+};
+
+/*************************************************************************************/
+
+class AliHBTWeightQInvCorrelFctnPerfectPID: public AliHBTTwoPairFctn1D, public AliHBTCorrelFunction
+{
+//Weight Q Invaraint Correlation Function
+//1D two particle function
+//Fills the function only for correctly reconstructed PID
+//Together with regular 
+ public:
+   AliHBTWeightQInvCorrelFctnPerfectPID(Int_t nbins = 100, Double_t maxXval = 0.15, Double_t minXval = 0.0);
+   virtual ~AliHBTWeightQInvCorrelFctnPerfectPID(){};
+   void ProcessSameEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair);
+   void ProcessDiffEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair);
+   TH1* GetResult();
+ protected:
+   Double_t GetValue(AliHBTPair* trackpair, AliHBTPair* /*partpair*/) const {return trackpair->GetQInv();}
+ private:
+   ClassDef(AliHBTWeightQInvCorrelFctnPerfectPID,1)
+};
+/*************************************************************************************/
+class AliHBTWeightQOutSQideQLongFctnPerfectPID: public AliHBTTwoPairFctn3D, public AliHBTCorrelFunction
+{
+
+  public:
+    AliHBTWeightQOutSQideQLongFctnPerfectPID(Int_t nXbins = 100, Double_t maxXval = 0.15, Double_t minXval = 0.0,
+                                            Int_t nYbins = 100, Double_t maxYval = 0.15, Double_t minYval = 0.0,
+                                            Int_t nZbins = 100, Double_t maxZval = 0.15, Double_t minZval = 0.0);
+    virtual  ~AliHBTWeightQOutSQideQLongFctnPerfectPID(){}
+
+    TH1* GetResult();
+    void ProcessSameEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair);
+    void ProcessDiffEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair);
+
+  protected:
+    void GetValues(AliHBTPair* /*trackpair*/, AliHBTPair* /*partpair*/, Double_t& /*x*/, Double_t& /*y*/, Double_t& /*z*/) const {}
+
+    ClassDef(AliHBTWeightQOutSQideQLongFctnPerfectPID,1)
+};
+
+/*************************************************************************************/
+class AliHBTQOutSQideQLongFctnPerfectPID: public AliHBTTwoPairFctn3D, public AliHBTCorrelFunction
+{
+
+  public:
+    AliHBTQOutSQideQLongFctnPerfectPID(Int_t nXbins = 100, Double_t maxXval = 0.15, Double_t minXval = 0.0,
+                                            Int_t nYbins = 100, Double_t maxYval = 0.15, Double_t minYval = 0.0,
+                                            Int_t nZbins = 100, Double_t maxZval = 0.15, Double_t minZval = 0.0);
+    virtual  ~AliHBTQOutSQideQLongFctnPerfectPID(){}
+
+    TH1* GetResult();
+    void ProcessSameEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair);
+    void ProcessDiffEventParticles(AliHBTPair* trackpair, AliHBTPair* partpair);
+
+  protected:
+    void GetValues(AliHBTPair* /*trackpair*/, AliHBTPair* /*partpair*/, Double_t& /*x*/, Double_t& /*y*/, Double_t& /*z*/) const {}
+
+    ClassDef(AliHBTQOutSQideQLongFctnPerfectPID,1)
+};
+
+
+/*************************************************************************************/
+
 class AliHBTPairPIDProbVsQInvFctn: public AliHBTOnePairFctn1D, public AliHBTCorrelFunction
 {
 //Q Invaraint Correlation Function
 class AliHBTPairPIDProbVsQInvFctn: public AliHBTOnePairFctn1D, public AliHBTCorrelFunction
 {
 //Q Invaraint Correlation Function
index 30deb03850310f5c742a24aa2dc5fd5299185944..4ab65f81fd7b56607763f91de660be3cc5f75cb9 100644 (file)
 
 #pragma link C++ class AliHBTMonPIDPurityVsPtFctn+;
 #pragma link C++ class AliHBTMonPIDContaminationVsPtFctn+;
 
 #pragma link C++ class AliHBTMonPIDPurityVsPtFctn+;
 #pragma link C++ class AliHBTMonPIDContaminationVsPtFctn+;
+#pragma link C++ class AliHBTQInvCorrelFctnPerfectPID+;
+#pragma link C++ class AliHBTWeightQInvCorrelFctnPerfectPID+;
+#pragma link C++ class AliHBTWeightQOutSQideQLongFctnPerfectPID+;
+#pragma link C++ class AliHBTQOutSQideQLongFctnPerfectPID+;
 #pragma link C++ class AliHBTPairPIDProbVsQInvFctn+;
 #pragma link C++ class AliHBTPairPIDProbVsQOutSQideQLongFctn+;
 
 #pragma link C++ class AliHBTPairPIDProbVsQInvFctn+;
 #pragma link C++ class AliHBTPairPIDProbVsQOutSQideQLongFctn+;