]> git.uio.no Git - u/mrichter/AliRoot.git/blame - MUON/AliMUONAlignment.h
Updated comments for Doxygen
[u/mrichter/AliRoot.git] / MUON / AliMUONAlignment.h
CommitLineData
010eb601 1#ifndef ALIMUONALIGNMENT_H
2#define ALIMUONALIGNMENT_H
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6/* $Id$ */
7
8/// \ingroup rec
9/// \class AliMUONAlignment
10/// \brief Class for alignment of muon spectrometer
11//
12// Authors: Bruce Becker, Javier Castillo
13
14#include <TObject.h>
15
16class TGeoCombiTrans;
17class TClonesArray;
18class AliMillepede;
19class AliMUONGeometryTransformer;
20class AliMUONTrack;
21class AliMUONTrackParam;
22class AliMUONHitForRec;
23
24class AliMUONAlignment:public TObject
25{
26
27public:
28 AliMUONAlignment();
29 virtual ~AliMUONAlignment();
30
31 void ProcessTrack(AliMUONTrack *track);
c4ee792d 32 /// Set geometry transformer
010eb601 33 void SetGeometryTransformer(AliMUONGeometryTransformer * transformer) {
34 fTransform = transformer;
35 }
36
010eb601 37 void FixStation(Int_t iSt);
38 void AllowVariations(Bool_t *bStOnOff);
39 void SetNonLinear(Bool_t *bStOnOff, Bool_t *bVarXYT);
40 void AddConstraints(Bool_t *bStOnOff, Bool_t *bVarXYT);
41 void AddConstraints(Bool_t *bStOnOff, Bool_t *bVarXYT, Bool_t *bDetTLBR);
42 void ResetConstraints();
43
44 void FixParameter(Int_t param, Double_t value);
45 void SetNonLinear(Int_t param);
46 void AddConstraint(Double_t *factor, Double_t value );
47 void InitGlobalParameters(Double_t *par);
c4ee792d 48 /// Set array of local derivatives
010eb601 49 void SetLocalDerivative(Int_t index, Double_t value) {
50 fLocalDerivatives[index] = value;
51 }
c4ee792d 52 /// Set array of global derivatives
010eb601 53 void SetGlobalDerivative(Int_t index, Double_t value) {
54 fGlobalDerivatives[index] = value;
55 }
56 void LocalFit(Int_t iTrack, Double_t *lTrackParam, Int_t lSingleFit);
57 void GlobalFit(Double_t *parameters,Double_t *errors,Double_t *pulls);
58 void PrintGlobalParameters();
59 Double_t GetParError(Int_t iPar);
60
61 AliMUONGeometryTransformer*
62 ReAlign(const AliMUONGeometryTransformer * transformer, double *misAlignments, Bool_t verbose);
63
c4ee792d 64 private:
65 /// Not implemented
010eb601 66 AliMUONAlignment(const AliMUONAlignment& right);
c4ee792d 67 /// Not implemented
010eb601 68 AliMUONAlignment& operator = (const AliMUONAlignment& right);
010eb601 69
70 void Init(Int_t nGlobal, Int_t nLocal, Int_t nStdDev);
71 void ConstrainT(Int_t lDetElem, Int_t lCh, Double_t *lConstraintT, Int_t iVar);
72 void ConstrainL(Int_t lDetElem, Int_t lCh, Double_t *lConstraintL, Int_t iVar);
73 void ConstrainB(Int_t lDetElem, Int_t lCh, Double_t *lConstraintB, Int_t iVar);
74 void ConstrainR(Int_t lDetElem, Int_t lCh, Double_t *lConstraintR, Int_t iVar);
75 void FillDetElemData();
76 void FillRecPointData();
77 void FillTrackParamData();
78 void ResetLocalEquation();
79 void LocalEquationX();
80 void LocalEquationY();
81
82 TGeoCombiTrans ReAlign(const TGeoCombiTrans& transform, double *detElemMisAlignment) const;
83
c4ee792d 84 Bool_t fBFieldOn; ///< Flag for Magnetic filed On/Off
010eb601 85
c4ee792d 86 Bool_t fDoF[3]; ///< Flags degrees of freedom to align (x,y,phi)
87 Double_t fAllowVar[3]; ///< "Encouraged" variation for degrees of freedom
88 Double_t fStartFac; ///< Initial value for chi2 cut
89 ///< if > 1 Iterations in AliMillepede are turned on
90 Double_t fResCutInitial; ///< Cut on residual for first iteration
91 Double_t fResCut; ///< Cut on residual for other iterations
92
93 AliMillepede *fMillepede; ///< Detector independent alignment class
010eb601 94
c4ee792d 95 TClonesArray *fTrackParamAtHit; ///< Array of track parameters
96 TClonesArray *fHitForRecAtHit; ///< Array of track hits
97 AliMUONTrack *fTrack; ///< AliMUONTrack
98 AliMUONHitForRec *fRecHit; ///< AliMUONHitForRec
99 AliMUONTrackParam *fTrackParam; ///< Track parameters
100
101 Int_t fNGlobal; ///< Number of global parameters
102 Int_t fNLocal; ///< Number of local parameters
103 Int_t fNStdDev; ///< Number of standard deviations for chi2 cut
104 Double_t fClustPos[3]; ///< Cluster position
105 Double_t fClustPosLoc[3]; ///< Cluster position in local coordinates
106 Double_t fTrackSlope0[2]; ///< Track slope at reference point
107 Double_t fTrackSlope[2]; ///< Track slope at current point
108 Double_t fTrackPos0[3]; ///< Track intersection at reference point
109 Double_t fTrackPos[3]; ///< Track intersection at current point
110 Double_t fTrackPosLoc[3]; ///< Track intersection at current point in local coordinates
111 Double_t fMeas[2]; ///< Current measurement (depend on B field On/Off)
112 Double_t fSigma[2]; ///< Estimated resolution on measurement
113
114 Double_t fGlobalDerivatives[468]; ///< Array of global derivatives
115 Double_t fLocalDerivatives[4]; ///< Array of local derivatives
116
117 Double_t fConstraintX[468]; ///< Array for constraint equation all X
118 Double_t fConstraintY[468]; ///< Array for constraint equation all Y
119 Double_t fConstraintP[468]; ///< Array for constraint equation all P
120 Double_t fConstraintXT[468]; ///< Array for constraint equation X Top half
121 Double_t fConstraintYT[468]; ///< Array for constraint equation Y Top half
122 Double_t fConstraintPT[468]; ///< Array for constraint equation P Top half
123 Double_t fConstraintXB[468]; ///< Array for constraint equation X Bottom half
124 Double_t fConstraintYB[468]; ///< Array for constraint equation Y Bottom half
125 Double_t fConstraintPB[468]; ///< Array for constraint equation P Bottom half
126 Double_t fConstraintXR[468]; ///< Array for constraint equation X Right half
127 Double_t fConstraintYR[468]; ///< Array for constraint equation Y Right half
128 Double_t fConstraintPR[468]; ///< Array for constraint equation P Right half
129 Double_t fConstraintXL[468]; ///< Array for constraint equation X Left half
130 Double_t fConstraintYL[468]; ///< Array for constraint equation Y Left half
131 Double_t fConstraintPL[468]; ///< Array for constraint equation P Left half
132 Double_t fConstraintX3[468]; ///< Array for constraint equation St3 X
133 Double_t fConstraintY3[468]; ///< Array for constraint equation St3 Y
134 Double_t fConstraintX4[468]; ///< Array for constraint equation St4 X
135 Double_t fConstraintY4[468]; ///< Array for constraint equation St4 Y
136 Double_t fConstraintP4[468]; ///< Array for constraint equation St4 P
137 Double_t fConstraintX5[468]; ///< Array for constraint equation St5 X
138 Double_t fConstraintY5[468]; ///< Array for constraint equation St5 Y
139
140 Int_t fDetElemId; ///< Detection element id
141 Int_t fDetElemNumber; ///< Detection element number
142 Double_t fPhi; ///< Azimuthal tilt of detection element
143 Double_t fCosPhi; ///< Cosine of fPhi
144 Double_t fSinPhi; ///< Sine of fPhi
145 Double_t fDetElemPos[3]; ///< Position of detection element
146
147 AliMUONGeometryTransformer *fTransform; ///< Geometry transformation
148
149 static Int_t fgNSt; ///< Number tracking stations
150 static Int_t fgNCh; ///< Number tracking chambers
151 static Int_t fgNParCh; ///< Number of degrees of freedom per chamber
152 static Int_t fgNDetElem; ///< Total number of detection elements
153 static Int_t fgNDetElemCh[10]; ///< Number of detection elements per chamber
154 static Int_t fgSNDetElemCh[10];///< Sum of detection elements up to this chamber (inc)
010eb601 155
156ClassDef(AliMUONAlignment, 0)};
157
158#endif