CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
BremRecoveryPhiRoadAlgo.cc
Go to the documentation of this file.
1 
4 
5 #include <iostream>
6 
8 {
9 
10  // get barrel and endcap parametersets
11  edm::ParameterSet barrelPset = pset.getParameter<edm::ParameterSet>("barrel");
12  edm::ParameterSet endcapPset = pset.getParameter<edm::ParameterSet>("endcap");
13 
14  // set barrel parameters
15  etVec_ = barrelPset.getParameter<std::vector<double> >("etVec");
16  cryVec_ = barrelPset.getParameter<std::vector<int> >("cryVec");
17  cryMin_ = barrelPset.getParameter<int>("cryMin");
18 
19  // set endcap parameters
20  a_ = endcapPset.getParameter<double>("a");
21  b_ = endcapPset.getParameter<double>("b");
22  c_ = endcapPset.getParameter<double>("c");
23 
24 }
25 
27 {
28 
29  //
30  // Take as input the ET in 5x5 crystals
31  // and compute the optimal phi road
32  // as a number of crystals
33 
34  for (unsigned int i = 0; i < cryVec_.size(); ++i)
35  {
36  if (et < etVec_[i]) return cryVec_[i];
37  }
38  return cryMin_;
39 
40 }
41 
43 {
44 
45  //
46  // Take as input the energy in the seed BasicCluster
47  // and return the optimal phi road
48  // length in radians
49 
50  return ((a_ / (energy + b_)) + c_);
51 
52 }
53 
T getParameter(std::string const &) const
int i
Definition: DBlmapReader.cc:9
double endcapPhiRoad(double energy)
std::vector< double > etVec_
BremRecoveryPhiRoadAlgo(const edm::ParameterSet &pset)