Go to the source code of this file.
◆ algorithm()
Definition at line 11 of file DDTECOptoHybAlgo.cc.
14 int startCopyNo =
args.value<
int>(
"StartCopyNo");
15 double rpos =
args.value<
double>(
"Rpos");
16 double zpos =
args.value<
double>(
"Zpos");
17 double optoHeight =
args.value<
double>(
"OptoHeight");
18 double optoWidth =
args.value<
double>(
"OptoWidth");
19 vector<double>
angles =
args.value<vector<double> >(
"Angles");
23 LogDebug(
"TECGeom") <<
"Parent " << mother.name() <<
" Child " <<
child.name() <<
" NameSpace " << ns.name();
24 LogDebug(
"TECGeom") <<
"Height of the Hybrid " << optoHeight <<
" and Width " << optoWidth <<
"Rpos " << rpos
25 <<
" Zpos " << zpos <<
" StartCopyNo " << startCopyNo <<
" Number " <<
angles.size();
28 rpos += optoHeight / 2;
29 int copyNo = startCopyNo;
33 phix += asin(optoWidth / 2 / rpos);
34 double xpos = rpos *
cos(phix);
35 double ypos = rpos *
sin(phix);
39 double phiy = phix + 90._deg;
42 string rotstr = ns.nsName(
child.name()) + std::to_string(phideg * 1000.);
43 auto irot = ctxt.
rotations.find(ns.prepend(rotstr));
45 rotation = ns.rotation(ns.prepend(rotstr));
47 double theta = 90._deg;
48 LogDebug(
"TECGeom") <<
"test: Creating a new "
49 <<
"rotation: " << rotstr <<
"\t90., " <<
convertRadToDeg(phix) <<
", 90.,"
54 mother.placeVolume(
child, copyNo, Transform3D(
rotation, tran));
55 LogDebug(
"TECGeom") <<
"test " <<
child.name() <<
" number " << copyNo <<
" positioned in " << mother.name()
56 <<
" at " << tran <<
" with " <<
rotation;
59 LogDebug(
"TECGeom") <<
"<<== End of DDTECOptoHybAlgo construction ...";
References angle(), particleFlowDisplacedVertex_cfi::angles, writedatasetfile::args, angle_units::operators::convertRadToDeg(), funct::cos(), MillePedeFileConverter_cfg::e, LogDebug, cms::makeRotation3D(), cms::DDNamespace::name(), cms::DDNamespace::nsName(), PixelTestBeamValidation_cfi::Position, cms::DDNamespace::prepend(), idealTransformation::rotation, cms::DDNamespace::rotation(), cms::DDParsingContext::rotations, funct::sin(), theta(), and cms::DDNamespace::volume().
◆ DD4HEP_OPEN_PLUGIN()
DD4HEP_OPEN_PLUGIN |
( |
dd4hep |
, |
|
|
ddcms_det_element_DDCMS_track_DDTECOptoHybAlgo |
|
|
) |
| |
DDRotationMatrix makeRotation3D(double thetaX, double phiX, double thetaY, double phiY, double thetaZ, double phiZ)
std::unordered_map< std::string, dd4hep::Rotation3D > rotations