]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - macros/Config.C
iVZERO defined
[u/mrichter/AliRoot.git] / macros / Config.C
index 2e2cc4a5655a99896335d0531cc47da0b4465192..ca028246930aee2ba4411f0adba8b1532a69f1cd 100644 (file)
@@ -1,9 +1,17 @@
+static Int_t    eventsPerRun = 100;
+enum PprGeo_t 
+{
+    kHoles, kNoHoles
+};
+static PprGeo_t geo = kHoles;
+
 void Config()
 {
     // 7-DEC-2000 09:00
     // Switch on Transition Radiation simulation. 6/12/00 18:00
     // iZDC=1  7/12/00 09:00
     // ThetaRange is (0., 180.). It was (0.28,179.72) 7/12/00 09:00
+    // Theta range given through pseudorapidity limits 22/6/2001
 
     // Set Random Number seed
     // gRandom->SetSeed(12345);
@@ -75,8 +83,10 @@ void Config()
 
     gener->SetMomentumRange(0, 999);
     gener->SetPhiRange(0, 360);
-    //  gener->SetThetaRange(0.28,179.72);
-    gener->SetThetaRange(0., 180.);
+    // Set pseudorapidity range from -8 to 8.
+    Float_t thmin = EtaToTheta(8);   // theta min. <---> eta max
+    Float_t thmax = EtaToTheta(-8);  // theta max. <---> eta min 
+    gener->SetThetaRange(thmin,thmax);
     gener->SetOrigin(0, 0, 0);  //vertex position
     gener->SetSigma(0, 0, 0);   //Sigma in (X,Y,Z) (cm) on IP position
     gener->Init();
@@ -85,33 +95,37 @@ void Config()
     // track by track
     //
     //gener->SetVertexSmear(perTrack); 
-
-    gAlice->SetField(-999, 2);  //Specify maximum magnetic field in Tesla (neg. ==> default field)
-
-    Int_t   iABSO = 1;
-    Int_t   iCASTOR = 1;
-    Int_t   iDIPO = 1;
-    Int_t   iFMD = 1;
-    Int_t   iFRAME = 1;
-    Int_t   iHALL = 1;
-    Int_t   iITS = 1;
-    Int_t   iMAG = 1;
-    Int_t   iMUON = 1;
-    Int_t   iPHOS = 1;
-    Int_t   iPIPE = 1;
-    Int_t   iPMD = 1;
-    Int_t   iRICH = 1;
-    Int_t   iSHIL = 1;
-    Int_t   iSTART = 1;
-    Int_t   iTOF = 1;
-    Int_t   iTPC = 1;
-    Int_t   iTRD = 1;
-    Int_t   iZDC = 1;
+    // Field (L3 0.4 T)
+    AliMagFMaps* field = new AliMagFMaps("Maps","Maps", 2, 1., 10., 1);
+    rootfile->cd();
+    gAlice->SetField(field);    
+
+
+    Int_t   iABSO  =  1;
+    Int_t   iDIPO  =  1;
+    Int_t   iFMD   =  1;
+    Int_t   iFRAME =  1;
+    Int_t   iHALL  =  1;
+    Int_t   iITS   =  1;
+    Int_t   iMAG   =  1;
+    Int_t   iMUON  =  1;
+    Int_t   iPHOS  =  1;
+    Int_t   iPIPE  =  1;
+    Int_t   iPMD   =  1;
+    Int_t   iRICH  =  1;
+    Int_t   iSHIL  =  1;
+    Int_t   iSTART =  1;
+    Int_t   iTOF   =  1;
+    Int_t   iTPC   =  1;
+    Int_t   iTRD   =  1;
+    Int_t   iZDC   =  1;
+    Int_t   iEMCAL =  1;
+    Int_t   iCRT   =  0;
+    Int_t   iVZERO =  1;
 
     //=================== Alice BODY parameters =============================
     AliBODY *BODY = new AliBODY("BODY", "Alice envelop");
 
-
     if (iMAG)
     {
         //=================== MAG parameters ============================
@@ -146,15 +160,19 @@ void Config()
     {
         //=================== FRAME parameters ============================
 
-        AliFRAME *FRAME = new AliFRAMEv2("FRAME", "Space Frame");
-
+        AliFRAMEv2 *FRAME = new AliFRAMEv2("FRAME", "Space Frame");
+       if (geo == kHoles) {
+           FRAME->SetHoles(1);
+       } else {
+           FRAME->SetHoles(0);
+       }
     }
 
     if (iSHIL)
     {
         //=================== SHIL parameters ============================
 
-        AliSHIL *SHIL = new AliSHILv0("SHIL", "Shielding");
+        AliSHIL *SHIL = new AliSHILv2("SHIL", "Shielding Version 2");
     }
 
 
@@ -165,9 +183,9 @@ void Config()
         AliPIPE *PIPE = new AliPIPEv0("PIPE", "Beam Pipe");
     }
  
-  if(iITS) {
+    if(iITS) {
 
-//=================== ITS parameters ============================
+    //=================== ITS parameters ============================
     //
     // As the innermost detector in ALICE, the Inner Tracking System "impacts" on
     // almost all other detectors. This involves the fact that the ITS geometry
@@ -185,26 +203,26 @@ void Config()
     //
     //AliITS *ITS  = new AliITSv5asymm("ITS","Updates ITS TDR detailed version with asymmetric services");
     //
-    AliITSvPPRasymm *ITS  = new AliITSvPPRasymm("ITS","New ITS PPR detailed version with asymmetric services");
-    ITS->SetMinorVersion(2);                                         // don't touch this parameter if you're not an ITS developer
-    ITS->SetReadDet(kFALSE);                                         // don't touch this parameter if you're not an ITS developer
+       AliITSvPPRasymm *ITS  = new AliITSvPPRasymm("ITS","New ITS PPR detailed version with asymmetric services");
+       ITS->SetMinorVersion(2);                                         // don't touch this parameter if you're not an ITS developer
+       ITS->SetReadDet(kFALSE);                                         // don't touch this parameter if you're not an ITS developer
     //    ITS->SetWriteDet("$ALICE_ROOT/ITS/ITSgeometry_vPPRasymm2.det");  // don't touch this parameter if you're not an ITS developer
-    ITS->SetThicknessDet1(300.);   // detector thickness on layer 1 must be in the range [100,300]
-    ITS->SetThicknessDet2(300.);   // detector thickness on layer 2 must be in the range [100,300]
-    ITS->SetThicknessChip1(300.);  // chip thickness on layer 1 must be in the range [150,300]
-    ITS->SetThicknessChip2(300.);  // chip thickness on layer 2 must be in the range [150,300]
-    ITS->SetRails(1);             // 1 --> rails in ; 0 --> rails out
-    ITS->SetCoolingFluid(1);       // 1 --> water ; 0 --> freon
-    //
+       ITS->SetThicknessDet1(200.);   // detector thickness on layer 1 must be in the range [100,300]
+       ITS->SetThicknessDet2(200.);   // detector thickness on layer 2 must be in the range [100,300]
+       ITS->SetThicknessChip1(200.);  // chip thickness on layer 1 must be in the range [150,300]
+       ITS->SetThicknessChip2(200.);  // chip thickness on layer 2 must be in the range [150,300]
+       ITS->SetRails(0);            // 1 --> rails in ; 0 --> rails out
+       ITS->SetCoolingFluid(1);   // 1 --> water ; 0 --> freon
+       //
     //AliITSvPPRsymm *ITS  = new AliITSvPPRsymm("ITS","New ITS PPR detailed version with symmetric services");
     //ITS->SetMinorVersion(2);                                       // don't touch this parameter if you're not an ITS developer
     //ITS->SetReadDet(kFALSE);                                       // don't touch this parameter if you're not an ITS developer
     //ITS->SetWriteDet("$ALICE_ROOT/ITS/ITSgeometry_vPPRsymm2.det"); // don't touch this parameter if you're not an ITS developer
-    //ITS->SetThicknessDet1(300.);   // detector thickness on layer 1 must be in the range [100,300]
-    //ITS->SetThicknessDet2(300.);   // detector thickness on layer 2 must be in the range [100,300]
-    //ITS->SetThicknessChip1(300.);  // chip thickness on layer 1 must be in the range [150,300]
-    //ITS->SetThicknessChip2(300.);  // chip thickness on layer 2 must be in the range [150,300]
-    //ITS->SetRails(1);              // 1 --> rails in ; 0 --> rails out
+    //ITS->SetThicknessDet1(200.);   // detector thickness on layer 1 must be in the range [100,300]
+    //ITS->SetThicknessDet2(200.);   // detector thickness on layer 2 must be in the range [100,300]
+    //ITS->SetThicknessChip1(200.);  // chip thickness on layer 1 must be in the range [150,300]
+    //ITS->SetThicknessChip2(200.);  // chip thickness on layer 2 must be in the range [150,300]
+    //ITS->SetRails(0);              // 1 --> rails in ; 0 --> rails out
     //ITS->SetCoolingFluid(1);       // 1 --> water ; 0 --> freon
     //
     //
@@ -213,11 +231,11 @@ void Config()
     //                                                     
     //
     //AliITSvPPRcoarseasymm *ITS  = new AliITSvPPRcoarseasymm("ITS","New ITS PPR coarse version with asymmetric services");
-    //ITS->SetRails(1);                // 1 --> rails in ; 0 --> rails out
+    //ITS->SetRails(0);                // 1 --> rails in ; 0 --> rails out
     //ITS->SetSupportMaterial(0);      // 0 --> Copper ; 1 --> Aluminum ; 2 --> Carbon
     //
     //AliITS *ITS  = new AliITSvPPRcoarsesymm("ITS","New ITS PPR coarse version with symmetric services");
-    //ITS->SetRails(1);                // 1 --> rails in ; 0 --> rails out
+    //ITS->SetRails(0);                // 1 --> rails in ; 0 --> rails out
     //ITS->SetSupportMaterial(0);      // 0 --> Copper ; 1 --> Aluminum ; 2 --> Carbon
     //                      
     //
@@ -230,9 +248,8 @@ void Config()
     // ITSgeometry.tme) in a format understandable to the CAD system EUCLID.
     // The default (=0) means that you dont want to use this facility.
     //
-    ITS->SetEUCLID(0);  
-  }
-  
+       ITS->SetEUCLID(0);  
+    }
 
     if (iTPC)
     {
@@ -262,16 +279,21 @@ void Config()
 
     }
 
-    if (iTOF)
-    {
+
+    if (iTOF) {
+       if (geo == kHoles) {
         //=================== TOF parameters ============================
-        AliTOF *TOF = new AliTOFv2("TOF", "normal TOF");
+           AliTOF *TOF = new AliTOFv2FHoles("TOF", "TOF with Holes");
+       } else {
+           AliTOF *TOF = new AliTOFv4T0("TOF", "normal TOF");
+       }
     }
 
+
     if (iRICH)
     {
         //=================== RICH parameters ===========================
-        AliRICH *RICH = new AliRICHv1("RICH", "normal RICH");
+        AliRICH *RICH = new AliRICHv3("RICH", "normal RICH");
 
     }
 
@@ -280,14 +302,7 @@ void Config()
     {
         //=================== ZDC parameters ============================
 
-        AliZDC *ZDC = new AliZDCv1("ZDC", "normal ZDC");
-    }
-
-    if (iCASTOR)
-    {
-        //=================== CASTOR parameters ============================
-
-        AliCASTOR *CASTOR = new AliCASTORv1("CASTOR", "normal CASTOR");
+        AliZDC *ZDC = new AliZDCv2("ZDC", "normal ZDC");
     }
 
     if (iTRD)
@@ -298,21 +313,25 @@ void Config()
 
         // Select the gas mixture (0: 97% Xe + 3% isobutane, 1: 90% Xe + 10% CO2)
         TRD->SetGasMix(1);
-
-        // With hole in front of PHOS
-        TRD->SetPHOShole();
-        // With hole in front of RICH
-        TRD->SetRICHhole();
-        // Switch on TR
-        AliTRDsim *TRDsim = TRD->CreateTR();
+       if (geo == kHoles) {
+           // With hole in front of PHOS
+           TRD->SetPHOShole();
+           // With hole in front of RICH
+           TRD->SetRICHhole();
+       }
+           // Switch on TR
+           AliTRDsim *TRDsim = TRD->CreateTR();
     }
 
     if (iFMD)
     {
         //=================== FMD parameters ============================
-
-        AliFMD *FMD = new AliFMDv1("FMD", "normal FMD");
-    }
+       AliFMD *FMD = new AliFMDv1("FMD", "normal FMD");
+        FMD->SetRingsSi1(256);
+        FMD->SetRingsSi2(128);
+        FMD->SetSectorsSi1(20);
+        FMD->SetSectorsSi2(40);      
+   }
 
     if (iMUON)
     {
@@ -324,21 +343,14 @@ void Config()
 
     if (iPHOS)
     {
-        AliPHOS *PHOS = new AliPHOSv1("PHOS", "GPS2");
+        AliPHOS *PHOS = new AliPHOSv1("PHOS", "IHEP");
     }
 
 
     if (iPMD)
     {
         //=================== PMD parameters ============================
-
         AliPMD *PMD = new AliPMDv1("PMD", "normal PMD");
-
-        PMD->SetPAR(1., 1., 0.8, 0.02);
-        PMD->SetIN(6., 18., -580., 27., 27.);
-        PMD->SetGEO(0.0, 0.2, 4.);
-        PMD->SetPadSize(0.8, 1.0, 1.0, 1.5);
-
     }
 
     if (iSTART)
@@ -347,5 +359,26 @@ void Config()
         AliSTART *START = new AliSTARTv1("START", "START Detector");
     }
 
+    if (iEMCAL)
+    {
+        //=================== EMCAL parameters ============================
+        AliEMCAL *EMCAL = new AliEMCALv1("EMCAL", "EMCALArch1a");
+    }
+
+     if (iCRT)
+    {
+        //=================== CRT parameters ============================
+        AliCRT *CRT = new AliCRTv0("CRT", "normal ACORDE");
+    }
+
+     if (iVZERO)
+    {
+        //=================== CRT parameters ============================
+        AliVZERO *VZERO = new AliVZEROv2("VZERO", "normal VZERO");
+    }
+
+}
 
+Float_t EtaToTheta(Float_t arg){
+  return (180./TMath::Pi())*2.*atan(exp(-arg));
 }