ROOT logo
AliAnalysisTaskElecHadronCorrel* ConfigHFEElecHadronCorl(Bool_t useMC){
  //
  // HFE standard task configuration
  //

  Bool_t kAnalyseTaggedTracks = kTRUE;
  
  AliHFEcuts *hfecuts = new AliHFEcuts("hfeCutsEMCAL","HFE Standard Cuts");
  hfecuts->CreateStandardCuts();
  //hfecuts->SetTPCiter1(kTRUE);
  hfecuts->SetMinNClustersTPC(120);
  hfecuts->SetMinRatioTPCclusters(0.6);
  //hfecuts->SetTPCmodes(AliHFEextraCuts::kCrossedRows, AliHFEextraCuts::kFoundOverCR);
  hfecuts->SetTPCmodes(AliHFEextraCuts::kFound, AliHFEextraCuts::kFoundOverFindable);
  //hfecuts->SetUseMixedVertex(kTRUE);

  hfecuts->SetMinNClustersITS(3);
  hfecuts->SetCutITSpixel(AliHFEextraCuts::kAny); //shud be put back
  hfecuts->SetCheckITSLayerStatus(kFALSE); // shud be put back
//  hfecuts->UnsetVertexRequirement();
  hfecuts->SetVertexRange(10.);
  //hfecuts->SetSigmaToVertex(10);
  hfecuts->SetTOFPIDStep(kFALSE);
//  hfecuts->SetQAOn();
 hfecuts->SetPtRange(0, 30);
 hfecuts->SetMaxImpactParam(1,2);

  AliAnalysisTaskElecHadronCorrel *task = new AliAnalysisTaskElecHadronCorrel("HFE-hadron correlations");
  printf("task ------------------------ %p\n ", task);
  task->SetHFECuts(hfecuts);
  task->SetInvariantMassCut(0.05);
//  task->SetRemovePileUp(kTRUE);

  // Define PID
  AliHFEpid *pid = task->GetPID();
  if(useMC) pid->SetHasMCData(kTRUE);
  pid->AddDetector("TPC", 0);
  pid->AddDetector("EMCAL", 1);
  // change E/p cuts
  AliHFEpidEMCAL *emcpid = pid->AliHFEpid::GetDetPID(AliHFEpid::kEMCALpid);
  emcpid->SetEoPMax(1.2);
  emcpid->SetEoPMim(0.8);

  Double_t params[4];
  char *cutmodel;
  if(useMC){
	  // Monte-Carlo needs modelling of the falling mean with momentum at low momentum
	  // for high momentum it is consistent with a flat -0.94
	  cutmodel = "[0]*TMath::Exp([1]*x) + [2] + [3]*x";
	  Double_t paramsMC[4] = {0.7174, -1.588, -0.9395, 0.0246};
	  for(int ipar = 0; ipar < 4; ipar++) params[ipar] = paramsMC[ipar];
  } else {
	  // Data is consistent with a flat 0.12
	  cutmodel = "pol0";
	  //params[0] = -0.0015;
	  //params[0] = -3.0;
	  //params[0] = -0.05; //sigma min
	  params[0] = -1.0; //sigma min
  }
  pid->ConfigureTPCdefaultCut(cutmodel, params,3.0); 

  printf("*************************************\n");
  printf("Configuring standard Task:\n");
//  task->PrintStatus();
  pid->PrintStatus();
  printf("*************************************\n"); 
  return task;
}
 ConfigHFEElecHadronCorl.C:1
 ConfigHFEElecHadronCorl.C:2
 ConfigHFEElecHadronCorl.C:3
 ConfigHFEElecHadronCorl.C:4
 ConfigHFEElecHadronCorl.C:5
 ConfigHFEElecHadronCorl.C:6
 ConfigHFEElecHadronCorl.C:7
 ConfigHFEElecHadronCorl.C:8
 ConfigHFEElecHadronCorl.C:9
 ConfigHFEElecHadronCorl.C:10
 ConfigHFEElecHadronCorl.C:11
 ConfigHFEElecHadronCorl.C:12
 ConfigHFEElecHadronCorl.C:13
 ConfigHFEElecHadronCorl.C:14
 ConfigHFEElecHadronCorl.C:15
 ConfigHFEElecHadronCorl.C:16
 ConfigHFEElecHadronCorl.C:17
 ConfigHFEElecHadronCorl.C:18
 ConfigHFEElecHadronCorl.C:19
 ConfigHFEElecHadronCorl.C:20
 ConfigHFEElecHadronCorl.C:21
 ConfigHFEElecHadronCorl.C:22
 ConfigHFEElecHadronCorl.C:23
 ConfigHFEElecHadronCorl.C:24
 ConfigHFEElecHadronCorl.C:25
 ConfigHFEElecHadronCorl.C:26
 ConfigHFEElecHadronCorl.C:27
 ConfigHFEElecHadronCorl.C:28
 ConfigHFEElecHadronCorl.C:29
 ConfigHFEElecHadronCorl.C:30
 ConfigHFEElecHadronCorl.C:31
 ConfigHFEElecHadronCorl.C:32
 ConfigHFEElecHadronCorl.C:33
 ConfigHFEElecHadronCorl.C:34
 ConfigHFEElecHadronCorl.C:35
 ConfigHFEElecHadronCorl.C:36
 ConfigHFEElecHadronCorl.C:37
 ConfigHFEElecHadronCorl.C:38
 ConfigHFEElecHadronCorl.C:39
 ConfigHFEElecHadronCorl.C:40
 ConfigHFEElecHadronCorl.C:41
 ConfigHFEElecHadronCorl.C:42
 ConfigHFEElecHadronCorl.C:43
 ConfigHFEElecHadronCorl.C:44
 ConfigHFEElecHadronCorl.C:45
 ConfigHFEElecHadronCorl.C:46
 ConfigHFEElecHadronCorl.C:47
 ConfigHFEElecHadronCorl.C:48
 ConfigHFEElecHadronCorl.C:49
 ConfigHFEElecHadronCorl.C:50
 ConfigHFEElecHadronCorl.C:51
 ConfigHFEElecHadronCorl.C:52
 ConfigHFEElecHadronCorl.C:53
 ConfigHFEElecHadronCorl.C:54
 ConfigHFEElecHadronCorl.C:55
 ConfigHFEElecHadronCorl.C:56
 ConfigHFEElecHadronCorl.C:57
 ConfigHFEElecHadronCorl.C:58
 ConfigHFEElecHadronCorl.C:59
 ConfigHFEElecHadronCorl.C:60
 ConfigHFEElecHadronCorl.C:61
 ConfigHFEElecHadronCorl.C:62
 ConfigHFEElecHadronCorl.C:63
 ConfigHFEElecHadronCorl.C:64
 ConfigHFEElecHadronCorl.C:65
 ConfigHFEElecHadronCorl.C:66
 ConfigHFEElecHadronCorl.C:67
 ConfigHFEElecHadronCorl.C:68
 ConfigHFEElecHadronCorl.C:69