69 distanceZ = nArgs[
"DistZ"];
71 copyNumber =
int(nArgs[
"Number"]);
74 edm::LogVerbatim(
"HCalGeom") <<
"DDHCalTestBeamAlgo: Parameters for position" 78 <<
"\tDz " <<
dz <<
"\tcopyNumber " << copyNumber;
81 childName = sArgs[
"ChildName"];
84 <<
" NameSpace " << idNameSpace;
89 double thetax = 90._deg +
theta;
90 double sthx =
sin(thetax);
96 double thetay = 90._deg;
97 double phiy = 90._deg + phi;
98 double thetaz =
theta;
104 edm::LogVerbatim(
"HCalGeom") <<
"DDHCalTestBeamAlgo: Creating a rotation " << rotstr <<
"\t" 109 rotation =
DDrot(
DDName(rotstr, idNameSpace), thetax, phix, thetay, phiy, thetaz, phiz);
112 double xpos = r *
cos(phi);
113 double ypos = r *
sin(phi);
118 cpv.
position(
DDName(childName, idNameSpace), parentName, copyNumber, tran, rotation);
120 edm::LogVerbatim(
"HCalGeom") <<
"DDHCalTestBeamAlgo: " <<
DDName(childName, idNameSpace) <<
" number " << copyNumber
121 <<
" positioned in " << parentName <<
" at " << tran <<
" with " <<
rotation;
127 edm::LogInfo(
"HCalGeom") <<
"DDHCalTestBeamAlgo: Suggested Beam position " 128 <<
"(" << xpos <<
", " << ypos <<
", " << zpos <<
") and (dist, eta, phi) = (" << (dist -
dz)
129 <<
", " <<
eta <<
", " << phi <<
")";
static AlgebraicMatrix initialize()
constexpr NumType convertRadToDeg(NumType radians)
Sin< T >::type sin(const T &t)
Geom::Theta< T > theta() const
DDName is used to identify DDD entities uniquely.
void initialize(const DDNumericArguments &nArgs, const DDVectorArguments &vArgs, const DDMapArguments &mArgs, const DDStringArguments &sArgs, const DDStringVectorArguments &vsArgs) override
static std::string & ns()
Compact representation of the geometrical detector hierarchy.
ROOT::Math::DisplacementVector3D< ROOT::Math::Cartesian3D< double > > DDTranslation
Represents a uniquely identifyable rotation matrix.
~DDHCalTestBeamAlgo() override
Cos< T >::type cos(const T &t)
Abs< T >::type abs(const T &t)
void position(const DDLogicalPart &self, const DDLogicalPart &parent, const std::string ©no, const DDTranslation &trans, const DDRotation &rot, const DDDivision *div=0)
#define DEFINE_EDM_PLUGIN(factory, type, name)
void execute(DDCompactView &cpv) override