/*
$Log$
+Revision 1.21 2000/11/30 11:13:11 barbera
+ Added changes suggested by Federico Carminati on nov, 30, 2000
+
+Revision 1.20 2000/10/07 17:29:51 nilsen
+Blank Line added at end of file to remove a warning for hp compilers
+(Give me a Break!).
+
+Revision 1.19 2000/10/05 20:49:59 nilsen
+Now using root generated streamers.
+
+Revision 1.11.4.10 2000/07/31 13:50:51 barbera
+Updated from the release
+
Revision 1.17 2000/07/10 16:07:19 fca
Release version of ITS code
#include <TFile.h> // only required for Tracking function?
#include <TCanvas.h>
#include <TObjArray.h>
+#include <TObjString.h>
#include <TClonesArray.h>
+#include <TLorentzVector.h>
+#include <TMath.h>
+
#include "AliMC.h"
-#include "AliMagF.h"
#include "AliConst.h"
+#include "AliMagF.h"
#include "AliITShit.h"
#include "AliITSv3.h"
#include "AliRun.h"
-#include "AliMC.h"
-#include "AliConst.h"
-
ClassImp(AliITSv3)
//_____________________________________________________________________________
// Standard default constructor for the ITS version 3.
////////////////////////////////////////////////////////////////////////
- fIdN = 6;
- fIdName = new TString[fIdN];
- fIdName[0] = "ITS1";
- fIdName[1] = "ITS2";
- fIdName[2] = "ITS3";
- fIdName[3] = "ITS4";
- fIdName[4] = "ITS5";
- fIdName[5] = "ITS6";
- fIdSens = new Int_t[fIdN];
- for (Int_t i=0;i<fIdN;i++) fIdSens[i]=fIdName[i].Length();
- fMinorVersionV3=1;
+ fIdN = 0;
+ fIdName = 0;
+ fIdSens = 0;
+ fMajorVersion = 3;
+ fMinorVersion = -1;
}
//____________________________________________________________________________
AliITSv3::AliITSv3(const AliITSv3 &source){
////////////////////////////////////////////////////////////////////////
// Standard constructor for the ITS version 3.
////////////////////////////////////////////////////////////////////////
- fIdN = 6;
- fIdName = new TString[fIdN];
+
+ fIdN = 6;
+/*
+// TObjArray of TObjStrings
+ fIdName = new TObjArray(fIdN);
+ fIdName->AddAt(new TObjString("ITS1"),0);
+ fIdName->AddAt(new TObjString("ITS2"),1);
+ fIdName->AddAt(new TObjString("ITS3"),2);
+ fIdName->AddAt(new TObjString("ITS4"),3);
+ fIdName->AddAt(new TObjString("ITS5"),4);
+ fIdName->AddAt(new TObjString("ITS6"),5);
+*/
+// Array of TStrings.
+ fIdName = new TString[fIdN];
fIdName[0] = "ITS1";
fIdName[1] = "ITS2";
fIdName[2] = "ITS3";
fIdName[4] = "ITS5";
fIdName[5] = "ITS6";
fIdSens = new Int_t[fIdN];
- for (Int_t i=0;i<fIdN;i++) fIdSens[i]=fIdName[i].Length();
- fMinorVersionV3=1;
+ for (Int_t i=0;i<fIdN;i++) fIdSens[i] = 0;
+ fMajorVersion = 3;
+ fMinorVersion = 1;
}//__________________________________________________________________________
void AliITSv3::BuildGeometry(){
////////////////////////////////////////////////////////////////////////
// --- Define SSD with the 35+39 lay-out
- if (fMinorVersionV3 < 3) {
+ if (fMinorVersion < 3) {
//--- Define ghost volume containing the Strip Detectors and fill it with air
// or vacuum
// --- Define SSD with the 32+36 lay-out
- if (fMinorVersionV3 >2 && fMinorVersionV3 < 6) {
+ if (fMinorVersion >2 && fMinorVersion < 6) {
//--- Define ghost volume containing the Strip Detectors and fill it with air
// or vacuum
// GOTO 8901 ! skip outer wall
- if (fMinorVersionV3 == 0 || fMinorVersionV3 == 3) {
+ if (fMinorVersion == 0 || fMinorVersion == 3) {
dits[0] = 49.9;
dits[1] = dits[0] + .06926;
// GOTO 9012 ! skip octagonal frame
- if (fMinorVersionV3 == 1) {
+ if (fMinorVersion == 1) {
rzero = 34.;
dtra[0] = .92;
gMC->Gspos(knatra1[15], 1, "ITSV", xpos, ypos, zpos, idrotm[5115], "ONLY");
- } else if (fMinorVersionV3 == 4) {
+ } else if (fMinorVersion == 4) {
rzero = 34.;
// GOTO 9123 ! skip hexagonal frame
- if (fMinorVersionV3 == 2) {
+ if (fMinorVersion == 2) {
rzero = 33.5;
dtra2[0] = .92;
gMC->Gspos(knatra4[15], 1, "ITSV", xpos, ypos, zpos, idrotm[5225], "ONLY");
- } else if (fMinorVersionV3 == 5) {
+ } else if (fMinorVersion == 5) {
rzero = 33.5;
gMC->Gsvolu("RP04", "PGON", idtmed[274], dpgon, 10);
gMC->Gspos("RP04", 1, "ITSV", xpos, ypos, zpos, 0, "ONLY");
- if (fMinorVersionV3 < 3 ) {
+ if (fMinorVersion < 3 ) {
offset2 = 5.2;
dpgon[0] = offset2 + 360./(2.*35.);
dpgon[1] = 360.;
gMC->Gsvolu("RP06", "PGON", idtmed[274], dpgon, 10);
gMC->Gspos("RP06", 1, "ITSV", xpos, ypos, zpos, 0, "ONLY");
}
- if (fMinorVersionV3 > 2 && fMinorVersionV3 < 6) {
+ if (fMinorVersion > 2 && fMinorVersion < 6) {
offset2 = 5.2;
dpgon[0] = offset2 + 5.625;
dpgon[1] = 360.;
gMC->Gsvolu("LP04", "PGON", idtmed[274], dpgon, 10);
gMC->Gspos("LP04", 1, "ITSV", xpos, ypos, zpos, 0, "ONLY");
- if (fMinorVersionV3 < 3) {
+ if (fMinorVersion < 3) {
offset2 = 5.2;
dpgon[0] = offset2 + 360./(2.*35.);
dpgon[1] = 360.;
gMC->Gsvolu("LP06", "PGON", idtmed[274], dpgon, 10);
gMC->Gspos("LP06", 1, "ITSV", xpos, ypos, zpos, 0, "ONLY");
}
- if (fMinorVersionV3 > 2 && fMinorVersionV3 < 6) {
+ if (fMinorVersion > 2 && fMinorVersion < 6) {
offset2 = 5.2;
dpgon[0] = offset2 + 5.625;
dpgon[1] = 360.;
if (fEuclidOut) {
gMC->WriteEuclid("ITSgeometry", "ITSV", 1, 5);
- }
- fMinorVersion = fMinorVersionV3;
+ };
}
//_____________________________________________________________________________
void AliITSv3::CreateMaterials(){
AliITS::Init();
fMajorVersion = 3;
- fMinorVersion = fMinorVersionV3;
}
//_____________________________________________________________________________
void AliITSv3::StepManager(){
} // end if printit[layer][ladder][detector]
#endif
}
-//____________________________________________________________________________
-void AliITSv3::Streamer(TBuffer &R__b){
-////////////////////////////////////////////////////////////////////////
-// A dummy Streamer function for this class AliITSv3. By default it
-// only streams the AliITS class as it is required. Since this class
-// dosen't contain any "real" data to be saved, it doesn't.
-////////////////////////////////////////////////////////////////////////
-
- if (R__b.IsReading()) {
- Version_t R__v = R__b.ReadVersion();
- if (R__v==1) {
- AliITS::Streamer(R__b);
- }else{
- AliITS::Streamer(R__b);
- } // end if
- } else {
- R__b.WriteVersion(AliITSv3::IsA());
- AliITS::Streamer(R__b);
- } // end if R__b.IsReading()
-}
-
-