{ int hel_inner_medium = 24 ; int hel_outer_medium = 24 ; int hel_driftgas = 8 ; int hel_nsec = 24; float hel_phi0 = 11.25 ; float hel_rout = 99. ; float hel_rin = 21.20 ; float hel_length = 54. ; float hel_swdis = 1.0 ; float hel_stagg = 0.02; float helv_dim[23] = { 0. , 360. , 133.5 , 20. , 21.2, 139.8 , 20. , 21.2, 139.8 , 20. , 21.2, 192.2 , 20. , 21.2, 192.2 , 20. , 21.2, 195.7 , 20. , 21.2, 197.2 , 20. , 21.2 }; float helf_dim[23] = {0. , 360. , 133.5 , 99. , 105.5, 139.8 , 99. , 105.5, 139.8 , 99. , 100.5, 192.2 , 99. , 100.5, 192.2 , 99. , 105.5, 195.7 , 99. , 105.5, 197.2 , 102. , 105.5 }; float hels_rot[6]; float hel_pos[3] = { 0. , 0. , 139.}; float phi = 360./(float(hel_nsec)); float hels_dim[5] = { hel_rin , hel_rout , hel_length/2 , -phi/2 , +phi/2 }; // hel_rin , hel_rout, hel_slen /// Inner Stesalit Frame ///// TGeoPcon *pcov = new TGeoPcon(helv_dim[0] , helv_dim[1] , 7 ); pcov->DefineSection( 0 , helv_dim[2] , helv_dim[3] , helv_dim[4] ); pcov->DefineSection( 1 , helv_dim[5] , helv_dim[6] , helv_dim[7] ); pcov->DefineSection( 2 , helv_dim[8] , helv_dim[9] , helv_dim[10] ); pcov->DefineSection( 3 , helv_dim[11] , helv_dim[12] , helv_dim[13] ); pcov->DefineSection( 4 , helv_dim[14] , helv_dim[15] , helv_dim[16] ); pcov->DefineSection( 5 , helv_dim[17] , helv_dim[18] , helv_dim[19] ); pcov->DefineSection( 6 , helv_dim[20] , helv_dim[21] , helv_dim[22] ); TGeoVolume *helv = new TGeoVolume( "HELV" , pcov , medium[hel_inner_medium-1] ); /// Outer Stesalit Frame ///// TGeoPcon *pcof = new TGeoPcon(helf_dim[0] , helf_dim[1] , 7 ); pcof->DefineSection( 0 , helf_dim[2] , helf_dim[3] , helf_dim[4] ); pcof->DefineSection( 1 , helf_dim[5] , helf_dim[6] , helf_dim[7] ); pcof->DefineSection( 2 , helf_dim[8] , helf_dim[9] , helf_dim[10] ); pcof->DefineSection( 3 , helf_dim[11] , helf_dim[12] , helf_dim[13] ); pcof->DefineSection( 4 , helf_dim[14] , helf_dim[15] , helf_dim[16] ); pcof->DefineSection( 5 , helf_dim[17] , helf_dim[18] , helf_dim[19] ); pcof->DefineSection( 6 , helf_dim[20] , helf_dim[21] , helf_dim[22] ); TGeoVolume *helf = new TGeoVolume("HELF", pcof , medium[hel_outer_medium-1]); // Helitron Volume TGeoVolume *hels = gGeoManager -> MakeTubs("HELS",medium[hel_driftgas-1],hels_dim[0],hels_dim[1],hels_dim[2],hels_dim[3],hels_dim[4]); gGeoManager->SetVolumeAttribute("HELS","seen",1); gGeoManager->SetVolumeAttribute("HELS","colo",15); int in_drift_cell = hel_length*2 / hel_swdis ; TGeoVolume *hdcl = hels->Divide("hdcl",int(3),-hels_dim[2]/2.,hels_dim[2]/2.,hel_swdis); gGeoManager->SetVolumeAttribute("hdcl","seen",1); gGeoManager->SetVolumeAttribute("hdcl","colo",15); float helwrr_dim[3] = { 0. , 0.010 , (hel_rout-hel_rin)/2 }; float helwrp_dim[3] = { 0. , 0.005 , (hel_rout-hel_rin)/2 }; float helwrc_dim[3] = { 0. , 0.003 , (hel_length)/2 }; int hel_hwrr_medium = 12 ; int hel_hwrp_medium = 13 ; int hel_hwrc_medium = 14 ; TGeoVolume *hwrr = gGeoManager -> MakeTube("Hwrr",medium[hel_hwrr_medium-1],helwrr_dim[0],helwrr_dim[1],helwrr_dim[2]); gGeoManager->SetVolumeAttribute("Hwrr","seen",1); gGeoManager->SetVolumeAttribute("Hwrr","colo",15); TGeoVolume *hwrp = gGeoManager -> MakeTube("Hwrp",medium[hel_hwrp_medium-1],helwrp_dim[0],helwrp_dim[1],helwrp_dim[2]); gGeoManager->SetVolumeAttribute("Hwrp","seen",1); gGeoManager->SetVolumeAttribute("Hwrp","colo",15); TGeoVolume *hwrc = gGeoManager -> MakeTube("Hwrc",medium[hel_hwrc_medium-1],helwrc_dim[0],helwrc_dim[1],hel_length/(2*in_drift_cell)); gGeoManager->SetVolumeAttribute("Hwrc","seen",1); gGeoManager->SetVolumeAttribute("Hwrc","colo",15); hdcl->AddNode( hwrr , 1 ,new TGeoCombiTrans( (hel_rout+hel_rin)/2 , 0. , hel_swdis/2 ,new TGeoRotation("rot1",90.,90.,0.,0.,90.,0.))); hdcl->AddNode( hwrp , 1 ,new TGeoCombiTrans((hel_rout+hel_rin)/2, hel_stagg , 0. ,new TGeoRotation("rot1",90.,90.,0.,0.,90.,0.))); hwrr->SetLineColor(5); hwrc->SetLineColor(19); hwrp->SetLineColor(4); hels->SetVisibility(true); hels->SetLineColor(5); int i=0; float xw=hel_rin; while(xwAddNode( hwrc , i ,new TGeoTranslation( xw , xw * tan(phi/2.*3.14/180) , 0. )); i++; xw += hel_swdis; } for(int i=0;iAddNode( hels , i ,new TGeoCombiTrans( 0. , 0. , hel_pos[2] + hel_length/2 ,new TGeoRotation("rot1",hels_rot[0],hels_rot[1],hels_rot[2],hels_rot[3],hels_rot[4], hels_rot[5]))); } CTUB->AddNode( helv , 1 , new TGeoTranslation( 0. , 0. , 0. ) ); // Inner Stesalit CTUB->AddNode( helf , 1 , new TGeoTranslation( 0. , 0. , 0. ) ); // Outer Stesalit }