CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions
AnalyticalErrorPropagation Class Reference

#include <AnalyticalErrorPropagation.h>

Public Member Functions

std::pair
< TrajectoryStateOnSurface,
double > 
operator() (const FreeTrajectoryState &startingState, const Surface &surface, SurfaceSideDefinition::SurfaceSide side, const GlobalTrajectoryParameters &destParameters, const double &s) const
 

Detailed Description

Definition at line 14 of file AnalyticalErrorPropagation.h.

Member Function Documentation

std::pair< TrajectoryStateOnSurface, double > AnalyticalErrorPropagation::operator() ( const FreeTrajectoryState startingState,
const Surface surface,
SurfaceSideDefinition::SurfaceSide  side,
const GlobalTrajectoryParameters destParameters,
const double &  s 
) const

Definition at line 10 of file AnalyticalErrorPropagation.cc.

References FreeTrajectoryState::curvilinearError(), h, FreeTrajectoryState::hasError(), GlobalTrajectoryParameters::magneticFieldInInverseGeV(), CurvilinearTrajectoryError::matrix(), GlobalTrajectoryParameters::momentum(), FreeTrajectoryState::parameters(), GlobalTrajectoryParameters::position(), FreeTrajectoryState::position(), and asciidump::s.

14 {
15  if (startingState.hasError()) {
16 
17  //
18  // compute jacobian
19  //
20 
21  // FIXME: Compute mean B field between startingState and destParameters and pass it to analyticalJacobian
22  GlobalPoint xStart = startingState.position();
23  GlobalPoint xDest = destParameters.position();
24  GlobalVector h1 = destParameters.magneticFieldInInverseGeV(xStart);
25  GlobalVector h2 = destParameters.magneticFieldInInverseGeV(xDest);
26  GlobalVector h = 0.5*(h1+h2);
27  //LogDebug("RungeKutta") << "AnalyticalErrorPropagation: The Fields are: " << h1 << ", " << h2 << ", " << h ;
28 
29  //
30  AnalyticalCurvilinearJacobian analyticalJacobian(startingState.parameters(),
31  destParameters.position(),
32  destParameters.momentum(), s);
33  AlgebraicMatrix55 jacobian(analyticalJacobian.jacobian());
34  CurvilinearTrajectoryError cte( ROOT::Math::Similarity(jacobian, startingState.curvilinearError().matrix()));
35  return std::pair<TrajectoryStateOnSurface,double>(TrajectoryStateOnSurface(destParameters,cte,surface,side),s);
36  }
37  else {
38  //
39  // return state without errors
40  //
41  return std::pair<TrajectoryStateOnSurface,double>(TrajectoryStateOnSurface(destParameters,surface,side),s);
42  }
43 }
const GlobalTrajectoryParameters & parameters() const
GlobalVector magneticFieldInInverseGeV(const GlobalPoint &x) const
const CurvilinearTrajectoryError & curvilinearError() const
GlobalPoint position() const
const AlgebraicSymMatrix55 & matrix() const
string s
Definition: asciidump.py:422
The Signals That Services Can Subscribe To This is based on ActivityRegistry h
Helper function to determine trigger accepts.
Definition: Activities.doc:4
ROOT::Math::SMatrix< double, 5, 5, ROOT::Math::MatRepStd< double, 5, 5 > > AlgebraicMatrix55