X-Git-Url: http://git.uio.no/git/?a=blobdiff_plain;f=ITS%2FAliITStrackerMI.cxx;h=6c22ebf7c59ed63e9dc77f3ce961bd74bd24d2f0;hb=492ee96b5535db3c2339326e687ca140fb603684;hp=4ac015446a1f625352b49f2f52a49962eff60f11;hpb=421c4ba79a29c958ed72e9bdec9095470d582414;p=u%2Fmrichter%2FAliRoot.git diff --git a/ITS/AliITStrackerMI.cxx b/ITS/AliITStrackerMI.cxx index 4ac015446a1..6c22ebf7c59 100644 --- a/ITS/AliITStrackerMI.cxx +++ b/ITS/AliITStrackerMI.cxx @@ -877,7 +877,7 @@ Bool_t AliITStrackerMI::GetTrackPointTrackingError(Int_t index, detxy[1] = det.GetR()*TMath::Sin(det.GetPhi()); Double_t alpha = t->GetAlpha(); Double_t xdetintrackframe = detxy[0]*TMath::Cos(alpha)+detxy[1]*TMath::Sin(alpha); - Float_t phi = TMath::ASin(t->GetSnpAt(xdetintrackframe,GetBz())); + Float_t phi = TMath::ASin(t->GetSnpAt(xdetintrackframe+cl->GetX(),GetBz())); phi += alpha-det.GetPhi(); Float_t tgphi = TMath::Tan(phi); @@ -1045,7 +1045,7 @@ void AliITStrackerMI::FollowProlongationTree(AliITStrackMI * otrack, Int_t esdin if(LocalModuleCoord(ilayer,idet,vtrack,xloc,zloc)) { // local module coords vtrack->SetModuleIndexInfo(ilayer,idet,modstatus,xloc,zloc); } - if(constrain) vtrack->Improve(budgetToPrimVertex,xyzVtx,ersVtx); + if(constrain && AliITSReconstructor::GetRecoParam()->GetImproveWithVertex()) vtrack->Improve(budgetToPrimVertex,xyzVtx,ersVtx); ntracks[ilayer]++; continue; } @@ -1136,7 +1136,7 @@ void AliITStrackerMI::FollowProlongationTree(AliITStrackMI * otrack, Int_t esdin TMath::Abs(updatetrack->GetD(1)/(1.+ilayer)) > // z AliITSReconstructor::GetRecoParam()->GetMaxDZforPrimTrk()) isPrim=kFALSE; } - if (isPrim) updatetrack->Improve(budgetToPrimVertex,xyzVtx,ersVtx); + if (isPrim && AliITSReconstructor::GetRecoParam()->GetImproveWithVertex()) updatetrack->Improve(budgetToPrimVertex,xyzVtx,ersVtx); } updatetrack->SetNDeadZone(updatetrack->GetNDeadZone()+1); if (dead) { @@ -1246,7 +1246,7 @@ void AliITStrackerMI::FollowProlongationTree(AliITStrackMI * otrack, Int_t esdin TMath::Abs(updatetrack->GetD(1)/(1.+ilayer)) > // z AliITSReconstructor::GetRecoParam()->GetMaxDZforPrimTrk()) isPrim=kFALSE; } - if (isPrim) updatetrack->Improve(budgetToPrimVertex,xyzVtx,ersVtx); + if (isPrim && AliITSReconstructor::GetRecoParam()->GetImproveWithVertex()) updatetrack->Improve(budgetToPrimVertex,xyzVtx,ersVtx); } //apply vertex constrain ntracks[ilayer]++; } // create new hypothesis @@ -1264,7 +1264,7 @@ void AliITStrackerMI::FollowProlongationTree(AliITStrackMI * otrack, Int_t esdin vtrack->SetClIndex(ilayer,-1); modstatus = 3; // skipped vtrack->SetModuleIndexInfo(ilayer,idet,modstatus,xloc,zloc); - vtrack->Improve(budgetToPrimVertex,xyzVtx,ersVtx); + if(AliITSReconstructor::GetRecoParam()->GetImproveWithVertex()) vtrack->Improve(budgetToPrimVertex,xyzVtx,ersVtx); vtrack->IncrementNSkipped(); ntracks[ilayer]++; } @@ -3414,7 +3414,9 @@ AliITStrackMI * AliITStrackerMI::GetBestHypothesys(Int_t esdindex, AliITStrackMI backtrack = new(backtrack) AliITStrackMI(*track); if (track->GetConstrain()) { if (!CorrectForPipeMaterial(backtrack,"inward")) continue; - if (!backtrack->Improve(0,xyzVtx,ersVtx)) continue; + if (AliITSReconstructor::GetRecoParam()->GetImproveWithVertex()) { + if (!backtrack->Improve(0,xyzVtx,ersVtx)) continue; + } backtrack->ResetCovariance(10.); }else{ backtrack->ResetCovariance(10.); @@ -3742,15 +3744,15 @@ Double_t AliITStrackerMI::GetPredictedChi2MI(AliITStrackMI* track, const AliITSR // // Compute predicted chi2 // + // Take into account the mis-alignment (bring track to cluster plane) + Double_t xTrOrig=track->GetX(); + if (!track->Propagate(xTrOrig+cluster->GetX())) return 1000.; Float_t erry,errz,covyz; Float_t theta = track->GetTgl(); Float_t phi = track->GetSnp(); - phi = TMath::Abs(phi)*TMath::Sqrt(1./((1.-phi)*(1.+phi))); + phi *= TMath::Sqrt(1./((1.-phi)*(1.+phi))); AliITSClusterParam::GetError(layer,cluster,theta,phi,track->GetExpQ(),erry,errz,covyz); AliDebug(2,Form(" chi2: tr-cl %f %f tr X %f cl X %f",track->GetY()-cluster->GetY(),track->GetZ()-cluster->GetZ(),track->GetX(),cluster->GetX())); - // Take into account the mis-alignment (bring track to cluster plane) - Double_t xTrOrig=track->GetX(); - if (!track->Propagate(xTrOrig+cluster->GetX())) return 1000.; AliDebug(2,Form(" chi2: tr-cl %f %f tr X %f cl X %f",track->GetY()-cluster->GetY(),track->GetZ()-cluster->GetZ(),track->GetX(),cluster->GetX())); Double_t chi2 = track->GetPredictedChi2MI(cluster->GetY(),cluster->GetZ(),erry,errz,covyz); // Bring the track back to detector plane in ideal geometry @@ -4612,7 +4614,7 @@ Bool_t AliITStrackerMI::IsOKForPlaneEff(const AliITStrackMI* track, const Int_t tmp.GetClIndex(lay),((AliESDtrack*)tmp.GetESDtrack())->GetLabel())) ; if (tmp.GetClIndex(lay)>=0) ncl_in++; } - Int_t ncl=ncl_out+ncl_out; + Int_t ncl=ncl_out+ncl_in; Bool_t nextout = kFALSE; if(ilayer==AliITSgeomTGeo::kNLayers-1) nextout=kTRUE; // you are already on the outermost layer else nextout = ((tmp.GetClIndex(ilayer+1)>=0)? kTRUE : kFALSE );