1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
7 * Permission to use, copy, modify and distribute this software and its *
8 * documentation strictly for non-commercial purposes is hereby granted *
9 * without fee, provided that the above copyright notice appears in all *
10 * copies and that both the copyright notice and this permission notice *
11 * appear in the supporting documentation. The authors make no claims *
12 * about the suitability of this software for any purpose. It is *
13 * provided "as is" without express or implied warranty. *
14 **************************************************************************/
18 Revision 1.1.2.1 2000/06/04 16:32:31 Nilsen
19 A new class to hold the matrix information needed by AliITSgeom.
26 #include "AliITSgeomMatrix.h"
28 ClassImp(AliITSgeomMatrix)
29 //----------------------------------------------------------------------
30 AliITSgeomMatrix::AliITSgeomMatrix(){
31 ////////////////////////////////////////////////////////////////////////
32 // The Default constructor for the AliITSgeomMatrix class. By Default
33 // the angles of rotations are set to zero, meaning that the rotation
34 // matrix is the unit matrix. The translation vector is also set to zero
35 // as are the module id number. The detector type is set to -1 (an undefined
36 // value). The full rotation matrix is kept so that the evaluation
37 // of a coordinate transformation can be done quickly and with a minimum
38 // of CPU overhead. The basic coordinate systems are the ALICE global
39 // coordinate system and the detector local coordinate system. In general
40 // this structure is not limited to just those two coordinate systems.
43 <img src="picts/ITS/AliISgeomMatrix_L1.gif">
46 ////////////////////////////////////////////////////////////////////////
49 fDetectorIndex = -1; // a value never defined.
52 frot[i] = ftran[i] = 0.0;
53 for(j=0;j<3;j++) fm[i][j] = 0.0;
55 fm[0][0] = fm[1][1] = fm[2][2] = 1.0;
57 //----------------------------------------------------------------------
58 AliITSgeomMatrix::AliITSgeomMatrix(const AliITSgeomMatrix &sourse){
59 ////////////////////////////////////////////////////////////////////////
60 // The standard copy constructor. This make a full / proper copy of
62 ////////////////////////////////////////////////////////////////////////
65 this->fDetectorIndex = sourse.fDetectorIndex;
67 this->fid[i] = sourse.fid[i];
68 this->frot[i] = sourse.frot[i];
69 this->ftran[i] = sourse.ftran[i];
70 for(j=0;j<3;j++) this->fm[i][j] = sourse.fm[i][j];
73 //----------------------------------------------------------------------
74 void AliITSgeomMatrix::operator=(const AliITSgeomMatrix &sourse){
75 ////////////////////////////////////////////////////////////////////////
76 // The standard = operator. This make a full / proper copy of
78 ////////////////////////////////////////////////////////////////////////
81 this->fDetectorIndex = sourse.fDetectorIndex;
83 this->fid[i] = sourse.fid[i];
84 this->frot[i] = sourse.frot[i];
85 this->ftran[i] = sourse.ftran[i];
86 for(j=0;j<3;j++) this->fm[i][j] = sourse.fm[i][j];
89 //----------------------------------------------------------------------
90 AliITSgeomMatrix::AliITSgeomMatrix(const Int_t idt,const Int_t id[3],
91 const Double_t rot[3],const Double_t tran[3]){
92 ////////////////////////////////////////////////////////////////////////
93 // This is a constructor for the AliITSgeomMatrix class. The matrix is
94 // defined by 3 standard rotation angles [radians], and the translation
95 // vector tran [cm]. In addition the layer, ladder, and detector number
96 // for this particular module and the type of module must be given.
97 // The full rotation matrix is kept so that the evaluation
98 // of a coordinate transformation can be done quickly and with a minimum
99 // of CPU overhead. The basic coordinate systems are the ALICE global
100 // coordinate system and the detector local coordinate system. In general
101 // this structure is not limited to just those two coordinate systems.
104 <img src="picts/ITS/AliISgeomMatrix_L1.gif">
107 ////////////////////////////////////////////////////////////////////////
110 fDetectorIndex = idt; // a value never defined.
116 this->MatrixFromAngle();
118 //----------------------------------------------------------------------
119 AliITSgeomMatrix::AliITSgeomMatrix(const Int_t idt, const Int_t id[3],
120 const Double_t matrix[3][3],
121 const Double_t tran[3]){
122 ////////////////////////////////////////////////////////////////////////
123 // This is a constructor for the AliITSgeomMatrix class. The rotation matrix
124 // is given as one of the inputs, and the translation vector tran [cm]. In
125 // addition the layer, ladder, and detector number for this particular
126 // module and the type of module must be given. The full rotation matrix
127 // is kept so that the evaluation of a coordinate transformation can be
128 // done quickly and with a minimum of CPU overhead. The basic coordinate
129 // systems are the ALICE global coordinate system and the detector local
130 // coordinate system. In general this structure is not limited to just
131 // those two coordinate systems.
134 <img src="picts/ITS/AliISgeomMatrix_L1.gif">
137 ////////////////////////////////////////////////////////////////////////
140 fDetectorIndex = idt; // a value never defined.
144 for(j=0;j<3;j++) fm[i][j] = matrix[i][j];
146 this->AngleFromMatrix();
148 //----------------------------------------------------------------------
149 void AliITSgeomMatrix::SixAnglesFromMatrix(Double_t *ang){
150 ////////////////////////////////////////////////////////////////////////
151 // This function returns the 6 GEANT 3.21 rotation angles [degrees] in
152 // the array ang which must be at least [6] long.
153 ////////////////////////////////////////////////////////////////////////
154 Double_t si,c=180./TMath::Pi();
156 ang[1] = TMath::ATan2(fm[0][1],fm[0][0]);
157 if(TMath::Cos(ang[1])!=0.0) si = fm[0][0]/TMath::Cos(ang[1]);
158 else si = fm[0][1]/TMath::Sin(ang[1]);
159 ang[0] = TMath::ATan2(si,fm[0][2]);
161 ang[3] = TMath::ATan2(fm[1][1],fm[1][0]);
162 if(TMath::Cos(ang[3])!=0.0) si = fm[1][0]/TMath::Cos(ang[3]);
163 else si = fm[1][1]/TMath::Sin(ang[3]);
164 ang[4] = TMath::ATan2(si,fm[1][2]);
166 ang[6] = TMath::ATan2(fm[2][1],fm[2][0]);
167 if(TMath::Cos(ang[6])!=0.0) si = fm[2][0]/TMath::Cos(ang[6]);
168 else si = fm[2][1]/TMath::Sin(ang[6]);
169 ang[5] = TMath::ATan2(si,fm[2][2]);
171 for(Int_t i=0;i<6;i++) {ang[i] *= c; if(ang[i]<0.0) ang[i] += 360.;}
173 //----------------------------------------------------------------------
174 void AliITSgeomMatrix::MatrixFromSixAngles(const Double_t *ang){
175 ////////////////////////////////////////////////////////////////////////
176 // Given the 6 GEANT 3.21 rotation angles [degree], this will compute and
177 // set the rotations matrix and 3 standard rotation angles [radians].
178 // These angles and rotation matrix are overwrite the existing values in
180 ////////////////////////////////////////////////////////////////////////
182 Double_t si,lr[9],c=TMath::Pi()/180.;
184 si = TMath::Sin(c*ang[0]);
185 if(ang[0]== 90.0) si = +1.0;
186 if(ang[0]==270.0) si = -1.0;
187 if(ang[0]== 0.0||ang[0]==180.) si = 0.0;
188 lr[0] = si * TMath::Cos(c*ang[1]);
189 lr[1] = si * TMath::Sin(c*ang[1]);
190 lr[2] = TMath::Cos(c*ang[0]);
191 if(ang[0]== 90.0||ang[0]==270.) lr[2] = 0.0;
192 if(ang[0]== 0.0) lr[2] = +1.0;
193 if(ang[0]==180.0) lr[2] = -1.0;
195 si = TMath::Sin(c*ang[2]);
196 if(ang[2]== 90.0) si = +1.0;
197 if(ang[2]==270.0) si = -1.0;
198 if(ang[2]== 0.0||ang[2]==180.) si = 0.0;
199 lr[3] = si * TMath::Cos(c*ang[3]);
200 lr[4] = si * TMath::Sin(c*ang[3]);
201 lr[5] = TMath::Cos(c*ang[2]);
202 if(ang[2]== 90.0||ang[2]==270.) lr[5] = 0.0;
203 if(ang[2]== 0.0) lr[5] = +1.0;
204 if(ang[2]==180.0) lr[5] = -1.0;
206 si = TMath::Sin(c*ang[4]);
207 if(ang[4]== 90.0) si = +1.0;
208 if(ang[4]==270.0) si = -1.0;
209 if(ang[4]== 0.0||ang[4]==180.) si = 0.0;
210 lr[6] = si * TMath::Cos(c*ang[5]);
211 lr[7] = si * TMath::Sin(c*ang[5]);
212 lr[8] = TMath::Cos(c*ang[4]);
213 if(ang[4]== 90.0||ang[4]==270.0) lr[8] = 0.0;
214 if(ang[4]== 0.0) lr[8] = +1.0;
215 if(ang[4]==180.0) lr[8] = -1.0;
216 // Normalize these elements and fill matrix fm.
217 for(i=0;i<3;i++){// reuse si.
219 for(j=0;j<3;j++) si += lr[3*i+j]*lr[3*i+j];
220 si = TMath::Sqrt(1./si);
221 for(j=0;j<3;j++) fm[i][j] = si*lr[3*i+j];
223 this->AngleFromMatrix();
225 //----------------------------------------------------------------------
226 AliITSgeomMatrix::AliITSgeomMatrix(const Double_t rotd[6]/*degrees*/,
227 const Int_t idt,const Int_t id[3],
228 const Double_t tran[3]){
229 ////////////////////////////////////////////////////////////////////////
230 // This is a constructor for the AliITSgeomMatrix class. The matrix is
231 // defined by the 6 GEANT 3.21 rotation angles [degrees], and the translation
232 // vector tran [cm]. In addition the layer, ladder, and detector number
233 // for this particular module and the type of module must be given.
234 // The full rotation matrix is kept so that the evaluation
235 // of a coordinate transformation can be done quickly and with a minimum
236 // of CPU overhead. The basic coordinate systems are the ALICE global
237 // coordinate system and the detector local coordinate system. In general
238 // this structure is not limited to just those two coordinate systems.
241 <img src="picts/ITS/AliISgeomMatrix_L1.gif">
244 ////////////////////////////////////////////////////////////////////////
247 fDetectorIndex = idt; // a value never defined.
252 this->MatrixFromSixAngles(rotd);
254 //----------------------------------------------------------------------
255 void AliITSgeomMatrix::AngleFromMatrix(){
256 ////////////////////////////////////////////////////////////////////////
257 // Computes the angles from the rotation matrix up to a phase of 180 degrees.
258 ////////////////////////////////////////////////////////////////////////
260 // get angles from matrix up to a phase of 180 degrees.
262 rx = TMath::ATan2(fm[2][1],fm[2][2]);if(rx<0.0) rx += 2.0*TMath::Pi();
263 ry = TMath::ASin(fm[0][2]); if(ry<0.0) ry += 2.0*TMath::Pi();
264 rz = TMath::ATan2(fm[1][1],fm[0][0]);if(rz<0.0) rz += 2.0*TMath::Pi();
270 //----------------------------------------------------------------------
271 void AliITSgeomMatrix::MatrixFromAngle(){
272 ////////////////////////////////////////////////////////////////////////
273 // Computes the Rotation matrix from the angles [radians] kept in this
275 ////////////////////////////////////////////////////////////////////////
276 Double_t sx,sy,sz,cx,cy,cz;
278 sx = TMath::Sin(frot[0]); cx = TMath::Cos(frot[0]);
279 sy = TMath::Sin(frot[1]); cy = TMath::Cos(frot[1]);
280 sz = TMath::Sin(frot[2]); cz = TMath::Cos(frot[2]);
281 fm[0][0] = cz*cy; // fr[0]
282 fm[0][1] = -cz*sy*sx - sz*cx; // fr[1]
283 fm[0][2] = -cz*sy*cx + sz*sx; // fr[2]
284 fm[1][0] = sz*cy; // fr[3]
285 fm[1][1] = -sz*sy*sx + cz*cx; // fr[4]
286 fm[1][2] = -sz*sy*cx - cz*sx; // fr[5]
287 fm[2][0] = sy; // fr[6]
288 fm[2][1] = cy*sx; // fr[7]
289 fm[2][2] = cy*cx; // fr[8]
292 //----------------------------------------------------------------------
293 void AliITSgeomMatrix::GtoLPosition(const Double_t g0[3],Double_t l[3]){
294 ////////////////////////////////////////////////////////////////////////
295 // Returns the local coordinates given the global coordinates [cm].
296 ////////////////////////////////////////////////////////////////////////
300 for(i=0;i<3;i++) g[i] = g0[i] - ftran[i];
303 for(j=0;j<3;j++) l[i] += fm[i][j]*g[j];
304 // g = R l + translation
308 //----------------------------------------------------------------------
309 void AliITSgeomMatrix::LtoGPosition(const Double_t l[3],Double_t g[3]){
310 ////////////////////////////////////////////////////////////////////////
311 // Returns the global coordinates given the local coordinates [cm].
312 ////////////////////////////////////////////////////////////////////////
317 for(j=0;j<3;j++) g[i] += fm[j][i]*l[j];
319 // g = R^t l + translation
323 //----------------------------------------------------------------------
324 void AliITSgeomMatrix::GtoLMomentum(const Double_t g[3],Double_t l[3]){
325 ////////////////////////////////////////////////////////////////////////
326 // Returns the local coordinates of the momentum given the global
327 // coordinates of the momentum. It transforms just like GtoLPosition
328 // except that the translation vector is zero.
329 ////////////////////////////////////////////////////////////////////////
334 for(j=0;j<3;j++) l[i] += fm[i][j]*g[j];
339 //----------------------------------------------------------------------
340 void AliITSgeomMatrix::LtoGMomentum(const Double_t l[3],Double_t g[3]){
341 ////////////////////////////////////////////////////////////////////////
342 // Returns the Global coordinates of the momentum given the local
343 // coordinates of the momentum. It transforms just like LtoGPosition
344 // except that the translation vector is zero.
345 ////////////////////////////////////////////////////////////////////////
350 for(j=0;j<3;j++) g[i] += fm[j][i]*l[j];
355 //----------------------------------------------------------------------
356 void AliITSgeomMatrix::GtoLPositionError(const Double_t g[3][3],
358 ////////////////////////////////////////////////////////////////////////
359 // Given an Uncertainty matrix in Global coordinates it is rotated so that
360 // its representation in local coordinates can be returned. There is no
361 // effect due to the translation vector or its uncertainty.
362 ////////////////////////////////////////////////////////////////////////
365 for(i=0;i<3;i++)for(j=0;j<3;j++)for(k=0;k<3;k++)for(m=0;m<3;m++)
366 l[i][m] = fm[j][i]*g[j][k]*fm[k][m];
370 //----------------------------------------------------------------------
371 void AliITSgeomMatrix::LtoGPositionError(const Double_t l[3][3],
373 ////////////////////////////////////////////////////////////////////////
374 // Given an Uncertainty matrix in Local coordinates it is rotated so that
375 // its representation in global coordinates can be returned. There is no
376 // effect due to the translation vector or its uncertainty.
377 ////////////////////////////////////////////////////////////////////////
380 for(i=0;i<3;i++)for(j=0;j<3;j++)for(k=0;k<3;k++)for(m=0;m<3;m++)
381 g[i][m] = fm[i][j]*l[j][k]*fm[m][k];
385 //----------------------------------------------------------------------
386 void AliITSgeomMatrix::GtoLPositionTracking(const Double_t g0[3],
388 ////////////////////////////////////////////////////////////////////////
389 // A slightly different coordinate system is used when tracking.
390 // This coordinate system is only relevant when the geometry represents
391 // the cylindrical ALICE ITS geometry. For tracking the Z axis is left
392 // alone but X -> -Y and Y -> X such that X always points out of the
393 // ITS Cylinder for every layer including layer 1 (where the detector
394 // are mounted upside down).
397 <img src="picts/ITS/AliITSgeomMatrix_T1.gif">
400 ////////////////////////////////////////////////////////////////////////
403 this->GtoLPosition(g0,l0);
404 if(fid[0]==1){ // for layer 1 the detector are flipped upside down
405 // with respect to the others.
416 //----------------------------------------------------------------------
417 void AliITSgeomMatrix::LtoGPositionTracking(const Double_t l[3],
419 ////////////////////////////////////////////////////////////////////////
420 // A slightly different coordinate system is used when tracking.
421 // This coordinate system is only relevant when the geometry represents
422 // the cylindrical ALICE ITS geometry. For tracking the Z axis is left
423 // alone but X -> -Y and Y -> X such that X always points out of the
424 // ITS Cylinder for every layer including layer 1 (where the detector
425 // are mounted upside down).
428 <img src="picts/ITS/AliITSgeomMatrix_T1.gif">
431 ////////////////////////////////////////////////////////////////////////
434 if(fid[0]==1){ // for layer 1 the detector are flipped upside down
435 // with respect to the others.
444 this->LtoGPosition(l0,g);
447 //----------------------------------------------------------------------
448 void AliITSgeomMatrix::GtoLMomentumTracking(const Double_t g[3],
450 ////////////////////////////////////////////////////////////////////////
451 // A slightly different coordinate system is used when tracking.
452 // This coordinate system is only relevant when the geometry represents
453 // the cylindrical ALICE ITS geometry. For tracking the Z axis is left
454 // alone but X -> -Y and Y -> X such that X always points out of the
455 // ITS Cylinder for every layer including layer 1 (where the detector
456 // are mounted upside down).
459 <img src="picts/ITS/AliITSgeomMatrix_T1.gif">
462 ////////////////////////////////////////////////////////////////////////
465 this->GtoLMomentum(g,l0);
466 if(fid[0]==1){ // for layer 1 the detector are flipped upside down
467 // with respect to the others.
479 //----------------------------------------------------------------------
480 void AliITSgeomMatrix::LtoGMomentumTracking(const Double_t l[3],
482 ////////////////////////////////////////////////////////////////////////
483 // A slightly different coordinate system is used when tracking.
484 // This coordinate system is only relevant when the geometry represents
485 // the cylindrical ALICE ITS geometry. For tracking the Z axis is left
486 // alone but X -> -Y and Y -> X such that X always points out of the
487 // ITS Cylinder for every layer including layer 1 (where the detector
488 // are mounted upside down).
491 <img src="picts/ITS/AliITSgeomMatrix_T1.gif">
494 ////////////////////////////////////////////////////////////////////////
497 if(fid[0]==1){ // for layer 1 the detector are flipped upside down
498 // with respect to the others.
507 this->LtoGMomentum(l0,g);
510 //----------------------------------------------------------------------
511 void AliITSgeomMatrix::GtoLPositionErrorTracking(const Double_t g[3][3],
513 ////////////////////////////////////////////////////////////////////////
514 // A slightly different coordinate system is used when tracking.
515 // This coordinate system is only relevant when the geometry represents
516 // the cylindrical ALICE ITS geometry. For tracking the Z axis is left
517 // alone but X -> -Y and Y -> X such that X always points out of the
518 // ITS Cylinder for every layer including layer 1 (where the detector
519 // are mounted upside down).
522 <img src="picts/ITS/AliITSgeomMatrix_T1.gif">
525 ////////////////////////////////////////////////////////////////////////
528 Double_t A0[3][3] = {{0.,+1.,0.},{-1.,0.,0.},{0.,0.,+1.}};
529 Double_t A1[3][3] = {{0.,-1.,0.},{+1.,0.,0.},{0.,0.,+1.}};
531 if(fid[0]==1) for(i=0;i<3;i++)for(j=0;j<3;j++)for(k=0;k<3;k++)
532 Rt[i][k] = A0[i][j]*fm[j][k];
533 else for(i=0;i<3;i++)for(j=0;j<3;j++)for(k=0;k<3;k++)
534 Rt[i][k] = A1[i][j]*fm[j][k];
535 for(i=0;i<3;i++)for(j=0;j<3;j++)for(k=0;k<3;k++)for(m=0;m<3;m++)
536 l[i][m] = Rt[j][i]*g[j][k]*Rt[k][m];
540 //----------------------------------------------------------------------
541 void AliITSgeomMatrix::LtoGPositionErrorTracking(const Double_t l[3][3],
543 ////////////////////////////////////////////////////////////////////////
544 // A slightly different coordinate system is used when tracking.
545 // This coordinate system is only relevant when the geometry represents
546 // the cylindrical ALICE ITS geometry. For tracking the Z axis is left
547 // alone but X -> -Y and Y -> X such that X always points out of the
548 // ITS Cylinder for every layer including layer 1 (where the detector
549 // are mounted upside down).
552 <img src="picts/ITS/AliITSgeomMatrix_T1.gif">
555 ////////////////////////////////////////////////////////////////////////
558 Double_t A0[3][3] = {{0.,+1.,0.},{-1.,0.,0.},{0.,0.,+1.}};
559 Double_t A1[3][3] = {{0.,-1.,0.},{+1.,0.,0.},{0.,0.,+1.}};
561 if(fid[0]==1) for(i=0;i<3;i++)for(j=0;j<3;j++)for(k=0;k<3;k++)
562 Rt[i][k] = A0[i][j]*fm[j][k];
563 else for(i=0;i<3;i++)for(j=0;j<3;j++)for(k=0;k<3;k++)
564 Rt[i][k] = A1[i][j]*fm[j][k];
565 for(i=0;i<3;i++)for(j=0;j<3;j++)for(k=0;k<3;k++)for(m=0;m<3;m++)
566 g[i][m] = Rt[i][j]*l[j][k]*Rt[m][k];
570 //----------------------------------------------------------------------
571 void AliITSgeomMatrix::PrintTitles(ostream *os){
572 ////////////////////////////////////////////////////////////////////////
573 // Standard output format for this class but it includes variable
574 // names and formatting that makes it easer to read.
575 ////////////////////////////////////////////////////////////////////////
578 *os << "fDetectorIndex=" << fDetectorIndex << " fid[3]={";
579 for(i=0;i<3;i++) *os << fid[i] << " ";
580 *os << "} frot[3]={";
581 for(i=0;i<3;i++) *os << frot[i] << " ";
582 *os << "} ftran[3]={";
583 for(i=0;i<3;i++) *os << ftran[i] << " ";
584 *os << "} fm[3][3]={";
585 for(i=0;i<3;i++){for(j=0;j<3;j++){ *os << fm[i][j] << " ";} *os <<"}{";}
589 //----------------------------------------------------------------------
590 void AliITSgeomMatrix::print(ostream *os){
591 ////////////////////////////////////////////////////////////////////////
592 // Standard output format for this class.
593 ////////////////////////////////////////////////////////////////////////
596 *os << fDetectorIndex << " ";
597 for(i=0;i<3;i++) *os << fid[i] << " ";
598 for(i=0;i<3;i++) *os << frot[i] << " ";
599 for(i=0;i<3;i++) *os << ftran[i] << " ";
600 for(i=0;i<3;i++)for(j=0;j<3;j++) *os << fm[i][j] << " ";
604 //----------------------------------------------------------------------
605 void AliITSgeomMatrix::read(istream *is){
606 ////////////////////////////////////////////////////////////////////////
607 // Standard input format for this class.
608 ////////////////////////////////////////////////////////////////////////
611 *is >> fDetectorIndex;
612 for(i=0;i<3;i++) *is >> fid[i];
613 for(i=0;i<3;i++) *is >> frot[i];
614 for(i=0;i<3;i++) *is >> ftran[i];
615 for(i=0;i<3;i++)for(j=0;j<3;j++) *is >> fm[i][j];
618 //----------------------------------------------------------------------
619 ostream &operator<<(ostream &os,AliITSgeomMatrix &p){
620 ////////////////////////////////////////////////////////////////////////
621 // Standard output streaming function.
622 ////////////////////////////////////////////////////////////////////////
627 //----------------------------------------------------------------------
628 istream &operator>>(istream &is,AliITSgeomMatrix &r){
629 ////////////////////////////////////////////////////////////////////////
630 // Standard input streaming function.
631 ////////////////////////////////////////////////////////////////////////
636 //----------------------------------------------------------------------
637 void AliITSgeomMatrix::Streamer(TBuffer &R__b){
638 ////////////////////////////////////////////////////////////////////////
639 // Stream an object of class AliITSgeomMatrix.
640 ////////////////////////////////////////////////////////////////////////
643 if (R__b.IsReading()) {
644 Version_t R__v = R__b.ReadVersion(&R__s, &R__c);
646 R__b >> fDetectorIndex;
647 R__b.ReadStaticArray(fid);
648 R__b.ReadStaticArray(frot);
649 R__b.ReadStaticArray(ftran);
650 R__b.ReadStaticArray((double*)fm);
651 R__b.CheckByteCount(R__s, R__c, AliITSgeomMatrix::IsA());
653 } else { // R__b.IsWriting()
654 R__c = R__b.WriteVersion(AliITSgeomMatrix::IsA(), kTRUE);
655 R__b << fDetectorIndex;
656 R__b.WriteArray(fid, 3);
657 R__b.WriteArray(frot, 3);
658 R__b.WriteArray(ftran, 3);
659 R__b.WriteArray((double*)fm, 9);
660 R__b.SetByteCount(R__c, kTRUE);
661 } // end if R__b.IsReading()||IsWriting()
663 //______________________________________________________________________