fNtracks(0),
fSeeds(0),
fIteration(0),
- fParam(0),
+ fkParam(0),
fDebugStreamer(0)
{
//
track->SetRow((i&0x00ff0000)>>16);
track->SetSector(sec);
// Int_t index = i&0xFFFF;
- if (sec>=fParam->GetNInnerSector()) track->SetRow(track->GetRow()+fParam->GetNRowLow());
+ if (sec>=fkParam->GetNInnerSector()) track->SetRow(track->GetRow()+fkParam->GetNRowLow());
track->SetClusterIndex2(track->GetRow(), i);
//track->fFirstPoint = row;
//if ( track->fLastPoint<row) track->fLastPoint =row;
fNtracks(0),
fSeeds(0),
fIteration(0),
- fParam(0),
+ fkParam(0),
fDebugStreamer(0)
{
//---------------------------------------------------------------------
for (i=0; i<fkNIS; i++) fInnerSec[i].Setup(par,0);
for (i=0; i<fkNOS; i++) fOuterSec[i].Setup(par,1);
- fParam = par;
+ fkParam = par;
Int_t nrowlow = par->GetNRowLow();
Int_t nrowup = par->GetNRowUp();
fNtracks(0),
fSeeds(0),
fIteration(0),
- fParam(0),
+ fkParam(0),
fDebugStreamer(0)
{
//------------------------------------
//------------------------------------------------------------------
fOutput=t.fOutput;
}
-AliTPCtrackerMI & AliTPCtrackerMI::operator=(const AliTPCtrackerMI& /*r*/){
+AliTPCtrackerMI & AliTPCtrackerMI::operator=(const AliTPCtrackerMI& /*r*/)
+{
//------------------------------
// dummy
//--------------------------------------------------------------
}
-void AliTPCtrackerMI::FillESD(TObjArray* arr)
+void AliTPCtrackerMI::FillESD(const TObjArray* arr)
{
//
//
"Tr0.="<<pt<<
"\n";
}
- // pt->PropagateTo(fParam->GetInnerRadiusLow());
+ // pt->PropagateTo(fkParam->GetInnerRadiusLow());
if (pt->GetKinkIndex(0)<=0){ //don't propagate daughter tracks
- pt->PropagateTo(fParam->GetInnerRadiusLow());
+ pt->PropagateTo(fkParam->GetInnerRadiusLow());
}
if (( pt->GetPoints()[2]- pt->GetPoints()[0])>5 && pt->GetPoints()[3]>0.8){
-Double_t AliTPCtrackerMI::ErrY2(AliTPCseed* seed, AliTPCclusterMI * cl){
+Double_t AliTPCtrackerMI::ErrY2(AliTPCseed* seed, const AliTPCclusterMI * cl){
//
//
// Use calibrated cluster error from OCDB
//
AliTPCClusterParam * clparam = AliTPCcalibDB::Instance()->GetClusterParam();
//
- Float_t z = TMath::Abs(fParam->GetZLength(0)-TMath::Abs(seed->GetZ()));
+ Float_t z = TMath::Abs(fkParam->GetZLength(0)-TMath::Abs(seed->GetZ()));
Int_t ctype = cl->GetType();
Int_t type = (cl->GetRow()<63) ? 0: (cl->GetRow()>126) ? 1:2;
Double_t angle = seed->GetSnp()*seed->GetSnp();
// gnoise1 = 0.0004/padlength;
// Float_t nel = 0.268*amp;
// Float_t nprim = 0.155*amp;
-// ggg1[i] = fParam->GetDiffT()*fParam->GetDiffT()*(2+0.001*nel/(padlength*padlength))/nel;
+// ggg1[i] = fkParam->GetDiffT()*fkParam->GetDiffT()*(2+0.001*nel/(padlength*padlength))/nel;
// glandau1[i] = (2.+0.12*nprim)*0.5* (2.+nprim*nprim*0.001/(padlength*padlength))/nprim;
// if (glandau1[i]>1) glandau1[i]=1;
// glandau1[i]*=padlength*padlength/12.;
// gnoise2 = 0.0004/padlength;
// nel = 0.3*amp;
// nprim = 0.133*amp;
-// ggg2[i] = fParam->GetDiffT()*fParam->GetDiffT()*(2+0.0008*nel/(padlength*padlength))/nel;
+// ggg2[i] = fkParam->GetDiffT()*fkParam->GetDiffT()*(2+0.0008*nel/(padlength*padlength))/nel;
// glandau2[i] = (2.+0.12*nprim)*0.5*(2.+nprim*nprim*0.001/(padlength*padlength))/nprim;
// if (glandau2[i]>1) glandau2[i]=1;
// glandau2[i]*=padlength*padlength/12.;
// gnoise3 = 0.0004/padlength;
// nel = 0.3*amp;
// nprim = 0.133*amp;
-// ggg3[i] = fParam->GetDiffT()*fParam->GetDiffT()*(2+0.0008*nel/(padlength*padlength))/nel;
+// ggg3[i] = fkParam->GetDiffT()*fkParam->GetDiffT()*(2+0.0008*nel/(padlength*padlength))/nel;
// glandau3[i] = (2.+0.12*nprim)*0.5*(2.+nprim*nprim*0.001/(padlength*padlength))/nprim;
// if (glandau3[i]>1) glandau3[i]=1;
// glandau3[i]*=padlength*padlength/12.;
// return 1.;
// }
// Float_t snoise2;
-// Float_t z = TMath::Abs(fParam->GetZLength(0)-TMath::Abs(seed->GetZ()));
+// Float_t z = TMath::Abs(fkParam->GetZLength(0)-TMath::Abs(seed->GetZ()));
// Int_t ctype = cl->GetType();
// Float_t padlength= GetPadPitchLength(seed->GetRow());
// Double_t angle2 = seed->GetSnp()*seed->GetSnp();
-Double_t AliTPCtrackerMI::ErrZ2(AliTPCseed* seed, AliTPCclusterMI * cl){
+Double_t AliTPCtrackerMI::ErrZ2(AliTPCseed* seed, const AliTPCclusterMI * cl){
//
//
// Use calibrated cluster error from OCDB
//
AliTPCClusterParam * clparam = AliTPCcalibDB::Instance()->GetClusterParam();
//
- Float_t z = TMath::Abs(fParam->GetZLength(0)-TMath::Abs(seed->GetZ()));
+ Float_t z = TMath::Abs(fkParam->GetZLength(0)-TMath::Abs(seed->GetZ()));
Int_t ctype = cl->GetType();
Int_t type = (cl->GetRow()<63) ? 0: (cl->GetRow()>126) ? 1:2;
//
// gnoise1 = 0.0004/padlength;
// Float_t nel = 0.268*amp;
// Float_t nprim = 0.155*amp;
-// ggg1[i] = fParam->GetDiffT()*fParam->GetDiffT()*(2+0.001*nel/(padlength*padlength))/nel;
+// ggg1[i] = fkParam->GetDiffT()*fkParam->GetDiffT()*(2+0.001*nel/(padlength*padlength))/nel;
// glandau1[i] = (2.+0.12*nprim)*0.5* (2.+nprim*nprim*0.001/(padlength*padlength))/nprim;
// if (glandau1[i]>1) glandau1[i]=1;
// glandau1[i]*=padlength*padlength/12.;
// gnoise2 = 0.0004/padlength;
// nel = 0.3*amp;
// nprim = 0.133*amp;
-// ggg2[i] = fParam->GetDiffT()*fParam->GetDiffT()*(2+0.0008*nel/(padlength*padlength))/nel;
+// ggg2[i] = fkParam->GetDiffT()*fkParam->GetDiffT()*(2+0.0008*nel/(padlength*padlength))/nel;
// glandau2[i] = (2.+0.12*nprim)*0.5*(2.+nprim*nprim*0.001/(padlength*padlength))/nprim;
// if (glandau2[i]>1) glandau2[i]=1;
// glandau2[i]*=padlength*padlength/12.;
// gnoise3 = 0.0004/padlength;
// nel = 0.3*amp;
// nprim = 0.133*amp;
-// ggg3[i] = fParam->GetDiffT()*fParam->GetDiffT()*(2+0.0008*nel/(padlength*padlength))/nel;
+// ggg3[i] = fkParam->GetDiffT()*fkParam->GetDiffT()*(2+0.0008*nel/(padlength*padlength))/nel;
// glandau3[i] = (2.+0.12*nprim)*0.5*(2.+nprim*nprim*0.001/(padlength*padlength))/nprim;
// if (glandau3[i]>1) glandau3[i]=1;
// glandau3[i]*=padlength*padlength/12.;
// return 1.;
// }
// Float_t snoise2;
-// Float_t z = TMath::Abs(fParam->GetZLength(0)-TMath::Abs(seed->GetZ()));
+// Float_t z = TMath::Abs(fkParam->GetZLength(0)-TMath::Abs(seed->GetZ()));
// Int_t ctype = cl->GetType();
// Float_t padlength= GetPadPitchLength(seed->GetRow());
// //
//_____________________________________________________________________________
Double_t AliTPCtrackerMI::F1old(Double_t x1,Double_t y1,
Double_t x2,Double_t y2,
- Double_t x3,Double_t y3)
+ Double_t x3,Double_t y3) const
{
//-----------------------------------------------------------------
// Initial approximation of the track curvature
//_____________________________________________________________________________
Double_t AliTPCtrackerMI::F1(Double_t x1,Double_t y1,
Double_t x2,Double_t y2,
- Double_t x3,Double_t y3)
+ Double_t x3,Double_t y3) const
{
//-----------------------------------------------------------------
// Initial approximation of the track curvature
Double_t AliTPCtrackerMI::F2(Double_t x1,Double_t y1,
Double_t x2,Double_t y2,
- Double_t x3,Double_t y3)
+ Double_t x3,Double_t y3) const
{
//-----------------------------------------------------------------
// Initial approximation of the track curvature
//_____________________________________________________________________________
Double_t AliTPCtrackerMI::F2old(Double_t x1,Double_t y1,
Double_t x2,Double_t y2,
- Double_t x3,Double_t y3)
+ Double_t x3,Double_t y3) const
{
//-----------------------------------------------------------------
// Initial approximation of the track curvature times center of curvature
//_____________________________________________________________________________
Double_t AliTPCtrackerMI::F3(Double_t x1,Double_t y1,
Double_t x2,Double_t y2,
- Double_t z1,Double_t z2)
+ Double_t z1,Double_t z2) const
{
//-----------------------------------------------------------------
// Initial approximation of the tangent of the track dip angle
Double_t AliTPCtrackerMI::F3n(Double_t x1,Double_t y1,
Double_t x2,Double_t y2,
- Double_t z1,Double_t z2, Double_t c)
+ Double_t z1,Double_t z2, Double_t c) const
{
//-----------------------------------------------------------------
// Initial approximation of the tangent of the track dip angle
return kFALSE;
}
- Double_t c1=x[4]*x1 - x[2], r1=sqrt(1.- c1*c1);
- Double_t c2=x[4]*x2 - x[2], r2=sqrt(1.- c2*c2);
+ Double_t c1=x[4]*x1 - x[2], r1=sqrt((1.-c1)*(1.+c1));
+ Double_t c2=x[4]*x2 - x[2], r2=sqrt((1.-c2)*(1.+c2));
y = x[0];
z = x[1];
}
-Int_t AliTPCtrackerMI::LoadClusters(TObjArray *arr)
+Int_t AliTPCtrackerMI::LoadClusters(const TObjArray *arr)
{
//
// load clusters to the memory
//
Int_t sec,row;
- fParam->AdjustSectorRow(clrow->GetID(),sec,row);
+ fkParam->AdjustSectorRow(clrow->GetID(),sec,row);
for (Int_t icl=0; icl<clrow->GetArray()->GetEntriesFast(); icl++){
Transform((AliTPCclusterMI*)(clrow->GetArray()->At(icl)));
return 0;
}
-Int_t AliTPCtrackerMI::LoadClusters(TClonesArray *arr)
+Int_t AliTPCtrackerMI::LoadClusters(const TClonesArray *arr)
{
//
// load clusters to the memory from one
Int_t left=0;
if (sec<fkNIS*2){
left = sec/fkNIS;
- fInnerSec[sec%fkNIS].InsertCluster(clust, count[sec][row], fParam);
+ fInnerSec[sec%fkNIS].InsertCluster(clust, count[sec][row], fkParam);
}
else{
left = (sec-fkNIS*2)/fkNOS;
- fOuterSec[(sec-fkNIS*2)%fkNOS].InsertCluster(clust, count[sec][row], fParam);
+ fOuterSec[(sec-fkNIS*2)%fkNOS].InsertCluster(clust, count[sec][row], fkParam);
}
}
br->GetEntry(i);
//
Int_t sec,row;
- fParam->AdjustSectorRow(clrow->GetID(),sec,row);
+ fkParam->AdjustSectorRow(clrow->GetID(),sec,row);
for (Int_t icl=0; icl<clrow->GetArray()->GetEntriesFast(); icl++){
Transform((AliTPCclusterMI*)(clrow->GetArray()->At(icl)));
}
if (!transform) {
AliFatal("Tranformations not in calibDB");
}
+ transform->SetCurrentRecoParam((AliTPCRecoParam*)AliTPCReconstructor::GetRecoParam());
Double_t x[3]={cluster->GetRow(),cluster->GetPad(),cluster->GetTimeBin()};
Int_t i[1]={cluster->GetDetector()};
transform->Transform(x,i,0,1);
//
//
//
- //if (!fParam->IsGeoRead()) fParam->ReadGeoMatrices();
- TGeoHMatrix *mat = fParam->GetClusterMatrix(cluster->GetDetector());
+ //if (!fkParam->IsGeoRead()) fkParam->ReadGeoMatrices();
+ TGeoHMatrix *mat = fkParam->GetClusterMatrix(cluster->GetDetector());
//TGeoHMatrix mat;
Double_t pos[3]= {cluster->GetX(),cluster->GetY(),cluster->GetZ()};
Double_t posC[3]={cluster->GetX(),cluster->GetY(),cluster->GetZ()};
else
{
if (IsFindable(t))
- // if (TMath::Abs(z)<(AliTPCReconstructor::GetCtgRange()*x+10) && TMath::Abs(z)<fParam->GetZLength(0) && (TMath::Abs(t.GetSnp())<AliTPCReconstructor::GetMaxSnpTracker()))
+ // if (TMath::Abs(z)<(AliTPCReconstructor::GetCtgRange()*x+10) && TMath::Abs(z)<fkParam->GetZLength(0) && (TMath::Abs(t.GetSnp())<AliTPCReconstructor::GetMaxSnpTracker()))
t.SetNFoundable(t.GetNFoundable()+1);
else
return 0;
Int_t sector = (index&0xff000000)>>24;
// Int_t row = (index&0x00ff0000)>>16;
Float_t xyz[3];
- // xyz[0] = fParam->GetPadRowRadii(sector,row);
+ // xyz[0] = fkParam->GetPadRowRadii(sector,row);
xyz[0] = cl->GetX();
xyz[1] = cl->GetY();
xyz[2] = cl->GetZ();
Float_t sin,cos;
- fParam->AdjustCosSin(sector,cos,sin);
+ fkParam->AdjustCosSin(sector,cos,sin);
Float_t x = cos*xyz[0]-sin*xyz[1];
Float_t y = cos*xyz[1]+sin*xyz[0];
Float_t cov[6];
Float_t sigmaY2 = 0.027*cl->GetSigmaY2();
- if (sector < fParam->GetNInnerSector()) sigmaY2 *= 2.07;
+ if (sector < fkParam->GetNInnerSector()) sigmaY2 *= 2.07;
Float_t sigmaZ2 = 0.066*cl->GetSigmaZ2();
- if (sector < fParam->GetNInnerSector()) sigmaZ2 *= 1.77;
+ if (sector < fkParam->GetNInnerSector()) sigmaZ2 *= 1.77;
cov[0] = sin*sin*sigmaY2;
cov[1] = -sin*cos*sigmaY2;
cov[2] = 0.;
p.SetXYZ(x,y,xyz[2],cov);
AliGeomManager::ELayerID iLayer;
Int_t idet;
- if (sector < fParam->GetNInnerSector()) {
+ if (sector < fkParam->GetNInnerSector()) {
iLayer = AliGeomManager::kTPC1;
idet = sector;
}
else {
iLayer = AliGeomManager::kTPC2;
- idet = sector - fParam->GetNInnerSector();
+ idet = sector - fkParam->GetNInnerSector();
}
UShort_t volid = AliGeomManager::LayerToVolUID(iLayer,idet);
p.SetVolumeID(volid);
-void AliTPCtrackerMI::SignClusters(TObjArray * arr, Float_t fnumber, Float_t fdensity)
+void AliTPCtrackerMI::SignClusters(const TObjArray * arr, Float_t fnumber, Float_t fdensity)
{
//
//sign clusters to be "used"
}
-void AliTPCtrackerMI::StopNotActive(TObjArray * arr, Int_t row0, Float_t th0, Float_t th1, Float_t th2) const
+void AliTPCtrackerMI::StopNotActive(const TObjArray * arr, Int_t row0, Float_t th0, Float_t th1, Float_t th2) const
{
// stop not active tracks
// take th1 as threshold for number of founded to number of foundable on last 10 active rows
}
}
- seed->PropagateTo(fParam->GetInnerRadiusLow());
+ seed->PropagateTo(fkParam->GetInnerRadiusLow());
seed->UpdatePoints();
AddCovariance(seed);
MakeBitmaps(seed);
esd->UpdateTrackParams(seed,AliESDtrack::kTPCrefit);
esd->SetTPCPoints(seed->GetPoints());
esd->SetTPCPointsF(seed->GetNFoundable());
- Int_t ndedx = seed->GetNCDEDX(0)+seed->GetNCDEDX(1)+seed->GetNCDEDX(2)+seed->GetNCDEDX(3);
- Float_t sdedx = (seed->GetSDEDX(0)+seed->GetSDEDX(1)+seed->GetSDEDX(2)+seed->GetSDEDX(3))*0.25;
+ Int_t ndedx = seed->GetNCDEDX(0);
+ Float_t sdedx = seed->GetSDEDX(0);
Float_t dedx = seed->GetdEdx();
esd->SetTPCsignal(dedx, sdedx, ndedx);
//
esd->UpdateTrackParams(seed,AliESDtrack::kTPCout);
esd->SetTPCPoints(seed->GetPoints());
esd->SetTPCPointsF(seed->GetNFoundable());
- Int_t ndedx = seed->GetNCDEDX(0)+seed->GetNCDEDX(1)+seed->GetNCDEDX(2)+seed->GetNCDEDX(3);
- Float_t sdedx = (seed->GetSDEDX(0)+seed->GetSDEDX(1)+seed->GetSDEDX(2)+seed->GetSDEDX(3))*0.25;
+ Int_t ndedx = seed->GetNCDEDX(0);
+ Float_t sdedx = seed->GetSDEDX(0);
Float_t dedx = seed->GetdEdx();
esd->SetTPCsignal(dedx, sdedx, ndedx);
ntracks++;
Double_t x[5], c[15];
// Int_t di = i1-i2;
//
+ AliTPCseed * seed = new AliTPCseed();
Double_t alpha=fSectors->GetAlpha(), shift=fSectors->GetAlphaShift();
Double_t cs=cos(alpha), sn=sin(alpha);
- //
+ //
+ // Double_t x1 =fOuterSec->GetX(i1);
+ //Double_t xx2=fOuterSec->GetX(i2);
+
Double_t x1 =GetXrow(i1);
Double_t xx2=GetXrow(i2);
c[13]=f30*sy1*f40+f32*sy2*f42;
c[14]=f40*sy1*f40+f42*sy2*f42+f43*sy3*f43;
+ // if (!BuildSeed(kr1[is],kcl,0,x1,x2,x3,x,c)) continue;
UInt_t index=kr1.GetIndex(is);
- AliTPCseed track(x1, ns*alpha+shift, x, c, index);
+ seed->~AliTPCseed(); // this does not set the pointer to 0...
+ AliTPCseed *track=new(seed) AliTPCseed(x1, ns*alpha+shift, x, c, index);
- track.SetIsSeeding(kTRUE);
- track.SetSeed1(i1);
- track.SetSeed2(i2);
- track.SetSeedType(3);
+ track->SetIsSeeding(kTRUE);
+ track->SetSeed1(i1);
+ track->SetSeed2(i2);
+ track->SetSeedType(3);
//if (dsec==0) {
- FollowProlongation(track, (i1+i2)/2,1);
+ FollowProlongation(*track, (i1+i2)/2,1);
Int_t foundable,found,shared;
- track.GetClusterStatistic((i1+i2)/2,i1, found, foundable, shared, kTRUE);
- if ((found<0.55*foundable) || shared>0.5*found || (track.GetSigmaY2()+track.GetSigmaZ2())>0.5){
+ track->GetClusterStatistic((i1+i2)/2,i1, found, foundable, shared, kTRUE);
+ if ((found<0.55*foundable) || shared>0.5*found || (track->GetSigmaY2()+track->GetSigmaZ2())>0.5){
+ seed->Reset();
+ seed->~AliTPCseed();
continue;
}
//}
nin++;
- FollowProlongation(track, i2,1);
+ FollowProlongation(*track, i2,1);
//Int_t rc = 1;
- track.SetBConstrain(1);
+ track->SetBConstrain(1);
// track->fLastPoint = i1+fInnerSec->GetNRows(); // first cluster in track position
- track.SetLastPoint(i1); // first cluster in track position
- track.SetFirstPoint(track.GetLastPoint());
+ track->SetLastPoint(i1); // first cluster in track position
+ track->SetFirstPoint(track->GetLastPoint());
- if (track.GetNumberOfClusters()<(i1-i2)*0.5 ||
- track.GetNumberOfClusters() < track.GetNFoundable()*0.6 ||
- track.GetNShared()>0.4*track.GetNumberOfClusters() ) {
+ if (track->GetNumberOfClusters()<(i1-i2)*0.5 ||
+ track->GetNumberOfClusters() < track->GetNFoundable()*0.6 ||
+ track->GetNShared()>0.4*track->GetNumberOfClusters() ) {
+ seed->Reset();
+ seed->~AliTPCseed();
continue;
}
nout1++;
// Z VERTEX CONDITION
Double_t zv, bz=GetBz();
- if ( !track.GetZAt(0.,bz,zv) ) continue;
+ if ( !track->GetZAt(0.,bz,zv) ) continue;
if (TMath::Abs(zv-z3)>cuts[2]) {
- FollowProlongation(track, TMath::Max(i2-20,0));
- if ( track.GetZAt(0.,bz,zv) ) continue;
+ FollowProlongation(*track, TMath::Max(i2-20,0));
+ if ( !track->GetZAt(0.,bz,zv) ) continue;
if (TMath::Abs(zv-z3)>cuts[2]){
- // If track do not point to the primary vertex, but sufficientlu long
- //try to refit it without constrain
- //
- //
- FollowProlongation(track, TMath::Max(i2-40,0));
- if ( !track.GetZAt(0.,bz,zv) ) continue;
- if (TMath::Abs(zv-z3)>cuts[2] &&(track.GetNumberOfClusters() > track.GetNFoundable()*0.7)){
+ FollowProlongation(*track, TMath::Max(i2-40,0));
+ if ( !track->GetZAt(0.,bz,zv) ) continue;
+ if (TMath::Abs(zv-z3)>cuts[2] &&(track->GetNumberOfClusters() > track->GetNFoundable()*0.7)){
// make seed without constrain
- AliTPCseed * track2 = MakeSeed(&track,0.2,0.5,1.);
+ AliTPCseed * track2 = MakeSeed(track,0.2,0.5,1.);
FollowProlongation(*track2, i2,1);
track2->SetBConstrain(kFALSE);
track2->SetSeedType(1);
- arr->AddLast(track2->Clone());
+ arr->AddLast(track2);
+ seed->Reset();
+ seed->~AliTPCseed();
continue;
}
else{
- //seed->Reset();
- //seed->~AliTPCseed();
+ seed->Reset();
+ seed->~AliTPCseed();
continue;
-
+
}
}
}
- track.SetSeedType(0);
- arr->AddLast(track.Clone());
- //seed = new AliTPCseed;
+ track->SetSeedType(0);
+ arr->AddLast(track);
+ seed = new AliTPCseed;
nout2++;
// don't consider other combinations
- if (track.GetNumberOfClusters() > track.GetNFoundable()*0.8)
+ if (track->GetNumberOfClusters() > track->GetNFoundable()*0.8)
break;
}
}
if (fDebug>3){
Info("MakeSeeds3","\nSeeding statistic:\t%d\t%d\t%d\t%d\t%d\t%d",nin0,nin1,nin2,nin,nout1,nout2);
}
- // delete seed;
+ delete seed;
}
}
-AliTPCseed *AliTPCtrackerMI::ReSeed(AliTPCseed *track, Float_t r0, Float_t r1, Float_t r2)
+AliTPCseed *AliTPCtrackerMI::ReSeed(const AliTPCseed *track, Float_t r0, Float_t r1, Float_t r2)
{
//
//
-void AliTPCtrackerMI::FindMultiMC(TObjArray * array, AliESDEvent */*esd*/, Int_t iter)
+void AliTPCtrackerMI::FindMultiMC(const TObjArray * array, AliESDEvent */*esd*/, Int_t iter)
{
//
// find multi tracks - THIS FUNCTION IS ONLY FOR DEBUG PURPOSES
Int_t i0 = indexes[is0];
AliTPCseed * track0 = (AliTPCseed*)array->At(i0);
if (!track0) continue;
- if (track0->GetKinkIndexes()[0]!=0) continue;
Float_t xc0 = helixes[i0].GetHelix(6);
Float_t yc0 = helixes[i0].GetHelix(7);
Float_t fi0 = TMath::ATan2(yc0,xc0);
AliTPCseed * track1 = (AliTPCseed*)array->At(i1);
if (!track1) continue;
//
- if (TMath::Abs(track0->GetRelativeSector()-track1->GetRelativeSector())>1) continue;
- if (track1->GetKinkIndexes()[0]>0 &&track0->GetKinkIndexes()[0]<0) continue;
- if (track1->GetKinkIndexes()[0]!=0) continue;
+ Int_t dsec = TMath::Abs((track0->GetRelativeSector()%18)-(track1->GetRelativeSector()%18)); // sector distance
+ if (dsec>1 && dsec<17) continue;
+
+ if (track1->GetKinkIndexes()[0] == -track0->GetKinkIndexes()[0]) continue;
Float_t dtheta = TMath::Abs(track0->GetTgl()-track1->GetTgl())<TMath::Abs(track0->GetTgl()+track1->GetTgl())? track0->GetTgl()-track1->GetTgl():track0->GetTgl()+track1->GetTgl();
if (TMath::Abs(dtheta)>kMaxdTheta) continue;
Float_t fi1 = TMath::ATan2(yc1,xc1);
//
Float_t dfi = fi0-fi1;
- if (dfi>1.5*TMath::Pi()) dfi-=TMath::Pi(); // take care about edge effect
- if (dfi<-1.5*TMath::Pi()) dfi+=TMath::Pi(); //
+ if (dfi>TMath::Pi()) dfi-=TMath::TwoPi(); // take care about edge effect
+ if (dfi<-TMath::Pi()) dfi+=TMath::TwoPi(); //
if (TMath::Abs(dfi)>kMaxdPhi&&helixes[i0].GetHelix(4)*helixes[i1].GetHelix(4)<0){
//
// if short tracks with undefined sign
fi1 = -TMath::ATan2(yc1,-xc1);
dfi = fi0-fi1;
+ if (dfi>TMath::Pi()) dfi-=TMath::TwoPi(); // take care about edge effect
+ if (dfi<-TMath::Pi()) dfi+=TMath::TwoPi(); //
}
if (TMath::Abs(dfi)>kMaxdPhi) continue;
//
-void AliTPCtrackerMI::FindCurling(TObjArray * array, AliESDEvent */*esd*/, Int_t iter)
+void AliTPCtrackerMI::FindCurling(const TObjArray * array, AliESDEvent */*esd*/, Int_t iter)
{
//
// find Curling tracks
Float_t x[3] = { kink->GetPosition()[0],kink->GetPosition()[1],kink->GetPosition()[2]};
Int_t index[4];
- fParam->Transform0to1(x,index);
- fParam->Transform1to2(x,index);
+ fkParam->Transform0to1(x,index);
+ fkParam->Transform1to2(x,index);
row0 = GetRowNumber(x[0]);
if (kink->GetR()<100) continue;
timer.Print();
}
-void AliTPCtrackerMI::FindV0s(TObjArray * array, AliESDEvent *esd)
+void AliTPCtrackerMI::FindV0s(const TObjArray * array, AliESDEvent *esd)
{
//
// find V0s
if (!pt) continue;
if (!t.IsActive()) continue;
// follow prolongation to the first layer
- if ( (fSectors ==fInnerSec) || (t.GetFirstPoint()-fParam->GetNRowLow()>rfirst+1) )
+ if ( (fSectors ==fInnerSec) || (t.GetFirstPoint()-fkParam->GetNRowLow()>rfirst+1) )
FollowProlongation(t, rfirst+1);
}
if (!pt) continue;
if (nr==80) pt->UpdateReference();
if (!pt->IsActive()) continue;
- // if ( (fSectors ==fOuterSec) && (pt->fFirstPoint-fParam->GetNRowLow())<nr) continue;
+ // if ( (fSectors ==fOuterSec) && (pt->fFirstPoint-fkParam->GetNRowLow())<nr) continue;
if (pt->GetRelativeSector()>17) {
continue;
}
AliTPCseed *pt=(AliTPCseed*)arr->UncheckedAt(i);
if (!pt) continue;
if (!pt->IsActive()) continue;
- // if ((fSectors ==fOuterSec) && (pt->fFirstPoint-fParam->GetNRowLow())<nr) continue;
+ // if ((fSectors ==fOuterSec) && (pt->fFirstPoint-fkParam->GetNRowLow())<nr) continue;
if (pt->GetRelativeSector()>17) {
continue;
}
//
//
AliTPCClusterParam * clparam = AliTPCcalibDB::Instance()->GetClusterParam();
- Float_t zdrift = TMath::Abs((fParam->GetZLength(0)-TMath::Abs(seed->GetZ())));
- Int_t type = (seed->GetSector() < fParam->GetNSector()/2) ? 0: (row>126) ? 1:2;
+ Float_t zdrift = TMath::Abs((fkParam->GetZLength(0)-TMath::Abs(seed->GetZ())));
+ Int_t type = (seed->GetSector() < fkParam->GetNSector()/2) ? 0: (row>126) ? 1:2;
Double_t angulary = seed->GetSnp();
angulary = angulary*angulary/(1.-angulary*angulary);
Double_t angularz = seed->GetTgl()*seed->GetTgl()*(1.+angulary);
Double_t sigmaz = clparam->GetRMS0(1,type,zdrift,TMath::Sqrt(TMath::Abs(angularz)));
seed->SetCurrentSigmaY2(sigmay*sigmay);
seed->SetCurrentSigmaZ2(sigmaz*sigmaz);
- // Float_t sd2 = TMath::Abs((fParam->GetZLength(0)-TMath::Abs(seed->GetZ())))*fParam->GetDiffL()*fParam->GetDiffL();
-// // Float_t padlength = fParam->GetPadPitchLength(seed->fSector);
+ // Float_t sd2 = TMath::Abs((fkParam->GetZLength(0)-TMath::Abs(seed->GetZ())))*fkParam->GetDiffL()*fkParam->GetDiffL();
+// // Float_t padlength = fkParam->GetPadPitchLength(seed->fSector);
// Float_t padlength = GetPadPitchLength(row);
// //
-// Float_t sresy = (seed->GetSector() < fParam->GetNSector()/2) ? 0.2 :0.3;
+// Float_t sresy = (seed->GetSector() < fkParam->GetNSector()/2) ? 0.2 :0.3;
// seed->SetCurrentSigmaY2(sd2+padlength*padlength*angulary/12.+sresy*sresy);
// //
-// Float_t sresz = fParam->GetZSigma();
+// Float_t sresz = fkParam->GetZSigma();
// seed->SetCurrentSigmaZ2(sd2+padlength*padlength*angularz*angularz*(1+angulary)/12.+sresz*sresz);
/*
Float_t wy = GetSigmaY(seed);
Int_t firstpoint = 0;
Int_t lastpoint = 159;
AliTPCTrackerPoint *point;
+ AliTPCclusterMI *cluster;
for (int iter=firstpoint; iter<lastpoint; iter++) {
- point = t->GetTrackPoint(iter);
- if (point) {
+ // Change to cluster pointers to see if we have a cluster at given padrow
+ cluster = t->GetClusterPointer(iter);
+ if (cluster) {
t->SetClusterMapBit(iter, kTRUE);
+ point = t->GetTrackPoint(iter);
if (point->IsShared())
t->SetSharedMapBit(iter,kTRUE);
else
Float_t z = track.GetZ();
if (TMath::Abs(z)<(AliTPCReconstructor::GetCtgRange()*track.GetX()+kDeltaZ) &&
- TMath::Abs(z)<fParam->GetZLength(0) &&
+ TMath::Abs(z)<fkParam->GetZLength(0) &&
(TMath::Abs(track.GetSnp())<AliTPCReconstructor::GetMaxSnpTracker()))
return kTRUE;
return kFALSE;