13 #include "CLHEP/Units/GlobalSystemOfUnits.h"
14 #include "CLHEP/Units/GlobalPhysicalConstants.h"
25 edm::LogInfo(
"HFShower") <<
"HFFibre:: Speed of light in fibre " << cFibre
31 DDValue ddv1(attribute,value,0);
43 edm::LogInfo(
"HFShower") <<
"HFFibre: " << nBinAtt <<
" attL ";
44 for (
int it=0; it<
nBinAtt; it++)
45 edm::LogInfo(
"HFShower") <<
"HFFibre: attL[" << it <<
"] = "
46 <<
attL[it]*cm <<
"(1/cm)";
50 std::vector<double> nvec =
getDDDArray(
"lambLim",sv,nb);
51 lambLim[0] =
static_cast<int>(nvec[0]);
52 lambLim[1] =
static_cast<int>(nvec[1]);
59 edm::LogInfo(
"HFShower") <<
"HFFibre: " << nb <<
" Long Fibre Length";
60 for (
int it=0; it<nb; it++)
61 edm::LogInfo(
"HFShower") <<
"HFFibre: longFL[" << it <<
"] = "
65 edm::LogInfo(
"HFShower") <<
"HFFibre: " << nb <<
" Short Fibre Length";
66 for (
int it=0; it<nb; it++)
67 edm::LogInfo(
"HFShower") <<
"HFFibre: shortFL[" << it <<
"] = "
71 <<
" view for " << attribute <<
" matching "
74 <<
"cannot match " << attribute <<
" to " << name <<
"\n";
78 attribute =
"ReadOutName";
81 DDValue ddv2(attribute,value,0);
92 edm::LogInfo(
"HFShower") <<
"HFFibre: " << nb <<
" gpar (cm)";
93 for (
int i=0;
i<nb;
i++)
95 <<
gpar[
i]/cm <<
" cm";
101 edm::LogInfo(
"HFShower") <<
"HFFibre: radius[" <<
i <<
"] = "
105 <<
" view for " << attribute <<
" matching "
108 <<
"cannot match " << attribute <<
" to " << name <<
"\n";
123 double att =
attL[
j];
125 edm::LogInfo(
"HFShower") <<
"HFFibre::attLength for Lambda " << lambda
126 <<
" index " << i <<
" " << j <<
" Att. Length "
134 double zFibre =
zShift(point, depth, fromEndAbs);
137 edm::LogInfo(
"HFShower") <<
"HFFibre::tShift for point " << point
138 <<
" ( depth = " << depth <<
", traversed length = "
139 << zFibre/cm <<
" cm) = " << time/ns <<
" ns";
147 double hR =
sqrt((point.x())*(point.x())+(point.y())*(point.y()));
149 double length = 250*cm;
150 if (fromEndAbs < 0) {
151 zFibre = 0.5*
gpar[1] - point.z();
162 if (fromEndAbs > 0) {
165 double zz = 0.5*
gpar[1] + point.z();
168 if (depth == 2) zFibre +=
gpar[0];
172 edm::LogInfo(
"HFShower") <<
"HFFibre::zShift for point " << point
173 <<
" (R = " << hR/cm <<
" cm, Index = " << ieta
174 <<
", depth = " << depth <<
", Fibre Length = "
175 << length/cm <<
" cm = " << zFibre/cm
186 LogDebug(
"HFShower") <<
"HFFibre:getDDDArray called for " << str
187 <<
" with nMin " << nmin;
194 const std::vector<double> & fvec = value.
doubles();
195 int nval = fvec.size();
198 edm::LogError(
"HFShower") <<
"HFFibre : # of " << str <<
" bins "
199 << nval <<
" < " << nmin <<
" ==> illegal";
201 <<
"nval < nmin for array " << str <<
"\n";
204 if (nval < 1 && nmin != 0) {
205 edm::LogError(
"HFShower") <<
"HFFibre : # of " << str <<
" bins "
206 << nval <<
" < 1 ==> illegal (nmin="
209 <<
"nval < 1 for array " << str <<
"\n";
216 edm::LogError(
"HFShower") <<
"HFFibre : cannot get array " << str;
218 <<
"cannot get array " << str <<
"\n";
220 std::vector<double> fvec;
double tShift(const G4ThreeVector &point, int depth, int fromEndAbs=0)
std::vector< double > gpar
T getParameter(std::string const &) const
std::vector< double > getDDDArray(const std::string &, const DDsvalues_type &, int &)
const std::vector< double > & doubles() const
a reference to the double-valued values stored in the given instance of DDValue
void addFilter(const DDFilter &, DDLogOp op=DDLogOp::AND)
double attLength(double lambda)
double zShift(const G4ThreeVector &point, int depth, int fromEndAbs=0)
std::vector< double > radius
type of data representation of DDCompactView
bool DDfetch(const DDsvalues_type *, DDValue &)
helper for retrieving DDValues from DDsvalues_type *.
std::vector< std::pair< unsigned int, DDValue > > DDsvalues_type
std::maps an index to a DDValue. The index corresponds to the index assigned to the name of the std::...
HFFibre(std::string &name, const DDCompactView &cpv, edm::ParameterSet const &p)
std::vector< double > shortFL
std::vector< double > attL
DDsvalues_type mergedSpecifics() const
bool firstChild()
set the current node to the first child ...
void setCriteria(const DDValue &nameVal, DDCompOp, DDLogOp l=DDLogOp::AND, bool asString=true, bool merged=true)
*vegas h *****************************************************used in the default bin number in original ***version of VEGAS is ***a higher bin number might help to derive a more precise ***grade subtle point
std::vector< double > longFL
The DDGenericFilter is a runtime-parametrized Filter looking on DDSpecifcs.