test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
RadialInterval.h
Go to the documentation of this file.
1 #ifndef RadialInterval_H
2 #define RadialInterval_H
3 
4 // Created 1/11/04. F. Beaudette (CERN)
5 // This class is used to ease the lateral development with
6 // different spot fractions in FamosShower.
7 
8 
9 #include <vector>
10 
12 
14 {
15  public:
17  RadialInterval(double RC,unsigned nSpots, double energy,
18  const RandomEngineAndDistribution* engine);
20 
23  void addInterval(double,double);
26  void compute();
28  inline unsigned nIntervals() const { return nInter;}
30  inline double getSpotEnergy(unsigned i) const {
31  // std::cout << " getSpotEnergy " << i << " " << spotE.size() << std::endl;
32  return spotE[i];}
34  inline unsigned getNumberOfSpots(unsigned i) const {
35  // std::cout << " getNumberOfSpots " << i << " " << nspots.size() << std::endl;
36  return nspots[i];
37  }
39  inline double getUmin(unsigned i) const {
40  // std::cout << " getUmin " << i << " " << uMin.size() << std::endl;
41  return uMin[i];
42  }
44  inline double getUmax(unsigned i) const {
45  // std::cout << " getUmax " << i << " " << uMax.size() << std::endl;
46  return uMax[i];
47  }
48 
49  private:
50  double currentRad;
52  double currentUlim;
53  double theR;
54  unsigned theNumberOfSpots;
55  double theSpotEnergy;
56  unsigned nInter;
57 
58  std::vector<double> uMin;
59  std::vector<double> uMax;
60  std::vector<unsigned> nspots;
61  std::vector<double> spotE;
62  std::vector<double> dspotsunscaled;
63  std::vector<double> spotfraction;
64 
65  private:
66  // Fraction of the energy in rm Moliere radius
67  double energyFractionInRadius(double rm);
68 
69  // Famos Random Engine
71 
72 };
73 #endif
int i
Definition: DBlmapReader.cc:9
std::vector< double > spotE
unsigned getNumberOfSpots(unsigned i) const
Number of spots in a given interval.
const RandomEngineAndDistribution * random
RadialInterval(double RC, unsigned nSpots, double energy, const RandomEngineAndDistribution *engine)
Standard constructor Rc: mean Radius.
string rm
Definition: submit.py:76
double currentEnergyFraction
double getUmin(unsigned i) const
Lower limit of the argument in the radius generator.
std::vector< double > uMin
std::vector< double > spotfraction
std::vector< double > uMax
std::vector< unsigned > nspots
unsigned nIntervals() const
Number of intervals.
unsigned theNumberOfSpots
double energyFractionInRadius(double rm)
std::vector< double > dspotsunscaled
double theSpotEnergy
double getSpotEnergy(unsigned i) const
Spot energy in a given interval.
double getUmax(unsigned i) const
Upper limit of the argument in the radius generator.
void addInterval(double, double)