16 #include "CLHEP/Units/GlobalPhysicalConstants.h" 17 #include "CLHEP/Units/GlobalSystemOfUnits.h" 20 LogDebug(
"TIBGeom") <<
"DDTIBRadCableAlgo_MTCC info: Creating an instance";
34 LogDebug(
"TIBGeom") <<
"DDTIBRadCableAlgo_MTCC debug: Parent " << parentName
39 layRin = vArgs[
"RadiusLo"];
41 LogDebug(
"TIBGeom") <<
"DDTIBRadCableAlgo_MTCC debug: Disk Rmin " <<
rMin 42 <<
"\tRMax " <<
rMax <<
"\tSeparation of layers " 43 <<
deltaR <<
" with " <<
layRin.size() <<
" layers at R =";
44 for (i = 0; i <
layRin.size(); i++)
51 LogDebug(
"TIBGeom") <<
"DDTIBRadCableAlgo_MTCC debug: SupportCylinder " 52 <<
"Thickness " <<
cylinderT <<
"\tSupportDisk " 53 <<
"Thickness " <<
supportT <<
"\tExtra width along R " 56 cableT = nArgs[
"CableThick"];
58 LogDebug(
"TIBGeom") <<
"DDTIBRadCableAlgo_MTCC debug: Cable Thickness " 59 <<
cableT <<
" with materials: ";
60 for (i = 0; i <
cableMat.size(); i++)
63 strucMat = vsArgs[
"StructureMaterial"];
65 <<
" materials for open structure:";
70 LogDebug(
"TIBGeom") <<
"DDTIBRadCableAlgo_MTCC debug: " <<
layers.size()
72 for (i=0; i<
layers.size(); i++)
79 LogDebug(
"TIBGeom") <<
"==>> Constructing DDTIBRadCableAlgo_MTCC...";
92 for (
unsigned int i=0;
i<
layRin.size();
i++) {
96 for(
double layer :
layers) {
97 if(
i+1==(
unsigned int)layer) {
104 name =
"TIBSupportSideDisk" + std::to_string(
i);
108 rout, 0, CLHEP::twopi);
109 LogDebug(
"TIBGeom") <<
"DDTIBRadCableAlgo_MTCC test: " 112 << CLHEP::twopi/CLHEP::deg <<
" with Rin " << rin
113 <<
" Rout " << rout <<
" ZHalf " <<
dz;
118 LogDebug(
"TIBGeom") <<
"DDTIBRadCableAlgo_MTCC test: " 120 <<
" positioned in " << diskName <<
" at " << r1
121 <<
" with no rotation";
124 name =
"TIBOpenZone" + std::to_string(
i);
126 if (
i == 0) rin =
rMin;
129 rout, 0, CLHEP::twopi);
130 LogDebug(
"TIBGeom") <<
"DDTIBRadCableAlgo_MTCC test: " 133 << CLHEP::twopi/CLHEP::deg <<
" with Rin " << rin
134 <<
" Rout " << rout <<
" ZHalf " <<
dz;
141 LogDebug(
"TIBGeom") <<
"DDTIBRadCableAlgo_MTCC test: " 143 <<
" positioned in " << diskName
144 <<
" at " << r2 <<
" with no rotation";
147 name =
"TIBRadCable" + std::to_string(i);
149 std::vector<double> pgonZ;
150 pgonZ.emplace_back(-0.5*
cableT);
152 pgonZ.emplace_back(0.5*
cableT);
153 std::vector<double> pgonRmin;
154 pgonRmin.emplace_back(rv);
155 pgonRmin.emplace_back(rv);
156 pgonRmin.emplace_back(rv);
157 std::vector<double> pgonRmax;
158 pgonRmax.emplace_back(
rMax);
159 pgonRmax.emplace_back(
rMax);
160 pgonRmax.emplace_back(rv);
162 CLHEP::twopi,pgonZ, pgonRmin, pgonRmax);
163 LogDebug(
"TIBGeom") <<
"DDTIBRadCableAlgo_MTCC test: " 166 <<
" from 0 to " << CLHEP::twopi/CLHEP::deg
167 <<
" and with " << pgonZ.size() <<
" sections";
168 for (
unsigned int ii = 0;
ii <pgonZ.size();
ii++)
169 LogDebug(
"TIBGeom") <<
"\t" <<
"\tZ = " << pgonZ[
ii] <<
"\tRmin = " 170 << pgonRmin[
ii] <<
"\tRmax = " << pgonRmax[
ii];
172 LogDebug(
"TIBGeom") <<
" material cableName " << i <<
" " << cableName;
178 LogDebug(
"TIBGeom") <<
"DDTIBRadCableAlgo_MTCC test: " 180 <<
" positioned in " << diskName <<
" at " 181 << r3 <<
" with no rotation";
188 for(
double layer : layers) {
189 if(
i+1==(
unsigned int)layer) {
196 unsigned int i =
layRin.size();
199 name =
"TIBOpenZone" + std::to_string(i);
201 rout, 0, CLHEP::twopi);
202 LogDebug(
"TIBGeom") <<
"DDTIBRadCableAlgo_MTCC test: " 205 << CLHEP::twopi/CLHEP::deg <<
" with Rin " << rin
206 <<
" Rout " << rout <<
" ZHalf " <<
dz;
213 LogDebug(
"TIBGeom") <<
"DDTIBRadCableAlgo_MTCC test: " 215 <<
" positioned in " << diskName
216 <<
" at " << r2 <<
" with no rotation";
219 LogDebug(
"TIBGeom") <<
"<<== End of DDTIBRadCableAlgo_MTCC construction ...";
std::vector< double > layers
std::vector< LayerSetAndLayers > layers(const SeedingLayerSetsHits &sets)
DDMaterial is used to define and access material information.
static DDSolid polycone(const DDName &name, double startPhi, double deltaPhi, const std::vector< double > &z, const std::vector< double > &rmin, const std::vector< double > &rmax)
Creates a polycone (refere to Geant3 or Geant4 documentation)
void execute(DDCompactView &cpv) override
DDName is used to identify DDD entities uniquely.
~DDTIBRadCableAlgo_MTCC() override
static std::string & ns()
Compact representation of the geometrical detector hierarchy.
A DDSolid represents the shape of a part.
ROOT::Math::DisplacementVector3D< ROOT::Math::Cartesian3D< double > > DDTranslation
Represents a uniquely identifyable rotation matrix.
std::vector< std::string > strucMat
U second(std::pair< T, U > const &p)
void initialize(const DDNumericArguments &nArgs, const DDVectorArguments &vArgs, const DDMapArguments &mArgs, const DDStringArguments &sArgs, const DDStringVectorArguments &vsArgs) override
std::vector< std::string > cableMat
A DDLogicalPart aggregates information concerning material, solid and sensitveness ...
std::vector< double > layRin
static DDSolid tubs(const DDName &name, double zhalf, double rIn, double rOut, double startPhi, double deltaPhi)
void position(const DDLogicalPart &self, const DDLogicalPart &parent, const std::string ©no, const DDTranslation &trans, const DDRotation &rot, const DDDivision *div=0)
std::pair< std::string, std::string > DDSplit(const std::string &n)
split into (name,namespace), separator = ':'