/*
$Log$
+Revision 1.13 2001/10/12 22:07:20 nilsen
+A patch for C++ io manipulation functions so that they will work both
+with GNU gcc 2.96 and GNU gcc 3.01 compilers. Needs to be tested with
+other platforms.
+
+Revision 1.12 2001/08/24 21:06:37 nilsen
+Added more documentation, fixed up some coding violations, and some
+forward declorations.
+
+Revision 1.11 2001/05/16 08:17:49 hristov
+Bug fixed in the StepManager to account for the difference in the geometry
+tree for the ITS pixels. This fixes both the funny distribution of pixel
+coordinates and the missing hits/digits/points in many sectors of the ITS
+pixel barrel. Also included is a patch to properly get and use the detector
+dimensions through out the ITS code. (B.Nilsen)
+
+Revision 1.10 2001/04/26 22:44:34 nilsen
+Bug fix.
+
+Revision 1.9 2001/02/09 00:00:57 nilsen
+Fixed compatibility problem with HP unix {ios::fmtflags -> Int_t}. Fixed
+bugs in iostream based streamers used to read and write .det files. Fixed
+some detector sizes. Fixed bugs in some default-special constructors.
+
+Revision 1.8 2001/02/03 00:00:30 nilsen
+New version of AliITSgeom and related files. Now uses automatic streamers,
+set up for new formatted .det file which includes detector information.
+Additional smaller modifications are still to come.
+
*/
+////////////////////////////////////////////////////////////////////////
+// This class is for the Silicon Pixel Detector, SPD, specific geometry.
+// It is being replaced by AliITSsegmentationSPD class. This file also
+// constains classes derived from AliITSgeomSPD which do nothing but
+// initilize this one with predefined values.
+////////////////////////////////////////////////////////////////////////
+
#include <iostream.h>
#include <iomanip.h>
#include <TShape.h>
+#include <TMath.h>
#include "AliITSgeomSPD.h"
return;
}
//______________________________________________________________________
-void AliITSgeomSPD::Print(ostream *os){
+void AliITSgeomSPD::Print(ostream *os) const {
// Standard output format for this class
Int_t i;
+#if defined __GNUC__
+#if __GNUC__ > 2
ios::fmtflags fmt;
+#else
+ Int_t fmt;
+#endif
+#else
+ Int_t fmt;
+#endif
fmt = os->setf(ios::scientific); // set scientific floating point output
*os << "TBRIK" << " ";
*os << setprecision(16) << GetDz() << " ";
*os << fNbinx-1 << " " << fNbinz-1 << " ";
for(i=0;i<fNbinx;i++) *os << setprecision(16) << fLowBinEdgeX[i] << " ";
- for(i=0;i<fNbinx;i++) *os << setprecision(16) << fLowBinEdgeZ[i] << " ";
+ for(i=0;i<fNbinz;i++) *os << setprecision(16) << fLowBinEdgeZ[i] << " ";
*os << endl;
os->flags(fmt);
return;
/*
$Log$
+Revision 1.13 2001/10/12 22:07:20 nilsen
+A patch for C++ io manipulation functions so that they will work both
+with GNU gcc 2.96 and GNU gcc 3.01 compilers. Needs to be tested with
+other platforms.
+
+Revision 1.12 2001/08/24 21:06:37 nilsen
+Added more documentation, fixed up some coding violations, and some
+forward declorations.
+
+Revision 1.11 2001/05/16 08:17:49 hristov
+Bug fixed in the StepManager to account for the difference in the geometry tree for the ITS pixels. This fixes both the funny distribution of pixel coordinates and the missing hits/digits/points in many sectors of the ITS pixel barrel. Also included is a patch to properly get and use the detector dimensions through out the ITS code. (B.Nilsen)
+
+Revision 1.10 2001/04/26 22:44:34 nilsen
+Bug fix.
+
+Revision 1.9 2001/02/09 00:00:57 nilsen
+Fixed compatibility problem with HP unix {ios::fmtflags -> Int_t}. Fixed
+bugs in iostream based streamers used to read and write .det files. Fixed
+some detector sizes. Fixed bugs in some default-special constructors.
+
+Revision 1.8 2001/02/03 00:00:30 nilsen
+New version of AliITSgeom and related files. Now uses automatic streamers,
+set up for new formatted .det file which includes detector information.
+Additional smaller modifications are still to come.
+
Revision 1.7 2000/10/02 16:32:35 barbera
Forward declaration added
for(i=1;i<knbinz;i++) SetLowBinEdgeZ(i+1,GetBinLowEdgeZ(i)+kbinz0);
SetLowBinEdgeZ(knbinz,GetBinLowEdgeZ(knbinz-1)+kbinz1);
- if(dx!=kdx || dz!=kdz) Warning("::Default Creator",
- "Detector size may not be write.");
+ if(TMath::Abs(dx-kdx)>1.0E-4 || TMath::Abs(dz-kdz)>1.0E-4)
+ Warning("Default Creator","Detector size may not be write.");
SetShape("ActiveSPD","Active volume of SPD","SPD SI DET",dx,kdy,dz);
// cout << "AliITSgeomSPD300 default creator called: end" << endl;
}
//=====================================================================
/*
$Log$
+Revision 1.13 2001/10/12 22:07:20 nilsen
+A patch for C++ io manipulation functions so that they will work both
+with GNU gcc 2.96 and GNU gcc 3.01 compilers. Needs to be tested with
+other platforms.
+
+Revision 1.12 2001/08/24 21:06:37 nilsen
+Added more documentation, fixed up some coding violations, and some
+forward declorations.
+
+Revision 1.11 2001/05/16 08:17:49 hristov
+Bug fixed in the StepManager to account for the difference in the geometry tree for the ITS pixels. This fixes both the funny distribution of pixel coordinates and the missing hits/digits/points in many sectors of the ITS pixel barrel. Also included is a patch to properly get and use the detector dimensions through out the ITS code. (B.Nilsen)
+
+Revision 1.10 2001/04/26 22:44:34 nilsen
+Bug fix.
+
+Revision 1.9 2001/02/09 00:00:57 nilsen
+Fixed compatibility problem with HP unix {ios::fmtflags -> Int_t}. Fixed
+bugs in iostream based streamers used to read and write .det files. Fixed
+some detector sizes. Fixed bugs in some default-special constructors.
+
+Revision 1.8 2001/02/03 00:00:30 nilsen
+New version of AliITSgeom and related files. Now uses automatic streamers,
+set up for new formatted .det file which includes detector information.
+Additional smaller modifications are still to come.
+
Revision 1.7 2000/10/02 16:32:35 barbera
Forward declaration added
ClassImp(AliITSgeomSPD425Short)
-AliITSgeomSPD425Short::AliITSgeomSPD425Short(){
+AliITSgeomSPD425Short::AliITSgeomSPD425Short() : AliITSgeomSPD(){
////////////////////////////////////////////////////////////////////////
// default constructor, for ITS post TDR geometry. This only consists of
// a default constructor to construct the defalut post TDR SPD detector
// geometry 256 X 197 425 by 50 micron pixels with interleaved 625 by 50
// micron pixels (large detector).
+////////////////////////////////////////////////////////////////////////
+}
+//----------------------------------------------------------------------
+AliITSgeomSPD425Short::AliITSgeomSPD425Short(Int_t npar,Float_t *par) :
+ AliITSgeomSPD(){
+////////////////////////////////////////////////////////////////////////
+// Standard constructor, for ITS post TDR geometry. This only consists of
+// a default constructor to construct the defalut post TDR SPD detector
+// geometry 256 X 197 425 by 50 micron pixels with interleaved 625 by 50
+// micron pixels (large detector).
////////////////////////////////////////////////////////////////////////
- const Float_t kdx=0.6400,kdy=0.0075,kdz=4.2650; // cm; Standard pixel
- // detector size is 2dx
- // wide, 2dz long, and
- // 2dy thick. Geant 3.12
- // units.
+ const Float_t kdx=0.6400/*,kdy=0.015*/,kdz=3.480; // cm; Standard pixel
+ // detector size is 2dx
+ // wide, 2dz long, and
+ // 2dy thick. Geant 3.12
+ // units.
const Float_t kbinx0 = 0.0050; // cm; Standard pixel size in x direction.
const Int_t knbinx = 256; // number of pixels along x direction.
const Float_t kbinz0 = 0.0425; // cm; Standard pixel size in z direction.
const Float_t kbinz1 = 0.0625; // cm; Special pixel size in z direction.
- const Int_t knbinz = 163; // number of pixels along z direction.
+ const Int_t knbinz = 160; // number of pixels along z direction.
Int_t i;
Float_t dx,dz,*binSizeX,*binSizeZ;
binSizeZ[ 31] = kbinz1;
binSizeZ[ 32] = kbinz1;
+ binSizeZ[ 63] = kbinz1;
binSizeZ[ 64] = kbinz1;
- binSizeZ[ 65] = kbinz1;
- binSizeZ[ 97] = kbinz1;
- binSizeZ[ 98] = kbinz1;
+ binSizeZ[ 95] = kbinz1;
+ binSizeZ[ 96] = kbinz1;
- binSizeZ[130] = kbinz1;
- binSizeZ[131] = kbinz1;
+ binSizeZ[127] = kbinz1;
+ binSizeZ[128] = kbinz1;
// correct detector size for bin size.
dx = 0.0;
for(i=0;i<knbinz;i++) dz += binSizeZ[i];
dz *= 0.5;
- SetShape("ActiveSPD","Active volume of SPD","SPD SI DET",dx,kdy,dz);
- if(dx!=kdx || dz!=kdz) Warning("AliITSgeomSPD425Short::Default Creator",
- "Detector size may not be write.");
+ SetShape("ActiveSPD","Active volume of SPD","SPD SI DET",
+ par[0],par[1],par[2]);
+ if(TMath::Abs(dx-kdx)>1.0E-4 || TMath::Abs(dz-kdz)>1.0E-4)
+ Warning("Default Creator","Detector size may not be write.");
InitLowBinEdgeX(); // array of bin sizes along x.
InitLowBinEdgeZ(); // array of bin sizes along x.
/*
$Log$
+Revision 1.13 2001/10/12 22:07:20 nilsen
+A patch for C++ io manipulation functions so that they will work both
+with GNU gcc 2.96 and GNU gcc 3.01 compilers. Needs to be tested with
+other platforms.
+
+Revision 1.12 2001/08/24 21:06:37 nilsen
+Added more documentation, fixed up some coding violations, and some
+forward declorations.
+
+Revision 1.11 2001/05/16 08:17:49 hristov
+Bug fixed in the StepManager to account for the difference in the geometry tree for the ITS pixels. This fixes both the funny distribution of pixel coordinates and the missing hits/digits/points in many sectors of the ITS pixel barrel. Also included is a patch to properly get and use the detector dimensions through out the ITS code. (B.Nilsen)
+
+Revision 1.10 2001/04/26 22:44:34 nilsen
+Bug fix.
+
+Revision 1.9 2001/02/09 00:00:57 nilsen
+Fixed compatibility problem with HP unix {ios::fmtflags -> Int_t}. Fixed
+bugs in iostream based streamers used to read and write .det files. Fixed
+some detector sizes. Fixed bugs in some default-special constructors.
+
+Revision 1.8 2001/02/03 00:00:30 nilsen
+New version of AliITSgeom and related files. Now uses automatic streamers,
+set up for new formatted .det file which includes detector information.
+Additional smaller modifications are still to come.
+
Revision 1.7 2000/10/02 16:32:35 barbera
Forward declaration added
const Int_t knbinx = 256; // number of pixels along x direction.
const Float_t kbinz0 = 0.0425; // cm; Standard pixel size in z direction.
const Float_t kbinz1 = 0.0625; // cm; Special pixel size in z direction.
- const Int_t knbinz = 196; // number of pixels along z direction.
+ const Int_t knbinz = 192; // number of pixels along z direction.
Int_t i;
Float_t dx,dz,*binSizeX,*binSizeZ;
binSizeZ[ 31] = kbinz1;
binSizeZ[ 32] = kbinz1;
+ binSizeZ[ 63] = kbinz1;
binSizeZ[ 64] = kbinz1;
- binSizeZ[ 65] = kbinz1;
- binSizeZ[ 97] = kbinz1;
- binSizeZ[ 98] = kbinz1;
+ binSizeZ[ 95] = kbinz1;
+ binSizeZ[ 96] = kbinz1;
- binSizeZ[130] = kbinz1;
- binSizeZ[131] = kbinz1;
+ binSizeZ[127] = kbinz1;
+ binSizeZ[128] = kbinz1;
- binSizeZ[163] = kbinz1;
- binSizeZ[164] = kbinz1;
+ binSizeZ[159] = kbinz1;
+ binSizeZ[160] = kbinz1;
// correct detector size for bin size.
dx = 0.0;
dz *= 0.5;
SetShape("ActiveSPD","Active volume of SPD","SPD SI DET",dx,kdy,dz);
- if(dx!=kdx || dz!=kdz) Warning("AliITSgeomSPD425Long::Default Creator",
- "Detector size may not be write.");
+ if(TMath::Abs(dx-kdx)>1.0E-4 || TMath::Abs(dz-kdz)>1.0E-4)
+ Warning("Default Creator","Detector size may not be write.");
InitLowBinEdgeX(); // array of bin sizes along x.
InitLowBinEdgeZ(); // array of bin sizes along x.