ATLAS Offline Software
Public Member Functions | Static Public Attributes | Protected Member Functions | Protected Attributes | Private Member Functions | List of all members
Trk::PatternTrackParameters Class Referencefinalabstract

#include <PatternTrackParameters.h>

Inheritance diagram for Trk::PatternTrackParameters:
Collaboration diagram for Trk::PatternTrackParameters:

Public Member Functions

 PatternTrackParameters ()
 
 PatternTrackParameters (const PatternTrackParameters &)
 
PatternTrackParametersoperator= (const PatternTrackParameters &)
 
 PatternTrackParameters (PatternTrackParameters &&) noexcept=default
 
PatternTrackParametersoperator= (PatternTrackParameters &&) noexcept=default
 
virtual ~PatternTrackParameters ()=default
 
bool iscovariance () const
 
double sinPhi () const
 
double cosPhi () const
 
double sinTheta () const
 
double cosTheta () const
 
double cotTheta () const
 
void changeDirection ()
 
double transverseMomentum () const
 
virtual const SurfaceassociatedSurface () const override final
 Access to the Surface associated to the Parameters. More...
 
Amg::Vector3D position () const
 
Amg::Vector3D momentum () const
 
double charge () const
 
virtual bool hasSurface () const override final
 Test to see if there's a not null surface ptr. More...
 
virtual Amg::RotationMatrix3D measurementFrame () const override final
 Return the measurement frame - this is needed for alignment, in particular for StraightLine and Perigee Surface. More...
 
virtual PatternTrackParametersclone () const override final
 clone method for polymorphic deep copy More...
 
constexpr virtual ParametersType type () const override final
 Return the ParametersType enum. More...
 
virtual SurfaceType surfaceType () const override final
 Returns the Surface Type enum for the surface used to define the derived class. More...
 
virtual void updateParametersHelper (const AmgVector(5) &) override final
 
void setParameters (const Surface *, const double *)
 
void setCovariance (const double *)
 
void setParametersWithCovariance (const Surface *, const double *, const double *)
 
void setParametersWithCovariance (const Surface *, const double *, const AmgSymMatrix(5)&)
 
std::unique_ptr< TrackParametersconvert (bool) const
 
bool production (const TrackParameters *)
 
void diagonalization (double)
 
bool initiate (PatternTrackParameters &, const Amg::Vector2D &, const Amg::MatrixX &)
 
void addNoise (const NoiseOnSurface &, PropDirection)
 
void removeNoise (const NoiseOnSurface &, PropDirection)
 
std::ostream & dump (std::ostream &) const
 
MsgStream & dump (MsgStream &) const
 
const AmgVector (DIM) &parameters() const
 Access methods for the parameters. More...
 
 AmgVector (DIM) &parameters()
 
const AmgSymMatrix (DIM) *covariance() const
 Access method for the covariance matrix - returns nullptr if no covariance matrix is given. More...
 
 AmgSymMatrix (DIM) *covariance()
 
constexpr bool isCharged () const
 Returns true if Charged or false if Neutral. More...
 
Amg::Vector2D localPosition () const
 Access method for the local coordinates, \((loc1,loc2)\) local parameter definitions differ for each surface type. More...
 
void setParameters (const AmgVector(DIM) &param)
 set parameters More...
 
void setCovariance (const AmgSymMatrix(DIM) &cov)
 set covariance More...
 
void updateParameters (const AmgVector(DIM) &, const AmgSymMatrix(DIM) &)
 Update parameters and covariance , passing covariance by ref. More...
 
void updateParameters (const AmgVector(DIM) &)
 Update parameters. More...
 

Static Public Attributes

static constexpr int dim = DIM
 

Protected Member Functions

Amg::Vector3D localToGlobal (const PlaneSurface *) const
 
Amg::Vector3D localToGlobal (const StraightLineSurface *) const
 
Amg::Vector3D localToGlobal (const DiscSurface *) const
 
Amg::Vector3D localToGlobal (const CylinderSurface *) const
 
Amg::Vector3D localToGlobal (const PerigeeSurface *) const
 
Amg::Vector3D localToGlobal (const ConeSurface *) const
 
Amg::Vector3D calculatePosition (void) const
 
Amg::Vector3D calculateMomentum (void) const
 
double absoluteMomentum () const
 
 AmgVector (DIM) m_parameters
 contains the n x n covariance matrix More...
 
virtual void updateParametersHelper (const AmgVector(DIM) &)=0
 contains the n parameters More...
 

Protected Attributes

SurfaceUniquePtrT< const Surfacem_surface
 
std::optional< AmgSymMatrix(DIM)> m_covariance = std::nullopt
 charge definition for this track More...
 
m_chargeDef {}
 charge definition for this track More...
 

Private Member Functions

std::string to_string () const
 

Detailed Description

Definition at line 32 of file PatternTrackParameters.h.

Constructor & Destructor Documentation

◆ PatternTrackParameters() [1/3]

Trk::PatternTrackParameters::PatternTrackParameters ( )

◆ PatternTrackParameters() [2/3]

Trk::PatternTrackParameters::PatternTrackParameters ( const PatternTrackParameters )

◆ PatternTrackParameters() [3/3]

Trk::PatternTrackParameters::PatternTrackParameters ( PatternTrackParameters &&  )
defaultnoexcept

◆ ~PatternTrackParameters()

virtual Trk::PatternTrackParameters::~PatternTrackParameters ( )
virtualdefault

Member Function Documentation

◆ absoluteMomentum()

double Trk::PatternTrackParameters::absoluteMomentum ( ) const
protected

◆ addNoise()

void Trk::PatternTrackParameters::addNoise ( const NoiseOnSurface ,
PropDirection   
)

◆ AmgSymMatrix() [1/2]

template<int DIM, class T >
Trk::ParametersCommon< DIM, T >::AmgSymMatrix ( DIM  )
inherited

◆ AmgSymMatrix() [2/2]

template<int DIM, class T >
const Trk::ParametersCommon< DIM, T >::AmgSymMatrix ( DIM  ) const
inherited

Access method for the covariance matrix - returns nullptr if no covariance matrix is given.

◆ AmgVector() [1/3]

template<int DIM, class T >
Trk::ParametersCommon< DIM, T >::AmgVector ( DIM  ) &
inherited

◆ AmgVector() [2/3]

template<int DIM, class T >
const Trk::ParametersCommon< DIM, T >::AmgVector ( DIM  ) const &
inherited

Access methods for the parameters.

◆ AmgVector() [3/3]

template<int DIM, class T >
Trk::ParametersCommon< DIM, T >::AmgVector ( DIM  )
protectedinherited

contains the n x n covariance matrix

◆ associatedSurface()

virtual const Surface& Trk::PatternTrackParameters::associatedSurface ( ) const
finaloverridevirtual

Access to the Surface associated to the Parameters.

Implements Trk::ParametersCommon< DIM, T >.

◆ calculateMomentum()

Amg::Vector3D Trk::PatternTrackParameters::calculateMomentum ( void  ) const
protected

Definition at line 441 of file PatternTrackParameters.cxx.

441  {
442  double p = absoluteMomentum();
443  double Sf = std::sin(m_parameters[2]), Cf = std::cos(m_parameters[2]);
444  double Se = std::sin(m_parameters[3]), Ce = std::cos(m_parameters[3]);
445  return {p * Se * Cf, p * Se * Sf, p * Ce};
446 }

◆ calculatePosition()

Amg::Vector3D Trk::PatternTrackParameters::calculatePosition ( void  ) const
protected

Definition at line 413 of file PatternTrackParameters.cxx.

413  {
414  if (!m_surface) {
415  return {0, 0, 0};
416  }
417  switch ( m_surface->type()){
419  return localToGlobal(static_cast<const Trk::PlaneSurface*>(m_surface.get()));
420  break;
422  return localToGlobal(static_cast<const Trk::StraightLineSurface*>(m_surface.get()));
423  break;
425  return localToGlobal(static_cast<const Trk::DiscSurface*>(m_surface.get()));
426  break;
428  return localToGlobal(static_cast<const Trk::CylinderSurface*>(m_surface.get()));
429  break;
431  return localToGlobal(static_cast<const Trk::PerigeeSurface*>(m_surface.get()));
432  break;
434  return localToGlobal(static_cast<const Trk::ConeSurface*>(m_surface.get()));
435  break;
436  default:
437  return {0, 0, 0};
438  }
439 }

◆ changeDirection()

void Trk::PatternTrackParameters::changeDirection ( )

Definition at line 368 of file PatternTrackParameters.cxx.

369 {
370  constexpr double pi = M_PI;
371  constexpr double pi2 = 2.*M_PI; //NB CLHEP also defines pi and pi2 constants.
372 
373  m_parameters[ 2] = m_parameters[2]-pi;
374  m_parameters[ 3] = pi-m_parameters[3];
375  m_parameters[ 4] = -m_parameters[4] ;
376 
377  if (m_parameters[2] < -pi) {
378  m_parameters[2] += pi2;
379  }
380 
381  if ((m_surface->type() != Trk::SurfaceType::Line) &&
382  (m_surface->type() != Trk::SurfaceType::Perigee)) {
383 
384  if (m_covariance == std::nullopt) {
385  return;
386  }
387 
388  m_covariance->fillSymmetric(0, 3, -(*m_covariance)(0, 3));
389  m_covariance->fillSymmetric(1, 3, -(*m_covariance)(1, 3));
390  m_covariance->fillSymmetric(2, 3, -(*m_covariance)(2, 3));
391  m_covariance->fillSymmetric(0, 4, -(*m_covariance)(0, 4));
392  m_covariance->fillSymmetric(1, 4, -(*m_covariance)(1, 4));
393  m_covariance->fillSymmetric(2, 4, -(*m_covariance)(2, 4));
394 
395  return;
396  }
397 
398  m_parameters[ 0] = -m_parameters[ 0];
399 
400 
401  if(m_covariance == std::nullopt) {
402  return;
403  }
404 
405  m_covariance->fillSymmetric(0, 1, -(*m_covariance)(0, 1));
406  m_covariance->fillSymmetric(0, 2, -(*m_covariance)(0, 2));
407  m_covariance->fillSymmetric(1, 3, -(*m_covariance)(1, 3));
408  m_covariance->fillSymmetric(2, 3, -(*m_covariance)(2, 3));
409  m_covariance->fillSymmetric(1, 4, -(*m_covariance)(1, 4));
410  m_covariance->fillSymmetric(2, 4, -(*m_covariance)(2, 4));
411 }

◆ charge()

double Trk::PatternTrackParameters::charge ( ) const

◆ clone()

virtual PatternTrackParameters* Trk::PatternTrackParameters::clone ( ) const
finaloverridevirtual

clone method for polymorphic deep copy

Returns
new object copied from the concrete type of this object.

Implements Trk::ParametersCommon< DIM, T >.

◆ convert()

std::unique_ptr< Trk::TrackParameters > Trk::PatternTrackParameters::convert ( bool  covariance) const

Definition at line 26 of file PatternTrackParameters.cxx.

27 {
28  std::optional<AmgSymMatrix(5)> e = std::nullopt;
29  if (covariance && m_covariance != std::nullopt) {
30  e = AmgSymMatrix(5)(*m_covariance);
31  }
32  const AmgVector(5)& p = m_parameters;
33  return m_surface ? m_surface->createUniqueTrackParameters(
34  p[0], p[1], p[2], p[3], p[4], std::move(e))
35  : nullptr;
36 }

◆ cosPhi()

double Trk::PatternTrackParameters::cosPhi ( ) const

◆ cosTheta()

double Trk::PatternTrackParameters::cosTheta ( ) const

◆ cotTheta()

double Trk::PatternTrackParameters::cotTheta ( ) const

◆ diagonalization()

void Trk::PatternTrackParameters::diagonalization ( double  )

◆ dump() [1/2]

MsgStream & Trk::PatternTrackParameters::dump ( MsgStream &  out) const

Definition at line 153 of file PatternTrackParameters.cxx.

154 {
155  out<<to_string();
156  return out;
157 }

◆ dump() [2/2]

std::ostream & Trk::PatternTrackParameters::dump ( std::ostream &  out) const

Definition at line 143 of file PatternTrackParameters.cxx.

144 {
145  out<<to_string();
146  return out;
147 }

◆ hasSurface()

virtual bool Trk::PatternTrackParameters::hasSurface ( ) const
finaloverridevirtual

Test to see if there's a not null surface ptr.

Implements Trk::ParametersCommon< DIM, T >.

◆ initiate()

bool Trk::PatternTrackParameters::initiate ( PatternTrackParameters Tp,
const Amg::Vector2D P,
const Amg::MatrixX E 
)

Definition at line 320 of file PatternTrackParameters.cxx.

322 {
323 
324  int n = E.rows(); if(n<=0 || n>2) { return false;
325 }
326 
327  if (Tp.m_covariance != std::nullopt) {
328  if (m_covariance == std::nullopt) {
329  m_covariance = AmgSymMatrix(5)(*Tp.m_covariance);
330  } else {
331  *m_covariance = *Tp.m_covariance;
332  }
333  } else {
334  if (m_covariance == std::nullopt) {
335  m_covariance.emplace();
336  }
337  }
338 
339  m_parameters[0] = P (0);
340 
341  m_covariance->fillSymmetric(0, 0, E(0,0));
342 
343  if(n==2) {
344  m_parameters[ 1] = P(1);
345  m_covariance->fillSymmetric(0, 1, E(1,0));
346  m_covariance->fillSymmetric(1, 1, E(1,1));
347  }
348  else {
349  m_parameters[ 1] = Tp.m_parameters[ 1];
350  }
351  m_parameters[ 2] = Tp.m_parameters[ 2];
352  m_parameters[ 3] = Tp.m_parameters[ 3];
353  m_parameters[ 4] = Tp.m_parameters[ 4];
354 
355  if (Tp.m_surface != nullptr) {
356  m_surface.reset(Tp.m_surface->isFree() ? Tp.m_surface->clone() : Tp.m_surface.get());
357  } else {
358  m_surface.reset(nullptr);
359  }
360 
361  return true;
362 }

◆ isCharged()

template<int DIM, class T >
constexpr bool Trk::ParametersCommon< DIM, T >::isCharged ( ) const
constexprinherited

Returns true if Charged or false if Neutral.

◆ iscovariance()

bool Trk::PatternTrackParameters::iscovariance ( ) const
inline

Definition at line 42 of file PatternTrackParameters.h.

42 {return m_covariance != std::nullopt ;}

◆ localPosition()

template<int DIM, class T >
Amg::Vector2D Trk::ParametersCommon< DIM, T >::localPosition ( ) const
inherited

Access method for the local coordinates, \((loc1,loc2)\) local parameter definitions differ for each surface type.

◆ localToGlobal() [1/6]

Amg::Vector3D Trk::PatternTrackParameters::localToGlobal ( const ConeSurface su) const
protected

Definition at line 294 of file PatternTrackParameters.cxx.

296 {
297  const Amg::Transform3D& T = su->transform();
298  double Ax[3] = {T(0,0),T(1,0),T(2,0)};
299  double Ay[3] = {T(0,1),T(1,1),T(2,1)};
300  double Az[3] = {T(0,2),T(1,2),T(2,2)};
301 
302  double r = m_parameters[1]*su->bounds().tanAlpha();
303  double Sf;
304  double Cf; sincos((m_parameters[0]/r),&Sf,&Cf);
305  double xl = r*Cf;
306  double yl = r*Sf;
307 
308 
309  Amg::Vector3D gp
310  (Ax[0]*xl+Ay[0]*yl+Az[0]*m_parameters[1]+T(0,3),
311  Ax[1]*xl+Ay[1]*yl+Az[1]*m_parameters[1]+T(1,3),
312  Ax[2]*xl+Ay[2]*yl+Az[2]*m_parameters[1]+T(2,3));
313  return gp;
314 }

◆ localToGlobal() [2/6]

Amg::Vector3D Trk::PatternTrackParameters::localToGlobal ( const CylinderSurface su) const
protected

Definition at line 239 of file PatternTrackParameters.cxx.

241 {
242  const Amg::Transform3D& T = su->transform();
243  double Ax[3] = {T(0,0),T(1,0),T(2,0)};
244  double Ay[3] = {T(0,1),T(1,1),T(2,1)};
245  double Az[3] = {T(0,2),T(1,2),T(2,2)};
246 
247  double R = su->bounds().r();
248  double fr = m_parameters[0]/R;
249 
250  double Sf;
251  double Cf; sincos(fr,&Sf,&Cf);
252 
253  Amg::Vector3D gp
254  (R*(Cf*Ax[0]+Sf*Ay[0])+m_parameters[1]*Az[0]+T(0,3),
255  R*(Cf*Ax[1]+Sf*Ay[1])+m_parameters[1]*Az[1]+T(1,3),
256  R*(Cf*Ax[2]+Sf*Ay[2])+m_parameters[1]*Az[2]+T(2,3));
257  return gp;
258 }

◆ localToGlobal() [3/6]

Amg::Vector3D Trk::PatternTrackParameters::localToGlobal ( const DiscSurface su) const
protected

Definition at line 214 of file PatternTrackParameters.cxx.

216 {
217  const Amg::Transform3D& T = su->transform();
218  double Ax[3] = {T(0,0),T(1,0),T(2,0)};
219  double Ay[3] = {T(0,1),T(1,1),T(2,1)};
220 
221  double Sf;
222  double Cf; sincos(m_parameters[1],&Sf,&Cf);
223 
224  double d0 = Cf*Ax[0]+Sf*Ay[0];
225  double d1 = Cf*Ax[1]+Sf*Ay[1];
226  double d2 = Cf*Ax[2]+Sf*Ay[2];
227 
228  Amg::Vector3D gp
229  (m_parameters[0]*d0+T(0,3),
230  m_parameters[0]*d1+T(1,3),
231  m_parameters[0]*d2+T(2,3));
232  return gp;
233 }

◆ localToGlobal() [4/6]

Amg::Vector3D Trk::PatternTrackParameters::localToGlobal ( const PerigeeSurface su) const
protected

Definition at line 264 of file PatternTrackParameters.cxx.

266 {
267  const Amg::Transform3D& T = su->transform();
268  double A[3] = {T(0,2),T(1,2),T(2,2)};
269 
270  double Sf;
271  double Cf; sincos(m_parameters[2],&Sf,&Cf);
272  double Se;
273  double Ce; sincos(m_parameters[3],&Se,&Ce);
274 
275  double P3 = Cf*Se;
276  double P4 = Sf*Se;
277  double P5 = Ce;
278  double Bx = A[1]*P5-A[2]*P4;
279  double By = A[2]*P3-A[0]*P5;
280  double Bz = A[0]*P4-A[1]*P3;
281  double Bn = 1./std::sqrt(Bx*Bx+By*By+Bz*Bz); Bx*=Bn; By*=Bn; Bz*=Bn;
282 
283  Amg::Vector3D gp
284  (m_parameters[1]*A[0]+Bx*m_parameters[0]+T(0,3),
285  m_parameters[1]*A[1]+By*m_parameters[0]+T(1,3),
286  m_parameters[1]*A[2]+Bz*m_parameters[0]+T(2,3));
287  return gp;
288 }

◆ localToGlobal() [5/6]

Amg::Vector3D Trk::PatternTrackParameters::localToGlobal ( const PlaneSurface su) const
protected

Definition at line 167 of file PatternTrackParameters.cxx.

169 {
170  const Amg::Transform3D& T = su->transform();
171  double Ax[3] = {T(0,0),T(1,0),T(2,0)};
172  double Ay[3] = {T(0,1),T(1,1),T(2,1)};
173 
174  Amg::Vector3D gp (m_parameters[0]*Ax[0]+m_parameters[1]*Ay[0]+T(0,3),
175  m_parameters[0]*Ax[1]+m_parameters[1]*Ay[1]+T(1,3),
176  m_parameters[0]*Ax[2]+m_parameters[1]*Ay[2]+T(2,3));
177  return gp;
178 }

◆ localToGlobal() [6/6]

Amg::Vector3D Trk::PatternTrackParameters::localToGlobal ( const StraightLineSurface su) const
protected

Definition at line 184 of file PatternTrackParameters.cxx.

186 {
187  const Amg::Transform3D& T = su->transform();
188  double A[3] = {T(0,2),T(1,2),T(2,2)};
189 
190  double Sf;
191  double Cf; sincos(m_parameters[2],&Sf,&Cf);
192  double Se;
193  double Ce; sincos(m_parameters[3],&Se,&Ce);
194 
195  double P3 = Cf*Se;
196  double P4 = Sf*Se;
197  double P5 = Ce;
198  double Bx = A[1]*P5-A[2]*P4;
199  double By = A[2]*P3-A[0]*P5;
200  double Bz = A[0]*P4-A[1]*P3;
201  double Bn = 1./std::sqrt(Bx*Bx+By*By+Bz*Bz); Bx*=Bn; By*=Bn; Bz*=Bn;
202 
203  Amg::Vector3D gp
204  (m_parameters[1]*A[0]+Bx*m_parameters[0]+T(0,3),
205  m_parameters[1]*A[1]+By*m_parameters[0]+T(1,3),
206  m_parameters[1]*A[2]+Bz*m_parameters[0]+T(2,3));
207  return gp;
208 }

◆ measurementFrame()

virtual Amg::RotationMatrix3D Trk::PatternTrackParameters::measurementFrame ( ) const
finaloverridevirtual

Return the measurement frame - this is needed for alignment, in particular for StraightLine and Perigee Surface.

  • the default implementation is the RotationMatrix3D of the transform

Implements Trk::ParametersCommon< DIM, T >.

◆ momentum()

Amg::Vector3D Trk::PatternTrackParameters::momentum ( ) const

◆ operator=() [1/2]

PatternTrackParameters& Trk::PatternTrackParameters::operator= ( const PatternTrackParameters )

◆ operator=() [2/2]

PatternTrackParameters& Trk::PatternTrackParameters::operator= ( PatternTrackParameters &&  )
defaultnoexcept

◆ position()

Amg::Vector3D Trk::PatternTrackParameters::position ( ) const

Definition at line 79 of file PatternTrackParameters.cxx.

80 {
81  return calculatePosition();
82 }

◆ production()

bool Trk::PatternTrackParameters::production ( const TrackParameters )

Definition at line 42 of file PatternTrackParameters.cxx.

42  {
43 
44  if (!T) {
45  return false;
46  }
47  if (!T->hasSurface()) {
48  return false;
49  }
50 
51  m_surface.reset(T->associatedSurface().isFree() ? T->associatedSurface().clone() : &T->associatedSurface());
52 
53  m_parameters = T->parameters();
54 
55  const AmgSymMatrix(5)* C = T->covariance();
56 
57  if(C) {
58  if (m_covariance == std::nullopt) {
59  m_covariance.emplace();
60  }
61 
62  for (std::size_t i = 0; i < 5; i++) {
63  for (std::size_t j = 0; j <= i; j++) {
64  m_covariance->fillSymmetric(i, j, (*C)(i, j));
65  }
66  }
67  }
68  else {
69  m_covariance.reset();
70  }
71 
72  return true;
73 }

◆ removeNoise()

void Trk::PatternTrackParameters::removeNoise ( const NoiseOnSurface ,
PropDirection   
)

◆ setCovariance() [1/2]

template<int DIM, class T >
void Trk::ParametersCommon< DIM, T >::setCovariance ( const AmgSymMatrix(DIM) &  cov)
inherited

set covariance

◆ setCovariance() [2/2]

void Trk::PatternTrackParameters::setCovariance ( const double *  )

◆ setParameters() [1/2]

template<int DIM, class T >
void Trk::ParametersCommon< DIM, T >::setParameters ( const AmgVector(DIM) &  param)
inherited

set parameters

◆ setParameters() [2/2]

void Trk::PatternTrackParameters::setParameters ( const Surface ,
const double *   
)

◆ setParametersWithCovariance() [1/2]

void Trk::PatternTrackParameters::setParametersWithCovariance ( const Surface ,
const double *  ,
const AmgSymMatrix(5)&   
)

◆ setParametersWithCovariance() [2/2]

void Trk::PatternTrackParameters::setParametersWithCovariance ( const Surface ,
const double *  ,
const double *   
)

◆ sinPhi()

double Trk::PatternTrackParameters::sinPhi ( ) const

◆ sinTheta()

double Trk::PatternTrackParameters::sinTheta ( ) const

◆ surfaceType()

virtual SurfaceType Trk::PatternTrackParameters::surfaceType ( ) const
finaloverridevirtual

Returns the Surface Type enum for the surface used to define the derived class.

Implements Trk::ParametersCommon< DIM, T >.

◆ to_string()

std::string Trk::PatternTrackParameters::to_string ( ) const
private

Definition at line 105 of file PatternTrackParameters.cxx.

105  {
106  std::stringstream ss;
107  const Trk::Surface* s = m_surface.get();
108  const AmgVector(5)& P = m_parameters;
109  const std::string name{s?s->name():""};
110  const std::string N("\n");
111  ss << "Track parameters for " << name << " surface " << N;
112  ss.unsetf(std::ios::fixed);
113  ss.setf (std::ios::showpos);
114  ss.setf (std::ios::scientific);
115  if (m_covariance != std::nullopt) {
116  const AmgSymMatrix(5) & V = *m_covariance;
117  ss << std::setprecision(4) <<
118  P[ 0]<<" |"<<V(0, 0) << N;
119  ss << std::setprecision(4) <<
120  P[ 1]<<" |"<<V(0, 1)<<" "<<V(1, 1) << N;
121  ss << std::setprecision(4) <<
122  P[ 2]<<" |"<<V(0, 2)<<" "<<V(1, 2)<<" "<<V(2, 2) << N;
123  ss << std::setprecision(4) <<
124  P[ 3]<<" |"<<V(0, 3)<<" "<<V(1, 3)<<" "<<V(2, 3)<<" "<<V(3, 3) << N;
125  ss << std::setprecision(4) <<
126  P[ 4]<<" |"<<V(0, 4)<<" "<<V(1, 4)<<" "<<V(2, 4)<<" "<<V(3, 4)<<" "<<V(4, 4) << N;
127  }
128  else {
129  ss << std::setprecision(4) << P[ 0] << " |" << N;
130  ss << std::setprecision(4) << P[ 1] << " |" << N;
131  ss << std::setprecision(4) << P[ 2] << " |" << N;
132  ss << std::setprecision(4) << P[ 3] << " |" << N;
133  ss << std::setprecision(4) << P[ 4] << " |" << N;
134  }
135  return ss.str();
136 }

◆ transverseMomentum()

double Trk::PatternTrackParameters::transverseMomentum ( ) const

◆ type()

constexpr virtual ParametersType Trk::PatternTrackParameters::type ( ) const
constexprfinaloverridevirtual

Return the ParametersType enum.

Implements Trk::ParametersCommon< DIM, T >.

◆ updateParameters() [1/2]

template<int DIM, class T >
void Trk::ParametersCommon< DIM, T >::updateParameters ( const AmgVector(DIM) &  )
inherited

Update parameters.

Derived classes override the implementation via updateParametersHelper as this could possibly lead to updating other data members

◆ updateParameters() [2/2]

template<int DIM, class T >
void Trk::ParametersCommon< DIM, T >::updateParameters ( const AmgVector(DIM) &  ,
const AmgSymMatrix(DIM) &   
)
inherited

Update parameters and covariance , passing covariance by ref.

A covariance is created if one does not exist. Otherwise in place update occurs via assignment.

Derived classes override the implementation via updateParametersHelper as this could possibly lead to updating other data members

◆ updateParametersHelper() [1/2]

virtual void Trk::PatternTrackParameters::updateParametersHelper ( const AmgVector(5) &  )
finaloverridevirtual

◆ updateParametersHelper() [2/2]

template<int DIM, class T >
virtual void Trk::ParametersCommon< DIM, T >::updateParametersHelper ( const AmgVector(DIM) &  )
protectedpure virtualinherited

contains the n parameters

Implemented in Trk::ParametersBase< DIM, T >, and Trk::CurvilinearParametersT< DIM, T, S >.

Member Data Documentation

◆ dim

template<int DIM, class T >
constexpr int Trk::ParametersCommon< DIM, T >::dim = DIM
staticconstexprinherited

Definition at line 50 of file ParametersCommon.h.

◆ m_chargeDef

template<int DIM, class T >
T Trk::ParametersCommon< DIM, T >::m_chargeDef {}
protectedinherited

charge definition for this track

Definition at line 149 of file ParametersCommon.h.

◆ m_covariance

template<int DIM, class T >
std::optional<AmgSymMatrix(DIM)> Trk::ParametersCommon< DIM, T >::m_covariance = std::nullopt
protectedinherited

charge definition for this track

Definition at line 147 of file ParametersCommon.h.

◆ m_surface

SurfaceUniquePtrT<const Surface> Trk::PatternTrackParameters::m_surface
protected

Definition at line 88 of file PatternTrackParameters.h.


The documentation for this class was generated from the following files:
Trk::ParametersCommon::AmgVector
const AmgVector(DIM) &parameters() const
Access methods for the parameters.
Trk::PatternTrackParameters::localToGlobal
Amg::Vector3D localToGlobal(const PlaneSurface *) const
Definition: PatternTrackParameters.cxx:168
AllowedVariables::e
e
Definition: AsgElectronSelectorTool.cxx:37
beamspotman.r
def r
Definition: beamspotman.py:676
Trk::ParametersCommon::m_covariance
std::optional< AmgSymMatrix(DIM)> m_covariance
charge definition for this track
Definition: ParametersCommon.h:147
python.SystemOfUnits.s
int s
Definition: SystemOfUnits.py:131
PowhegControl_ttHplus_NLO.ss
ss
Definition: PowhegControl_ttHplus_NLO.py:83
Trk::PerigeeSurface
Definition: PerigeeSurface.h:43
DMTest::P
P_v1 P
Definition: P.h:23
DMTest::C
C_v1 C
Definition: C.h:26
python.AthDsoLogger.out
out
Definition: AthDsoLogger.py:71
python.PhysicalConstants.pi2
float pi2
Definition: PhysicalConstants.py:52
M_PI
#define M_PI
Definition: ActiveFraction.h:11
Trk::ParametersCommon::AmgSymMatrix
const AmgSymMatrix(DIM) *covariance() const
Access method for the covariance matrix - returns nullptr if no covariance matrix is given.
dq_defect_virtual_defect_validation.d1
d1
Definition: dq_defect_virtual_defect_validation.py:79
Trk::DiscSurface
Definition: DiscSurface.h:54
JetTiledMap::N
@ N
Definition: TiledEtaPhiMap.h:44
drawFromPickle.cos
cos
Definition: drawFromPickle.py:36
Trk::PatternTrackParameters::absoluteMomentum
double absoluteMomentum() const
Trk::PatternTrackParameters::m_surface
SurfaceUniquePtrT< const Surface > m_surface
Definition: PatternTrackParameters.h:88
pi
#define pi
Definition: TileMuonFitter.cxx:65
A
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
lumiFormat.i
int i
Definition: lumiFormat.py:85
beamspotman.n
n
Definition: beamspotman.py:731
Trk::CylinderSurface
Definition: CylinderSurface.h:55
Amg::Transform3D
Eigen::Affine3d Transform3D
Definition: GeoPrimitives.h:46
AnalysisUtils::Delta::R
double R(const INavigable4Momentum *p1, const double v_eta, const double v_phi)
Definition: AnalysisMisc.h:49
Trk::SurfaceType::Cone
@ Cone
Trk::PatternTrackParameters::calculatePosition
Amg::Vector3D calculatePosition(void) const
Definition: PatternTrackParameters.cxx:413
Trk::SurfaceType::Perigee
@ Perigee
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
Trk::d0
@ d0
Definition: ParamDefs.h:63
VP1PartSpect::E
@ E
Definition: VP1PartSpectFlags.h:21
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
Trk::PlaneSurface
Definition: PlaneSurface.h:64
dq_defect_virtual_defect_validation.d2
d2
Definition: dq_defect_virtual_defect_validation.py:81
Trk::SurfaceType::Disc
@ Disc
Trk::SurfaceType::Cylinder
@ Cylinder
Trk::ConeSurface
Definition: ConeSurface.h:51
Trk::SurfaceType::Plane
@ Plane
Trk::PatternTrackParameters::to_string
std::string to_string() const
Definition: PatternTrackParameters.cxx:105
drawFromPickle.sin
sin
Definition: drawFromPickle.py:36
Trk::SurfaceType::Line
@ Line
Trk::Surface
Definition: Tracking/TrkDetDescr/TrkSurfaces/TrkSurfaces/Surface.h:75
grepfile.fr
fr
Definition: grepfile.py:32
TSU::T
unsigned long long T
Definition: L1TopoDataTypes.h:35
Trk::StraightLineSurface
Definition: StraightLineSurface.h:51