/*
$Log$
+Revision 1.38 2002/06/13 08:43:46 vicinanz
+Merging added and test macro
+
+Revision 1.37 2002/05/03 07:34:19 vicinanz
+Updated SDigitizer; Added AliTOFanalyzeSDigits.C macro
+
+Revision 1.36 2002/04/19 14:40:51 vicinanz
+Updated SDigitizer
+
+Revision 1.35 2002/03/21 13:52:53 vicinanz
+Minor changes to AliTOF constructor
+
+Revision 1.34 2002/02/20 13:41:38 hristov
+Default arguments set only in the header file
+
+Revision 1.33 2002/02/19 10:39:38 vicinanz
+t0 classes added and material update (steel added)
+
Revision 1.31 2001/11/22 11:22:51 hristov
Updated version of TOF digitization, N^2 problem solved (J.Chudoba)
#include "AliTOF.h"
#include "AliTOFhit.h"
+#include "AliTOFhitT0.h"
#include "AliTOFdigit.h"
#include "AliTOFSDigit.h"
#include "AliTOFRawSector.h"
//
// Default constructor
//
- fFGeom = 0;
- fDTask = 0;
- fReTask = 0;
+ fFGeom = 0x0;
+ fDTask = 0x0;
+ fReTask = 0x0;
fIshunt = 0;
fSDigits = 0 ;
+ fNSDigits = 0;
fDigits = 0 ;
- fReconParticles = 0;
+ fReconParticles = 0x0;
fName="TOF";
- fMerger = 0;
+ fMerger = 0x0;
/* fp
CreateTOFFolders();
*/
}
//_____________________________________________________________________________
-AliTOF::AliTOF(const char *name, const char *title)
+AliTOF::AliTOF(const char *name, const char *title, Option_t *option)
: AliDetector(name,title)
{
//
//
// Initialization of hits, sdigits and digits array
- //
-
- fDTask=0;
- fReTask=0;
- fFGeom=0;
- fReconParticles=0;
- fMerger=0;
-
- fHits = new TClonesArray("AliTOFhit", 1000);
+ // added option for time zero analysis
+ if (strstr(option,"tzero")){
+ fHits = new TClonesArray("AliTOFhitT0", 1000);
+ cout << "tzero option requires AliTOFv4T0 as TOF version (check Your Config.C)" << endl;
+ }else{
+ fHits = new TClonesArray("AliTOFhit", 1000);
+ }
gAlice->AddHitList(fHits);
fIshunt = 0;
fSDigits = new TClonesArray("AliTOFSDigit", 1000);
fDigits = new TClonesArray("AliTOFdigit", 1000);
+ fNSDigits = 0;
+
+ fFGeom = 0x0;
+ fDTask = 0x0;
+ fReTask = 0x0;
+ fReconParticles = 0x0;
+ fMerger = 0x0;
+
//
// Digitization parameters
//
TClonesArray &lhits = *fHits;
new(lhits[fNhits++]) AliTOFhit(fIshunt, track, vol, hits);
}
-
+
+//_____________________________________________________________________________
+void AliTOF::AddT0Hit(Int_t track, Int_t *vol, Float_t *hits)
+{
+ //
+ // Add a TOF hit
+ // new with placement used
+ //
+ TClonesArray &lhits = *fHits;
+ new(lhits[fNhits++]) AliTOFhitT0(fIshunt, track, vol, hits);
+}
+
//_____________________________________________________________________________
void AliTOF::AddDigit(Int_t *tracks, Int_t *vol, Float_t *digits)
{
{
//
// Defines TOF materials for all versions
- // Authors : Maxim Martemianov, Boris Zagreev (ITEP)
- // 18/09/98
- // Revision: F. Pierella 5-3-2001
- // Bologna University
+ // Revision: F. Pierella 18-VI-2002
//
+
Int_t isxfld = gAlice->Field()->Integ();
Float_t sxmgmx = gAlice->Field()->Max();
//
- //--- Quartz (SiO2)
+ //--- Quartz (SiO2) to simulate float glass
+ // density tuned to have correct float glass
+ // radiation length
Float_t aq[2] = { 28.0855,15.9994 };
Float_t zq[2] = { 14.,8. };
Float_t wq[2] = { 1.,2. };
- Float_t dq = 2.20;
+ Float_t dq = 2.55; // std value: 2.2
Int_t nq = -2;
+
// --- Freon C2F4H2 (TOF-TDR pagg.)
// Geant Manual CONS110-1, pag. 43 (Geant, Detector Description and Simulation Tool)
Float_t afre[3] = {12.011,18.998,1.007};
Float_t wmatg10[4] = { .259,.288,.248,.205 };
Float_t densg10 = 1.7;
Int_t nlmatg10 = -4;
- // --- DME
- Float_t adme[5] = { 12.,1.,16.,19.,79. };
- Float_t zdme[5] = { 6.,1., 8., 9.,35. };
- Float_t wmatdme[5] = { .4056,.0961,.2562,.1014,.1407 };
- Float_t densdme = .00205;
- Int_t nlmatdme = 5;
+
+ // plexiglass CH2=C(CH3)CO2CH3
+ Float_t aplex[3] = { 12.,1.,16.};
+ Float_t zplex[3] = { 6.,1., 8.};
+ Float_t wmatplex[3] = {5.,8.,2.};
+ Float_t densplex =1.16;
+ Int_t nplex = -3;
+
// ---- ALUMINA (AL203)
Float_t aal[2] = { 27.,16.};
Float_t zal[2] = { 13., 8.};
Float_t wwa[2] = { 2., 1. };
Float_t dwa = 1.0;
Int_t nwa = -2;
+
+// stainless steel
+ Float_t asteel[4] = { 55.847,51.9961,58.6934,28.0855 };
+ Float_t zsteel[4] = { 26.,24.,28.,14. };
+ Float_t wsteel[4] = { .715,.18,.1,.005 };
+
//
//AliMaterial(0, "Vacuum$", 1e-16, 1e-16, 1e-16, 1e16, 1e16);
AliMaterial( 1, "Air$",14.61,7.3,0.001205,30423.24,67500.);
AliMaterial( 3, "C $", 12.01, 6.0, 2.265,18.8, 74.4);
AliMixture ( 4, "Polyethilene$", ape, zpe, dpe, npe, wpe);
AliMixture ( 5, "G10$", ag10, zg10, densg10, nlmatg10, wmatg10);
- AliMixture ( 6, "DME ", adme, zdme, densdme, nlmatdme, wmatdme);
+ AliMixture ( 6, "PLE$", aplex, zplex, densplex, nplex, wmatplex);
AliMixture ( 7, "CO2$", ac, zc, dc, nc, wc);
AliMixture ( 8, "ALUMINA$", aal, zal, densal, nlmatal, wmatal);
AliMaterial( 9, "Al $", 26.98, 13., 2.7, 8.9, 37.2);
AliMaterial(10, "C-TRD$", 12.01, 6., 2.265*18.8/69.282*15./100, 18.8, 74.4); // for 15%
AliMixture (11, "Mylar$", amy, zmy, dmy, nmy, wmy);
AliMixture (12, "Freon$", afre, zfre, densfre, nfre, wfre);
- AliMixture (13, "Quartz$", aq, zq, dq, nq, wq);
+ AliMixture (13, "Glass$", aq, zq, dq, nq, wq);
AliMixture (14, "Water$", awa, zwa, dwa, nwa, wwa);
+ AliMixture (15, "STAINLESS STEEL$", asteel, zsteel, 7.88, 4, wsteel);
Float_t epsil, stmin, deemax, stemax;
AliMedium( 3, "C $" , 3, 0, isxfld, sxmgmx, 10., stemax, deemax, epsil, stmin);
AliMedium( 4, "Pol$" , 4, 0, isxfld, sxmgmx, 10., stemax, deemax, epsil, stmin);
AliMedium( 5, "G10$" , 5, 0, isxfld, sxmgmx, 10., stemax, deemax, epsil, stmin);
- AliMedium( 6, "DME$" , 6, 0, isxfld, sxmgmx, 10., stemax, deemax, epsil, stmin);
+ AliMedium( 6, "PLE$" , 6, 0, isxfld, sxmgmx, 10., stemax, deemax, epsil, stmin);
AliMedium( 7, "CO2$" , 7, 0, isxfld, sxmgmx, 10., -.01, -.1, .01, -.01);
AliMedium( 8,"ALUMINA$", 8, 0, isxfld, sxmgmx, 10., stemax, deemax, epsil, stmin);
AliMedium( 9,"Al Frame$",9, 0, isxfld, sxmgmx, 10., stemax, deemax, epsil, stmin);
AliMedium(14, "Fre-S$", 12, 1, isxfld, sxmgmx, 10., stemax, deemax, epsil, stmin);
AliMedium(15, "Glass$", 13, 0, isxfld, sxmgmx, 10., stemax, deemax, epsil, stmin);
AliMedium(16, "Water$", 14, 0, isxfld, sxmgmx, 10., stemax, deemax, epsil, stmin);
+ AliMedium(17, "STEEL$", 15, 0, isxfld, sxmgmx, 10., stemax, deemax, epsil, stmin);
}
//_____________________________________________________________________________
cout<<"ALiTOF::Hits2SDigits> start...\n";
//#endif
- char * fileSDigits = 0 ;
+ //char * fileSDigits = 0 ;
char * fileHeader = 0;
- AliTOFSDigitizer * sd = new AliTOFSDigitizer(fileHeader,fileSDigits) ;
+ AliTOFSDigitizer * sd = new AliTOFSDigitizer(fileHeader) ;
sd->Exec("") ;
sd->Print("");
tD->Write(0,TObject::kOverwrite);
}
+////////////////////////////////////////////////////////////////////////
+void AliTOF::RecreateSDigitsArray() {
+//
+// delete TClonesArray fSDigits and create it again
+// needed for backward compatability with PPR test production
+//
+ delete fSDigits;
+ fSDigits = new TClonesArray("AliTOFSDigit", 1000);
+}
+////////////////////////////////////////////////////////////////////////
+void AliTOF::CreateSDigitsArray() {
+//
+// create TClonesArray fSDigits
+// needed for backward compatability with PPR test production
+//
+ fSDigits = new TClonesArray("AliTOFSDigit", 1000);
+}