]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - STRUCT/AliDIPOv2.cxx
1. Removing harmless, innocent but disturbing error message index out of bounds)2...
[u/mrichter/AliRoot.git] / STRUCT / AliDIPOv2.cxx
index 43cb21466f5f731054987b9eac857940c3773210..02e4693dcc825abd36050e6c9707c37b7f0b9568 100644 (file)
@@ -34,6 +34,8 @@
 //                                                                           //
 //                                                                           //
 
+#include <TGeoGlobalMagField.h>
+#include <TGeoVolume.h>
 #include <TVirtualMC.h>
 
 #include "AliConst.h"
@@ -647,13 +649,9 @@ void AliDIPOv2::CreateCompensatorDipole()
     Int_t idrotm[1899];
 //
     Float_t pbox[3];
-    Float_t ptube[3];
-    ptube[0] = 4.;
-    ptube[1] = 65. * TMath::Sqrt(2.);
-    ptube[2] = (kLCoilH + 2. * kRCoilC) / 2.;
 //  Mother volumes
-    gMC->Gsvolu("DCM0", "TUBE", idtmed[1814 + 40], ptube, 3);
-    gMC->Gsatt ("DCM0", "SEEN", 0);
+    TGeoVolumeAssembly* asDCM0 = new TGeoVolumeAssembly("DCM0");
+    asDCM0->SetName("DCM0");
     
 //
 //  Mother volume containing lower coil
@@ -802,7 +800,7 @@ void AliDIPOv2::CreateCompensatorDipole()
 
 
     AliMatrix(idrotm[1816], 270., 0., 90., 90.,  180., 0.);  
-    gMC->Gspos("DCM0", 1, "ALIC",  0., -6.75,  1085., idrotm[1816], "ONLY");
+    gMC->Gspos("DCM0", 1, "ALIC",  0., -12.,  1075., idrotm[1816], "ONLY");
 }
 
 //_____________________________________________________________________________
@@ -860,9 +858,9 @@ void AliDIPOv2::CreateMaterials()
   // Create Materials for Magnetic Dipole version 2
   //
   
-  Int_t isxfld1   = gAlice->Field()->Integ();
-  Int_t isxfld2   = gAlice->Field()->PrecInteg();
-  Float_t sxmgmx  = gAlice->Field()->Max();
+  Int_t isxfld1   = ((AliMagF*)TGeoGlobalMagField::Instance()->GetField())->Integ();
+  Int_t isxfld2   = ((AliMagF*)TGeoGlobalMagField::Instance()->GetField())->PrecInteg();
+  Float_t sxmgmx  = ((AliMagF*)TGeoGlobalMagField::Instance()->GetField())->Max();
   
   
   Float_t asteel[4] = { 55.847,51.9961,58.6934,28.0855 };