use the symbolic name for spaceframe sectors
authorrgrosso <rgrosso@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 4 Apr 2012 12:38:10 +0000 (12:38 +0000)
committerrgrosso <rgrosso@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 4 Apr 2012 12:38:10 +0000 (12:38 +0000)
GRP/MakeSTRUCTFullMisAlignment.C
GRP/MakeSTRUCTResMisAlignment.C
GRP/MakeSTRUCTZeroMisAlignment.C

index 684c993..3effb99 100644 (file)
@@ -8,27 +8,21 @@ void MakeSTRUCTFullMisAlignment(){
   const char* macroname = "MakeSTRUCTFullMisAlignment.C";
   TClonesArray *array = new TClonesArray("AliAlignObjParams",20);
 
+  const char* baseSymName ="FRAME/Sector"; //base of symbolic name corresponding to base of path "ALIC_1/B077_1/BSEGMO";
+  TString symname;
+
   // the following hardcoded values have been obtained by taking the output of the ANSYS simulation
   // (finite elements simulation of deformations for given loads) and recalculating the avarege
   // displacement of the center of each space-frame sector
-  ((*array)[0]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO0_1",0,0.13375,-0.0275,0,0,0,0,kTRUE);
-  ((*array)[1]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO1_1",0,0.25125,0.00125,0,0,0,0,kTRUE);
-  ((*array)[2]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO2_1",0,0.2325,-0.03625,0,0,0,0,kTRUE);
-  ((*array)[3]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO3_1",0,0.17,-0.14375,0,0,0,0,kTRUE);
-  ((*array)[4]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO4_1",0,0.1475,-0.2,0,0,0,0,kTRUE);
-  ((*array)[5]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO5_1",0,0.12625,-0.13375,0,0,0,0,kTRUE);
-  ((*array)[6]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO6_1",0,0.06375,-0.02125,0,0,0,0,kTRUE);
-  ((*array)[7]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO7_1",0,0.0475,0.015,0,0,0,0,kTRUE);
-  ((*array)[8]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO8_1",0,0.1775,-0.0175,0,0,0,0,kTRUE);
-  ((*array)[9]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO9_1",0,0.32375,-0.03125,0,0,0,0,kTRUE);
-  ((*array)[10]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO10_1",0,0.35125,-0.0325,0,0,0,0,kTRUE);
-  ((*array)[11]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO11_1",0,0.285,-0.105,0,0,0,0,kTRUE);
-  ((*array)[12]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO12_1",0,0.205,-0.24375,0,0,0,0,kTRUE);
-  ((*array)[13]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO13_1",0,0.1775,-0.32,0,0,0,0,kTRUE);
-  ((*array)[14]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO14_1",0,0.1525,-0.25375,0,0,0,0,kTRUE);
-  ((*array)[15]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO15_1",0,0.07625,-0.1225,0,0,0,0,kTRUE);
-  ((*array)[16]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO16_1",0,0.0075,-0.04875,0,0,0,0,kTRUE);
-  ((*array)[17]) = new AliAlignObjParams("ALIC_1/B077_1/BSEGMO17_1",0,0.01375,-0.04125,0,0,0,0,kTRUE);
+  Double_t dx[18]={0.13375,0.25125,0.2325,0.17,0.1475,0.12625,0.06375,0.0475,0.1775,0.32375,0.35125,0.285,0.205,0.1775,0.1525,0.07625,0.0075,0.01375};
+  Double_t dy[18]={-0.0275,0.00125,-0.03625,-0.14375,-0.2,-0.13375,-0.02125,0.015,-0.0175,-0.03125,-0.0325,-0.105,-0.24375,-0.32,-0.25375,-0.1225,-0.04875,-0.04125};
+
+  for(Int_t sm=0; sm<18; sm++){
+    symname = baseSymName;
+    symname += sm;
+    cout<<symname.Data()<<endl;
+    ((*array)[sm]) = new AliAlignObjParams(symname.Data(),0,dx[sm],dy[sm],0.,0.,0.,0.,kTRUE);
+  }
 
   if( TString(gSystem->Getenv("TOCDB")) != TString("kTRUE") ){
     // save on file
index 8ac79ed..36379c1 100644 (file)
@@ -10,18 +10,16 @@ void MakeSTRUCTResMisAlignment(){
   AliGeomManager::ELayerID iLayer = AliGeomManager::kInvalidLayer;
   UShort_t dvoluid = AliGeomManager::LayerToVolUID(iLayer,iIndex); //dummy vol id
 
-  const char* basepath ="ALIC_1/B077_1/BSEGMO";
-  TString segmpath;
+  const char* baseSymName ="FRAME/Sector"; //base of symbolic name corresponding to base of path "ALIC_1/B077_1/BSEGMO";
+  TString symname;
 
   for(Int_t sm=0; sm<18; sm++){
-    segmpath=basepath;
-    segmpath+=sm;
-    segmpath+="_1";
-    cout<<segmpath.Data()<<endl;
-    new((*array)[sm]) AliAlignObjParams(segmpath.Data(),dvoluid,0.,0.,0.,0.,0.,0.,kTRUE);
+    symname = baseSymName;
+    symname += sm;
+    cout<<symname.Data()<<endl;
+    new((*array)[sm]) AliAlignObjParams(symname.Data(),dvoluid,0.,0.,0.,0.,0.,0.,kTRUE);
   }
 
-
   if( TString(gSystem->Getenv("TOCDB")) != TString("kTRUE") ){
     // save on file
     const char* filename = "STRUCTresMisalignment.root";
index 0ebbe07..8ca0d08 100644 (file)
@@ -10,15 +10,14 @@ void MakeSTRUCTZeroMisAlignment(){
   AliGeomManager::ELayerID iLayer = AliGeomManager::kInvalidLayer;
   UShort_t dvoluid = AliGeomManager::LayerToVolUID(iLayer,iIndex); //dummy vol id
 
-  const char* basepath ="ALIC_1/B077_1/BSEGMO";
-  TString segmpath;
+  const char* baseSymName ="FRAME/Sector"; //base of symbolic name corresponding to base of path "ALIC_1/B077_1/BSEGMO";
+  TString symname;
 
   for(Int_t sm=0; sm<18; sm++){
-    segmpath=basepath;
-    segmpath+=sm;
-    segmpath+="_1";
-    cout<<segmpath.Data()<<endl;
-    new((*array)[sm]) AliAlignObjParams(segmpath.Data(),dvoluid,0.,0.,0.,0.,0.,0.,kTRUE);
+    symname = baseSymName;
+    symname += sm;
+    cout<<symname.Data()<<endl;
+    new((*array)[sm]) AliAlignObjParams(symname.Data(),dvoluid,0.,0.,0.,0.,0.,0.,kTRUE);
   }
 
   if( TString(gSystem->Getenv("TOCDB")) != TString("kTRUE") ){