]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - STRUCT/AliPIPEv3.cxx
Changed vacuum density to avoid problems with fluka.
[u/mrichter/AliRoot.git] / STRUCT / AliPIPEv3.cxx
index 092d0932e86d6f59c7edd7dfec7d4bada7765384..bf60f7fdb054e7ddd8c5799feebdee3c47cc3a4c 100644 (file)
 
 #include <Riostream.h>
 
-#include <TSystem.h>
-#include <TVirtualMC.h>
+#include <TGeoBBox.h>
+#include <TGeoCompositeShape.h>
+#include <TGeoCone.h>
+#include <TGeoGlobalMagField.h>
 #include <TGeoManager.h>
-#include <TGeoVolume.h>
+#include <TGeoMatrix.h>
+#include <TGeoPcon.h>
 #include <TGeoTorus.h>
 #include <TGeoTube.h>
-#include <TGeoCone.h>
-#include <TGeoPcon.h>
-#include <TGeoBBox.h>
+#include <TGeoVolume.h>
 #include <TGeoXtru.h>
-#include <TGeoCompositeShape.h>
+#include <TSystem.h>
+#include <TVirtualMC.h>
 
 #include "AliConst.h"
 #include "AliMagF.h"
@@ -369,10 +371,11 @@ void AliPIPEv3::CreateGeometry()
 //
 //  Central beam pipe support collars
 //  LHCVC2C_0019
+//  cp1l = 405.
 //  Position at z = -46., 40., 150.
-    TGeoVolume* voCpSupC = new TGeoVolume("CpSupC", new TGeoTube(3.0, 4.0, 0.35), kMedAco);
-    voCp1->AddNode(voCpSupC, 1, new TGeoTranslation(0., 0.,  kCP1Length / 2. - 81.5));
-    voCp1->AddNode(voCpSupC, 2, new TGeoTranslation(0., 0.,  kCP1Length / 2.- 191.5));
+    TGeoVolume* voCpSupC = new TGeoVolume("CpSupC", new TGeoTube(3.051, 4.00, 0.35), kMedAco);
+    voCp1->AddNode(voCpSupC, 1, new TGeoTranslation(0., 0.,  kCP1Length / 2. - 98.2 - 34.77));
+//    voCp1->AddNode(voCpSupC, 2, new TGeoTranslation(0., 0.,  kCP1Length / 2.- 191.5));
 //  Beam Pipe Protection Tube
 //
 //  ALIFWDA_0025
@@ -578,7 +581,7 @@ void AliPIPEv3::CreateGeometry()
     voCp3Mo->SetVisibility(0);
     TGeoVolumeAssembly* voCp3 = new TGeoVolumeAssembly("Cp3");
     voCp3->AddNode(voCp3Mo,  1, gGeoIdentity);
-    voCp3->AddNode(voCpSupC, 3, new TGeoTranslation(0., 0., - kCP3Length / 2. + 4.5));
+    voCp3->AddNode(voCpSupC, 3, new TGeoTranslation(0., 0., - kCP3Length / 2. + 4.6));
     dz = kCP3pos;
 
 //////////////////////////////////////////////
@@ -987,8 +990,8 @@ void AliPIPEv3::CreateGeometry()
 // Pos 2.1 RF Contact Flange      LHCVSR__0003
 //
     TGeoPcon* shRB24B1RCTFlange = new TGeoPcon(0., 360., 6);
-    const Float_t kRB24B1RCTFlangeRin  = 8.06/2.;  // Inner radius
-    const Float_t kRB24B1RCTFlangeL    = 1.45;     // Length
+    const Float_t kRB24B1RCTFlangeRin  = 8.06/2. + 0.05;  // Inner radius
+    const Float_t kRB24B1RCTFlangeL    = 1.45;            // Length
     
     z = 0.;
     shRB24B1RCTFlange->DefineSection(0, z, kRB24B1RCTFlangeRin,  8.20/2.);
@@ -1019,7 +1022,7 @@ void AliPIPEv3::CreateGeometry()
     z =  kRB24B1RCTL -  kRB24B1RCTSL;
     // In the (VSR0004) this section is straight in (LHCVC2U_0001) it is conical ????
     shRB24B1RCT->DefineSection(1, z,  kRB24B1RCTRin + 0.35,  kRB24B1RCTRin + 0.35 + kRB24B1RCTd);
-    z = kRB24B1RCTL;
+    z = kRB24B1RCTL - 0.03;
     shRB24B1RCT->DefineSection(2, z,  kRB24B1RCTRin,  kRB24B1RCTRin + kRB24B1RCTd);
 
     TGeoVolume* voRB24B1RCT = new TGeoVolume("RB24B1RCT", shRB24B1RCT, kMedCu);
@@ -1047,7 +1050,7 @@ void AliPIPEv3::CreateGeometry()
     shRB24B1TTF->DefineSection(5, z,  6.30/2.,  6.7/2.);
     // Transition Tube
     z += 3.75;
-    shRB24B1TTF->DefineSection(6, z,  8.2/2.,  8.6/2.);
+    shRB24B1TTF->DefineSection(6, z,  8.05/2.,  8.45/2.);
     TGeoVolume* voRB24B1TTF = new TGeoVolume("RB24B1TTF", shRB24B1TTF, kMedSteel);
     z =  0.;
     voRB24B1BellowM->AddNode(voRB24B1TTF, 1, new TGeoTranslation(0., 0., z));    
@@ -1557,7 +1560,7 @@ void AliPIPEv3::CreateGeometry()
     z += (20.35 - 0.63);
     shRB24VMABCTT->DefineSection(5, z, 6.3/2.,  6.7/2.);
     z += 0.63;
-    shRB24VMABCTT->DefineSection(6, z, 6.5/2.,  6.9/2.);
+    shRB24VMABCTT->DefineSection(6, z, 6.3/2.,  6.7/2.);
     TGeoVolume* voRB24VMABCTT = new TGeoVolume("RB24VMABCTT", shRB24VMABCTT, kMedSteel);
     voRB24VMABCRB->AddNode(voRB24VMABCTT, 1, new TGeoTranslation(0., 0., - kRB24VMABCRBT1L/2.-1.));
 
@@ -2126,7 +2129,7 @@ void AliPIPEv3::CreateGeometry()
       shRB26s3SFlange->DefineSection(5, z0, kRB26s3SFlangeRi3, kRB26s3SFlangeRo);
       TGeoVolume* voRB26s3SFlange = new TGeoVolume("RB26s3SFlange", shRB26s3SFlange, kMedSteel);
 
-      TGeoVolume* voRB26s3SFlangeM = new TGeoVolume("RB26s3SFlange", MakeMotherFromTemplate(shRB26s3SFlange, 0, 3), kMedVac);
+      TGeoVolume* voRB26s3SFlangeM = new TGeoVolume("RB26s3SFlangeM", MakeMotherFromTemplate(shRB26s3SFlange, 0, 3), kMedVac);
       voRB26s3SFlangeM->AddNode(voRB26s3SFlange, 1, gGeoIdentity);
         
 ///////////////////////////////////
@@ -2155,7 +2158,7 @@ void AliPIPEv3::CreateGeometry()
       shRB26s3FFlange->DefineSection(5, z0, kRB26s3FFlangeRi3, kRB26s3FFlangeRo);
       TGeoVolume* voRB26s3FFlange = new TGeoVolume("RB26s3FFlange", shRB26s3FFlange, kMedSteel);
       
-      TGeoVolume* voRB26s3FFlangeM = new TGeoVolume("RB26s3FFlange", MakeMotherFromTemplate(shRB26s3FFlange, 2, 5), kMedVac);
+      TGeoVolume* voRB26s3FFlangeM = new TGeoVolume("RB26s3FFlangeM", MakeMotherFromTemplate(shRB26s3FFlange, 2, 5), kMedVac);
       voRB26s3FFlangeM->AddNode(voRB26s3FFlange, 1, gGeoIdentity);
             
 
@@ -2393,7 +2396,7 @@ void AliPIPEv3::CreateGeometry()
       const Float_t kRB26s5CompTubeInnerR    = 10.00/2.;  // Connection tubes inner radius     [Pos 2 + 3]
       const Float_t kRB26s5CompTubeOuterR    = 10.30/2.;  // Connection tubes outer radius     [Pos 2 + 3]
       const Float_t kRB26s5WeldingTubeLeftL  =  3.70/2.;  // Left connection tube half length  [Pos 2]
-      const Float_t kRB26s5WeldingTubeRightL = 13.42/2.;  // Right connection tube half length [Pos 3]   (0.3 cm added for welding)
+      const Float_t kRB26s5WeldingTubeRightL = 13.40/2.;  // Right connection tube half length [Pos 3]   (0.3 cm added for welding)
       const Float_t kRB26s5RingInnerR        = 11.2/2.;   // Ring inner radius                 [Pos 4]
       const Float_t kRB26s5RingOuterR        = 16.0/2.;   // Ring inner radius                 [Pos 4]
       const Float_t kRB26s5RingL             =  0.4/2.;   // Ring half length                  [Pos 4]
@@ -2693,8 +2696,8 @@ void AliPIPEv3::CreateMaterials()
   //
 
   AliDebugClass(1,"Create PIPEv3 materials");
-  Int_t   isxfld = gAlice->Field()->Integ();
-  Float_t sxmgmx = gAlice->Field()->Max();
+  Int_t   isxfld = ((AliMagF*)TGeoGlobalMagField::Instance()->GetField())->Integ();
+  Float_t sxmgmx = ((AliMagF*)TGeoGlobalMagField::Instance()->GetField())->Max();
   // Steel (Inox)  
   Float_t asteel[4] = { 55.847,51.9961,58.6934,28.0855 };
   Float_t zsteel[4] = { 26.,24.,28.,14. };
@@ -2715,7 +2718,7 @@ void AliPIPEv3::CreateMaterials()
   Float_t zAir[4]={6.,7.,8.,18.};
   Float_t wAir[4]={0.000124,0.755267,0.231781,0.012827};
   Float_t dAir = 1.20479E-3;
-  Float_t dAir1 = 1.20479E-10;
+  Float_t dAir1 = 1.20479E-11;
   //
   // Insulation powder
   //                    Si         O       Ti     Al
@@ -2901,7 +2904,7 @@ TGeoPcon* AliPIPEv3::MakeInsulationFromTemplate(TGeoPcon* shape)
 }
 
 
-TGeoVolume* AliPIPEv3::MakeBellow(char* ext, Int_t nc, Float_t rMin, Float_t rMax, Float_t dU, Float_t rPlie, Float_t dPlie)
+TGeoVolume* AliPIPEv3::MakeBellow(const char* ext, Int_t nc, Float_t rMin, Float_t rMax, Float_t dU, Float_t rPlie, Float_t dPlie)
 {
     // nc     Number of convolution
     // rMin   Inner radius of the bellow