ROOT logo
/**************************************************************************
 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
 *                                                                        *
 * Author: The ALICE Off-line Project.                                    *
 * Contributors are mentioned in the code where appropriate.              *
 *                                                                        *
 * Permission to use, copy, modify and distribute this software and its   *
 * documentation strictly for non-commercial purposes is hereby granted   *
 * without fee, provided that the above copyright notice appears in all   *
 * copies and that both the copyright notice and this permission notice   *
 * appear in the supporting documentation. The authors make no claims     *
 * about the suitability of this software for any purpose. It is          *
 * provided "as is" without express or implied warranty.                  *
 **************************************************************************/

///////////////////////////////////////////////////////////////////////////////
//
//    Kalman filter based aligner:
//    Finds alignement constants for  two tracking volumes (by default ITS
//    and TPC)
//    Determines the inverse transformation of the second volume (TPC)
//    with respect to the first (ITS) (how to realign TPC to ITS)
//    by measuring the residual between the 2 tracks.
//    Additionally calculates some callibration parameters for TPC
//    Fit parameters are:
//    - 3 shifts, x,y,z
//    - 3 Cardan angles, psi, theta, phi (see definition in alignment docs),
//    - TPC drift velocity correction,
//    - TPC time offset correction.
//
//    Basic usage:
//    When aligning two volumes, at any given time a single instance of
//    the class should be active. The fit of the parameters is updated
//    by adding new data using one of the Add.... methods:
//
//    In collision events add an ESD event to update the fit (adds all tracks):
//
//        Bool_t AddESDevent( AliESDevent* pTrack );
//    
//    or add each individual track
//
//        AddESDtrack( AliESDtrack* pTrack );
//
//    For cosmic data, the assumption is that the tracking is done twice:
//    once global and once only ITS and the tracklets are saved inside
//    one AliESDEvent. The method
//
//        Bool_t AddCosmicEvent( AliESDEvent* pEvent );
//
//    then searches the event for matching tracklets and upon succes it updates.
//    One cosmic ideally triggers two updates: for the upper and lower half of
//    the cosmic (upper ITS tracklet+upper TPC tracklet, idem dito for lower)
//
//    by default give misalignment parameters for TPC as they appear to be.
//    TPC calibration parameters are always given as correction to values used in reco.
//
//    _________________________________________________________________________
//    Expert options:
//    look at AddESDevent() and AddCosmicEvent() to get the idea of how the
//    aligner works, it's safe to repeat the needed steps outside of the class,
//    only public methods are used.
//
//    Origin: Mikolaj Krzewicki, Nikhef, Mikolaj.Krzewicki@cern.ch
//
//////////////////////////////////////////////////////////////////////////////

#include <iostream>
#include <TObject.h>
#include <TMath.h>
#include <TMatrix.h>
#include <TVector.h>
#include <TVector3.h>
#include <TDecompLU.h>
#include <TArrayI.h>
#include <TObjArray.h>
#include <TH1D.h>
#include <TF1.h>

#include "AliESDtrack.h"
#include "AliESDEvent.h"
#include "AliExternalTrackParam.h"

#include "AliRelAlignerKalman.h"

ClassImp(AliRelAlignerKalman)

//______________________________________________________________________________
AliRelAlignerKalman::AliRelAlignerKalman():
    TObject(),
    fPTrackParam1(new AliExternalTrackParam()),
    fPTrackParam2(new AliExternalTrackParam()),
    fMagField(0.),
    fNMeasurementParams(4),
    fPX(new TVectorD( fgkNSystemParams )),
    fPXcov(new TMatrixDSym( fgkNSystemParams )),
    fPH(new TMatrixD( fNMeasurementParams, fgkNSystemParams )),
    fQ(1.e-15),
    fPMeasurement(new TVectorD( fNMeasurementParams )),
    fPMeasurementCov(new TMatrixDSym( fNMeasurementParams )),
    fPMeasurementPrediction(new TVectorD( fNMeasurementParams )),
    fOutRejSigmas(1.),
    fOutRejSigma2Median(5.),
    fYZOnly(kFALSE),
    fNumericalParanoia(kTRUE),
    fRejectOutliers(kTRUE),
    fRejectOutliersSigma2Median(kFALSE),
    fRequireMatchInTPC(kFALSE),
    fCuts(kFALSE),
    fMinPointsVol1(3),
    fMinPointsVol2(50),
    fMinPt(0.),
    fMaxPt(1.e100),
    fMaxMatchingAngle(0.1),
    fMaxMatchingDistance(10.),  //in cm
    fCorrectionMode(kFALSE),
    fNTracks(0),
    fNUpdates(0),
    fNOutliers(0),
    fNOutliersSigma2Median(0),
    fNMatchedCosmics(0),
    fNMatchedTPCtracklets(0),
    fNProcessedEvents(0),
    fTimeStamp(0),
    fRunNumber(0),
    fNMerges(0),
    fNMergesFailed(0),
    fTPCvd(2.64),
    fTPCZLengthA(2.4972500e02),
    fTPCZLengthC(2.4969799e02)
{
  //Default constructor
  for (Int_t i=0;i<fgkNSystemParams;i++) fDelta[i] = 1.e-6;
  for (Int_t i=0; i<4;i++){fResArrSigma2Median[i]=NULL;}
  Reset();
}

//______________________________________________________________________________
AliRelAlignerKalman::AliRelAlignerKalman(const AliRelAlignerKalman& a):
    TObject(static_cast<TObject>(a)),
    fPTrackParam1(new AliExternalTrackParam()),
    fPTrackParam2(new AliExternalTrackParam()),
    fMagField(a.fMagField),
    fNMeasurementParams(a.fNMeasurementParams),
    fPX(new TVectorD( *a.fPX )),
    fPXcov(new TMatrixDSym( *a.fPXcov )),
    fPH(new TMatrixD( fNMeasurementParams, fgkNSystemParams )),
    fQ(a.fQ),
    fPMeasurement(new TVectorD( fNMeasurementParams )),
    fPMeasurementCov(new TMatrixDSym( fNMeasurementParams )),
    fPMeasurementPrediction(new TVectorD( fNMeasurementParams )),
    fOutRejSigmas(a.fOutRejSigmas),
    fOutRejSigma2Median(a.fOutRejSigma2Median),
    fYZOnly(a.fYZOnly),
    fNumericalParanoia(a.fNumericalParanoia),
    fRejectOutliers(a.fRejectOutliers),
    fRejectOutliersSigma2Median(a.fRejectOutliersSigma2Median),
    fRequireMatchInTPC(a.fRequireMatchInTPC),
    fCuts(a.fCuts),
    fMinPointsVol1(a.fMinPointsVol1),
    fMinPointsVol2(a.fMinPointsVol2),
    fMinPt(a.fMinPt),
    fMaxPt(a.fMaxPt),
    fMaxMatchingAngle(a.fMaxMatchingAngle),
    fMaxMatchingDistance(a.fMaxMatchingDistance),  //in cm
    fCorrectionMode(a.fCorrectionMode),
    fNTracks(a.fNTracks),
    fNUpdates(a.fNUpdates),
    fNOutliers(a.fNOutliers),
    fNOutliersSigma2Median(a.fNOutliersSigma2Median),
    fNMatchedCosmics(a.fNMatchedCosmics),
    fNMatchedTPCtracklets(a.fNMatchedTPCtracklets),
    fNProcessedEvents(a.fNProcessedEvents),
    fTimeStamp(a.fTimeStamp),
    fRunNumber(a.fRunNumber),
    fNMerges(a.fNMerges),
    fNMergesFailed(a.fNMergesFailed),
    fTPCvd(a.fTPCvd),
    fTPCZLengthA(a.fTPCZLengthA),
    fTPCZLengthC(a.fTPCZLengthC)
{
  //copy constructor
  memcpy(fDelta,a.fDelta,fgkNSystemParams*sizeof(Double_t));

  //copy contents of the residuals array for sigma2median scheme
  for (Int_t i=0;i<4;i++)
  {
    if ((a.fResArrSigma2Median)[i]) 
    {
      fResArrSigma2Median[i] = new Double_t[fgkNtracksSigma2Median];
      memcpy(fResArrSigma2Median[i],(a.fResArrSigma2Median)[i],
             fgkNtracksSigma2Median*sizeof(Double_t));
    }
    else
      fResArrSigma2Median[i] = NULL;
  }
}

//______________________________________________________________________________
AliRelAlignerKalman& AliRelAlignerKalman::operator=(const AliRelAlignerKalman& a)
{
  //assignment operator
  if(&a == this) return *this;
  TObject::operator=(a);

  fMagField=a.fMagField;
  fNMeasurementParams=a.fNMeasurementParams;
  *fPX = *a.fPX;
  *fPXcov = *a.fPXcov;
  fQ=a.fQ;
  fOutRejSigmas=a.fOutRejSigmas;
  fOutRejSigma2Median=a.fOutRejSigma2Median;
  memcpy(fDelta,a.fDelta,fgkNSystemParams*sizeof(Double_t));
  fYZOnly=a.fYZOnly;
  fNumericalParanoia=a.fNumericalParanoia;
  fRejectOutliers=a.fRejectOutliers;
  fRejectOutliersSigma2Median=a.fRejectOutliersSigma2Median;
  fRequireMatchInTPC=a.fRequireMatchInTPC;
  fCuts=a.fCuts;
  fMinPointsVol1=a.fMinPointsVol1;
  fMinPointsVol2=a.fMinPointsVol2;
  fMinPt=a.fMinPt;
  fMaxPt=a.fMaxPt;
  fMaxMatchingAngle=a.fMaxMatchingAngle;
  fMaxMatchingDistance=a.fMaxMatchingDistance;  //in c;
  fCorrectionMode=a.fCorrectionMode;
  fNTracks=a.fNTracks;
  fNUpdates=a.fNUpdates;
  fNOutliers=a.fNOutliers;
  fNOutliersSigma2Median=a.fNOutliersSigma2Median;
  fNMatchedCosmics=a.fNMatchedCosmics;
  fNMatchedTPCtracklets=a.fNMatchedTPCtracklets;
  fNProcessedEvents=a.fNProcessedEvents;
  fTimeStamp=a.fTimeStamp;
  fRunNumber=a.fRunNumber;
  fNMerges=a.fNMerges;
  fTPCvd=a.fTPCvd;
  fTPCZLengthA=a.fTPCZLengthA;
  fTPCZLengthC=a.fTPCZLengthC;

  //copy contents of the residuals array for sigma2median scheme
  for (Int_t i=0;i<4;i++)
  {
    if ((a.fResArrSigma2Median)[i]) 
    {
      if (!(fResArrSigma2Median[i])) fResArrSigma2Median[i] = 
                                     new Double_t[fgkNtracksSigma2Median];
      memcpy(fResArrSigma2Median[i],(a.fResArrSigma2Median)[i],
             fgkNtracksSigma2Median*sizeof(Double_t));
    }
    else
      fResArrSigma2Median[i] = NULL;
  }
  return *this;
}

//______________________________________________________________________________
AliRelAlignerKalman::~AliRelAlignerKalman()
{
  //destructor
  delete fPTrackParam1;
  delete fPTrackParam2;
  delete fPX;
  delete fPXcov;
  delete fPH;
  delete fPMeasurement;
  delete fPMeasurementCov;
  for (Int_t i=0;i<4;i++) 
  {
    delete [] (fResArrSigma2Median[i]);
  }
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::AddESDevent( const AliESDEvent* pEvent )
{
  //Add all tracks in an ESD event

  fNProcessedEvents++; //update the counter
  
  Bool_t success=kFALSE;
  SetMagField( pEvent->GetMagneticField() );
  AliESDtrack* track=NULL;
  
  for (Int_t i=0; i<pEvent->GetNumberOfTracks(); i++)
  {
    track = pEvent->GetTrack(i);
    if (!track) continue;
    if ( ((track->GetStatus()&AliESDtrack::kTPCin)>0)&&
         ((track->GetStatus()&AliESDtrack::kITSrefit)>0)&&
         (track->GetNcls(0)>=fMinPointsVol1)&&
         (track->GetNcls(1)>=fMinPointsVol2) )
    { 
      success = ( AddESDtrack( track ) || success );
    }
  }
  if (success)
  {
    fTimeStamp = pEvent->GetTimeStamp();
    fRunNumber = pEvent->GetRunNumber();
  }
  return success;
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::AddESDtrack( const AliESDtrack* pTrack )
{
  //Adds a full track, returns true if results in a new estimate
  //  gets the inner TPC parameters from AliESDTrack::GetInnerParam()
  //  gets the outer ITS parameters from AliESDfriendTrack::GetITSout()

  const AliExternalTrackParam* pconstparamsITS = pTrack->GetOuterParam();
  if (!pconstparamsITS) return kFALSE;
  const AliExternalTrackParam* pconstparamsTPC = pTrack->GetInnerParam();
  if (!pconstparamsTPC) return kFALSE;
  
  //TPC part
  AliExternalTrackParam paramsTPC = (*pconstparamsTPC);
  paramsTPC.Rotate(pconstparamsITS->GetAlpha());
  paramsTPC.PropagateTo(pconstparamsITS->GetX(), fMagField);

  return (AddTrackParams(pconstparamsITS, &paramsTPC));
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::AddTrackParams( const AliExternalTrackParam* p1, const AliExternalTrackParam* p2 )
{
  //Update the estimate using new matching tracklets

  if (!SetTrackParams(p1, p2)) return kFALSE;
  return Update();
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::AddCosmicEvent( const AliESDEvent* pEvent )
{
  //Add an cosmic with separately tracked ITS and TPC parts, do trackmatching

  fNProcessedEvents++; //update the counter

  Bool_t success=kFALSE;
  TArrayI trackTArrITS(1);
  TArrayI trackTArrTPC(1);
  if (!FindCosmicTrackletNumbersInEvent( trackTArrITS, trackTArrTPC, pEvent )) return kFALSE;
  SetMagField( pEvent->GetMagneticField() );
  AliESDtrack* ptrack=NULL;
  const AliExternalTrackParam* pconstparams1;
  const AliExternalTrackParam* pconstparams2;
  AliExternalTrackParam params1;
  AliExternalTrackParam params2;
  
  ////////////////////////////////
  for (Int_t i=0;i<trackTArrITS.GetSize();i++)
  {
    //ITS track
    ptrack = pEvent->GetTrack(trackTArrITS[i]);
    pconstparams1 = ptrack->GetOuterParam();
    if (!pconstparams1) continue;
    params1 = *pconstparams1; //make copy to be safe
    
    //TPC track
    ptrack = pEvent->GetTrack(trackTArrTPC[i]);
    pconstparams2 = ptrack->GetInnerParam();
    if (!pconstparams2) continue;
    params2 = *pconstparams2; //make copy
    params2.Rotate(params1.GetAlpha());
    params2.PropagateTo( params1.GetX(), fMagField );

    if (!SetTrackParams( &params1, &params2 )) continue;
    
    //do some accounting and update
    if (Update())
      success = kTRUE;
    else
      continue;
  }
  fTimeStamp=pEvent->GetTimeStamp(); //always update timestamp even when no update performed
  fRunNumber=pEvent->GetRunNumber();
  return success;
}

//______________________________________________________________________________
void AliRelAlignerKalman::SetPoint2Track( Bool_t set )
{
  fNMeasurementParams = (set)?2:4;
  delete fPH;
  fPH = new TMatrixD( fNMeasurementParams, fgkNSystemParams );
  delete fPMeasurement;
  fPMeasurement = new TVectorD( fNMeasurementParams );
  delete fPMeasurementCov;
  fPMeasurementCov = new TMatrixDSym( fNMeasurementParams );
  delete fPMeasurementPrediction;
  fPMeasurementPrediction = new TVectorD( fNMeasurementParams );
  fYZOnly = set;
}

//______________________________________________________________________________
void AliRelAlignerKalman::Print(Option_t*) const
{
  //Print some useful info
  Double_t rad2deg = 180./TMath::Pi();
  printf("\nAliRelAlignerKalman\n");
  if (fCorrectionMode) printf("(Correction mode)\n");
  printf("  run: %i, timestamp: %i, magfield: %.3f\n", fRunNumber, fTimeStamp, fMagField);
  printf("  %i(-%i) inputs, %i(-%i) updates, %i(-%i) merges\n", fNTracks, fNOutliersSigma2Median, fNUpdates, fNOutliers, fNMerges, fNMergesFailed );
  printf("  psi(x):           % .3f ± (%.2f) mrad  |  % .3f ± (%.2f) deg\n",1e3*(*fPX)(0), 1e3*TMath::Sqrt((*fPXcov)(0,0)),(*fPX)(0)*rad2deg,TMath::Sqrt((*fPXcov)(0,0))*rad2deg);
  printf("  theta(y):         % .3f ± (%.2f) mrad  |  % .3f ± (%.2f) deg\n",1e3*(*fPX)(1), 1e3*TMath::Sqrt((*fPXcov)(1,1)),(*fPX)(1)*rad2deg,TMath::Sqrt((*fPXcov)(1,1))*rad2deg);
  printf("  phi(z):           % .3f ± (%.2f) mrad  |  % .3f ± (%.2f) deg\n",1e3*(*fPX)(2), 1e3*TMath::Sqrt((*fPXcov)(2,2)),(*fPX)(2)*rad2deg,TMath::Sqrt((*fPXcov)(2,2))*rad2deg);
  printf("  x:                % .3f ± (%.2f) micron\n", 1e4*(*fPX)(3), 1e4*TMath::Sqrt((*fPXcov)(3,3)));
  printf("  y:                % .3f ± (%.2f) micron\n", 1e4*(*fPX)(4), 1e4*TMath::Sqrt((*fPXcov)(4,4)));
  printf("  z:                % .3f ± (%.2f) micron\n", 1e4*(*fPX)(5), 1e4*TMath::Sqrt((*fPXcov)(5,5)));
  if (fgkNSystemParams>6) printf("  vd corr           % .5g ± (%.2g)    [ vd should be %.4g (was %.4g in reco) ]\n", (*fPX)(6), TMath::Sqrt((*fPXcov)(6,6)), (*fPX)(6)*fTPCvd, fTPCvd);
  if (fgkNSystemParams>7) printf("  t0                % .5g ± (%.2g) us  |  %.4g ± (%.2g) cm     [ t0_real = t0_rec+t0 ]\n",(*fPX)(7), TMath::Sqrt((*fPXcov)(7,7)), fTPCvd*(*fPX)(7), fTPCvd*TMath::Sqrt((*fPXcov)(7,7)));
  if (fgkNSystemParams>8) printf("  vd/dy             % .5f ± (%.2f) (cm/us)/m\n", (*fPX)(8), TMath::Sqrt((*fPXcov)(8,8)));
  printf("\n");
  return;
}

//______________________________________________________________________________
void AliRelAlignerKalman::PrintSystemMatrix()
{
  //Print the system matrix for this measurement
  printf("Kalman system matrix:\n");
  for ( Int_t i=0; i<fNMeasurementParams; i++ )
  {
    for ( Int_t j=0; j<fgkNSystemParams; j++ )
    {
      printf("% -2.2f  ", (*fPH)(i,j) );
    }//for i
    printf("\n");
  }//for j
  printf("\n");
  return;
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::SetTrackParams( const AliExternalTrackParam* exparam1, const AliExternalTrackParam* exparam2 )
{
  //Set the parameters, exparam1 will normally be ITS and exparam 2 tht TPC
  fNTracks++; //count added input sets

  //INPUT OUTLIER REJECTION
  if (fRejectOutliersSigma2Median && IsOutlierSigma2Median(exparam1,exparam2) ) return kFALSE;

  *fPTrackParam1 = *exparam1;
  *fPTrackParam2 = *exparam2;
  
  return kTRUE;
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::Update()
{
  //perform the update
  
  //if (fCalibrationMode) return UpdateCalibration();
  //if (fFillHistograms)
  //{
  //  if (!UpdateEstimateKalman()) return kFALSE;
  //  return UpdateCalibration(); //Update histograms only when update ok.
  //}
  //else return UpdateEstimateKalman();
  if (!PrepareMeasurement()) return kFALSE;
  if (!PrepareSystemMatrix()) return kFALSE;
  if (!PreparePrediction()) return kFALSE;
  return UpdateEstimateKalman();
}

//______________________________________________________________________________
void AliRelAlignerKalman::RotMat( TMatrixD &R, const TVectorD& angles )
{
  //Get Rotation matrix R given the Cardan angles psi, theta, phi (around x, y, z).
  Double_t sinpsi = TMath::Sin(angles(0));
  Double_t sintheta = TMath::Sin(angles(1));
  Double_t sinphi = TMath::Sin(angles(2));
  Double_t cospsi = TMath::Cos(angles(0));
  Double_t costheta = TMath::Cos(angles(1));
  Double_t cosphi = TMath::Cos(angles(2));

  R(0,0) = costheta*cosphi;
  R(0,1) = -costheta*sinphi;
  R(0,2) = sintheta;
  R(1,0) = sinpsi*sintheta*cosphi + cospsi*sinphi;
  R(1,1) = -sinpsi*sintheta*sinphi + cospsi*cosphi;
  R(1,2) = -costheta*sinpsi;
  R(2,0) = -cospsi*sintheta*cosphi + sinpsi*sinphi;
  R(2,1) = cospsi*sintheta*sinphi + sinpsi*cosphi;
  R(2,2) = costheta*cospsi;
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::PrepareMeasurement()
{
  //Calculate the residuals and their covariance matrix
  
    const Double_t* pararr1 = fPTrackParam1->GetParameter();
    const Double_t* pararr2 = fPTrackParam2->GetParameter();

    //Take the track parameters and calculate the input to the Kalman filter
    (*fPMeasurement)(0) = pararr2[0]-pararr1[0];
    (*fPMeasurement)(1) = pararr2[1]-pararr1[1];
    if (!fYZOnly)
    {
      (*fPMeasurement)(2) = pararr2[2]-pararr1[2];
      (*fPMeasurement)(3) = pararr2[3]-pararr1[3];
    }

    //the covariance
    const Double_t* parcovarr1 = fPTrackParam1->GetCovariance();
    const Double_t* parcovarr2 = fPTrackParam2->GetCovariance();
    (*fPMeasurementCov)(0,0)=parcovarr1[0];
    (*fPMeasurementCov)(0,1)=parcovarr1[1];
    (*fPMeasurementCov)(1,0)=parcovarr1[1];
    (*fPMeasurementCov)(1,1)=parcovarr1[2];
    (*fPMeasurementCov)(0,0)+=parcovarr2[0];
    (*fPMeasurementCov)(0,1)+=parcovarr2[1];
    (*fPMeasurementCov)(1,0)+=parcovarr2[1];
    (*fPMeasurementCov)(1,1)+=parcovarr2[2];
    if (!fYZOnly)
    {
      (*fPMeasurementCov)(0,2)=parcovarr1[3];
      (*fPMeasurementCov)(0,3)=parcovarr1[6];
      (*fPMeasurementCov)(1,2)=parcovarr1[4];
      (*fPMeasurementCov)(1,3)=parcovarr1[7];
      (*fPMeasurementCov)(2,0)=parcovarr1[3];
      (*fPMeasurementCov)(2,1)=parcovarr1[4];
      (*fPMeasurementCov)(2,2)=parcovarr1[5];
      (*fPMeasurementCov)(2,3)=parcovarr1[8];
      (*fPMeasurementCov)(3,0)=parcovarr1[6];
      (*fPMeasurementCov)(3,1)=parcovarr1[7];
      (*fPMeasurementCov)(3,2)=parcovarr1[8];
      (*fPMeasurementCov)(3,3)=parcovarr1[9];
      (*fPMeasurementCov)(0,2)+=parcovarr2[3];
      (*fPMeasurementCov)(0,3)+=parcovarr2[6];
      (*fPMeasurementCov)(1,2)+=parcovarr2[4];
      (*fPMeasurementCov)(1,3)+=parcovarr2[7];
      (*fPMeasurementCov)(2,0)+=parcovarr2[3];
      (*fPMeasurementCov)(2,1)+=parcovarr2[4];
      (*fPMeasurementCov)(2,2)+=parcovarr2[5];
      (*fPMeasurementCov)(2,3)+=parcovarr2[8];
      (*fPMeasurementCov)(3,0)+=parcovarr2[6];
      (*fPMeasurementCov)(3,1)+=parcovarr2[7];
      (*fPMeasurementCov)(3,2)+=parcovarr2[8];
      (*fPMeasurementCov)(3,3)+=parcovarr2[9];
    }
    
  //if (fApplyCovarianceCorrection)
  //  *fPMeasurementCov += *fPMeasurementCovCorr;
  return kTRUE;
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::PrepareSystemMatrix()
{
  //Calculate the system matrix for the Kalman filter
  //approximate the system using as reference the track in the first volume

  TVectorD z1( fNMeasurementParams );
  TVectorD z2( fNMeasurementParams );
  TVectorD x1( fgkNSystemParams );
  TVectorD x2( fgkNSystemParams );
  //get the derivatives
  for ( Int_t i=0; i<fgkNSystemParams; i++ )
  {
    x1 = *fPX;
    x2 = *fPX;
    x1(i) = x1(i) - fDelta[i]/(2.0);
    x2(i) = x2(i) + fDelta[i]/(2.0);
    if (!PredictMeasurement( z1, x1 )) return kFALSE;
    if (!PredictMeasurement( z2, x2 )) return kFALSE;
    for (Int_t j=0; j<fNMeasurementParams; j++ )
    {
      (*fPH)(j,i) = ( z2(j)-z1(j) ) / fDelta[i];
    }
  }
  return kTRUE;
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::PreparePrediction()
{
  //Prepare the prediction of the measurement using state vector
  return PredictMeasurement( (*fPMeasurementPrediction), (*fPX) );
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::PredictMeasurement( TVectorD& pred, const TVectorD& state )
{
  // Implements a system model for the Kalman fit
  // pred is [dy,dz,dsinphi,dtgl]
  // state is [psi,theta,phi,x,y,z,driftTPC,offsetTPC]
  // note: the measurement is in a local frame, so the prediction also has to be
  // note: state is the misalignment in global reference system

  if (fCorrectionMode)
  {
      AliExternalTrackParam track(*fPTrackParam2); //make a copy track
      if (!CorrectTrack( &track, state )) return kFALSE; //predict what the ideal track would be by applying correction
      
      const Double_t* oldparam = fPTrackParam2->GetParameter();
      const Double_t* newparam = track.GetParameter();

      //calculate the predicted residual
      pred(0) = oldparam[0] - newparam[0];
      pred(1) = oldparam[1] - newparam[1];
      if (!fYZOnly)
      {
        pred(2) = oldparam[2] - newparam[2];
        pred(3) = oldparam[3] - newparam[3];
      }
      return kTRUE;
  }
  else
  {
      AliExternalTrackParam track(*fPTrackParam1); //make a copy track
      if (!MisalignTrack( &track, state )) return kFALSE; //predict what the measured track would be by applying misalignment

      const Double_t* oldparam = fPTrackParam1->GetParameter();
      const Double_t* newparam = track.GetParameter();

      //calculate the predicted residual
      pred(0) = newparam[0] - oldparam[0];
      pred(1) = newparam[1] - oldparam[1];
      if (!fYZOnly)
      {
        pred(2) = newparam[2] - oldparam[2];
        pred(3) = newparam[3] - oldparam[3];
      }
      return kTRUE;
    }
  return kFALSE;
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::UpdateEstimateKalman()
{
  //Kalman estimation of noisy constants: in the model A=1
  //The arguments are (following the usual convention):
  //  fPX - the state vector (parameters)
  //  fPXcov - the state covariance matrix (parameter errors)
  //  fPMeasurement - measurement vector
  //  fPMeasurementCov - measurement covariance matrix
  //  fPH - measurement model matrix ( fPMeasurement = Hx + v ) v being measurement noise (error fR)

  TMatrixDSym identity(TMatrixDSym::kUnit, (*fPXcov));            //unit matrix

  //predict the state
  //(*fPXcov) = (*fPXcov) + fQ*identity;  //add some process noise (diagonal)

  // update prediction with measurement
  // calculate Kalman gain
  // K = PH/(HPH+fPMeasurementCov)
  TMatrixD pht( (*fPXcov), TMatrixD::kMultTranspose, (*fPH) );  //common factor (used twice)
  TMatrixD hpht( (*fPH), TMatrixD::kMult, pht );
  hpht += (*fPMeasurementCov);

  //shit happens so protect yourself!
//  if (fNumericalParanoia)
//  {
//    TDecompLU lu(hpht);
//    if (lu.Condition() > 1e12) return kFALSE;
//    lu.Invert(hpht);
//  }
//  else
//  {
    Double_t det=0.0;
    hpht.Invert(&det); //since the matrix is small...
    if (det < 2e-99) return kFALSE; //we need some sort of protection even in this case....
//  }
  //printf("KalmanUpdate: det(hpht): %.4g\n",det);

  TMatrixD k(pht, TMatrixD::kMult, hpht ); //compute K (hpht is already inverted)

  // update the state and its covariance matrix
  TVectorD xupdate(fgkNSystemParams);
  xupdate = k*((*fPMeasurement)-(*fPMeasurementPrediction));

  //SIMPLE OUTLIER REJECTION
  if ( IsOutlier( xupdate, (*fPXcov) ) && fRejectOutliers )
  {
    fNOutliers++;
    //printf("AliRelAlignerKalman: outlier\n");
    return kFALSE;
  }

  TMatrixD kh( k, TMatrixD::kMult, (*fPH) );
  TMatrixD ikh(fgkNSystemParams,fgkNSystemParams); //this is because for some reason TMatrixD::kAdd didn't work
  ikh = identity - kh;
  TMatrixD ikhp( ikh, TMatrixD::kMult, (*fPXcov) ); // (identity-KH)fPXcov
  if (!IsPositiveDefinite(ikhp)) return kFALSE;

  (*fPX) += xupdate;
  TMatrixDSymFromTMatrixD( (*fPXcov), ikhp ); //make the matrix completely symetrical

  fNUpdates++;

  return kTRUE;
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::IsOutlier( const TVectorD& update, const TMatrixDSym& covmatrix )
{
  //check whether an update is an outlier given the covariance matrix of the fit

  Bool_t is=kFALSE;
  for (Int_t i=0;i<fgkNSystemParams;i++)
  {
    if (covmatrix(i,i)<0.) return kTRUE; //if cov matrix has neg diagonals something went wrong
    is = (is) || (TMath::Abs(update(i)) > fOutRejSigmas*TMath::Sqrt((covmatrix)(i,i)));
  }
  return is;
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::IsOutlierSigma2Median( const AliExternalTrackParam* pITS, 
                                                   const AliExternalTrackParam* pTPC )
{
  //check if the input residuals are not too far off their median
  TVectorD vecDelta(4),vecMedian(4), vecRMS(4);
  TVectorD vecDeltaN(5);
  Double_t sign=(pITS->GetParameter()[1]>0)? 1.:-1.;
  vecDeltaN[4]=0;
  for (Int_t i=0;i<4;i++){
    vecDelta[i]=(pITS->GetParameter()[i]-pTPC->GetParameter()[i])*sign;
    (fResArrSigma2Median[i])[(fNTracks-1)%fgkNtracksSigma2Median]=vecDelta[i];
  }
  Int_t entries=(fNTracks<fgkNtracksSigma2Median)?fNTracks:fgkNtracksSigma2Median;
  for (Int_t i=0;i<fNMeasurementParams;i++){       //in point2trackmode just take the first 2 params (zy)
    vecMedian[i] = TMath::Median(entries,fResArrSigma2Median[i]);
    vecRMS[i]    = TMath::RMS(entries,fResArrSigma2Median[i]);
    vecDeltaN[i] = 0;
    if (vecRMS[i]>0.){
      vecDeltaN[i] = (vecDelta[i]-vecMedian[i])/vecRMS[i];
      vecDeltaN[4]+= TMath::Abs(vecDeltaN[i]);  //sum of abs residuals
    }
  }
  Bool_t outlier=kFALSE;
  if (fNTracks<3)  outlier=kTRUE;   //median and RMS still to be defined
  if ( vecDeltaN[4]/fNMeasurementParams>fOutRejSigma2Median) outlier=kTRUE;
  if (outlier) fNOutliersSigma2Median++;
  return outlier;
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::IsPositiveDefinite( const TMatrixD& mat ) const
{
  //check for positive definiteness

  for (Int_t i=0; i<mat.GetNcols(); i++)
  {
    if (mat(i,i)<=0.) return kFALSE;
  }

  if (!fNumericalParanoia) return kTRUE;

  TDecompLU lu(mat);
  return (lu.Decompose());
}

//______________________________________________________________________________
void AliRelAlignerKalman::TMatrixDSymFromTMatrixD( TMatrixDSym& matsym, const TMatrixD& mat )
{
  //Produce a valid symmetric matrix out of an almost symmetric TMatrixD

  for (Int_t i=0; i<mat.GetNcols(); i++)
  {
    matsym(i,i) = mat(i,i); //copy diagonal
    for (Int_t j=i+1; j<mat.GetNcols(); j++)
    {
      //copy the rest
      Double_t average = (mat(i,j)+mat(j,i))/2.;
      matsym(i,j)=average;
      matsym(j,i)=average;
    }
  }
  matsym.MakeValid();
  return;
}

//______________________________________________________________________________
void AliRelAlignerKalman::Angles( TVectorD &angles, const TMatrixD &rotmat )
{
  //Calculate the Cardan angles (psi,theta,phi) from rotation matrix
  //b = R*a
  angles(0) = TMath::ATan2( -rotmat(1,2), rotmat(2,2) );
  angles(1) = TMath::ASin( rotmat(0,2) );
  angles(2) = TMath::ATan2( -rotmat(0,1), rotmat(0,0) );
  return;
}

//______________________________________________________________________________
void AliRelAlignerKalman::PrintCorrelationMatrix()
{
  //Print the correlation matrix for the fitted parameters
  printf("Correlation matrix for system parameters:\n");
  for ( Int_t i=0; i<fgkNSystemParams; i++ )
  {
    for ( Int_t j=0; j<i+1; j++ )
    {
      if ((*fPXcov)(i,i)==0. || (*fPXcov)(j,j)==0.) printf("   NaN  ");
      else
        printf("% -1.3f  ", (*fPXcov)(i,j)/TMath::Sqrt( (*fPXcov)(i,i) * (*fPXcov)(j,j) ) );
    }//for j
    printf("\n");
  }//for i
  printf("\n");
  return;
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::FindCosmicTrackletNumbersInEvent( TArrayI& outITSindexTArr, TArrayI& outTPCindexTArr, const AliESDEvent* pEvent )
{
  //Find matching track segments in an event with tracks in TPC and ITS(standalone)

  //Sanity cuts on tracks + check which tracks are ITS which are TPC
  Int_t ntracks = pEvent->GetNumberOfTracks(); ////printf("number of tracks in event: %i\n", ntracks);
  fMagField = pEvent->GetMagneticField();
  if (ntracks<2)
  {
    //printf("TrackFinder: less than 2 tracks!\n");
    return kFALSE;
  }
  Float_t* phiArr = new Float_t[ntracks];
  Float_t* thetaArr = new Float_t[ntracks];
  Int_t* goodtracksArr = new Int_t[ntracks];
  Int_t* candidateTPCtracksArr = new Int_t[ntracks];
  Int_t* matchedITStracksArr = new Int_t[ntracks];
  Int_t* matchedTPCtracksArr = new Int_t[ntracks];
  Int_t* tracksArrITS = new Int_t[ntracks];
  Int_t* tracksArrTPC = new Int_t[ntracks];
  Int_t* nPointsArr = new Int_t[ntracks];
  Int_t nITStracks = 0;
  Int_t nTPCtracks = 0;
  Int_t nGoodTracks = 0;
  Int_t nCandidateTPCtracks = 0;
  Int_t nMatchedITStracks = 0;
  AliESDtrack* pTrack = NULL;
  Bool_t foundMatchTPC = kFALSE;

  //select and clasify tracks
  for (Int_t itrack=0; itrack < ntracks; itrack++)
  {
    pTrack = pEvent->GetTrack(itrack);
    if (!pTrack)
    {
      //std::cout<<"no track!"<<std::endl;
      continue;
    }
    if (fCuts)
    {
      if (pTrack->GetP()<fMinPt || pTrack->GetP()>fMaxPt) continue;
    }
    goodtracksArr[nGoodTracks]=itrack;
    Float_t phi = pTrack->GetAlpha()+TMath::ASin(pTrack->GetSnp());
    Float_t theta = 0.5*TMath::Pi()-TMath::ATan(pTrack->GetTgl());
    phiArr[nGoodTracks]=phi;
    thetaArr[nGoodTracks]=theta;

    //check if track is ITS
    Int_t nClsITS = pTrack->GetNcls(0);
    Int_t nClsTPC = pTrack->GetNcls(1);
    if ( ((pTrack->GetStatus()&AliESDtrack::kITSout)>0)&&
         !((pTrack->GetStatus()&AliESDtrack::kTPCin)>0)&&
         !(nClsITS<fMinPointsVol1) )  //enough points
    {
      tracksArrITS[nITStracks] = nGoodTracks;
      nITStracks++;
      nGoodTracks++;
      continue;
    }

    //check if track is TPC
    if ( ((pTrack->GetStatus()&AliESDtrack::kTPCin)>0)&&
         !(nClsTPC<fMinPointsVol2) )  //enough points
    {
      tracksArrTPC[nTPCtracks] = nGoodTracks;
      nTPCtracks++;
      nGoodTracks++;
      //printf("tracksArrTPC[%d]=%d, goodtracksArr[%d]=%d\n",nTPCtracks-1,tracksArrTPC[nTPCtracks-1],nGoodTracks-1,goodtracksArr[nGoodTracks-1]);
      continue;
    }
  }//for itrack   -   selection fo tracks

  //printf("TrackFinder: %d ITS | %d TPC out of %d tracks in event\n", nITStracks,nTPCtracks,ntracks);

  if ( nITStracks < 1 || nTPCtracks < 1 )
  {
    delete [] phiArr;
    delete [] thetaArr;
    delete [] goodtracksArr;
    delete [] matchedITStracksArr;
    delete [] candidateTPCtracksArr;
    delete [] matchedTPCtracksArr;
    delete [] tracksArrITS;
    delete [] tracksArrTPC;
    delete [] nPointsArr;
    return kFALSE;
  }

  //find matching in TPC
  if (nTPCtracks>1)  //if there is something to be matched, try and match it
  {
    Float_t min = 10000000.;
    for (Int_t itr1=0; itr1<nTPCtracks; itr1++)
    {
      for (Int_t itr2=itr1+1; itr2<nTPCtracks; itr2++)
      {
        Float_t deltatheta = TMath::Abs(TMath::Pi()-thetaArr[tracksArrTPC[itr1]]-thetaArr[tracksArrTPC[itr2]]);
        if (deltatheta > fMaxMatchingAngle) continue;
        Float_t deltaphi = TMath::Abs(TMath::Abs(phiArr[tracksArrTPC[itr1]]-phiArr[tracksArrTPC[itr2]])-TMath::Pi());
        if (deltaphi > fMaxMatchingAngle) continue;
        if (deltatheta+deltaphi<min) //only the best matching pair
        {
          min=deltatheta+deltaphi;
          candidateTPCtracksArr[0] = tracksArrTPC[itr1];  //store the index of track in goodtracksArr[]
          candidateTPCtracksArr[1] = tracksArrTPC[itr2];
          nCandidateTPCtracks = 2;
          foundMatchTPC = kTRUE;
          //printf("TrackFinder: Matching TPC tracks candidates:\n");
          //printf("TrackFinder: candidateTPCtracksArr[0]=%d\n",tracksArrTPC[itr1]);
          //printf("TrackFinder: candidateTPCtracksArr[1]=%d\n",tracksArrTPC[itr2]);
        }
      }
    }
  }//if nTPCtracks>1
  else //if nTPCtracks==1 - if nothing to match, take the only one we've got
  {
    candidateTPCtracksArr[0] = tracksArrTPC[0];
    nCandidateTPCtracks = 1;
    foundMatchTPC = kFALSE;
  }
  if (foundMatchTPC) fNMatchedTPCtracklets++;
  //if no match but the requirement is set return kFALSE
  if (fRequireMatchInTPC && !foundMatchTPC)
  {
    delete [] phiArr;
    delete [] thetaArr;
    delete [] goodtracksArr;
    delete [] candidateTPCtracksArr;
    delete [] matchedITStracksArr;
    delete [] matchedTPCtracksArr;
    delete [] tracksArrITS;
    delete [] tracksArrTPC;
    delete [] nPointsArr;
    //printf("TrackFinder: no match in TPC && required\n");
    return kFALSE;
  }

  //if no match and more than one track take all TPC tracks
  if (!fRequireMatchInTPC && !foundMatchTPC)
  {
    for (Int_t i=0;i<nTPCtracks;i++)
    {
      candidateTPCtracksArr[i] = tracksArrTPC[i];
    }
    nCandidateTPCtracks = nTPCtracks;
  }
  //printf("TrackFinder: nCandidateTPCtracks: %i\n", nCandidateTPCtracks);

  Double_t* minDifferenceArr = new Double_t[nCandidateTPCtracks];

  //find ITS matches for good TPC tracks
  Bool_t matchedITStracks=kFALSE;
  for (Int_t itpc=0;itpc<nCandidateTPCtracks;itpc++)
  {
    minDifferenceArr[nMatchedITStracks] = 10000000.;
    matchedITStracks=kFALSE;
    for (Int_t iits=0; iits<nITStracks; iits++)
    {
      AliESDtrack* itstrack = pEvent->GetTrack(goodtracksArr[tracksArrITS[iits]]);
      const AliExternalTrackParam* parits = itstrack->GetOuterParam();
      AliESDtrack* tpctrack = pEvent->GetTrack(goodtracksArr[candidateTPCtracksArr[itpc]]);
      const AliExternalTrackParam* tmp = tpctrack->GetInnerParam();
      AliExternalTrackParam partpc(*tmp);  //make a copy to avoid tampering with original params
      partpc.Rotate(parits->GetAlpha());
      partpc.PropagateTo(parits->GetX(),fMagField);
      Float_t dtgl = TMath::Abs(partpc.GetTgl()-parits->GetTgl());
      if (dtgl > fMaxMatchingAngle) continue;
      Float_t dsnp = TMath::Abs(partpc.GetSnp()-parits->GetSnp());
      if (dsnp > fMaxMatchingAngle) continue;
      Float_t dy = TMath::Abs(partpc.GetY()-parits->GetY());
      Float_t dz = TMath::Abs(partpc.GetZ()-parits->GetZ());
      if (TMath::Sqrt(dy*dy+dz*dz) > fMaxMatchingDistance) continue;
      if (dtgl+dsnp<minDifferenceArr[nMatchedITStracks]) //only the best matching pair
      {
        minDifferenceArr[nMatchedITStracks]=dtgl+dsnp;
        matchedITStracksArr[nMatchedITStracks] = tracksArrITS[iits];
        matchedTPCtracksArr[nMatchedITStracks] = candidateTPCtracksArr[itpc]; //this tells us minDifferenceArrwhich TPC track this ITS track belongs to
        //printf("TrackFinder: Matching ITS to TPC:\n");
        //printf("TrackFinder: minDifferenceArr[%i]=%.2f\n",nMatchedITStracks,minDifferenceArr[nMatchedITStracks]);
        //printf("TrackFinder: matchedITStracksArr[%i]=%i\n",nMatchedITStracks,matchedITStracksArr[nMatchedITStracks]);
        //printf("TrackFinder: matchedTPCtracksArr[%i]=%i\n",nMatchedITStracks,matchedTPCtracksArr[nMatchedITStracks]);
        matchedITStracks=kTRUE;;
      }
    }
    if (matchedITStracks) nMatchedITStracks++;
  }

  if (nMatchedITStracks==0) //no match in ITS
  {
    delete [] phiArr;
    delete [] thetaArr;
    delete [] minDifferenceArr;
    delete [] goodtracksArr;
    delete [] matchedITStracksArr;
    delete [] candidateTPCtracksArr;
    delete [] matchedTPCtracksArr;
    delete [] tracksArrITS;
    delete [] tracksArrTPC;
    delete [] nPointsArr;
    //printf("TrackFinder: No match in ITS\n");
    return kFALSE;
  }

  //printf("TrackFinder: nMatchedITStracks: %i\n",nMatchedITStracks);
  //we found a cosmic
  fNMatchedCosmics++;

  //Now we may have ended up with more matches than we want in the case there was
  //no TPC match and there were many TPC tracks
  //a cosmic in a scenario like this will only have produced 1 pair, the rest is garbage
  //so take only the best pair.
  //same applies when there are more matches than ITS tracks - means that one ITS track
  //matches more TPC tracks.
  if ((nMatchedITStracks>2 && !foundMatchTPC) || nMatchedITStracks>nITStracks)
  {
    Int_t imin = TMath::LocMin(nMatchedITStracks,minDifferenceArr);
    matchedITStracksArr[0] = matchedITStracksArr[imin];
    matchedTPCtracksArr[0] = matchedTPCtracksArr[imin];
    nMatchedITStracks = 1;
    //printf("TrackFinder: too many matches - take only the best one\n");
    //printf("TrackFinder: LocMin in matched its tracks: %d\n",imin);
    //printf("TrackFinder: matchedITStracksArr[0]=%d\n",matchedITStracksArr[0]);
    //printf("TrackFinder: matchedTPCtracksArr[0]=%d\n",matchedTPCtracksArr[0]);
  }

  ///////////////////////////////////////////////////////////////////////////
  outITSindexTArr.Set(nMatchedITStracks);
  outTPCindexTArr.Set(nMatchedITStracks);
  for (Int_t i=0;i<nMatchedITStracks;i++)
  {
    outITSindexTArr.AddAt( goodtracksArr[matchedITStracksArr[i]], i );
    outTPCindexTArr.AddAt( goodtracksArr[matchedTPCtracksArr[i]], i );
    //printf("TrackFinder: Fill the output\n");
    //printf("TrackFinder: matchedITStracksArr[%d]=%d\n",i,matchedITStracksArr[i]);
    //printf("TrackFinder: matchedTPCtracksArr[%d]=%d\n",i,matchedTPCtracksArr[i]);
  }
  //printf("TrackFinder: Size of outputarrays: %d, %d\n", outITSindexTArr.GetSize(), outTPCindexTArr.GetSize());
  ///////////////////////////////////////////////////////////////////////////

  delete [] phiArr;
  delete [] thetaArr;
  delete [] minDifferenceArr;
  delete [] goodtracksArr;
  delete [] candidateTPCtracksArr;
  delete [] matchedITStracksArr;
  delete [] matchedTPCtracksArr;
  delete [] tracksArrITS;
  delete [] tracksArrTPC;
  delete [] nPointsArr;
  return kTRUE;
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::CorrectTrack( AliExternalTrackParam* tr, const TVectorD& misal ) const
{
  //implements the system model -
  //applies correction for misalignment and calibration to track
  //track needs to be already propagated to the global reference plane

  Double_t x = tr->GetX();
  Double_t alpha = tr->GetAlpha();
  Double_t point[3],dir[3];
  tr->GetXYZ(point);
  tr->GetDirection(dir);
  TVector3 Point(point);
  TVector3 Dir(dir);
  
  //Apply corrections to track

  //Shift
  Point(0) -= misal(3); //add shift in x
  Point(1) -= misal(4); //add shift in y
  Point(2) -= misal(5); //add shift in z
  //Rotation
  TMatrixD rotmat(3,3);
  RotMat( rotmat, misal );
  Point = rotmat.T() * Point;
  Dir = rotmat * Dir;
  
  //TPC vdrift and T0 corrections
  TVector3 Point2; //second point of the track
  Point2 = Point + Dir;
  Double_t vdCorr = 1./misal(6);
  Double_t t0 = misal(7);
  Double_t vdY = 0.0;
  if (fgkNSystemParams>8) vdY = misal(8)/100.; //change over 100cm.

  //my model
  if (Point(2)>0)
  {
    //A-Side
    Point(2) = Point(2)   - (fTPCZLengthA-Point(2))  * (vdCorr-1.+vdY*Point(1)/fTPCvd)  - (fTPCvd*vdCorr+vdY*Point(1))*t0;
    Point2(2) = Point2(2) - (fTPCZLengthA-Point2(2)) * (vdCorr-1.+vdY*Point2(1)/fTPCvd) - (fTPCvd*vdCorr+vdY*Point2(1))*t0;
  }
  else
  {
    //C-side
    Point(2) = Point(2)   - (fTPCZLengthC+Point(2))  * (1.-vdCorr-vdY*Point(1)/fTPCvd)  + (fTPCvd*vdCorr+vdY*Point(1))*t0;
    Point2(2) = Point2(2) - (fTPCZLengthC+Point2(2)) * (1.-vdCorr-vdY*Point2(1)/fTPCvd) + (fTPCvd*vdCorr+vdY*Point2(1))*t0;
  }

  //Stefan's model
  //if (Point(2)>0)
  //{
  //  //A-Side
  //  Point(2) = Point(2)   - (fTPCZLengthA-Point(2))  * (1.-vdCorr+vdY*Point(1)/fTPCvd)  - (fTPCvd*vdCorr+vdY*Point(1))*t0;
  //  Point2(2) = Point2(2) - (fTPCZLengthA-Point2(2)) * (1.-vdCorr+vdY*Point2(1)/fTPCvd) - (fTPCvd*vdCorr+vdY*Point2(1))*t0;
  //}
  //else
  //{
  //  //C-side
  //  Point(2) = Point(2)   + (fTPCZLengthC+Point(2))  * (1.-vdCorr+vdY*Point(1)/fTPCvd)  + (fTPCvd*vdCorr+vdY*Point(1))*t0;
  //  Point2(2) = Point2(2) + (fTPCZLengthC+Point2(2)) * (1.-vdCorr+vdY*Point2(1)/fTPCvd) + (fTPCvd*vdCorr+vdY*Point2(1))*t0;
  //}

  Dir = Point2-Point;
  Dir=Dir.Unit(); //keep unit length

  //Turn back to local system
  Dir.GetXYZ(dir);
  Point.GetXYZ(point);
  tr->Global2LocalPosition(point,alpha);
  tr->Global2LocalPosition(dir,alpha);

  //Calculate new intersection point with ref plane
  Double_t p[5],pcov[15];
  if (dir[0]==0.0) return kFALSE;
  Double_t s=(x-point[0])/dir[0];
  p[0] = point[1]+s*dir[1];
  p[1] = point[2]+s*dir[2];
  Double_t pt = TMath::Sqrt(dir[0]*dir[0]+dir[1]*dir[1]);
  if (pt==0.0) return kFALSE;
  p[2] = dir[1]/pt;
  p[3] = dir[2]/pt;
  //insert everything back into track
  const Double_t* pcovtmp = tr->GetCovariance();
  p[4] = tr->GetSigned1Pt(); //copy the momentum
  memcpy(pcov,pcovtmp,15*sizeof(Double_t));
  tr->Set(x,alpha,p,pcov);
  return kTRUE;

  ////put params back into track and propagate to ref
  //Double_t p[5],pcov[15];
  //p[0] = point[1];
  //p[1] = point[2];
  //Double_t xnew = point[0];
  //Double_t pt = TMath::Sqrt(dir[0]*dir[0]+dir[1]*dir[1]);
  //if (pt==0.0) return kFALSE;
  //p[2] = dir[1]/pt;
  //p[3] = dir[2]/pt;
  //p[4] = tr->GetSigned1Pt(); //copy the momentum
  //const Double_t* pcovtmp = tr->GetCovariance();
  //memcpy(pcov,pcovtmp,15*sizeof(Double_t));
  //tr->Set(xnew,alpha,p,pcov);
  //return tr->PropagateTo(x,fMagField);
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::MisalignTrack( AliExternalTrackParam* tr, const TVectorD& misal ) const
{
  //implements the system model -
  //applies misalignment and miscalibration to reference track
  //trackparams have to be at the global reference plane

  Double_t x = tr->GetX();
  Double_t alpha = tr->GetAlpha();
  Double_t point[3],dir[3];
  tr->GetXYZ(point);
  tr->GetDirection(dir);
  TVector3 Point(point);
  TVector3 Dir(dir);
  
  //Apply misalignment to track
  
  //TPC vdrift and T0 corrections
  TVector3 Point2; //second point of the track
  Point2 = Point + Dir;
  Double_t vdCorr = 1./misal(6);
  Double_t t0 = misal(7);
  Double_t vdY = 0.0;
  if (fgkNSystemParams>8) vdY = misal(8)/100.; //change over 100cm.

  if (Point(2)>0)
  {
    //A-Side
    Point(2) = Point(2)   + ((fTPCZLengthA-Point(2))/(vdCorr*fTPCvd+vdY*Point(1)))
                          * (fTPCvd*(vdCorr-1.)+vdY*Point(1)) + fTPCvd*t0;
    Point2(2) = Point2(2) + ((fTPCZLengthA-Point2(2))/(vdCorr*fTPCvd+vdY*Point2(1)))
                          * (fTPCvd*(vdCorr-1.)+vdY*Point2(1)) + fTPCvd*t0;
  }
  else
  {
    //C-side
    Point(2) = Point(2)   + (fTPCZLengthC+Point(2))/(vdCorr*fTPCvd+vdY*Point(1))
                          * (fTPCvd*(1.-vdCorr)-vdY*Point(1)) - fTPCvd*t0;
    Point2(2) = Point2(2) + (fTPCZLengthC+Point2(2))/(vdCorr*fTPCvd+vdY*Point2(1))
                          * (fTPCvd*(1.-vdCorr)-vdY*Point2(1)) - fTPCvd*t0;
  }
  Dir = Point2-Point;
  Dir=Dir.Unit(); //keep unit length

  //Rotation
  TMatrixD rotmat(3,3);
  RotMat( rotmat, misal );
  Point = rotmat * Point;
  Dir = rotmat * Dir;
  //Shift
  Point(0) += misal(3); //add shift in x
  Point(1) += misal(4); //add shift in y
  Point(2) += misal(5); //add shift in z

  //Turn back to local system
  Dir.GetXYZ(dir);
  Point.GetXYZ(point);
  tr->Global2LocalPosition(point,alpha);
  tr->Global2LocalPosition(dir,alpha);

  //Calculate new intersection point with ref plane
  Double_t p[5],pcov[15];
  if (dir[0]==0.0) return kFALSE;
  Double_t s=(x-point[0])/dir[0];
  p[0] = point[1]+s*dir[1];
  p[1] = point[2]+s*dir[2];
  Double_t pt = TMath::Sqrt(dir[0]*dir[0]+dir[1]*dir[1]);
  if (pt==0.0) return kFALSE;
  p[2] = dir[1]/pt;
  p[3] = dir[2]/pt;
  //insert everything back into track
  const Double_t* pcovtmp = tr->GetCovariance();
  p[4] = tr->GetSigned1Pt(); //copy the momentum
  memcpy(pcov,pcovtmp,15*sizeof(Double_t));
  tr->Set(x,alpha,p,pcov);
  return kTRUE;

  ////put params back into track and propagate to ref
  //Double_t p[5];
  //Double_t pcov[15];
  //p[0] = point[1];
  //p[1] = point[2];
  //Double_t xnew = point[0];
  //Double_t pt = TMath::Sqrt(dir[0]*dir[0]+dir[1]*dir[1]);
  //if (pt==0.0) return kFALSE;
  //p[2] = dir[1]/pt;
  //p[3] = dir[2]/pt;
  //p[4] = tr->GetSigned1Pt(); //copy the momentum
  //const Double_t* pcovtmp = tr->GetCovariance();
  //memcpy(pcov,pcovtmp,15*sizeof(Double_t));
  //printf("x before: %.5f, after: %.5f\n",x, xnew);
  //printf("before: %.4f %.4f %.4f %.4f %.4f \n",tr->GetParameter()[0],tr->GetParameter()[1],tr->GetParameter()[2],tr->GetParameter()[3],tr->GetParameter()[4]);
  //printf("after:  %.4f %.4f %.4f %.4f %.4f \n",p[0],p[1],p[2],p[3],p[4]);
  //tr->Set(xnew,alpha,p,pcov);
  //return tr->PropagateTo(x,fMagField);
}

//______________________________________________________________________________
void AliRelAlignerKalman::Reset()
{
  //full reset to defaults
  fPX->Zero();
  (*fPX)(6)=1.;
  ResetCovariance();

  //initialize the differentials per parameter
  for (Int_t i=0;i<4;i++) 
  {
    delete [] (fResArrSigma2Median[i]);
  }
  fRejectOutliersSigma2Median=kFALSE;

  fNMatchedCosmics=0;
  fNMatchedTPCtracklets=0;
  fNUpdates=0;
  fNOutliers=0;
  fNTracks=0;
  fNProcessedEvents=0;
  fRunNumber=0;
  fTimeStamp=0;
}

//______________________________________________________________________________
void AliRelAlignerKalman::ResetCovariance( const Double_t number )
{
  //Resets the covariance to the default if arg=0 or resets the off diagonals
  //to zero and releases the diagonals by factor arg.
  if (number!=0.)
  {
    for (Int_t z=0;z<6;z++)
    {
      for (Int_t zz=0;zz<6;zz++)
      {
        if (zz==z) continue; //don't touch diagonals
        (*fPXcov)(zz,z) = 0.;
        (*fPXcov)(z,zz) = 0.;
      }
      (*fPXcov)(z,z) = (*fPXcov)(z,z) * number;
    }
  }
  else
  {
    //Resets the covariance of the fit to a default value
    fPXcov->Zero();
    (*fPXcov)(0,0) = .08*.08; //psi (rad)
    (*fPXcov)(1,1) = .08*.08; //theta (rad
    (*fPXcov)(2,2) = .08*.08; //phi (rad)
    (*fPXcov)(3,3) = .3*.3; //x (cm)
    (*fPXcov)(4,4) = .3*.3; //y (cm)
    (*fPXcov)(5,5) = .3*.3; //z (cm)
  }
  ResetTPCparamsCovariance(number); 
}

//______________________________________________________________________________
void AliRelAlignerKalman::ResetTPCparamsCovariance( const Double_t number )
{
  //Resets the covariance to the default if arg=0 or resets the off diagonals
  //to zero and releases the diagonals by factor arg.
  
  //release diagonals
  if (number==0.)
  {
    if (fgkNSystemParams>6) (*fPXcov)(6,6) = .1*.1;
    if (fgkNSystemParams>7) (*fPXcov)(7,7) = 1.*1.;
    if (fgkNSystemParams>8) (*fPXcov)(8,8) = .1*.1;
  }
  else
  {
    if (fgkNSystemParams>6) (*fPXcov)(6,6) = number * (*fPXcov)(6,6);
    if (fgkNSystemParams>7) (*fPXcov)(7,7) = number * (*fPXcov)(7,7);
    if (fgkNSystemParams>8) (*fPXcov)(8,8) = number * (*fPXcov)(8,8);
  }
  
  //set crossterms to zero
  for (Int_t i=0;i<fgkNSystemParams;i++)
  {
    for (Int_t j=6;j<fgkNSystemParams;j++) //TPC params
    {
      if (i==j) continue; //don't touch diagonals
      (*fPXcov)(i,j) = 0.;
      (*fPXcov)(j,i) = 0.;
    }
  }
}

//______________________________________________________________________________
Bool_t AliRelAlignerKalman::Merge( const AliRelAlignerKalman* al )
{
  //Merge two aligners
  
  if (!al) return kFALSE;
  if (al==this) return kTRUE;
  if (al->fNUpdates == 0) return kTRUE; //no point in merging with an empty one
  
  //store the pointers to current stuff
  TVectorD* pmes = fPMeasurement;
  TMatrixDSym* pmescov = fPMeasurementCov;
  TVectorD* pmespred = fPMeasurementPrediction;
  TMatrixD* ph = fPH;

  //make a unity system matrix
  TMatrixD tmp(fgkNSystemParams,fgkNSystemParams);
  fPH = new TMatrixD(TMatrixD::kUnit, tmp);

  //mesurement is the state of the new aligner
  fPMeasurement = al->fPX;
  fPMeasurementCov = al->fPXcov;

  //the mesurement prediction is the state
  fPMeasurementPrediction = fPX; //this is safe as fPX doesn't change until end
  
  //do the merging
  Bool_t success = UpdateEstimateKalman();
  
  //restore pointers to old stuff
  fPMeasurement = pmes;
  fPMeasurementCov = pmescov;
  fPMeasurementPrediction = pmespred;
  delete fPH;
  fPH = ph;

  //merge stats
  if (!success)    
  {
    fNMergesFailed++;
    //printf("AliRelAlignerKalman::Merge failed\n");
    return kFALSE; //no point in merging stats if merge not succesful
  }
  fNProcessedEvents += al->fNProcessedEvents;
  fNUpdates += al->fNUpdates;
  fNOutliers += al->fNOutliers;
  fNOutliersSigma2Median += al->fNOutliersSigma2Median;
  fNTracks += al->fNTracks;
  fNMatchedTPCtracklets += al->fNMatchedTPCtracklets;
  fNMatchedCosmics += al->fNMatchedCosmics;
  if (fNMerges==0 || al->fNMerges==0) fNMerges++;
  else fNMerges += al->fNMerges;
  if (fTimeStamp < al->fTimeStamp) fTimeStamp = al->fTimeStamp; //take the newer one

  return success;
}

//______________________________________________________________________________
Long64_t AliRelAlignerKalman::Merge( TCollection* list )
{
  //merge all aligners in the collection
  Long64_t numberOfMerges=0;
  AliRelAlignerKalman* alignerFromList;
  if (!list) return 0;
  TIter next(list);
  while ( (alignerFromList = dynamic_cast<AliRelAlignerKalman*>(next())) )
  {
    if (alignerFromList == this) continue;
    if (Merge(alignerFromList)) numberOfMerges++;
  }
  return numberOfMerges;
}

//______________________________________________________________________________
Int_t AliRelAlignerKalman::Compare(const TObject *obj) const
{
  if (this == obj) return 0;
  const AliRelAlignerKalman* aobj = dynamic_cast<const AliRelAlignerKalman*>(obj);
  if (!aobj) return 0;
  if (fTimeStamp < aobj->fTimeStamp) return -1;
  else if (fTimeStamp > aobj->fTimeStamp) return 1;
  else return 0;
}

//________________________________________________________________________
Int_t AliRelAlignerKalman::FindMatchingTracks(TObjArray& arrITS, TObjArray& arrTPC, AliESDEvent* pESD)
{
  //find matching tracks and return tobjarrays with the params
  
  Int_t ntracks = pESD->GetNumberOfTracks();
  Int_t* matchedArr = new Int_t[ntracks]; //storage for index of ITS track for which a match was found
  for (Int_t i=0;i<ntracks;i++)
  {
    matchedArr[i]=0;
  }

  Int_t iMatched=-1;
  for (Int_t i=0; i<ntracks; i++)
  {
    //get track1 and friend
    AliESDtrack* track1 = pESD->GetTrack(i);
    if (!track1) continue;

    if (track1->GetNcls(0) < fMinPointsVol1) continue;

    if (!( ( track1->IsOn(AliESDtrack::kITSrefit)) &&
           (!track1->IsOn(AliESDtrack::kTPCin)) )) continue;

    const AliESDfriendTrack* constfriendtrack1 = track1->GetFriendTrack();
    if (!constfriendtrack1) continue;
    AliESDfriendTrack friendtrack1(*constfriendtrack1);
    
    if (!friendtrack1.GetITSOut()) continue;
    AliExternalTrackParam params1(*(friendtrack1.GetITSOut()));

    Double_t bestd = 1000.; //best distance
    Bool_t newi = kTRUE; //whether we start with a new i
    for (Int_t j=0; j<ntracks; j++)
    {
      if (matchedArr[j]>0 && matchedArr[j]!=i) continue; //already matched, everything tried 
      //get track2 and friend
      AliESDtrack* track2 = pESD->GetTrack(j);
      if (!track2) continue;
      if (track1==track2) continue;
      //if ( ( ( track2->IsOn(AliESDtrack::kITSout)) &&
      //       (!track2->IsOn(AliESDtrack::kTPCin)) )) continue; //all but ITS standalone

      if (track2->GetNcls(0) != track1->GetNcls(0)) continue;
      if (track2->GetITSClusterMap() != track1->GetITSClusterMap()) continue;
      if (track2->GetNcls(1) < fMinPointsVol2) continue; //min 80 clusters in TPC
      if (track2->GetTgl() > 1.) continue; //acceptance
      //cut crossing tracks
      if (track2->GetOuterParam()->GetZ()*track2->GetInnerParam()->GetZ()<0) continue;
      if (track2->GetInnerParam()->GetX()>90) continue;
      if (TMath::Abs(track2->GetInnerParam()->GetZ())<10.) continue; //too close to membrane?


      if (!track2->GetInnerParam()) continue;
      AliExternalTrackParam params2(*(track2->GetInnerParam()));

      //bring to same reference plane
      if (!params2.Rotate(params1.GetAlpha())) continue;
      if (!params2.PropagateTo(params1.GetX(), pESD->GetMagneticField())) continue;

      //pt cut
      if (params2.Pt() < fMinPt) continue;

      const Double32_t*	p1 = params1.GetParameter();
      const Double32_t*	p2 = params2.GetParameter();

      //hard cuts
      Double_t dy = TMath::Abs(p2[0]-p1[0]);
      Double_t dz = TMath::Abs(p2[1]-p1[1]);
      Double_t dphi = TMath::Abs(p2[2]-p1[2]);
      Double_t dlam = TMath::Abs(p2[3]-p1[3]);
      if (dy > 2.0) continue;
      if (dz > 10.0) continue;
      if (dphi > 0.1 ) continue;
      if (dlam > 0.1 ) continue;

      //best match only
      Double_t d = TMath::Sqrt(dy*dy+dz*dz+dphi*dphi+dlam*dlam);
      if ( d >= bestd) continue;
      bestd = d;
      matchedArr[j]=i; //j-th track matches i-th (ITS) track
      if (newi) iMatched++; newi=kFALSE; //increment at most once per i
      if (arrITS[iMatched] && arrTPC[iMatched])
      {
        *(arrITS[iMatched]) = params1;
        *(arrTPC[iMatched]) = params2;
      }
      else
      {
        arrITS[iMatched] = new AliExternalTrackParam(params1);
        arrTPC[iMatched] = new AliExternalTrackParam(params2);
      }//else
    }//for j
  }//for i
  delete [] matchedArr;
  return iMatched;
}

//________________________________________________________________________
void AliRelAlignerKalman::SetRejectOutliersSigma2Median(const Bool_t set )
{
  //Sets up or destroys the memory hungry array to hold the statistics
  //for data rejection with median
  if (set)
  {
    for (Int_t i=0;i<4;i++) 
    {
      if (!fResArrSigma2Median[i]) fResArrSigma2Median[i] = 
                                   new Double_t[fgkNtracksSigma2Median];
    }
    fRejectOutliersSigma2Median = kTRUE;
  }//else
  else
  {
    // it probably doesn't make sense to delete the arrays, they are not streamed
    //if (fRejectOutliersSigma2Median)
    //for (Int_t i=0;i<4;i++) 
    //{
    //  delete [] (fResArrSigma2Median[i]);
    //}
    fRejectOutliersSigma2Median = kFALSE;
  }//if
}


Int_t AliRelAlignerKalman::CheckCovariance(){
  //
  // check covariance matrix
  // Return values:
  //         -1    - everything OK
  //          >=0  - index of "corrupted" element in the covariance matrix
  TMatrixDSym& mat =(*fPXcov);
  for (Int_t irow=0; irow<9; irow++){
    if (mat(irow,irow)<=0.) return  irow*9;
    for (Int_t icol=0; icol<irow; icol++){
      Double_t corel = mat(irow,irow)*mat(icol,icol);
      if (corel<=0.) return irow*9+icol;
      corel=mat(irow,icol)/TMath::Sqrt(corel);
      if (TMath::Abs(corel)>=1.) return irow*9+icol;
    }  
  }
  return -1;
}
 AliRelAlignerKalman.cxx:1
 AliRelAlignerKalman.cxx:2
 AliRelAlignerKalman.cxx:3
 AliRelAlignerKalman.cxx:4
 AliRelAlignerKalman.cxx:5
 AliRelAlignerKalman.cxx:6
 AliRelAlignerKalman.cxx:7
 AliRelAlignerKalman.cxx:8
 AliRelAlignerKalman.cxx:9
 AliRelAlignerKalman.cxx:10
 AliRelAlignerKalman.cxx:11
 AliRelAlignerKalman.cxx:12
 AliRelAlignerKalman.cxx:13
 AliRelAlignerKalman.cxx:14
 AliRelAlignerKalman.cxx:15
 AliRelAlignerKalman.cxx:16
 AliRelAlignerKalman.cxx:17
 AliRelAlignerKalman.cxx:18
 AliRelAlignerKalman.cxx:19
 AliRelAlignerKalman.cxx:20
 AliRelAlignerKalman.cxx:21
 AliRelAlignerKalman.cxx:22
 AliRelAlignerKalman.cxx:23
 AliRelAlignerKalman.cxx:24
 AliRelAlignerKalman.cxx:25
 AliRelAlignerKalman.cxx:26
 AliRelAlignerKalman.cxx:27
 AliRelAlignerKalman.cxx:28
 AliRelAlignerKalman.cxx:29
 AliRelAlignerKalman.cxx:30
 AliRelAlignerKalman.cxx:31
 AliRelAlignerKalman.cxx:32
 AliRelAlignerKalman.cxx:33
 AliRelAlignerKalman.cxx:34
 AliRelAlignerKalman.cxx:35
 AliRelAlignerKalman.cxx:36
 AliRelAlignerKalman.cxx:37
 AliRelAlignerKalman.cxx:38
 AliRelAlignerKalman.cxx:39
 AliRelAlignerKalman.cxx:40
 AliRelAlignerKalman.cxx:41
 AliRelAlignerKalman.cxx:42
 AliRelAlignerKalman.cxx:43
 AliRelAlignerKalman.cxx:44
 AliRelAlignerKalman.cxx:45
 AliRelAlignerKalman.cxx:46
 AliRelAlignerKalman.cxx:47
 AliRelAlignerKalman.cxx:48
 AliRelAlignerKalman.cxx:49
 AliRelAlignerKalman.cxx:50
 AliRelAlignerKalman.cxx:51
 AliRelAlignerKalman.cxx:52
 AliRelAlignerKalman.cxx:53
 AliRelAlignerKalman.cxx:54
 AliRelAlignerKalman.cxx:55
 AliRelAlignerKalman.cxx:56
 AliRelAlignerKalman.cxx:57
 AliRelAlignerKalman.cxx:58
 AliRelAlignerKalman.cxx:59
 AliRelAlignerKalman.cxx:60
 AliRelAlignerKalman.cxx:61
 AliRelAlignerKalman.cxx:62
 AliRelAlignerKalman.cxx:63
 AliRelAlignerKalman.cxx:64
 AliRelAlignerKalman.cxx:65
 AliRelAlignerKalman.cxx:66
 AliRelAlignerKalman.cxx:67
 AliRelAlignerKalman.cxx:68
 AliRelAlignerKalman.cxx:69
 AliRelAlignerKalman.cxx:70
 AliRelAlignerKalman.cxx:71
 AliRelAlignerKalman.cxx:72
 AliRelAlignerKalman.cxx:73
 AliRelAlignerKalman.cxx:74
 AliRelAlignerKalman.cxx:75
 AliRelAlignerKalman.cxx:76
 AliRelAlignerKalman.cxx:77
 AliRelAlignerKalman.cxx:78
 AliRelAlignerKalman.cxx:79
 AliRelAlignerKalman.cxx:80
 AliRelAlignerKalman.cxx:81
 AliRelAlignerKalman.cxx:82
 AliRelAlignerKalman.cxx:83
 AliRelAlignerKalman.cxx:84
 AliRelAlignerKalman.cxx:85
 AliRelAlignerKalman.cxx:86
 AliRelAlignerKalman.cxx:87
 AliRelAlignerKalman.cxx:88
 AliRelAlignerKalman.cxx:89
 AliRelAlignerKalman.cxx:90
 AliRelAlignerKalman.cxx:91
 AliRelAlignerKalman.cxx:92
 AliRelAlignerKalman.cxx:93
 AliRelAlignerKalman.cxx:94
 AliRelAlignerKalman.cxx:95
 AliRelAlignerKalman.cxx:96
 AliRelAlignerKalman.cxx:97
 AliRelAlignerKalman.cxx:98
 AliRelAlignerKalman.cxx:99
 AliRelAlignerKalman.cxx:100
 AliRelAlignerKalman.cxx:101
 AliRelAlignerKalman.cxx:102
 AliRelAlignerKalman.cxx:103
 AliRelAlignerKalman.cxx:104
 AliRelAlignerKalman.cxx:105
 AliRelAlignerKalman.cxx:106
 AliRelAlignerKalman.cxx:107
 AliRelAlignerKalman.cxx:108
 AliRelAlignerKalman.cxx:109
 AliRelAlignerKalman.cxx:110
 AliRelAlignerKalman.cxx:111
 AliRelAlignerKalman.cxx:112
 AliRelAlignerKalman.cxx:113
 AliRelAlignerKalman.cxx:114
 AliRelAlignerKalman.cxx:115
 AliRelAlignerKalman.cxx:116
 AliRelAlignerKalman.cxx:117
 AliRelAlignerKalman.cxx:118
 AliRelAlignerKalman.cxx:119
 AliRelAlignerKalman.cxx:120
 AliRelAlignerKalman.cxx:121
 AliRelAlignerKalman.cxx:122
 AliRelAlignerKalman.cxx:123
 AliRelAlignerKalman.cxx:124
 AliRelAlignerKalman.cxx:125
 AliRelAlignerKalman.cxx:126
 AliRelAlignerKalman.cxx:127
 AliRelAlignerKalman.cxx:128
 AliRelAlignerKalman.cxx:129
 AliRelAlignerKalman.cxx:130
 AliRelAlignerKalman.cxx:131
 AliRelAlignerKalman.cxx:132
 AliRelAlignerKalman.cxx:133
 AliRelAlignerKalman.cxx:134
 AliRelAlignerKalman.cxx:135
 AliRelAlignerKalman.cxx:136
 AliRelAlignerKalman.cxx:137
 AliRelAlignerKalman.cxx:138
 AliRelAlignerKalman.cxx:139
 AliRelAlignerKalman.cxx:140
 AliRelAlignerKalman.cxx:141
 AliRelAlignerKalman.cxx:142
 AliRelAlignerKalman.cxx:143
 AliRelAlignerKalman.cxx:144
 AliRelAlignerKalman.cxx:145
 AliRelAlignerKalman.cxx:146
 AliRelAlignerKalman.cxx:147
 AliRelAlignerKalman.cxx:148
 AliRelAlignerKalman.cxx:149
 AliRelAlignerKalman.cxx:150
 AliRelAlignerKalman.cxx:151
 AliRelAlignerKalman.cxx:152
 AliRelAlignerKalman.cxx:153
 AliRelAlignerKalman.cxx:154
 AliRelAlignerKalman.cxx:155
 AliRelAlignerKalman.cxx:156
 AliRelAlignerKalman.cxx:157
 AliRelAlignerKalman.cxx:158
 AliRelAlignerKalman.cxx:159
 AliRelAlignerKalman.cxx:160
 AliRelAlignerKalman.cxx:161
 AliRelAlignerKalman.cxx:162
 AliRelAlignerKalman.cxx:163
 AliRelAlignerKalman.cxx:164
 AliRelAlignerKalman.cxx:165
 AliRelAlignerKalman.cxx:166
 AliRelAlignerKalman.cxx:167
 AliRelAlignerKalman.cxx:168
 AliRelAlignerKalman.cxx:169
 AliRelAlignerKalman.cxx:170
 AliRelAlignerKalman.cxx:171
 AliRelAlignerKalman.cxx:172
 AliRelAlignerKalman.cxx:173
 AliRelAlignerKalman.cxx:174
 AliRelAlignerKalman.cxx:175
 AliRelAlignerKalman.cxx:176
 AliRelAlignerKalman.cxx:177
 AliRelAlignerKalman.cxx:178
 AliRelAlignerKalman.cxx:179
 AliRelAlignerKalman.cxx:180
 AliRelAlignerKalman.cxx:181
 AliRelAlignerKalman.cxx:182
 AliRelAlignerKalman.cxx:183
 AliRelAlignerKalman.cxx:184
 AliRelAlignerKalman.cxx:185
 AliRelAlignerKalman.cxx:186
 AliRelAlignerKalman.cxx:187
 AliRelAlignerKalman.cxx:188
 AliRelAlignerKalman.cxx:189
 AliRelAlignerKalman.cxx:190
 AliRelAlignerKalman.cxx:191
 AliRelAlignerKalman.cxx:192
 AliRelAlignerKalman.cxx:193
 AliRelAlignerKalman.cxx:194
 AliRelAlignerKalman.cxx:195
 AliRelAlignerKalman.cxx:196
 AliRelAlignerKalman.cxx:197
 AliRelAlignerKalman.cxx:198
 AliRelAlignerKalman.cxx:199
 AliRelAlignerKalman.cxx:200
 AliRelAlignerKalman.cxx:201
 AliRelAlignerKalman.cxx:202
 AliRelAlignerKalman.cxx:203
 AliRelAlignerKalman.cxx:204
 AliRelAlignerKalman.cxx:205
 AliRelAlignerKalman.cxx:206
 AliRelAlignerKalman.cxx:207
 AliRelAlignerKalman.cxx:208
 AliRelAlignerKalman.cxx:209
 AliRelAlignerKalman.cxx:210
 AliRelAlignerKalman.cxx:211
 AliRelAlignerKalman.cxx:212
 AliRelAlignerKalman.cxx:213
 AliRelAlignerKalman.cxx:214
 AliRelAlignerKalman.cxx:215
 AliRelAlignerKalman.cxx:216
 AliRelAlignerKalman.cxx:217
 AliRelAlignerKalman.cxx:218
 AliRelAlignerKalman.cxx:219
 AliRelAlignerKalman.cxx:220
 AliRelAlignerKalman.cxx:221
 AliRelAlignerKalman.cxx:222
 AliRelAlignerKalman.cxx:223
 AliRelAlignerKalman.cxx:224
 AliRelAlignerKalman.cxx:225
 AliRelAlignerKalman.cxx:226
 AliRelAlignerKalman.cxx:227
 AliRelAlignerKalman.cxx:228
 AliRelAlignerKalman.cxx:229
 AliRelAlignerKalman.cxx:230
 AliRelAlignerKalman.cxx:231
 AliRelAlignerKalman.cxx:232
 AliRelAlignerKalman.cxx:233
 AliRelAlignerKalman.cxx:234
 AliRelAlignerKalman.cxx:235
 AliRelAlignerKalman.cxx:236
 AliRelAlignerKalman.cxx:237
 AliRelAlignerKalman.cxx:238
 AliRelAlignerKalman.cxx:239
 AliRelAlignerKalman.cxx:240
 AliRelAlignerKalman.cxx:241
 AliRelAlignerKalman.cxx:242
 AliRelAlignerKalman.cxx:243
 AliRelAlignerKalman.cxx:244
 AliRelAlignerKalman.cxx:245
 AliRelAlignerKalman.cxx:246
 AliRelAlignerKalman.cxx:247
 AliRelAlignerKalman.cxx:248
 AliRelAlignerKalman.cxx:249
 AliRelAlignerKalman.cxx:250
 AliRelAlignerKalman.cxx:251
 AliRelAlignerKalman.cxx:252
 AliRelAlignerKalman.cxx:253
 AliRelAlignerKalman.cxx:254
 AliRelAlignerKalman.cxx:255
 AliRelAlignerKalman.cxx:256
 AliRelAlignerKalman.cxx:257
 AliRelAlignerKalman.cxx:258
 AliRelAlignerKalman.cxx:259
 AliRelAlignerKalman.cxx:260
 AliRelAlignerKalman.cxx:261
 AliRelAlignerKalman.cxx:262
 AliRelAlignerKalman.cxx:263
 AliRelAlignerKalman.cxx:264
 AliRelAlignerKalman.cxx:265
 AliRelAlignerKalman.cxx:266
 AliRelAlignerKalman.cxx:267
 AliRelAlignerKalman.cxx:268
 AliRelAlignerKalman.cxx:269
 AliRelAlignerKalman.cxx:270
 AliRelAlignerKalman.cxx:271
 AliRelAlignerKalman.cxx:272
 AliRelAlignerKalman.cxx:273
 AliRelAlignerKalman.cxx:274
 AliRelAlignerKalman.cxx:275
 AliRelAlignerKalman.cxx:276
 AliRelAlignerKalman.cxx:277
 AliRelAlignerKalman.cxx:278
 AliRelAlignerKalman.cxx:279
 AliRelAlignerKalman.cxx:280
 AliRelAlignerKalman.cxx:281
 AliRelAlignerKalman.cxx:282
 AliRelAlignerKalman.cxx:283
 AliRelAlignerKalman.cxx:284
 AliRelAlignerKalman.cxx:285
 AliRelAlignerKalman.cxx:286
 AliRelAlignerKalman.cxx:287
 AliRelAlignerKalman.cxx:288
 AliRelAlignerKalman.cxx:289
 AliRelAlignerKalman.cxx:290
 AliRelAlignerKalman.cxx:291
 AliRelAlignerKalman.cxx:292
 AliRelAlignerKalman.cxx:293
 AliRelAlignerKalman.cxx:294
 AliRelAlignerKalman.cxx:295
 AliRelAlignerKalman.cxx:296
 AliRelAlignerKalman.cxx:297
 AliRelAlignerKalman.cxx:298
 AliRelAlignerKalman.cxx:299
 AliRelAlignerKalman.cxx:300
 AliRelAlignerKalman.cxx:301
 AliRelAlignerKalman.cxx:302
 AliRelAlignerKalman.cxx:303
 AliRelAlignerKalman.cxx:304
 AliRelAlignerKalman.cxx:305
 AliRelAlignerKalman.cxx:306
 AliRelAlignerKalman.cxx:307
 AliRelAlignerKalman.cxx:308
 AliRelAlignerKalman.cxx:309
 AliRelAlignerKalman.cxx:310
 AliRelAlignerKalman.cxx:311
 AliRelAlignerKalman.cxx:312
 AliRelAlignerKalman.cxx:313
 AliRelAlignerKalman.cxx:314
 AliRelAlignerKalman.cxx:315
 AliRelAlignerKalman.cxx:316
 AliRelAlignerKalman.cxx:317
 AliRelAlignerKalman.cxx:318
 AliRelAlignerKalman.cxx:319
 AliRelAlignerKalman.cxx:320
 AliRelAlignerKalman.cxx:321
 AliRelAlignerKalman.cxx:322
 AliRelAlignerKalman.cxx:323
 AliRelAlignerKalman.cxx:324
 AliRelAlignerKalman.cxx:325
 AliRelAlignerKalman.cxx:326
 AliRelAlignerKalman.cxx:327
 AliRelAlignerKalman.cxx:328
 AliRelAlignerKalman.cxx:329
 AliRelAlignerKalman.cxx:330
 AliRelAlignerKalman.cxx:331
 AliRelAlignerKalman.cxx:332
 AliRelAlignerKalman.cxx:333
 AliRelAlignerKalman.cxx:334
 AliRelAlignerKalman.cxx:335
 AliRelAlignerKalman.cxx:336
 AliRelAlignerKalman.cxx:337
 AliRelAlignerKalman.cxx:338
 AliRelAlignerKalman.cxx:339
 AliRelAlignerKalman.cxx:340
 AliRelAlignerKalman.cxx:341
 AliRelAlignerKalman.cxx:342
 AliRelAlignerKalman.cxx:343
 AliRelAlignerKalman.cxx:344
 AliRelAlignerKalman.cxx:345
 AliRelAlignerKalman.cxx:346
 AliRelAlignerKalman.cxx:347
 AliRelAlignerKalman.cxx:348
 AliRelAlignerKalman.cxx:349
 AliRelAlignerKalman.cxx:350
 AliRelAlignerKalman.cxx:351
 AliRelAlignerKalman.cxx:352
 AliRelAlignerKalman.cxx:353
 AliRelAlignerKalman.cxx:354
 AliRelAlignerKalman.cxx:355
 AliRelAlignerKalman.cxx:356
 AliRelAlignerKalman.cxx:357
 AliRelAlignerKalman.cxx:358
 AliRelAlignerKalman.cxx:359
 AliRelAlignerKalman.cxx:360
 AliRelAlignerKalman.cxx:361
 AliRelAlignerKalman.cxx:362
 AliRelAlignerKalman.cxx:363
 AliRelAlignerKalman.cxx:364
 AliRelAlignerKalman.cxx:365
 AliRelAlignerKalman.cxx:366
 AliRelAlignerKalman.cxx:367
 AliRelAlignerKalman.cxx:368
 AliRelAlignerKalman.cxx:369
 AliRelAlignerKalman.cxx:370
 AliRelAlignerKalman.cxx:371
 AliRelAlignerKalman.cxx:372
 AliRelAlignerKalman.cxx:373
 AliRelAlignerKalman.cxx:374
 AliRelAlignerKalman.cxx:375
 AliRelAlignerKalman.cxx:376
 AliRelAlignerKalman.cxx:377
 AliRelAlignerKalman.cxx:378
 AliRelAlignerKalman.cxx:379
 AliRelAlignerKalman.cxx:380
 AliRelAlignerKalman.cxx:381
 AliRelAlignerKalman.cxx:382
 AliRelAlignerKalman.cxx:383
 AliRelAlignerKalman.cxx:384
 AliRelAlignerKalman.cxx:385
 AliRelAlignerKalman.cxx:386
 AliRelAlignerKalman.cxx:387
 AliRelAlignerKalman.cxx:388
 AliRelAlignerKalman.cxx:389
 AliRelAlignerKalman.cxx:390
 AliRelAlignerKalman.cxx:391
 AliRelAlignerKalman.cxx:392
 AliRelAlignerKalman.cxx:393
 AliRelAlignerKalman.cxx:394
 AliRelAlignerKalman.cxx:395
 AliRelAlignerKalman.cxx:396
 AliRelAlignerKalman.cxx:397
 AliRelAlignerKalman.cxx:398
 AliRelAlignerKalman.cxx:399
 AliRelAlignerKalman.cxx:400
 AliRelAlignerKalman.cxx:401
 AliRelAlignerKalman.cxx:402
 AliRelAlignerKalman.cxx:403
 AliRelAlignerKalman.cxx:404
 AliRelAlignerKalman.cxx:405
 AliRelAlignerKalman.cxx:406
 AliRelAlignerKalman.cxx:407
 AliRelAlignerKalman.cxx:408
 AliRelAlignerKalman.cxx:409
 AliRelAlignerKalman.cxx:410
 AliRelAlignerKalman.cxx:411
 AliRelAlignerKalman.cxx:412
 AliRelAlignerKalman.cxx:413
 AliRelAlignerKalman.cxx:414
 AliRelAlignerKalman.cxx:415
 AliRelAlignerKalman.cxx:416
 AliRelAlignerKalman.cxx:417
 AliRelAlignerKalman.cxx:418
 AliRelAlignerKalman.cxx:419
 AliRelAlignerKalman.cxx:420
 AliRelAlignerKalman.cxx:421
 AliRelAlignerKalman.cxx:422
 AliRelAlignerKalman.cxx:423
 AliRelAlignerKalman.cxx:424
 AliRelAlignerKalman.cxx:425
 AliRelAlignerKalman.cxx:426
 AliRelAlignerKalman.cxx:427
 AliRelAlignerKalman.cxx:428
 AliRelAlignerKalman.cxx:429
 AliRelAlignerKalman.cxx:430
 AliRelAlignerKalman.cxx:431
 AliRelAlignerKalman.cxx:432
 AliRelAlignerKalman.cxx:433
 AliRelAlignerKalman.cxx:434
 AliRelAlignerKalman.cxx:435
 AliRelAlignerKalman.cxx:436
 AliRelAlignerKalman.cxx:437
 AliRelAlignerKalman.cxx:438
 AliRelAlignerKalman.cxx:439
 AliRelAlignerKalman.cxx:440
 AliRelAlignerKalman.cxx:441
 AliRelAlignerKalman.cxx:442
 AliRelAlignerKalman.cxx:443
 AliRelAlignerKalman.cxx:444
 AliRelAlignerKalman.cxx:445
 AliRelAlignerKalman.cxx:446
 AliRelAlignerKalman.cxx:447
 AliRelAlignerKalman.cxx:448
 AliRelAlignerKalman.cxx:449
 AliRelAlignerKalman.cxx:450
 AliRelAlignerKalman.cxx:451
 AliRelAlignerKalman.cxx:452
 AliRelAlignerKalman.cxx:453
 AliRelAlignerKalman.cxx:454
 AliRelAlignerKalman.cxx:455
 AliRelAlignerKalman.cxx:456
 AliRelAlignerKalman.cxx:457
 AliRelAlignerKalman.cxx:458
 AliRelAlignerKalman.cxx:459
 AliRelAlignerKalman.cxx:460
 AliRelAlignerKalman.cxx:461
 AliRelAlignerKalman.cxx:462
 AliRelAlignerKalman.cxx:463
 AliRelAlignerKalman.cxx:464
 AliRelAlignerKalman.cxx:465
 AliRelAlignerKalman.cxx:466
 AliRelAlignerKalman.cxx:467
 AliRelAlignerKalman.cxx:468
 AliRelAlignerKalman.cxx:469
 AliRelAlignerKalman.cxx:470
 AliRelAlignerKalman.cxx:471
 AliRelAlignerKalman.cxx:472
 AliRelAlignerKalman.cxx:473
 AliRelAlignerKalman.cxx:474
 AliRelAlignerKalman.cxx:475
 AliRelAlignerKalman.cxx:476
 AliRelAlignerKalman.cxx:477
 AliRelAlignerKalman.cxx:478
 AliRelAlignerKalman.cxx:479
 AliRelAlignerKalman.cxx:480
 AliRelAlignerKalman.cxx:481
 AliRelAlignerKalman.cxx:482
 AliRelAlignerKalman.cxx:483
 AliRelAlignerKalman.cxx:484
 AliRelAlignerKalman.cxx:485
 AliRelAlignerKalman.cxx:486
 AliRelAlignerKalman.cxx:487
 AliRelAlignerKalman.cxx:488
 AliRelAlignerKalman.cxx:489
 AliRelAlignerKalman.cxx:490
 AliRelAlignerKalman.cxx:491
 AliRelAlignerKalman.cxx:492
 AliRelAlignerKalman.cxx:493
 AliRelAlignerKalman.cxx:494
 AliRelAlignerKalman.cxx:495
 AliRelAlignerKalman.cxx:496
 AliRelAlignerKalman.cxx:497
 AliRelAlignerKalman.cxx:498
 AliRelAlignerKalman.cxx:499
 AliRelAlignerKalman.cxx:500
 AliRelAlignerKalman.cxx:501
 AliRelAlignerKalman.cxx:502
 AliRelAlignerKalman.cxx:503
 AliRelAlignerKalman.cxx:504
 AliRelAlignerKalman.cxx:505
 AliRelAlignerKalman.cxx:506
 AliRelAlignerKalman.cxx:507
 AliRelAlignerKalman.cxx:508
 AliRelAlignerKalman.cxx:509
 AliRelAlignerKalman.cxx:510
 AliRelAlignerKalman.cxx:511
 AliRelAlignerKalman.cxx:512
 AliRelAlignerKalman.cxx:513
 AliRelAlignerKalman.cxx:514
 AliRelAlignerKalman.cxx:515
 AliRelAlignerKalman.cxx:516
 AliRelAlignerKalman.cxx:517
 AliRelAlignerKalman.cxx:518
 AliRelAlignerKalman.cxx:519
 AliRelAlignerKalman.cxx:520
 AliRelAlignerKalman.cxx:521
 AliRelAlignerKalman.cxx:522
 AliRelAlignerKalman.cxx:523
 AliRelAlignerKalman.cxx:524
 AliRelAlignerKalman.cxx:525
 AliRelAlignerKalman.cxx:526
 AliRelAlignerKalman.cxx:527
 AliRelAlignerKalman.cxx:528
 AliRelAlignerKalman.cxx:529
 AliRelAlignerKalman.cxx:530
 AliRelAlignerKalman.cxx:531
 AliRelAlignerKalman.cxx:532
 AliRelAlignerKalman.cxx:533
 AliRelAlignerKalman.cxx:534
 AliRelAlignerKalman.cxx:535
 AliRelAlignerKalman.cxx:536
 AliRelAlignerKalman.cxx:537
 AliRelAlignerKalman.cxx:538
 AliRelAlignerKalman.cxx:539
 AliRelAlignerKalman.cxx:540
 AliRelAlignerKalman.cxx:541
 AliRelAlignerKalman.cxx:542
 AliRelAlignerKalman.cxx:543
 AliRelAlignerKalman.cxx:544
 AliRelAlignerKalman.cxx:545
 AliRelAlignerKalman.cxx:546
 AliRelAlignerKalman.cxx:547
 AliRelAlignerKalman.cxx:548
 AliRelAlignerKalman.cxx:549
 AliRelAlignerKalman.cxx:550
 AliRelAlignerKalman.cxx:551
 AliRelAlignerKalman.cxx:552
 AliRelAlignerKalman.cxx:553
 AliRelAlignerKalman.cxx:554
 AliRelAlignerKalman.cxx:555
 AliRelAlignerKalman.cxx:556
 AliRelAlignerKalman.cxx:557
 AliRelAlignerKalman.cxx:558
 AliRelAlignerKalman.cxx:559
 AliRelAlignerKalman.cxx:560
 AliRelAlignerKalman.cxx:561
 AliRelAlignerKalman.cxx:562
 AliRelAlignerKalman.cxx:563
 AliRelAlignerKalman.cxx:564
 AliRelAlignerKalman.cxx:565
 AliRelAlignerKalman.cxx:566
 AliRelAlignerKalman.cxx:567
 AliRelAlignerKalman.cxx:568
 AliRelAlignerKalman.cxx:569
 AliRelAlignerKalman.cxx:570
 AliRelAlignerKalman.cxx:571
 AliRelAlignerKalman.cxx:572
 AliRelAlignerKalman.cxx:573
 AliRelAlignerKalman.cxx:574
 AliRelAlignerKalman.cxx:575
 AliRelAlignerKalman.cxx:576
 AliRelAlignerKalman.cxx:577
 AliRelAlignerKalman.cxx:578
 AliRelAlignerKalman.cxx:579
 AliRelAlignerKalman.cxx:580
 AliRelAlignerKalman.cxx:581
 AliRelAlignerKalman.cxx:582
 AliRelAlignerKalman.cxx:583
 AliRelAlignerKalman.cxx:584
 AliRelAlignerKalman.cxx:585
 AliRelAlignerKalman.cxx:586
 AliRelAlignerKalman.cxx:587
 AliRelAlignerKalman.cxx:588
 AliRelAlignerKalman.cxx:589
 AliRelAlignerKalman.cxx:590
 AliRelAlignerKalman.cxx:591
 AliRelAlignerKalman.cxx:592
 AliRelAlignerKalman.cxx:593
 AliRelAlignerKalman.cxx:594
 AliRelAlignerKalman.cxx:595
 AliRelAlignerKalman.cxx:596
 AliRelAlignerKalman.cxx:597
 AliRelAlignerKalman.cxx:598
 AliRelAlignerKalman.cxx:599
 AliRelAlignerKalman.cxx:600
 AliRelAlignerKalman.cxx:601
 AliRelAlignerKalman.cxx:602
 AliRelAlignerKalman.cxx:603
 AliRelAlignerKalman.cxx:604
 AliRelAlignerKalman.cxx:605
 AliRelAlignerKalman.cxx:606
 AliRelAlignerKalman.cxx:607
 AliRelAlignerKalman.cxx:608
 AliRelAlignerKalman.cxx:609
 AliRelAlignerKalman.cxx:610
 AliRelAlignerKalman.cxx:611
 AliRelAlignerKalman.cxx:612
 AliRelAlignerKalman.cxx:613
 AliRelAlignerKalman.cxx:614
 AliRelAlignerKalman.cxx:615
 AliRelAlignerKalman.cxx:616
 AliRelAlignerKalman.cxx:617
 AliRelAlignerKalman.cxx:618
 AliRelAlignerKalman.cxx:619
 AliRelAlignerKalman.cxx:620
 AliRelAlignerKalman.cxx:621
 AliRelAlignerKalman.cxx:622
 AliRelAlignerKalman.cxx:623
 AliRelAlignerKalman.cxx:624
 AliRelAlignerKalman.cxx:625
 AliRelAlignerKalman.cxx:626
 AliRelAlignerKalman.cxx:627
 AliRelAlignerKalman.cxx:628
 AliRelAlignerKalman.cxx:629
 AliRelAlignerKalman.cxx:630
 AliRelAlignerKalman.cxx:631
 AliRelAlignerKalman.cxx:632
 AliRelAlignerKalman.cxx:633
 AliRelAlignerKalman.cxx:634
 AliRelAlignerKalman.cxx:635
 AliRelAlignerKalman.cxx:636
 AliRelAlignerKalman.cxx:637
 AliRelAlignerKalman.cxx:638
 AliRelAlignerKalman.cxx:639
 AliRelAlignerKalman.cxx:640
 AliRelAlignerKalman.cxx:641
 AliRelAlignerKalman.cxx:642
 AliRelAlignerKalman.cxx:643
 AliRelAlignerKalman.cxx:644
 AliRelAlignerKalman.cxx:645
 AliRelAlignerKalman.cxx:646
 AliRelAlignerKalman.cxx:647
 AliRelAlignerKalman.cxx:648
 AliRelAlignerKalman.cxx:649
 AliRelAlignerKalman.cxx:650
 AliRelAlignerKalman.cxx:651
 AliRelAlignerKalman.cxx:652
 AliRelAlignerKalman.cxx:653
 AliRelAlignerKalman.cxx:654
 AliRelAlignerKalman.cxx:655
 AliRelAlignerKalman.cxx:656
 AliRelAlignerKalman.cxx:657
 AliRelAlignerKalman.cxx:658
 AliRelAlignerKalman.cxx:659
 AliRelAlignerKalman.cxx:660
 AliRelAlignerKalman.cxx:661
 AliRelAlignerKalman.cxx:662
 AliRelAlignerKalman.cxx:663
 AliRelAlignerKalman.cxx:664
 AliRelAlignerKalman.cxx:665
 AliRelAlignerKalman.cxx:666
 AliRelAlignerKalman.cxx:667
 AliRelAlignerKalman.cxx:668
 AliRelAlignerKalman.cxx:669
 AliRelAlignerKalman.cxx:670
 AliRelAlignerKalman.cxx:671
 AliRelAlignerKalman.cxx:672
 AliRelAlignerKalman.cxx:673
 AliRelAlignerKalman.cxx:674
 AliRelAlignerKalman.cxx:675
 AliRelAlignerKalman.cxx:676
 AliRelAlignerKalman.cxx:677
 AliRelAlignerKalman.cxx:678
 AliRelAlignerKalman.cxx:679
 AliRelAlignerKalman.cxx:680
 AliRelAlignerKalman.cxx:681
 AliRelAlignerKalman.cxx:682
 AliRelAlignerKalman.cxx:683
 AliRelAlignerKalman.cxx:684
 AliRelAlignerKalman.cxx:685
 AliRelAlignerKalman.cxx:686
 AliRelAlignerKalman.cxx:687
 AliRelAlignerKalman.cxx:688
 AliRelAlignerKalman.cxx:689
 AliRelAlignerKalman.cxx:690
 AliRelAlignerKalman.cxx:691
 AliRelAlignerKalman.cxx:692
 AliRelAlignerKalman.cxx:693
 AliRelAlignerKalman.cxx:694
 AliRelAlignerKalman.cxx:695
 AliRelAlignerKalman.cxx:696
 AliRelAlignerKalman.cxx:697
 AliRelAlignerKalman.cxx:698
 AliRelAlignerKalman.cxx:699
 AliRelAlignerKalman.cxx:700
 AliRelAlignerKalman.cxx:701
 AliRelAlignerKalman.cxx:702
 AliRelAlignerKalman.cxx:703
 AliRelAlignerKalman.cxx:704
 AliRelAlignerKalman.cxx:705
 AliRelAlignerKalman.cxx:706
 AliRelAlignerKalman.cxx:707
 AliRelAlignerKalman.cxx:708
 AliRelAlignerKalman.cxx:709
 AliRelAlignerKalman.cxx:710
 AliRelAlignerKalman.cxx:711
 AliRelAlignerKalman.cxx:712
 AliRelAlignerKalman.cxx:713
 AliRelAlignerKalman.cxx:714
 AliRelAlignerKalman.cxx:715
 AliRelAlignerKalman.cxx:716
 AliRelAlignerKalman.cxx:717
 AliRelAlignerKalman.cxx:718
 AliRelAlignerKalman.cxx:719
 AliRelAlignerKalman.cxx:720
 AliRelAlignerKalman.cxx:721
 AliRelAlignerKalman.cxx:722
 AliRelAlignerKalman.cxx:723
 AliRelAlignerKalman.cxx:724
 AliRelAlignerKalman.cxx:725
 AliRelAlignerKalman.cxx:726
 AliRelAlignerKalman.cxx:727
 AliRelAlignerKalman.cxx:728
 AliRelAlignerKalman.cxx:729
 AliRelAlignerKalman.cxx:730
 AliRelAlignerKalman.cxx:731
 AliRelAlignerKalman.cxx:732
 AliRelAlignerKalman.cxx:733
 AliRelAlignerKalman.cxx:734
 AliRelAlignerKalman.cxx:735
 AliRelAlignerKalman.cxx:736
 AliRelAlignerKalman.cxx:737
 AliRelAlignerKalman.cxx:738
 AliRelAlignerKalman.cxx:739
 AliRelAlignerKalman.cxx:740
 AliRelAlignerKalman.cxx:741
 AliRelAlignerKalman.cxx:742
 AliRelAlignerKalman.cxx:743
 AliRelAlignerKalman.cxx:744
 AliRelAlignerKalman.cxx:745
 AliRelAlignerKalman.cxx:746
 AliRelAlignerKalman.cxx:747
 AliRelAlignerKalman.cxx:748
 AliRelAlignerKalman.cxx:749
 AliRelAlignerKalman.cxx:750
 AliRelAlignerKalman.cxx:751
 AliRelAlignerKalman.cxx:752
 AliRelAlignerKalman.cxx:753
 AliRelAlignerKalman.cxx:754
 AliRelAlignerKalman.cxx:755
 AliRelAlignerKalman.cxx:756
 AliRelAlignerKalman.cxx:757
 AliRelAlignerKalman.cxx:758
 AliRelAlignerKalman.cxx:759
 AliRelAlignerKalman.cxx:760
 AliRelAlignerKalman.cxx:761
 AliRelAlignerKalman.cxx:762
 AliRelAlignerKalman.cxx:763
 AliRelAlignerKalman.cxx:764
 AliRelAlignerKalman.cxx:765
 AliRelAlignerKalman.cxx:766
 AliRelAlignerKalman.cxx:767
 AliRelAlignerKalman.cxx:768
 AliRelAlignerKalman.cxx:769
 AliRelAlignerKalman.cxx:770
 AliRelAlignerKalman.cxx:771
 AliRelAlignerKalman.cxx:772
 AliRelAlignerKalman.cxx:773
 AliRelAlignerKalman.cxx:774
 AliRelAlignerKalman.cxx:775
 AliRelAlignerKalman.cxx:776
 AliRelAlignerKalman.cxx:777
 AliRelAlignerKalman.cxx:778
 AliRelAlignerKalman.cxx:779
 AliRelAlignerKalman.cxx:780
 AliRelAlignerKalman.cxx:781
 AliRelAlignerKalman.cxx:782
 AliRelAlignerKalman.cxx:783
 AliRelAlignerKalman.cxx:784
 AliRelAlignerKalman.cxx:785
 AliRelAlignerKalman.cxx:786
 AliRelAlignerKalman.cxx:787
 AliRelAlignerKalman.cxx:788
 AliRelAlignerKalman.cxx:789
 AliRelAlignerKalman.cxx:790
 AliRelAlignerKalman.cxx:791
 AliRelAlignerKalman.cxx:792
 AliRelAlignerKalman.cxx:793
 AliRelAlignerKalman.cxx:794
 AliRelAlignerKalman.cxx:795
 AliRelAlignerKalman.cxx:796
 AliRelAlignerKalman.cxx:797
 AliRelAlignerKalman.cxx:798
 AliRelAlignerKalman.cxx:799
 AliRelAlignerKalman.cxx:800
 AliRelAlignerKalman.cxx:801
 AliRelAlignerKalman.cxx:802
 AliRelAlignerKalman.cxx:803
 AliRelAlignerKalman.cxx:804
 AliRelAlignerKalman.cxx:805
 AliRelAlignerKalman.cxx:806
 AliRelAlignerKalman.cxx:807
 AliRelAlignerKalman.cxx:808
 AliRelAlignerKalman.cxx:809
 AliRelAlignerKalman.cxx:810
 AliRelAlignerKalman.cxx:811
 AliRelAlignerKalman.cxx:812
 AliRelAlignerKalman.cxx:813
 AliRelAlignerKalman.cxx:814
 AliRelAlignerKalman.cxx:815
 AliRelAlignerKalman.cxx:816
 AliRelAlignerKalman.cxx:817
 AliRelAlignerKalman.cxx:818
 AliRelAlignerKalman.cxx:819
 AliRelAlignerKalman.cxx:820
 AliRelAlignerKalman.cxx:821
 AliRelAlignerKalman.cxx:822
 AliRelAlignerKalman.cxx:823
 AliRelAlignerKalman.cxx:824
 AliRelAlignerKalman.cxx:825
 AliRelAlignerKalman.cxx:826
 AliRelAlignerKalman.cxx:827
 AliRelAlignerKalman.cxx:828
 AliRelAlignerKalman.cxx:829
 AliRelAlignerKalman.cxx:830
 AliRelAlignerKalman.cxx:831
 AliRelAlignerKalman.cxx:832
 AliRelAlignerKalman.cxx:833
 AliRelAlignerKalman.cxx:834
 AliRelAlignerKalman.cxx:835
 AliRelAlignerKalman.cxx:836
 AliRelAlignerKalman.cxx:837
 AliRelAlignerKalman.cxx:838
 AliRelAlignerKalman.cxx:839
 AliRelAlignerKalman.cxx:840
 AliRelAlignerKalman.cxx:841
 AliRelAlignerKalman.cxx:842
 AliRelAlignerKalman.cxx:843
 AliRelAlignerKalman.cxx:844
 AliRelAlignerKalman.cxx:845
 AliRelAlignerKalman.cxx:846
 AliRelAlignerKalman.cxx:847
 AliRelAlignerKalman.cxx:848
 AliRelAlignerKalman.cxx:849
 AliRelAlignerKalman.cxx:850
 AliRelAlignerKalman.cxx:851
 AliRelAlignerKalman.cxx:852
 AliRelAlignerKalman.cxx:853
 AliRelAlignerKalman.cxx:854
 AliRelAlignerKalman.cxx:855
 AliRelAlignerKalman.cxx:856
 AliRelAlignerKalman.cxx:857
 AliRelAlignerKalman.cxx:858
 AliRelAlignerKalman.cxx:859
 AliRelAlignerKalman.cxx:860
 AliRelAlignerKalman.cxx:861
 AliRelAlignerKalman.cxx:862
 AliRelAlignerKalman.cxx:863
 AliRelAlignerKalman.cxx:864
 AliRelAlignerKalman.cxx:865
 AliRelAlignerKalman.cxx:866
 AliRelAlignerKalman.cxx:867
 AliRelAlignerKalman.cxx:868
 AliRelAlignerKalman.cxx:869
 AliRelAlignerKalman.cxx:870
 AliRelAlignerKalman.cxx:871
 AliRelAlignerKalman.cxx:872
 AliRelAlignerKalman.cxx:873
 AliRelAlignerKalman.cxx:874
 AliRelAlignerKalman.cxx:875
 AliRelAlignerKalman.cxx:876
 AliRelAlignerKalman.cxx:877
 AliRelAlignerKalman.cxx:878
 AliRelAlignerKalman.cxx:879
 AliRelAlignerKalman.cxx:880
 AliRelAlignerKalman.cxx:881
 AliRelAlignerKalman.cxx:882
 AliRelAlignerKalman.cxx:883
 AliRelAlignerKalman.cxx:884
 AliRelAlignerKalman.cxx:885
 AliRelAlignerKalman.cxx:886
 AliRelAlignerKalman.cxx:887
 AliRelAlignerKalman.cxx:888
 AliRelAlignerKalman.cxx:889
 AliRelAlignerKalman.cxx:890
 AliRelAlignerKalman.cxx:891
 AliRelAlignerKalman.cxx:892
 AliRelAlignerKalman.cxx:893
 AliRelAlignerKalman.cxx:894
 AliRelAlignerKalman.cxx:895
 AliRelAlignerKalman.cxx:896
 AliRelAlignerKalman.cxx:897
 AliRelAlignerKalman.cxx:898
 AliRelAlignerKalman.cxx:899
 AliRelAlignerKalman.cxx:900
 AliRelAlignerKalman.cxx:901
 AliRelAlignerKalman.cxx:902
 AliRelAlignerKalman.cxx:903
 AliRelAlignerKalman.cxx:904
 AliRelAlignerKalman.cxx:905
 AliRelAlignerKalman.cxx:906
 AliRelAlignerKalman.cxx:907
 AliRelAlignerKalman.cxx:908
 AliRelAlignerKalman.cxx:909
 AliRelAlignerKalman.cxx:910
 AliRelAlignerKalman.cxx:911
 AliRelAlignerKalman.cxx:912
 AliRelAlignerKalman.cxx:913
 AliRelAlignerKalman.cxx:914
 AliRelAlignerKalman.cxx:915
 AliRelAlignerKalman.cxx:916
 AliRelAlignerKalman.cxx:917
 AliRelAlignerKalman.cxx:918
 AliRelAlignerKalman.cxx:919
 AliRelAlignerKalman.cxx:920
 AliRelAlignerKalman.cxx:921
 AliRelAlignerKalman.cxx:922
 AliRelAlignerKalman.cxx:923
 AliRelAlignerKalman.cxx:924
 AliRelAlignerKalman.cxx:925
 AliRelAlignerKalman.cxx:926
 AliRelAlignerKalman.cxx:927
 AliRelAlignerKalman.cxx:928
 AliRelAlignerKalman.cxx:929
 AliRelAlignerKalman.cxx:930
 AliRelAlignerKalman.cxx:931
 AliRelAlignerKalman.cxx:932
 AliRelAlignerKalman.cxx:933
 AliRelAlignerKalman.cxx:934
 AliRelAlignerKalman.cxx:935
 AliRelAlignerKalman.cxx:936
 AliRelAlignerKalman.cxx:937
 AliRelAlignerKalman.cxx:938
 AliRelAlignerKalman.cxx:939
 AliRelAlignerKalman.cxx:940
 AliRelAlignerKalman.cxx:941
 AliRelAlignerKalman.cxx:942
 AliRelAlignerKalman.cxx:943
 AliRelAlignerKalman.cxx:944
 AliRelAlignerKalman.cxx:945
 AliRelAlignerKalman.cxx:946
 AliRelAlignerKalman.cxx:947
 AliRelAlignerKalman.cxx:948
 AliRelAlignerKalman.cxx:949
 AliRelAlignerKalman.cxx:950
 AliRelAlignerKalman.cxx:951
 AliRelAlignerKalman.cxx:952
 AliRelAlignerKalman.cxx:953
 AliRelAlignerKalman.cxx:954
 AliRelAlignerKalman.cxx:955
 AliRelAlignerKalman.cxx:956
 AliRelAlignerKalman.cxx:957
 AliRelAlignerKalman.cxx:958
 AliRelAlignerKalman.cxx:959
 AliRelAlignerKalman.cxx:960
 AliRelAlignerKalman.cxx:961
 AliRelAlignerKalman.cxx:962
 AliRelAlignerKalman.cxx:963
 AliRelAlignerKalman.cxx:964
 AliRelAlignerKalman.cxx:965
 AliRelAlignerKalman.cxx:966
 AliRelAlignerKalman.cxx:967
 AliRelAlignerKalman.cxx:968
 AliRelAlignerKalman.cxx:969
 AliRelAlignerKalman.cxx:970
 AliRelAlignerKalman.cxx:971
 AliRelAlignerKalman.cxx:972
 AliRelAlignerKalman.cxx:973
 AliRelAlignerKalman.cxx:974
 AliRelAlignerKalman.cxx:975
 AliRelAlignerKalman.cxx:976
 AliRelAlignerKalman.cxx:977
 AliRelAlignerKalman.cxx:978
 AliRelAlignerKalman.cxx:979
 AliRelAlignerKalman.cxx:980
 AliRelAlignerKalman.cxx:981
 AliRelAlignerKalman.cxx:982
 AliRelAlignerKalman.cxx:983
 AliRelAlignerKalman.cxx:984
 AliRelAlignerKalman.cxx:985
 AliRelAlignerKalman.cxx:986
 AliRelAlignerKalman.cxx:987
 AliRelAlignerKalman.cxx:988
 AliRelAlignerKalman.cxx:989
 AliRelAlignerKalman.cxx:990
 AliRelAlignerKalman.cxx:991
 AliRelAlignerKalman.cxx:992
 AliRelAlignerKalman.cxx:993
 AliRelAlignerKalman.cxx:994
 AliRelAlignerKalman.cxx:995
 AliRelAlignerKalman.cxx:996
 AliRelAlignerKalman.cxx:997
 AliRelAlignerKalman.cxx:998
 AliRelAlignerKalman.cxx:999
 AliRelAlignerKalman.cxx:1000
 AliRelAlignerKalman.cxx:1001
 AliRelAlignerKalman.cxx:1002
 AliRelAlignerKalman.cxx:1003
 AliRelAlignerKalman.cxx:1004
 AliRelAlignerKalman.cxx:1005
 AliRelAlignerKalman.cxx:1006
 AliRelAlignerKalman.cxx:1007
 AliRelAlignerKalman.cxx:1008
 AliRelAlignerKalman.cxx:1009
 AliRelAlignerKalman.cxx:1010
 AliRelAlignerKalman.cxx:1011
 AliRelAlignerKalman.cxx:1012
 AliRelAlignerKalman.cxx:1013
 AliRelAlignerKalman.cxx:1014
 AliRelAlignerKalman.cxx:1015
 AliRelAlignerKalman.cxx:1016
 AliRelAlignerKalman.cxx:1017
 AliRelAlignerKalman.cxx:1018
 AliRelAlignerKalman.cxx:1019
 AliRelAlignerKalman.cxx:1020
 AliRelAlignerKalman.cxx:1021
 AliRelAlignerKalman.cxx:1022
 AliRelAlignerKalman.cxx:1023
 AliRelAlignerKalman.cxx:1024
 AliRelAlignerKalman.cxx:1025
 AliRelAlignerKalman.cxx:1026
 AliRelAlignerKalman.cxx:1027
 AliRelAlignerKalman.cxx:1028
 AliRelAlignerKalman.cxx:1029
 AliRelAlignerKalman.cxx:1030
 AliRelAlignerKalman.cxx:1031
 AliRelAlignerKalman.cxx:1032
 AliRelAlignerKalman.cxx:1033
 AliRelAlignerKalman.cxx:1034
 AliRelAlignerKalman.cxx:1035
 AliRelAlignerKalman.cxx:1036
 AliRelAlignerKalman.cxx:1037
 AliRelAlignerKalman.cxx:1038
 AliRelAlignerKalman.cxx:1039
 AliRelAlignerKalman.cxx:1040
 AliRelAlignerKalman.cxx:1041
 AliRelAlignerKalman.cxx:1042
 AliRelAlignerKalman.cxx:1043
 AliRelAlignerKalman.cxx:1044
 AliRelAlignerKalman.cxx:1045
 AliRelAlignerKalman.cxx:1046
 AliRelAlignerKalman.cxx:1047
 AliRelAlignerKalman.cxx:1048
 AliRelAlignerKalman.cxx:1049
 AliRelAlignerKalman.cxx:1050
 AliRelAlignerKalman.cxx:1051
 AliRelAlignerKalman.cxx:1052
 AliRelAlignerKalman.cxx:1053
 AliRelAlignerKalman.cxx:1054
 AliRelAlignerKalman.cxx:1055
 AliRelAlignerKalman.cxx:1056
 AliRelAlignerKalman.cxx:1057
 AliRelAlignerKalman.cxx:1058
 AliRelAlignerKalman.cxx:1059
 AliRelAlignerKalman.cxx:1060
 AliRelAlignerKalman.cxx:1061
 AliRelAlignerKalman.cxx:1062
 AliRelAlignerKalman.cxx:1063
 AliRelAlignerKalman.cxx:1064
 AliRelAlignerKalman.cxx:1065
 AliRelAlignerKalman.cxx:1066
 AliRelAlignerKalman.cxx:1067
 AliRelAlignerKalman.cxx:1068
 AliRelAlignerKalman.cxx:1069
 AliRelAlignerKalman.cxx:1070
 AliRelAlignerKalman.cxx:1071
 AliRelAlignerKalman.cxx:1072
 AliRelAlignerKalman.cxx:1073
 AliRelAlignerKalman.cxx:1074
 AliRelAlignerKalman.cxx:1075
 AliRelAlignerKalman.cxx:1076
 AliRelAlignerKalman.cxx:1077
 AliRelAlignerKalman.cxx:1078
 AliRelAlignerKalman.cxx:1079
 AliRelAlignerKalman.cxx:1080
 AliRelAlignerKalman.cxx:1081
 AliRelAlignerKalman.cxx:1082
 AliRelAlignerKalman.cxx:1083
 AliRelAlignerKalman.cxx:1084
 AliRelAlignerKalman.cxx:1085
 AliRelAlignerKalman.cxx:1086
 AliRelAlignerKalman.cxx:1087
 AliRelAlignerKalman.cxx:1088
 AliRelAlignerKalman.cxx:1089
 AliRelAlignerKalman.cxx:1090
 AliRelAlignerKalman.cxx:1091
 AliRelAlignerKalman.cxx:1092
 AliRelAlignerKalman.cxx:1093
 AliRelAlignerKalman.cxx:1094
 AliRelAlignerKalman.cxx:1095
 AliRelAlignerKalman.cxx:1096
 AliRelAlignerKalman.cxx:1097
 AliRelAlignerKalman.cxx:1098
 AliRelAlignerKalman.cxx:1099
 AliRelAlignerKalman.cxx:1100
 AliRelAlignerKalman.cxx:1101
 AliRelAlignerKalman.cxx:1102
 AliRelAlignerKalman.cxx:1103
 AliRelAlignerKalman.cxx:1104
 AliRelAlignerKalman.cxx:1105
 AliRelAlignerKalman.cxx:1106
 AliRelAlignerKalman.cxx:1107
 AliRelAlignerKalman.cxx:1108
 AliRelAlignerKalman.cxx:1109
 AliRelAlignerKalman.cxx:1110
 AliRelAlignerKalman.cxx:1111
 AliRelAlignerKalman.cxx:1112
 AliRelAlignerKalman.cxx:1113
 AliRelAlignerKalman.cxx:1114
 AliRelAlignerKalman.cxx:1115
 AliRelAlignerKalman.cxx:1116
 AliRelAlignerKalman.cxx:1117
 AliRelAlignerKalman.cxx:1118
 AliRelAlignerKalman.cxx:1119
 AliRelAlignerKalman.cxx:1120
 AliRelAlignerKalman.cxx:1121
 AliRelAlignerKalman.cxx:1122
 AliRelAlignerKalman.cxx:1123
 AliRelAlignerKalman.cxx:1124
 AliRelAlignerKalman.cxx:1125
 AliRelAlignerKalman.cxx:1126
 AliRelAlignerKalman.cxx:1127
 AliRelAlignerKalman.cxx:1128
 AliRelAlignerKalman.cxx:1129
 AliRelAlignerKalman.cxx:1130
 AliRelAlignerKalman.cxx:1131
 AliRelAlignerKalman.cxx:1132
 AliRelAlignerKalman.cxx:1133
 AliRelAlignerKalman.cxx:1134
 AliRelAlignerKalman.cxx:1135
 AliRelAlignerKalman.cxx:1136
 AliRelAlignerKalman.cxx:1137
 AliRelAlignerKalman.cxx:1138
 AliRelAlignerKalman.cxx:1139
 AliRelAlignerKalman.cxx:1140
 AliRelAlignerKalman.cxx:1141
 AliRelAlignerKalman.cxx:1142
 AliRelAlignerKalman.cxx:1143
 AliRelAlignerKalman.cxx:1144
 AliRelAlignerKalman.cxx:1145
 AliRelAlignerKalman.cxx:1146
 AliRelAlignerKalman.cxx:1147
 AliRelAlignerKalman.cxx:1148
 AliRelAlignerKalman.cxx:1149
 AliRelAlignerKalman.cxx:1150
 AliRelAlignerKalman.cxx:1151
 AliRelAlignerKalman.cxx:1152
 AliRelAlignerKalman.cxx:1153
 AliRelAlignerKalman.cxx:1154
 AliRelAlignerKalman.cxx:1155
 AliRelAlignerKalman.cxx:1156
 AliRelAlignerKalman.cxx:1157
 AliRelAlignerKalman.cxx:1158
 AliRelAlignerKalman.cxx:1159
 AliRelAlignerKalman.cxx:1160
 AliRelAlignerKalman.cxx:1161
 AliRelAlignerKalman.cxx:1162
 AliRelAlignerKalman.cxx:1163
 AliRelAlignerKalman.cxx:1164
 AliRelAlignerKalman.cxx:1165
 AliRelAlignerKalman.cxx:1166
 AliRelAlignerKalman.cxx:1167
 AliRelAlignerKalman.cxx:1168
 AliRelAlignerKalman.cxx:1169
 AliRelAlignerKalman.cxx:1170
 AliRelAlignerKalman.cxx:1171
 AliRelAlignerKalman.cxx:1172
 AliRelAlignerKalman.cxx:1173
 AliRelAlignerKalman.cxx:1174
 AliRelAlignerKalman.cxx:1175
 AliRelAlignerKalman.cxx:1176
 AliRelAlignerKalman.cxx:1177
 AliRelAlignerKalman.cxx:1178
 AliRelAlignerKalman.cxx:1179
 AliRelAlignerKalman.cxx:1180
 AliRelAlignerKalman.cxx:1181
 AliRelAlignerKalman.cxx:1182
 AliRelAlignerKalman.cxx:1183
 AliRelAlignerKalman.cxx:1184
 AliRelAlignerKalman.cxx:1185
 AliRelAlignerKalman.cxx:1186
 AliRelAlignerKalman.cxx:1187
 AliRelAlignerKalman.cxx:1188
 AliRelAlignerKalman.cxx:1189
 AliRelAlignerKalman.cxx:1190
 AliRelAlignerKalman.cxx:1191
 AliRelAlignerKalman.cxx:1192
 AliRelAlignerKalman.cxx:1193
 AliRelAlignerKalman.cxx:1194
 AliRelAlignerKalman.cxx:1195
 AliRelAlignerKalman.cxx:1196
 AliRelAlignerKalman.cxx:1197
 AliRelAlignerKalman.cxx:1198
 AliRelAlignerKalman.cxx:1199
 AliRelAlignerKalman.cxx:1200
 AliRelAlignerKalman.cxx:1201
 AliRelAlignerKalman.cxx:1202
 AliRelAlignerKalman.cxx:1203
 AliRelAlignerKalman.cxx:1204
 AliRelAlignerKalman.cxx:1205
 AliRelAlignerKalman.cxx:1206
 AliRelAlignerKalman.cxx:1207
 AliRelAlignerKalman.cxx:1208
 AliRelAlignerKalman.cxx:1209
 AliRelAlignerKalman.cxx:1210
 AliRelAlignerKalman.cxx:1211
 AliRelAlignerKalman.cxx:1212
 AliRelAlignerKalman.cxx:1213
 AliRelAlignerKalman.cxx:1214
 AliRelAlignerKalman.cxx:1215
 AliRelAlignerKalman.cxx:1216
 AliRelAlignerKalman.cxx:1217
 AliRelAlignerKalman.cxx:1218
 AliRelAlignerKalman.cxx:1219
 AliRelAlignerKalman.cxx:1220
 AliRelAlignerKalman.cxx:1221
 AliRelAlignerKalman.cxx:1222
 AliRelAlignerKalman.cxx:1223
 AliRelAlignerKalman.cxx:1224
 AliRelAlignerKalman.cxx:1225
 AliRelAlignerKalman.cxx:1226
 AliRelAlignerKalman.cxx:1227
 AliRelAlignerKalman.cxx:1228
 AliRelAlignerKalman.cxx:1229
 AliRelAlignerKalman.cxx:1230
 AliRelAlignerKalman.cxx:1231
 AliRelAlignerKalman.cxx:1232
 AliRelAlignerKalman.cxx:1233
 AliRelAlignerKalman.cxx:1234
 AliRelAlignerKalman.cxx:1235
 AliRelAlignerKalman.cxx:1236
 AliRelAlignerKalman.cxx:1237
 AliRelAlignerKalman.cxx:1238
 AliRelAlignerKalman.cxx:1239
 AliRelAlignerKalman.cxx:1240
 AliRelAlignerKalman.cxx:1241
 AliRelAlignerKalman.cxx:1242
 AliRelAlignerKalman.cxx:1243
 AliRelAlignerKalman.cxx:1244
 AliRelAlignerKalman.cxx:1245
 AliRelAlignerKalman.cxx:1246
 AliRelAlignerKalman.cxx:1247
 AliRelAlignerKalman.cxx:1248
 AliRelAlignerKalman.cxx:1249
 AliRelAlignerKalman.cxx:1250
 AliRelAlignerKalman.cxx:1251
 AliRelAlignerKalman.cxx:1252
 AliRelAlignerKalman.cxx:1253
 AliRelAlignerKalman.cxx:1254
 AliRelAlignerKalman.cxx:1255
 AliRelAlignerKalman.cxx:1256
 AliRelAlignerKalman.cxx:1257
 AliRelAlignerKalman.cxx:1258
 AliRelAlignerKalman.cxx:1259
 AliRelAlignerKalman.cxx:1260
 AliRelAlignerKalman.cxx:1261
 AliRelAlignerKalman.cxx:1262
 AliRelAlignerKalman.cxx:1263
 AliRelAlignerKalman.cxx:1264
 AliRelAlignerKalman.cxx:1265
 AliRelAlignerKalman.cxx:1266
 AliRelAlignerKalman.cxx:1267
 AliRelAlignerKalman.cxx:1268
 AliRelAlignerKalman.cxx:1269
 AliRelAlignerKalman.cxx:1270
 AliRelAlignerKalman.cxx:1271
 AliRelAlignerKalman.cxx:1272
 AliRelAlignerKalman.cxx:1273
 AliRelAlignerKalman.cxx:1274
 AliRelAlignerKalman.cxx:1275
 AliRelAlignerKalman.cxx:1276
 AliRelAlignerKalman.cxx:1277
 AliRelAlignerKalman.cxx:1278
 AliRelAlignerKalman.cxx:1279
 AliRelAlignerKalman.cxx:1280
 AliRelAlignerKalman.cxx:1281
 AliRelAlignerKalman.cxx:1282
 AliRelAlignerKalman.cxx:1283
 AliRelAlignerKalman.cxx:1284
 AliRelAlignerKalman.cxx:1285
 AliRelAlignerKalman.cxx:1286
 AliRelAlignerKalman.cxx:1287
 AliRelAlignerKalman.cxx:1288
 AliRelAlignerKalman.cxx:1289
 AliRelAlignerKalman.cxx:1290
 AliRelAlignerKalman.cxx:1291
 AliRelAlignerKalman.cxx:1292
 AliRelAlignerKalman.cxx:1293
 AliRelAlignerKalman.cxx:1294
 AliRelAlignerKalman.cxx:1295
 AliRelAlignerKalman.cxx:1296
 AliRelAlignerKalman.cxx:1297
 AliRelAlignerKalman.cxx:1298
 AliRelAlignerKalman.cxx:1299
 AliRelAlignerKalman.cxx:1300
 AliRelAlignerKalman.cxx:1301
 AliRelAlignerKalman.cxx:1302
 AliRelAlignerKalman.cxx:1303
 AliRelAlignerKalman.cxx:1304
 AliRelAlignerKalman.cxx:1305
 AliRelAlignerKalman.cxx:1306
 AliRelAlignerKalman.cxx:1307
 AliRelAlignerKalman.cxx:1308
 AliRelAlignerKalman.cxx:1309
 AliRelAlignerKalman.cxx:1310
 AliRelAlignerKalman.cxx:1311
 AliRelAlignerKalman.cxx:1312
 AliRelAlignerKalman.cxx:1313
 AliRelAlignerKalman.cxx:1314
 AliRelAlignerKalman.cxx:1315
 AliRelAlignerKalman.cxx:1316
 AliRelAlignerKalman.cxx:1317
 AliRelAlignerKalman.cxx:1318
 AliRelAlignerKalman.cxx:1319
 AliRelAlignerKalman.cxx:1320
 AliRelAlignerKalman.cxx:1321
 AliRelAlignerKalman.cxx:1322
 AliRelAlignerKalman.cxx:1323
 AliRelAlignerKalman.cxx:1324
 AliRelAlignerKalman.cxx:1325
 AliRelAlignerKalman.cxx:1326
 AliRelAlignerKalman.cxx:1327
 AliRelAlignerKalman.cxx:1328
 AliRelAlignerKalman.cxx:1329
 AliRelAlignerKalman.cxx:1330
 AliRelAlignerKalman.cxx:1331
 AliRelAlignerKalman.cxx:1332
 AliRelAlignerKalman.cxx:1333
 AliRelAlignerKalman.cxx:1334
 AliRelAlignerKalman.cxx:1335
 AliRelAlignerKalman.cxx:1336
 AliRelAlignerKalman.cxx:1337
 AliRelAlignerKalman.cxx:1338
 AliRelAlignerKalman.cxx:1339
 AliRelAlignerKalman.cxx:1340
 AliRelAlignerKalman.cxx:1341
 AliRelAlignerKalman.cxx:1342
 AliRelAlignerKalman.cxx:1343
 AliRelAlignerKalman.cxx:1344
 AliRelAlignerKalman.cxx:1345
 AliRelAlignerKalman.cxx:1346
 AliRelAlignerKalman.cxx:1347
 AliRelAlignerKalman.cxx:1348
 AliRelAlignerKalman.cxx:1349
 AliRelAlignerKalman.cxx:1350
 AliRelAlignerKalman.cxx:1351
 AliRelAlignerKalman.cxx:1352
 AliRelAlignerKalman.cxx:1353
 AliRelAlignerKalman.cxx:1354
 AliRelAlignerKalman.cxx:1355
 AliRelAlignerKalman.cxx:1356
 AliRelAlignerKalman.cxx:1357
 AliRelAlignerKalman.cxx:1358
 AliRelAlignerKalman.cxx:1359
 AliRelAlignerKalman.cxx:1360
 AliRelAlignerKalman.cxx:1361
 AliRelAlignerKalman.cxx:1362
 AliRelAlignerKalman.cxx:1363
 AliRelAlignerKalman.cxx:1364
 AliRelAlignerKalman.cxx:1365
 AliRelAlignerKalman.cxx:1366
 AliRelAlignerKalman.cxx:1367
 AliRelAlignerKalman.cxx:1368
 AliRelAlignerKalman.cxx:1369
 AliRelAlignerKalman.cxx:1370
 AliRelAlignerKalman.cxx:1371
 AliRelAlignerKalman.cxx:1372
 AliRelAlignerKalman.cxx:1373
 AliRelAlignerKalman.cxx:1374
 AliRelAlignerKalman.cxx:1375
 AliRelAlignerKalman.cxx:1376
 AliRelAlignerKalman.cxx:1377
 AliRelAlignerKalman.cxx:1378
 AliRelAlignerKalman.cxx:1379
 AliRelAlignerKalman.cxx:1380
 AliRelAlignerKalman.cxx:1381
 AliRelAlignerKalman.cxx:1382
 AliRelAlignerKalman.cxx:1383
 AliRelAlignerKalman.cxx:1384
 AliRelAlignerKalman.cxx:1385
 AliRelAlignerKalman.cxx:1386
 AliRelAlignerKalman.cxx:1387
 AliRelAlignerKalman.cxx:1388
 AliRelAlignerKalman.cxx:1389
 AliRelAlignerKalman.cxx:1390
 AliRelAlignerKalman.cxx:1391
 AliRelAlignerKalman.cxx:1392
 AliRelAlignerKalman.cxx:1393
 AliRelAlignerKalman.cxx:1394
 AliRelAlignerKalman.cxx:1395
 AliRelAlignerKalman.cxx:1396
 AliRelAlignerKalman.cxx:1397
 AliRelAlignerKalman.cxx:1398
 AliRelAlignerKalman.cxx:1399
 AliRelAlignerKalman.cxx:1400
 AliRelAlignerKalman.cxx:1401
 AliRelAlignerKalman.cxx:1402
 AliRelAlignerKalman.cxx:1403
 AliRelAlignerKalman.cxx:1404
 AliRelAlignerKalman.cxx:1405
 AliRelAlignerKalman.cxx:1406
 AliRelAlignerKalman.cxx:1407
 AliRelAlignerKalman.cxx:1408
 AliRelAlignerKalman.cxx:1409
 AliRelAlignerKalman.cxx:1410
 AliRelAlignerKalman.cxx:1411
 AliRelAlignerKalman.cxx:1412
 AliRelAlignerKalman.cxx:1413
 AliRelAlignerKalman.cxx:1414
 AliRelAlignerKalman.cxx:1415
 AliRelAlignerKalman.cxx:1416
 AliRelAlignerKalman.cxx:1417
 AliRelAlignerKalman.cxx:1418
 AliRelAlignerKalman.cxx:1419
 AliRelAlignerKalman.cxx:1420
 AliRelAlignerKalman.cxx:1421
 AliRelAlignerKalman.cxx:1422
 AliRelAlignerKalman.cxx:1423
 AliRelAlignerKalman.cxx:1424
 AliRelAlignerKalman.cxx:1425
 AliRelAlignerKalman.cxx:1426
 AliRelAlignerKalman.cxx:1427
 AliRelAlignerKalman.cxx:1428
 AliRelAlignerKalman.cxx:1429
 AliRelAlignerKalman.cxx:1430
 AliRelAlignerKalman.cxx:1431
 AliRelAlignerKalman.cxx:1432
 AliRelAlignerKalman.cxx:1433
 AliRelAlignerKalman.cxx:1434
 AliRelAlignerKalman.cxx:1435
 AliRelAlignerKalman.cxx:1436
 AliRelAlignerKalman.cxx:1437
 AliRelAlignerKalman.cxx:1438
 AliRelAlignerKalman.cxx:1439
 AliRelAlignerKalman.cxx:1440
 AliRelAlignerKalman.cxx:1441
 AliRelAlignerKalman.cxx:1442
 AliRelAlignerKalman.cxx:1443
 AliRelAlignerKalman.cxx:1444
 AliRelAlignerKalman.cxx:1445
 AliRelAlignerKalman.cxx:1446
 AliRelAlignerKalman.cxx:1447
 AliRelAlignerKalman.cxx:1448
 AliRelAlignerKalman.cxx:1449
 AliRelAlignerKalman.cxx:1450
 AliRelAlignerKalman.cxx:1451
 AliRelAlignerKalman.cxx:1452
 AliRelAlignerKalman.cxx:1453
 AliRelAlignerKalman.cxx:1454
 AliRelAlignerKalman.cxx:1455
 AliRelAlignerKalman.cxx:1456
 AliRelAlignerKalman.cxx:1457
 AliRelAlignerKalman.cxx:1458
 AliRelAlignerKalman.cxx:1459
 AliRelAlignerKalman.cxx:1460
 AliRelAlignerKalman.cxx:1461
 AliRelAlignerKalman.cxx:1462
 AliRelAlignerKalman.cxx:1463
 AliRelAlignerKalman.cxx:1464
 AliRelAlignerKalman.cxx:1465
 AliRelAlignerKalman.cxx:1466
 AliRelAlignerKalman.cxx:1467
 AliRelAlignerKalman.cxx:1468
 AliRelAlignerKalman.cxx:1469
 AliRelAlignerKalman.cxx:1470
 AliRelAlignerKalman.cxx:1471
 AliRelAlignerKalman.cxx:1472
 AliRelAlignerKalman.cxx:1473
 AliRelAlignerKalman.cxx:1474
 AliRelAlignerKalman.cxx:1475
 AliRelAlignerKalman.cxx:1476
 AliRelAlignerKalman.cxx:1477
 AliRelAlignerKalman.cxx:1478
 AliRelAlignerKalman.cxx:1479
 AliRelAlignerKalman.cxx:1480
 AliRelAlignerKalman.cxx:1481
 AliRelAlignerKalman.cxx:1482
 AliRelAlignerKalman.cxx:1483
 AliRelAlignerKalman.cxx:1484
 AliRelAlignerKalman.cxx:1485
 AliRelAlignerKalman.cxx:1486
 AliRelAlignerKalman.cxx:1487
 AliRelAlignerKalman.cxx:1488
 AliRelAlignerKalman.cxx:1489
 AliRelAlignerKalman.cxx:1490
 AliRelAlignerKalman.cxx:1491
 AliRelAlignerKalman.cxx:1492
 AliRelAlignerKalman.cxx:1493
 AliRelAlignerKalman.cxx:1494
 AliRelAlignerKalman.cxx:1495
 AliRelAlignerKalman.cxx:1496
 AliRelAlignerKalman.cxx:1497
 AliRelAlignerKalman.cxx:1498
 AliRelAlignerKalman.cxx:1499
 AliRelAlignerKalman.cxx:1500
 AliRelAlignerKalman.cxx:1501
 AliRelAlignerKalman.cxx:1502
 AliRelAlignerKalman.cxx:1503
 AliRelAlignerKalman.cxx:1504
 AliRelAlignerKalman.cxx:1505
 AliRelAlignerKalman.cxx:1506
 AliRelAlignerKalman.cxx:1507
 AliRelAlignerKalman.cxx:1508
 AliRelAlignerKalman.cxx:1509
 AliRelAlignerKalman.cxx:1510
 AliRelAlignerKalman.cxx:1511
 AliRelAlignerKalman.cxx:1512
 AliRelAlignerKalman.cxx:1513
 AliRelAlignerKalman.cxx:1514
 AliRelAlignerKalman.cxx:1515
 AliRelAlignerKalman.cxx:1516
 AliRelAlignerKalman.cxx:1517
 AliRelAlignerKalman.cxx:1518
 AliRelAlignerKalman.cxx:1519
 AliRelAlignerKalman.cxx:1520
 AliRelAlignerKalman.cxx:1521
 AliRelAlignerKalman.cxx:1522
 AliRelAlignerKalman.cxx:1523
 AliRelAlignerKalman.cxx:1524
 AliRelAlignerKalman.cxx:1525
 AliRelAlignerKalman.cxx:1526
 AliRelAlignerKalman.cxx:1527
 AliRelAlignerKalman.cxx:1528
 AliRelAlignerKalman.cxx:1529
 AliRelAlignerKalman.cxx:1530
 AliRelAlignerKalman.cxx:1531
 AliRelAlignerKalman.cxx:1532
 AliRelAlignerKalman.cxx:1533
 AliRelAlignerKalman.cxx:1534
 AliRelAlignerKalman.cxx:1535
 AliRelAlignerKalman.cxx:1536
 AliRelAlignerKalman.cxx:1537
 AliRelAlignerKalman.cxx:1538
 AliRelAlignerKalman.cxx:1539
 AliRelAlignerKalman.cxx:1540
 AliRelAlignerKalman.cxx:1541
 AliRelAlignerKalman.cxx:1542
 AliRelAlignerKalman.cxx:1543
 AliRelAlignerKalman.cxx:1544
 AliRelAlignerKalman.cxx:1545
 AliRelAlignerKalman.cxx:1546
 AliRelAlignerKalman.cxx:1547
 AliRelAlignerKalman.cxx:1548
 AliRelAlignerKalman.cxx:1549
 AliRelAlignerKalman.cxx:1550
 AliRelAlignerKalman.cxx:1551
 AliRelAlignerKalman.cxx:1552
 AliRelAlignerKalman.cxx:1553
 AliRelAlignerKalman.cxx:1554
 AliRelAlignerKalman.cxx:1555
 AliRelAlignerKalman.cxx:1556
 AliRelAlignerKalman.cxx:1557
 AliRelAlignerKalman.cxx:1558
 AliRelAlignerKalman.cxx:1559
 AliRelAlignerKalman.cxx:1560
 AliRelAlignerKalman.cxx:1561
 AliRelAlignerKalman.cxx:1562
 AliRelAlignerKalman.cxx:1563
 AliRelAlignerKalman.cxx:1564
 AliRelAlignerKalman.cxx:1565
 AliRelAlignerKalman.cxx:1566
 AliRelAlignerKalman.cxx:1567
 AliRelAlignerKalman.cxx:1568
 AliRelAlignerKalman.cxx:1569
 AliRelAlignerKalman.cxx:1570
 AliRelAlignerKalman.cxx:1571
 AliRelAlignerKalman.cxx:1572
 AliRelAlignerKalman.cxx:1573
 AliRelAlignerKalman.cxx:1574
 AliRelAlignerKalman.cxx:1575
 AliRelAlignerKalman.cxx:1576
 AliRelAlignerKalman.cxx:1577
 AliRelAlignerKalman.cxx:1578
 AliRelAlignerKalman.cxx:1579
 AliRelAlignerKalman.cxx:1580