Commit 0af6fa1c authored by Sylvester Joosten's avatar Sylvester Joosten
Browse files

Add simplified all silicon implementation

parent 91e6aac1
Pipeline #9842 failed with stages
in 1 minute and 50 seconds
<lccdd>
<comment> Simplified All Silicon Tracker based on:
https://github.com/reynier0611/g4lblvtx/blob/master/macros/auxiliary_studies/simplified_geometry/Fun4All_G4_simplified_v2.C
With some added info on ITS3 chip from
https://indico.bnl.gov/event/10677/contributions/45591/attachments/33204/53254/20210318-IR2%40EIC-SVT.pdf
To be used as standin until we get more detailed specs from the working group on the tracker.
Note that most details are replaced with
Note: initial implementation with hard-coded values,
TODO: add parametrization
</comment>
<define>
<constant name="ITS3Thickness" value=".03*mm"/>
<constant name="VtxRadius1" value="3.3*cm"/>
<constant name="VtxRadius2" value="5.7*cm"/>
<constant name="VtxLength" value="30*cm"/>
<constant name="VtxThickness" value="0.05/100*9.37*cm"/>
<constant name="VtxServiceThickness" value="VtxThickness-ITS3Thickness"/>
<constant name="TrkBarrelThickness" value="0.55/100*9.37*cm"/>
<constant name="TrkBarrelServiceThickness" value="TrkBarrelThickness-ITS3Thickness"/>
<constant name="TrkBarrel1Radius1" value="21.0*cm"/>
<constant name="TrkBarrel1Radius2" value="22.68*cm"/>
<constant name="TrkBarrel1Length1" value="54.0*cm"/>
<constant name="TrkBarrel1Length2" value="60.0*cm"/>
<constant name="TrkBarrel2Radius1" value="39.3*cm"/>
<constant name="TrkBarrel2Radius2" value="43.23*cm"/>
<constant name="TrkBarrel2Length1" value="105.0*cm"/>
<constant name="TrkBarrel2Length2" value="114.0*cm"/>
<constant name="TrkDiskThickness" value="0.25/100*9.37*cm"/>
<constant name="TrkDiskServiceThickness" value="TrkDiskThickness-ITS3Thickness"/>
<constant name="TrkNumOuterDisks" value="3"/>
<constant name="TrkInnerDisk1_z" value="25.0*cm"/>
<constant name="TrkInnerDisk2_z" value="49.0*cm"/>
<constant name="TrkOuterDisk_zmin" value="73.0*cm"/>
<constant name="TrkOuterDisk_zmax" value="121.0*cm"/>
<constant name="TrkOuterDisk_deltaz" value="(TrkOuterDisk_zmax-TrkOuterDisk_zmin)/(TrkNumOuterDisks-1)" />
<constant name="TrkInnerDisk1_rmin" value="0.05025461*TrkInnerDisk1_z-0.180808*cm"/>
<constant name="TrkInnerDisk2_rmin" value="0.05025461*TrkInnerDisk2_z-0.180808*cm"/>
<constant name="TrkOuterDisk_rmin" value="3.18*cm"/>
<constant name="TrkInnerDisk1_rmax" value="18.5*TrkInnerDisk1_z/TrkInnerDisk1_z*cm"/>
<constant name="TrkInnerDisk2_rmax" value="18.5*TrkInnerDisk2_z/TrkInnerDisk1_z*cm"/>
<constant name="TrkOuterDisk_rmax" value="43.23*cm"/>
</define>
<limits>
</limits>
<regions>
</regions>
<display>
</display>
<detectors>
<detector id="AllSiliconVtx_ID" name="AllSiliconVtx" type="refdet_CylinderTrackerBarrel" readout="ITS3Hits">
<module name="Module1" vis="AnlGreen">
<module_envelope rmin="VtxRadius1" thickness="VtxThickness" length="VtxLength" phi="360*degree" />
<module_component rmin="VtxRadius1" thickness="ITS3Thickness" material="Silicon" name="ITS3" sensitive="true" />
<module_component rmin="VtxRadius1 + ITS3Thickness" thickness="VtxServiceThickness" material="Silicon" name="VtxServices" />
</module>
<module name="Module2" vis="AnlGreen">
<module_envelope rmin="VtxRadius2" thickness="VtxThickness" length="VtxLength" phi="360*degree" />
<module_component rmin="VtxRadius2" thickness="ITS3Thickness" material="Silicon" name="ITS3" sensitive="true" />
<module_component rmin="VtxRadius2 + ITS3Thickness" thickness="VtxServiceThickness" material="Silicon" name="VtxServices" />
</module>
<layer module="Module1" id="1" vis="AnlGreen">
<barrel_envelope inner_r="VtxRadius1" outer_r="VtxRadius1 + VtxThickness" z_length="VtxLength" />
<rphi_layout phi_tilt="0.0" nphi="1" phi0="0.0" rc="VtxRadius1" dr="0.0*mm" />
<z_layout dr="0.0*mm" z0="0" nz="1" />
</layer>
<layer module="Module2" id="AllSiliconVtx_ID" vis="AnlGreen">
<barrel_envelope inner_r="VtxRadius2" outer_r="VtxRadius2 + VtxThickness" z_length="VtxLength" />
<rphi_layout phi_tilt="0.0" nphi="1" phi0="0.0" rc="VtxRadius2" dr="0.0*mm" />
<z_layout dr="0.0*mm" z0="0" nz="1" />
</layer>
</detector>
<detector id="AllSiliconTrk1Assembly_ID" name="AllSiliconTrkAssembly1" type="DD4hep_SubdetectorAssembly" vis="AnlGreen">
<composite name="AllSiliconTrkDisk1N" />
<composite name="AllSiliconTrkDisk1P" />
<composite name="AllSiliconBarrel1" />
</detector>
<detector id="AllSiliconTrkBarrel1_ID" name="AllSiliconTrkBarrel1" type="refdet_CylinderTrackerBarrel" readout="ITS3Hits">
<module name="Module1" id="1" vis="AnlGreen">
<module_envelope rmin="TrkBarrel1Radius1" thickness="TrkBarrelThickness" length="TrkBarrel1Length1" phi="360*degree" />
<module_component rmin="TrkBarrel1Radius1" thickness="ITS3Thickness" material="Silicon" name="ITS3" sensitive="true" />
<module_component rmin="TrkBarrel1Radius1 + ITS3Thickness" thickness="TrkBarrelServiceThickness" material="Silicon" name="TrkBarrel1Services" />
</module>
<module name="Module2" id="2" vis="AnlGreen">
<module_envelope rmin="TrkBarrel1Radius2" thickness="TrkBarrelThickness" length="TrkBarrel1Length2" phi="360*degree" />
<module_component rmin="TrkBarrel1Radius2" thickness="ITS3Thickness" material="Silicon" name="ITS3" sensitive="true" />
<module_component rmin="TrkBarrel1Radius2 + ITS3Thickness" thickness="TrkBarrelServiceThickness" material="Silicon" name="TrkBarrel1Services" />
</module>
<layer module="Module1" id="1" vis="AnlGreen">
<barrel_envelope inner_r="TrkBarrel1Radius1" outer_r="TrkBarrel1Radius1 + TrkBarrelThickness" z_length="TrkBarrel1Length1" />
<rphi_layout phi_tilt="0.0" nphi="1" phi0="0.0" rc="TrkBarrel1Radius1" dr="0.0*mm" />
<z_layout dr="0.0*mm" z0="0" nz="1" />
</layer>
<layer module="Module2" id="2" vis="AnlGreen">
<barrel_envelope inner_r="TrkBarrel1Radius2" outer_r="TrkBarrel1Radius2 + TrkBarrelThickness" z_length="TrkBarrel1Length2" />
<rphi_layout phi_tilt="0.0" nphi="1" phi0="0.0" rc="TrkBarrel1Radius2" dr="0.0*mm" />
<z_layout dr="0.0*mm" z0="0" nz="1" />
</layer>
</detector>
<detector id="AllSiliconTrkDisk1N_ID" name="AllSiliconTrkDisk1N" type="ref_DiskTracker" insideTrackingVolume="true" reflect="true" vis="kAnlGreen">
<position x="0" y="0" z="0"/>
<layer id="1" vis="AnlGreen"
inner_z="TrkInnerDisk1_z"
inner_r="TrkInnerDisk1_rmin"
outer_r="TrkInnerDisk1_rmax">
<slice material="Silicon" thickness="TrkDiskThickness" vis="AnlGreen" />
</layer>
</detector>
<detector id="AllSiliconTrkDisk1P_ID" name="AllSiliconTrkDisk1P" type="ref_DiskTracker" insideTrackingVolume="true" reflect="false" vis="kAnlGreen">
<position x="0" y="0" z="0"/>
<layer id="1" vis="AnlGreen"
inner_z="TrkInnerDisk1_z"
inner_r="TrkInnerDisk1_rmin"
outer_r="TrkInnerDisk1_rmax">
<slice material="Silicon" thickness="TrkDiskThickness" vis="AnlGreen" />
</layer>
</detector>
<detector id="AllSiliconTrk2Assembly_ID" name="AllSiliconTrkAssembly2" type="DD4hep_SubdetectorAssembly" vis="AnlGreen">
<composite name="AllSiliconTrkDisk2N" />
<composite name="AllSiliconTrkDisk2P" />
<composite name="AllSiliconBarrel2" />
</detector>
<detector id="AllSiliconTrkBarrel2_ID" name="AllSiliconTrkBarrel2" type="refdet_CylinderTrackerBarrel" readout="ITS3Hits">
<module name="Module1" id="1" vis="AnlGreen">
<module_envelope rmin="TrkBarrel2Radius1" thickness="TrkBarrelThickness" length="TrkBarrel2Length1" phi="360*degree" />
<module_component rmin="TrkBarrel2Radius1" thickness="ITS3Thickness" material="Silicon" name="ITS3" sensitive="true" />
<module_component rmin="TrkBarrel2Radius1 + ITS3Thickness" thickness="TrkBarrelServiceThickness" material="Silicon" name="TrkBarrel2Services" />
</module>
<module name="Module2" id="2" vis="AnlGreen">
<module_envelope rmin="TrkBarrel2Radius2" thickness="TrkBarrelThickness" length="TrkBarrel2Length2" phi="360*degree" />
<module_component rmin="TrkBarrel2Radius2" thickness="ITS3Thickness" material="Silicon" name="ITS3" sensitive="true" />
<module_component rmin="TrkBarrel2Radius2 + ITS3Thickness" thickness="TrkBarrelServiceThickness" material="Silicon" name="TrkBarrel2Services" />
</module>
<layer module="Module1" id="1" vis="AnlGreen">
<barrel_envelope inner_r="TrkBarrel2Radius1" outer_r="TrkBarrel2Radius1 + TrkBarrelThickness" z_length="TrkBarrel2Length1" />
<rphi_layout phi_tilt="0.0" nphi="1" phi0="0.0" rc="TrkBarrel2Radius1" dr="0.0*mm" />
<z_layout dr="0.0*mm" z0="0" nz="1" />
</layer>
<layer module="Module2" id="2" vis="AnlGreen">
<barrel_envelope inner_r="TrkBarrel2Radius2" outer_r="TrkBarrel2Radius2 + TrkBarrelThickness" z_length="TrkBarrel2Length2" />
<rphi_layout phi_tilt="0.0" nphi="1" phi0="0.0" rc="TrkBarrel2Radius2" dr="0.0*mm" />
<z_layout dr="0.0*mm" z0="0" nz="1" />
</layer>
</detector>
<detector id="AllSiliconTrkDisk2N_ID" name="AllSiliconTrkDisk2N" type="ref_DiskTracker" insideTrackingVolume="true" reflect="true" vis="kAnlGreen">
<position x="0" y="0" z="0"/>
<layer id="1" vis="AnlGreen"
inner_z="TrkInnerDisk2_z"
inner_r="TrkInnerDisk2_rmin"
outer_r="TrkInnerDisk2_rmax">
<!--slice material="Silicon" thickness="ITS3Thickness" vis="AnlGreen" sensitive="true"/-->
<!--slice material="Silicon" thickness="TrkDiskServiceThickness" vis="AnlGreen" /-->
<slice material="Silicon" thickness="TrkDiskThickness" vis="AnlGreen" />
</layer>
</detector>
<detector id="AllSiliconTrkDisk2P_ID" name="AllSiliconTrkDisk2P" type="ref_DiskTracker" insideTrackingVolume="true" reflect="false" vis="kAnlGreen">
<position x="0" y="0" z="0"/>
<layer id="1" vis="AnlGreen"
inner_z="TrkInnerDisk2_z"
inner_r="TrkInnerDisk2_rmin"
outer_r="TrkInnerDisk2_rmax">
<!--slice material="Silicon" thickness="ITS3Thickness" vis="AnlGreen" sensitive="true"/-->
<!--slice material="Silicon" thickness="TrkDiskServiceThickness" vis="AnlGreen" /-->
<slice material="Silicon" thickness="TrkDiskThickness" vis="AnlGreen" />
</layer>
</detector>
<detector id="AllSiliconTrkOuterN_ID" name="AllSiliconTrkOuterN" type="ref_DiskTracker" insideTrackingVolume="true" reflect="true" vis="kAnlGreen">
<position x="0" y="0" z="0"/>
<layer id="1" vis="AnlGreen"
inner_z="TrkOuterDisk_zmin"
inner_r="TrkOuterDisk_rmin"
outer_r="TrkOuterDisk_rmax">
<slice material="Silicon" thickness="TrkDiskThickness" vis="AnlGreen" />
</layer>
<layer id="2" vis="AnlGreen"
inner_z="TrkOuterDisk_zmin + 1 * TrkOuterDisk_deltaz"
inner_r="TrkOuterDisk_rmin"
outer_r="TrkOuterDisk_rmax">
<!--slice material="Silicon" thickness="ITS3Thickness" vis="AnlGreen" sensitive="true"/-->
<!--slice material="Silicon" thickness="TrkDiskServiceThickness" vis="AnlGreen" /-->
<slice material="Silicon" thickness="TrkDiskThickness" vis="AnlGreen" />
</layer>
<layer id="3" vis="AnlGreen"
inner_z="TrkOuterDisk_zmin + 2 * TrkOuterDisk_deltaz"
inner_r="TrkOuterDisk_rmin"
outer_r="TrkOuterDisk_rmax">
<!--slice material="Silicon" thickness="ITS3Thickness" vis="AnlGreen" sensitive="true"/-->
<!--slice material="Silicon" thickness="TrkDiskServiceThickness" vis="AnlGreen" /-->
<slice material="Silicon" thickness="TrkDiskThickness" vis="AnlGreen" />
</layer>
</detector>
<detector id="AllSiliconTrkOuterP_ID" name="AllSiliconTrkOuterP" type="ref_DiskTracker" insideTrackingVolume="true" reflect="false" vis="kAnlGreen">
<position x="0" y="0" z="0"/>
<layer id="1" vis="AnlGreen"
inner_z="TrkOuterDisk_zmin"
inner_r="TrkOuterDisk_rmin"
outer_r="TrkOuterDisk_rmax">
<slice material="Silicon" thickness="TrkDiskThickness" vis="AnlGreen" />
</layer>
<layer id="2" vis="AnlGreen"
inner_z="TrkOuterDisk_zmin + 1 * TrkOuterDisk_deltaz"
inner_r="TrkOuterDisk_rmin"
outer_r="TrkOuterDisk_rmax">
<!--slice material="Silicon" thickness="ITS3Thickness" vis="AnlGreen" sensitive="true"/-->
<!--slice material="Silicon" thickness="TrkDiskServiceThickness" vis="AnlGreen" /-->
<slice material="Silicon" thickness="TrkDiskThickness" vis="AnlGreen" />
</layer>
<layer id="3" vis="AnlGreen"
inner_z="TrkOuterDisk_zmin + 2 * TrkOuterDisk_deltaz"
inner_r="TrkOuterDisk_rmin"
outer_r="TrkOuterDisk_rmax">
<!--slice material="Silicon" thickness="ITS3Thickness" vis="AnlGreen" sensitive="true"/-->
<!--slice material="Silicon" thickness="TrkDiskServiceThickness" vis="AnlGreen" /-->
<slice material="Silicon" thickness="TrkDiskThickness" vis="AnlGreen" />
</layer>
</detector>
</detectors>
<readouts>
<readout name="ITS3Hits">
<segmentation type="CartesianGridXY" grid_size_x="0.010*mm" grid_size_y="0.010*mm" />
<id>system:8,barrel:3,layer:4,module:7,sensor:2,x:32:-16,y:-16</id>
</readout>
</readouts>
<plugins>
</plugins>
<fields>
</fields>
</lccdd>
......@@ -73,6 +73,7 @@
<constant name="SiVertexSubAssembly_ID" value="26"/>
<constant name="SiVertexEndcapP_ID" value="30"/>
<constant name="SiVertexEndcapN_ID" value="40"/>
<constant name="AllSiliconVtx_ID" value="41"/>
<comment>
Unused values reserved for vertex:
......@@ -130,6 +131,21 @@
<constant name="cb_CTD_Si_ID" value="74"/>
<comment>
Start over the IDs for all-silicon, as these are mutually exclusive detectors
</comment>
<constant name="AllSiliconTrk1Assembly_ID" value="50"/>
<constant name="AllSiliconTrkBarrel1_ID" value="51"/>
<constant name="AllSiliconTrkDisk1N_ID" value="52"/>
<constant name="AllSiliconTrkDisk1P_ID" value="53"/>
<constant name="AllSiliconTrk2Assembly_ID" value="54"/>
<constant name="AllSiliconTrkBarrel2_ID" value="55"/>
<constant name="AllSiliconTrkDisk2N_ID" value="56"/>
<constant name="AllSiliconTrkDisk2P_ID" value="57"/>
<constant name="AllSiliconTrkOuterN_ID" value="58"/>
<constant name="AllSiliconTrkOuterP_ID" value="59"/>
<constant name="AllSiliconSupport_ID" value="60"/>
<comment>
===================
(75-84) Barrel Tracker IDs
......@@ -327,10 +343,10 @@
<constant name="ForwardRICH_length" value="1.1*m"/>
<constant name="ForwardTRD_length" value="10.0*cm"/>
<constant name="ForwardTOF_length" value="5.0*cm"/>
<constant name="ForwardTOF_length" value="3.0*cm"/>
<constant name="BackwardCherenkov_length" value="20.0*cm"/>
<constant name="BackwardTOF_length" value="10.0*cm"/>
<constant name="BackwardCherenkov_length" value="15.0*cm"/>
<constant name="BackwardTOF_length" value="3.0*cm"/>
<comment> Total length of PID detectors above</comment>
<constant name="ForwardPIDLength" value="ForwardRICH_length + ForwardTRD_length + ForwardTOF_length"/>
......@@ -355,8 +371,8 @@
============================
</comment>
<constant name="ForwardTracking_length" value="6.0*cm"/>
<constant name="BackwardTracking_length" value="6.0*cm"/>
<constant name="ForwardTracking_length" value="0.0*cm"/>
<constant name="BackwardTracking_length" value="0.0*cm"/>
<comment>
-------------------------
......@@ -402,7 +418,7 @@
<constant name="TrackerBarrel_rmin" value="VertexTrackerBarrel_rmax"/>
<comment> This is just inside of the potential uRWEL detector hugging the DIRC from the inside </comment>
<constant name="TrackerBarrel_rmax" value="78*cm"/>
<constant name="TrackerBarrelOuter_length" value="2000.0*mm"/>
<constant name="TrackerBarrelOuter_length" value="2600.0*mm"/>
<constant name="TrackerBarrelInner_length" value="VertexTrackingRegion_length"/>
<constant name="TrackerBarrelInner_zmax" value="TrackerBarrelInner_length/2.0"/>
<constant name="TrackerBarrelOuter_zmax" value="TrackerBarrelOuter_length/2.0"/>
......@@ -458,7 +474,7 @@
<comment> these offesets could be implemented differently for clarity. </comment>
<constant name="EcalEndcapPSolenoid_offset" value="800.0*mm" />
<constant name="EcalEndcapNSolenoid_offset" value="0.0*mm" />
<constant name="EcalEndcapNSolenoid_offset" value="-100.0*mm" />
<constant name="HcalEndcapPExtra_length" value="40.0*cm"/>
<constant name="HcalEndcapNExtra_length" value="0.0*cm"/>
......@@ -470,12 +486,7 @@
<constant name="Barrel_rmax" value="Solenoid_rmin - 1.0 *cm "/>
<constant name="Barrel_TotalCalThickness" value="Barrel_rmax - EcalBarrel_rmin"/>
<constant name="CalBarrelDivider" value="0.8"/>
<comment> Leave room for TRD </comment>
<constant name="EcalBarrel_TotalThickness" value="Barrel_TotalCalThickness * CalBarrelDivider"/>
<constant name="HcalBarrel_TotalThickness" value="Barrel_TotalCalThickness * (1.0 - CalBarrelDivider)"/>
<constant name="EcalBarrel_TotalThickness" value="40.0*cm"/>
<constant name="EcalEndcapP_zmin" value="CentralTracking_length/2.0 + ForwardPIDLength"/>
<constant name="EcalEndcapN_zmin" value="CentralTracking_length/2.0 + BackwardPIDLength"/>
......@@ -494,7 +505,8 @@
<constant name="EndcapN_CalDivide" value="1.0"/> <comment> 0.5 means Ecal and Hcal have the same thickness </comment>
<constant name="EcalEndcapP_length" value="EndcapPTotalCal_length * EndcapP_CalDivide"/>
<constant name="EcalEndcapN_length" value="EndcapNTotalCal_length * EndcapN_CalDivide"/>
<!--constant name="EcalEndcapN_length" value="EndcapNTotalCal_length * EndcapN_CalDivide"/-->
<constant name="EcalEndcapN_length" value="40*cm"/>
<comment> These need to be set in sync with the forward and backward detectors </comment>
......@@ -575,9 +587,9 @@
-------------------------------
</comment>
<constant name="HcalEndcapP_length" value="50.0*cm"/>
<constant name="HcalEndcapN_length" value="50.0*cm"/>
<constant name="HcalBarrel_thickness" value="50.0*cm "/>
<constant name="HcalEndcapP_length" value="100.0*cm"/>
<constant name="HcalEndcapN_length" value="75.0*cm"/>
<constant name="HcalBarrel_thickness" value="100.0*cm "/>
<constant name="HcalBarrel_rmin" value="Solenoid_rmax"/>
<constant name="HcalBarrel_rmax" value="HcalBarrel_rmin + HcalBarrel_thickness"/>
......
......@@ -221,5 +221,9 @@
<composite n="6" ref="H"/>
<composite n="1" ref="O"/>
</material>
<material name="Graphite">
<D type="density" value="2.21" unit="g/cm3"/>
<composite n="1" ref="C"/>
</material>
</materials>
......@@ -118,8 +118,9 @@
<include ref="compact/ecal.xml"/>
<include ref="compact/hcal.xml"/>
<!--include ref="compact/ce_GEM.xml"/-->
<include ref="compact/vertex_tracker.xml"/>
<include ref="compact/gem_tracker_endcap.xml"/>
<!--include ref="compact/vertex_tracker.xml"/-->
<include ref="compact/allsilicon_simplified.xml"/>
<!--include ref="compact/gem_tracker_endcap.xml"/-->
<include ref="compact/ce_mrich.xml"/>
<include ref="compact/tof_endcap.xml"/>
<include ref="compact/forward_trd.xml"/>
......
#include "DD4hep/DetFactoryHelper.h"
#include "DD4hep/OpticalSurfaces.h"
#include "DD4hep/Printout.h"
#include "DDRec/DetectorData.h"
#include "DDRec/Surface.h"
#include <XML/Helper.h>
//////////////////////////////////
// Support structure for ALl-silicon
//////////////////////////////////
using namespace std;
using namespace dd4hep;
// Info from
// https://github.com/reynier0611/g4lblvtx/blob/master/source/AllSi_vtx_serv_2lyr_Detector.cc
// TODO: this is quite incomplete, should probably wait for official word
// from he tracking WG
static Ref_t createDetector(Detector& desc, xml_h e, SensitiveDetector sens)
{
xml_det_t x_det = e;
string detName = x_det.nameStr();
int detID = x_det.id();
bool reflect = x_det.reflect();
const int sign = reflect ? -1 : 1;
// second vertexing layer
std::vector<double> z_det = {15 * cm, 20 * cm};
std::vector<double> rin_l2 = {5.48 * cm, 14.8 * cm};
std::vector<double> rout_l2 = {0, 0};
// first vertexing layer
std::vector<double> rin_l1 = {3.30 * cm, 14.36 * cm};
std::vector<double> rout_l1 = {0, 0};
const int nzplanes_l2 = z_det.size();
const int nzplanes_l1 = z_det.size();
for (int i = 0; i < nzplanes_l2; i++) {
rout_l2[i] = rin_l2[i] + 0.44;
z_det[i] *= sign / abs(sign);
}
for (int i = 0; i < nzplanes_l1; i++) {
rout_l1[i] = rin_l1[i] + 0.44;
z_det[i] *= sign / abs(sign);
}
// mother volume
std::vector<double> rin_mo = rin_l1;
std::vector<double> rout_mo = rout_l2;
DetElement det(detName, detID);
Material Vacuum = desc.material("Vacuum");
Polycone empty_cone("empty_cone", 0.0, 360 * degree, z_det, rin_mo, rout_mo);
Volume detVol("empty_cone", empty_cone, Vacuum);
detVol.setVisAttributes(desc.invisible());
Volume motherVol = desc.pickMotherVolume(det);
Transform3D tr(RotationZYX(0.0, 0.0, 0.0), Position(0.0, 0.0, 0.));
PlacedVolume detPV = motherVol.placeVolume(detVol, tr);
detPV.addPhysVolID("system", detID);
detPV.addPhysVolID("barrel", 1);
det.setPlacement(detPV);
Material Al = desc.material("Al");
Material Graphite = desc.material("Graphite");
// cb_DIRC_bars_Logic.setVisAttributes(desc.visAttributes(x_det.visStr()));
Polycone polycone_l2("polycone_l2", 0, 360 * degree, z_det, rin_l2, rout_l2);
Volume logical_l2("polycone_l2_logic", polycone_l2, Al);
logical_l2.setVisAttributes(desc.visAttributes(x_det.visStr()));
detVol.placeVolume(logical_l2, tr);
Polycone polycone_l1("polycone_l1", 0, 360 * degree, z_det, rin_l1, rout_l1);
Volume logical_l1("polycone_l1_logic", polycone_l1, Al);
logical_l1.setVisAttributes(desc.visAttributes(x_det.visStr()));
detVol.placeVolume(logical_l1, tr);
return det;
}
DECLARE_DETELEMENT(allsilicon_support, createDetector)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment