HMPID propagation factors added for priors
authorPietro Antonioli <Pietro.Antonioli@bo.infn.it>
Fri, 3 Jan 2014 10:43:47 +0000 (11:43 +0100)
committerPietro Antonioli <Pietro.Antonioli@bo.infn.it>
Fri, 3 Jan 2014 10:43:47 +0000 (11:43 +0100)
STEER/STEERBase/AliPIDCombined.cxx

index 974a430..761fb8d 100644 (file)
@@ -140,14 +140,20 @@ UInt_t AliPIDCombined::ComputeProbabilities(const AliVTrack *track, const AliPID
   memset(priors,0,fSelectedSpecies*sizeof(Double_t));
   if (fEnablePriors){
     GetPriors(track,priors,response->GetCurrentCentrality());
-    
-    // for the moment we have three cases
+
+    // We apply the propagation factors of the more external detector
+    // 
+    // TPC+HMPID    --> apply HMPID propagation factors (TRD and TOF may be present)
     // TPC+EMCAL    --> apply EMCAL propagation factors (TRD and TOF may be present)
-    // TPC+TOF      --> apply TOF propagation factors (TRD may be present)
-    // TPC+TRD      --> apply TRD propagation factors
+    // TPC+TOF      --> apply TOF propagation factors (TRD may be present, HMPID and EMCAL not (if requested))
+    // TPC+TRD      --> apply TRD propagation factors (TOF, HMPID and EMCAL not present (if requested) )
+    // 
     if(fUseDefaultTPCPriors) {
+
       Double_t pt=TMath::Abs(track->Pt());
-      if ( (usedMask & AliPIDResponse::kDetEMCAL)==AliPIDResponse::kDetEMCAL ) { // EMCAL is the outer having prop. factors for the moment
+      if ( ( (usedMask & AliPIDResponse::kDetEMCAL)==AliPIDResponse::kDetEMCAL) || ( (usedMask & AliPIDResponse::kDetHMPID)==AliPIDResponse::kDetHMPID) ) {
+      // we assume EMCAL and HMPID cannot be simultaneously present
+      if ( (usedMask & AliPIDResponse::kDetEMCAL)==AliPIDResponse::kDetEMCAL ) {
        // EMCal case (for the moment only in combination with TPC)
        // propagation factors determined from LHC11d MC (LHC12a15f)
        // v2 clusterizer, dEta < 0.015, dPhi < 0.03, NonLinearityFunction = 6
@@ -178,6 +184,30 @@ UInt_t AliPIDCombined::ComputeProbabilities(const AliVTrack *track, const AliPID
        priors[3] *= kaonEMCALfactor;
        priors[4] *= protonEMCALfactor;       
       } // end of EMCAL case
+
+      else if ( (usedMask & AliPIDResponse::kDetHMPID)==AliPIDResponse::kDetHMPID ) {  // HMPID case
+
+       Float_t kaonHMPIDfactor   = 0.;
+       Float_t protonHMPIDfactor = 0.;                     
+        if(pt>1. && pt<6.)  kaonHMPIDfactor   = (-0.0729337 + pt*0.0999531 - pt*pt*0.0371803 + pt*pt*pt*0.00706436 - pt*pt*pt*pt*0.000643619 + pt*pt*pt*pt*pt*2.21853e-05)/(-0.00896231+ pt*0.0330702 - pt*pt*0.0109562+ pt*pt*pt*0.00232895 - pt*pt*pt*pt*0.000246143 + pt*pt*pt*pt*pt*9.59812e-06); 
+        if(pt>1.4 && pt<6.) protonHMPIDfactor = (-0.0444188 + pt*0.0681506 - pt*pt*0.0231819 + pt*pt*pt*0.00400771 - pt*pt*pt*pt*0.000339315 + pt*pt*pt*pt*pt*1.12616e-05)/(-0.00896231+ pt*0.0330702 - pt*pt*0.0109562+ pt*pt*pt*0.00232895 - pt*pt*pt*pt*0.000246143 + pt*pt*pt*pt*pt*9.59812e-06);        
+        if(pt>6. && pt<8.)  kaonHMPIDfactor   = (-0.0729337 + pt*0.0999531 - pt*pt*0.0371803 + pt*pt*pt*0.00706436 - pt*pt*pt*pt*0.000643619 + pt*pt*pt*pt*pt*2.21853e-05)/0.0530456;        
+        if(pt>8.)           kaonHMPIDfactor   = 0.0550432/0.0530456; 
+        if(pt>6. && pt<8.5) protonHMPIDfactor = (-0.0444188 + pt*0.0681506 - pt*pt*0.0231819 + pt*pt*pt*0.00400771 - pt*pt*pt*pt*0.000339315 + pt*pt*pt*pt*pt*1.12616e-05)/0.0530456;      
+        if(pt>8.5)          protonHMPIDfactor = 0.0530071/0.0530456;       
+                                 
+        if(track->Charge() < 0){ 
+         if(pt>0.4 && pt<6.) protonHMPIDfactor = (-0.0351485 + pt*0.0473821 - pt*pt*0.0147947 + pt*pt*pt*0.00254811- pt*pt*pt*pt*0.000224724 + pt*pt*pt*pt*pt*7.9303e-06)/(-0.00896231+ pt*0.0330702 - pt*pt*0.0109562+ pt*pt*pt*0.00232895 - pt*pt*pt*pt*0.000246143 + pt*pt*pt*pt*pt*9.59812e-06);
+         if(pt>6. && pt<8.5) protonHMPIDfactor = (-0.0351485 + pt*0.0473821 - pt*pt*0.0147947 + pt*pt*pt*0.00254811- pt*pt*pt*pt*0.000224724 + pt*pt*pt*pt*pt*7.9303e-06)/0.0530456; 
+         if(pt>8.5)          protonHMPIDfactor = 0.0457756/0.0530456; 
+       } 
+      
+        priors[3] *= kaonHMPIDfactor;
+        priors[4] *= protonHMPIDfactor;
+               
+      }
+
+    } // end of outer cases: EMCAL/HMPID
       else if ( (usedMask & AliPIDResponse::kDetTOF) == AliPIDResponse::kDetTOF ){
        Float_t kaonTOFfactor = 0.1;
        if(pt > 0.35) kaonTOFfactor = 1 - TMath::Exp(-TMath::Power(pt,4.19618E-07)/5.68017E-01)*TMath::Power(pt,-1.50705);