CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
EnergyLossUpdator.cc
Go to the documentation of this file.
3 
4 //
5 // Computation of contribution of energy loss to momentum and covariance
6 // matrix of local parameters based on Bethe-Bloch. For electrons
7 // contribution of radiation acc. to Bethe & Heitler.
8 //
10  const PropagationDirection propDir) const
11 {
12  //
13  // Get surface
14  //
15  const Surface& surface = TSoS.surface();
16  //
17  // Initialise dP and the update to the covariance matrix
18  //
19  theDeltaP = 0.;
20  theDeltaCov(0,0) = 0.;
21  //
22  // Now get information on medium
23  //
24  if (surface.mediumProperties()) {
25  //
26  // Bethe-Bloch
27  //
28  if ( mass()>0.001 )
30  //
31  // Special treatment for electrons (currently rather crude
32  // distinction using mass)
33  //
34  else
36  propDir);
37  if (propDir != alongMomentum) theDeltaP *= -1.;
38  }
39 }
40 //
41 // Computation of energy loss according to Bethe-Bloch
42 //
43 void
45  const MediumProperties& materialConstants) const {
46  //
47  // calculate absolute momentum and correction to path length from angle
48  // of incidence
49  //
50  double p = localP.mag();
51  double xf = fabs(p/localP.z());
52  // constants
53  const double m = mass(); // use mass hypothesis from constructor
54 
55  const double emass = 0.511e-3;
56  const double poti = 16.e-9 * 10.75; // = 16 eV * Z**0.9, for Si Z=14
57  const double eplasma = 28.816e-9 * sqrt(2.33*0.498); // 28.816 eV * sqrt(rho*(Z/A)) for Si
58  const double delta0 = 2*log(eplasma/poti) - 1.;
59 
60  // calculate general physics things
61  double e = sqrt(p*p + m*m);
62  double beta = p/e;
63  double gamma = e/m;
64  double eta2 = beta*gamma; eta2 *= eta2;
65  // double lnEta2 = log(eta2);
66  double ratio = emass/m;
67  double emax = 2.*emass*eta2/(1. + 2.*ratio*gamma + ratio*ratio);
68  // double delta = delta0 + lnEta2;
69 
70  // calculate the mean and sigma of energy loss
71  // xi = d[g/cm2] * 0.307075MeV/(g/cm2) * Z/A * 1/2
72  double xi = materialConstants.xi()*xf; xi /= (beta*beta);
73 
74 // double dEdx = xi*(log(2.*emass*eta2*emax/(poti*poti)) - 2.*(beta*beta));
75  //double dEdx = xi*(log(2.*emass*emax/(poti*poti))+lnEta2 - 2.*(beta*beta) - delta);
76 
77  double dEdx = xi*(log(2.*emass*emax/(poti*poti)) - 2.*(beta*beta) - delta0);
78  double dEdx2 = xi*emax*(1.-0.5*(beta*beta));
79  double dP = dEdx/beta;
80  double sigp2 = dEdx2*e*e/(p*p*p*p*p*p);
81  theDeltaP += -dP;
82  theDeltaCov(0,0) += sigp2;
83 }
84 //
85 // Computation of energy loss for electrons
86 //
87 void
89  const MediumProperties& materialConstants,
90  const PropagationDirection propDir) const {
91  //
92  // calculate absolute momentum and correction to path length from angle
93  // of incidence
94  //
95  double p = localP.mag();
96  double normalisedPath = fabs(p/localP.z())*materialConstants.radLen();
97  //
98  // Energy loss and variance according to Bethe and Heitler, see also
99  // Comp. Phys. Comm. 79 (1994) 157.
100  //
101  double z = exp(-normalisedPath);
102  double varz = exp(-normalisedPath*log(3.)/log(2.))-
103  z*z;
104  // exp(-2*normalisedPath);
105 
106  if ( propDir==oppositeToMomentum ) {
107  //
108  // for backward propagation: delta(1/p) is linear in z=p_outside/p_inside
109  // convert to obtain equivalent delta(p). Sign of deltaP is corrected
110  // in method compute -> deltaP<0 at this place!!!
111  //
112  theDeltaP += -p*(1/z-1);
113  theDeltaCov(0,0) += varz/(p*p);
114  }
115  else {
116  //
117  // for forward propagation: calculate in p (linear in 1/z=p_inside/p_outside),
118  // then convert sig(p) to sig(1/p).
119  //
120  theDeltaP += p*(z-1);
121  // double f = 1/p/z/z;
122  // patch to ensure consistency between for- and backward propagation
123  double f = 1./(p*z);
124  theDeltaCov(0,0) += f*f*varz;
125  }
126 }
const double beta
float radLen() const
void computeElectrons(const LocalVector &, const MediumProperties &, const PropagationDirection) const
PropagationDirection
double double double z
const MediumProperties * mediumProperties() const
Definition: Surface.h:93
LocalVector localMomentum() const
T mag() const
Definition: PV3DBase.h:66
T sqrt(T t)
Definition: SSEVec.h:46
T z() const
Definition: PV3DBase.h:63
double f[11][100]
float xi() const
const Surface & surface() const
virtual void compute(const TrajectoryStateOnSurface &, const PropagationDirection) const
void computeBetheBloch(const LocalVector &, const MediumProperties &) const
AlgebraicSymMatrix55 theDeltaCov