14 #include "CLHEP/Units/GlobalPhysicalConstants.h"
15 #include "CLHEP/Units/GlobalSystemOfUnits.h"
19 LogDebug(
"TrackerGeom") <<
"DDTrackerPhiAlgo info: Creating an instance";
30 if ( nArgs.find(
"StartCopyNo") != nArgs.end() ) {
31 startcn = size_t(nArgs[
"StartCopyNo"]);
35 if ( nArgs.find(
"IncrCopyNo") != nArgs.end() ) {
36 incrcn = int(nArgs[
"IncrCopyNo"]);
47 if ( nArgs.find(
"NumCopies") != nArgs.end() ) {
50 edm::LogError(
"TrackerGeom") <<
"DDTrackerPhiAlgo error: Parameter "
51 <<
"NumCopies does not agree with the size "
52 <<
"of the Phi vector. It was adjusted to "
53 <<
"be the size of the Phi vector and may "
54 <<
"lead to crashes or errors.";
60 LogDebug(
"TrackerGeom") <<
"DDTrackerPhiAlgo debug: Parameters for position"
61 <<
"ing:: " <<
" Radius " <<
radius <<
" Tilt "
62 <<
tilt/CLHEP::deg <<
" Copies " <<
phi.size()
64 for (
int i=0;
i<(int)(
phi.size());
i++)
65 LogDebug(
"TrackerGeom") <<
"\t[" <<
i <<
"] phi = " <<
phi[
i]/CLHEP::deg
66 <<
" z = " <<
zpos[
i];
71 LogDebug(
"TrackerGeom") <<
"DDTrackerPhiAlgo debug: Parent " << parentName
72 <<
"\tChild " <<
childName <<
" NameSpace "
80 double theta = 90.*CLHEP::deg;
85 double phiy = phix + 90.*CLHEP::deg;
86 double phideg =
phi[
i]/CLHEP::deg;
91 LogDebug(
"TrackerGeom") <<
"DDTrackerPhiAlgo test: Creating a new "
92 <<
"rotation: " << rotstr <<
"\t" <<
"90., "
93 << phix/CLHEP::deg <<
", 90.,"
94 << phiy/CLHEP::deg <<
", 0, 0";
103 cpv.
position(child, mother, ci, tran, rotation);
104 LogDebug(
"TrackerGeom") <<
"DDTrackerPhiAlgo test: " << child <<
" number "
105 << ci <<
" positioned in " << mother <<
" at "
std::vector< double > phi
virtual ~DDTrackerPhiAlgo()
Sin< T >::type sin(const T &t)
Geom::Theta< T > theta() const
void position(const DDLogicalPart &self, const DDLogicalPart &parent, std::string copyno, const DDTranslation &trans, const DDRotation &rot, const DDDivision *div=NULL)
const reco::GenParticle * mother(const reco::GenParticle &p, unsigned int imoth=0)
DDName is used to identify DDD entities uniquely.
static std::string & ns()
std::string dbl_to_string(const double &in)
Converts only the integer part of a double to a string.
type of data representation of DDCompactView
ROOT::Math::DisplacementVector3D< ROOT::Math::Cartesian3D< double > > DDTranslation
Represents a uniquely identifyable rotation matrix.
U second(std::pair< T, U > const &p)
Cos< T >::type cos(const T &t)
void execute(DDCompactView &cpv)
std::vector< double > zpos
void initialize(const DDNumericArguments &nArgs, const DDVectorArguments &vArgs, const DDMapArguments &mArgs, const DDStringArguments &sArgs, const DDStringVectorArguments &vsArgs)
std::pair< std::string, std::string > DDSplit(const std::string &n)
split into (name,namespace), separator = ':'