//_____________________________________________________________________________
void AliTRDmcTrack::GetPxPyPz(Double_t& px, Double_t& py, Double_t& pz,
- Int_t opt = 0) const
+ Int_t opt) const
{
//
// Returns momentum components at the entrance (opt >= 0), or
//_____________________________________________________________________________
void AliTRDmcTrack::GetPlanePxPyPz(Double_t& px, Double_t& py, Double_t& pz,
- Int_t plane, Int_t opt = 0) const
+ Int_t plane, Int_t opt) const
{
//
// Returns momentum components at the entrance (opt >= 0), or
/*
$Log$
+Revision 1.1 2001/11/06 17:19:41 cblume
+Add detailed geometry and simple simulator
+
*/
///////////////////////////////////////////////////////////////////////////////
//
const Int_t kNpla = AliTRDgeometry::Nplan();
- Float_t charge[kNpla];
- Int_t nCluster[kNpla];
+ Float_t * charge = new Float_t[kNpla];
+ Int_t * nCluster = new Int_t[kNpla];
Float_t lhPi = 0;
Float_t lhEl = 0;
}
}
else {
+ delete [] charge;
+ delete [] nCluster;
return kTRUE;
}
pSum = pEl + pPi;
- if (pSum <= 0) return kFALSE;
+ if (pSum <= 0) {
+ delete [] charge;
+ delete [] nCluster;
+ return kFALSE;
+ }
lhEl = pEl / pSum;
lhPi = pPi / pSum;
// Assign the likelihoods
t->SetLikelihoodElectron(lhEl);
+ delete [] charge;
+ delete [] nCluster;
return kTRUE;
}
if (isnan(t->GetP())) return kFALSE;
- Float_t charge[kNpla];
- Int_t nCluster[kNpla];
+ Float_t * charge = new Float_t[kNpla];
+ Int_t * nCluster = new Int_t[kNpla];
Float_t mom = t->GetP();
Int_t ipid = MCpid(t);
TH1F *hTmp = NULL;
- if (!SumCharge(t,charge,nCluster)) return kFALSE;
+ if (!SumCharge(t,charge,nCluster)) {
+ delete [] charge;
+ delete [] nCluster;
+ return kFALSE;
+ }
Int_t index = GetIndex(mom,ipid);
if (index > -1) {
}
}
+ delete [] charge;
+ delete [] nCluster;
return kTRUE;
}
, const Float_t maxmom);
virtual Bool_t FillSpectra(const AliTRDtrack *t);
- inline Int_t GetIndex(const AliTRDtrack *t);
- inline Int_t GetIndex(const Int_t imom, const Int_t ipid);
- inline Int_t GetIndex(const Float_t mom, const Int_t ipid);
+ Int_t GetIndex(const AliTRDtrack *t);
+ Int_t GetIndex(const Int_t imom, const Int_t ipid);
+ Int_t GetIndex(const Float_t mom, const Int_t ipid);
TObjArray* GetHist() const { return fHist; };