172 const double tol(0.01);
173 for (
unsigned int i = 0;
i <
layers.size();
i++) {
175 double routF =
rMax(zi);
176 int laymax = laymin +
layers[
i];
179 for (
int ly = laymin; ly < laymax; ++ly) {
188 edm::LogVerbatim(
"HGCalGeom") <<
"DDHGCalModule: Layer " << ly <<
":" << ii <<
" Front " << zi <<
", " << routF
189 <<
" Back " << zo <<
", " << rinB <<
" superlayer thickness " << layerThick[
i];
196 double rmax = routF *
cos(alpha) - tol;
197 std::vector<double> pgonZ, pgonRin, pgonRout;
198 pgonZ.emplace_back(-0.5 *
thick[ii]);
199 pgonZ.emplace_back(0.5 *
thick[ii]);
200 pgonRin.emplace_back(rinB);
201 pgonRin.emplace_back(rinB);
202 pgonRout.emplace_back(rmax);
203 pgonRout.emplace_back(rmax);
210 << (360.0 +
convertRadToDeg(-alpha)) <<
" with " << pgonZ.size() <<
" sections";
211 for (
unsigned int k = 0;
k < pgonZ.size(); ++
k)
212 edm::LogVerbatim(
"HGCalGeom") <<
"[" <<
k <<
"] z " << pgonZ[
k] <<
" R " << pgonRin[
k] <<
":" << pgonRout[
k];
219 edm::LogVerbatim(
"HGCalGeom") <<
"DDHGCalModule: " << solid.
name() <<
" Tubs made of " << matName
220 <<
" of dimensions " << rinB <<
", " << routF <<
", " << 0.5 *
thick[
ii]
231 edm::LogVerbatim(
"HGCalGeom") <<
"DDHGCalModule: " << glog.
name() <<
" number " << copy <<
" positioned in " 232 << module.
name() <<
" at " <<
r1 <<
" with " <<
rot;
238 if (fabs(thickTot - layerThick[
i]) < 0.00001) {
239 }
else if (thickTot > layerThick[i]) {
240 edm::LogError(
"HGCalGeom") <<
"Thickness of the partition " << layerThick[
i] <<
" is smaller than thickness " 241 << thickTot <<
" of all its components **** ERROR ****\n";
242 }
else if (thickTot < layerThick[i]) {
243 edm::LogWarning(
"HGCalGeom") <<
"Thickness of the partition " << layerThick[
i] <<
" does not match with " 244 << thickTot <<
" of the components\n";
DDMaterial is used to define and access material information.
constexpr NumType convertRadToDeg(NumType radians)
std::vector< int > copyNumber
DDName is used to identify DDD entities uniquely.
std::vector< int > layerSense
A DDSolid represents the shape of a part.
std::vector< int > layers
ROOT::Math::DisplacementVector3D< ROOT::Math::Cartesian3D< double > > DDTranslation
Represents a uniquely identifyable rotation matrix.
U second(std::pair< T, U > const &p)
std::vector< double > slopeB
constexpr long double piRadians(M_PIl)
std::vector< std::string > names
std::vector< std::string > materials
Cos< T >::type cos(const T &t)
A DDLogicalPart aggregates information concerning material, solid and sensitveness ...
static DDSolid tubs(const DDName &name, double zhalf, double rIn, double rOut, double startPhi, double deltaPhi)
std::vector< int > layerType
void position(const DDLogicalPart &self, const DDLogicalPart &parent, const std::string ©no, const DDTranslation &trans, const DDRotation &rot, const DDDivision *div=0)
std::vector< double > thick
std::vector< double > layerThick
void positionSensitive(DDLogicalPart &glog, double rin, double rout, DDCompactView &cpv)
alpha
zGenParticlesMatch = cms.InputTag(""),
std::pair< std::string, std::string > DDSplit(const std::string &n)
split into (name,namespace), separator = ':'
static DDSolid polyhedra(const DDName &name, int sides, double startPhi, double deltaPhi, const std::vector< double > &z, const std::vector< double > &rmin, const std::vector< double > &rmax)
Creates a polyhedra (refere to Geant3 or Geant4 documentation)