Trajectory parameters. More...
#include <PaTPar.h>
Public Member Functions | |
| float & | operator() (const int i, const int j=0) |
| Access to individual trajectory parameters and it's covariance matrix by "()" operator. | |
| double | Dip (bool in_deg=false) const |
| Dip angle. | |
| double | Azi (bool in_deg=false) const |
| Azi angle. | |
| double | Phi (bool in_deg=false) const |
angle. | |
| double | Theta (bool in_deg=false) const |
angle. | |
| double | DirCos (char axis) const |
| return direction cosine (axis = 'x','y','z' for COSx, COSy, COSz) | |
| void | DirVector (TVector3 &vec) const |
| return track direction unit vector "vec" | |
| double | Mom () const |
| return |P| | |
| int | Q () const |
| return charge | |
| double | qP () const |
| return |P|*charge | |
| double | Pt () const |
| return Pt | |
| double | Pos (int i) const |
| returns X if i == 0, Y if i == 1 and Z if i == 2 | |
| TVector3 | Pos () const |
| returns X,Y,Z as TVector3 | |
| double | X () const |
| X of the trajectory. | |
| double | Y () const |
| Y of the trajectory. | |
| double | Z () const |
| Z (fixed) where trajectory parameters are defined. | |
| double | dXdZ () const |
| dX/dZ (horizontal slope) of the trajectory | |
| double | dYdZ () const |
| dY/dZ (vertical slope) of the trajectory | |
| TVector3 | Mom3 () const |
| returns 3-vector of momentum components | |
| TLorentzVector | LzVec (double mass) const |
| returns Lorentz vector for specified mass | |
| TVector | ParVect () const |
| returns parameters as TVector | |
| TMatrix | CovMatrix () const |
| returns covariance matrix as TMatrix | |
| bool | IsEmpty () const |
| "true" it's empty (not defined) trajectory params | |
| bool | HasEmptyCov () const |
| true" if covariance matrix is not defined | |
| bool | HasMom () const |
| "true" if momentum had been defined | |
| void | Print (int level=0, string comment="") const |
| Print. | |
| void | Rotate (double ca, double sa, PaTPar &Pout) const |
| Rotate to "wire reference system". | |
| double | Dist (PaTPar &P) const |
| Straight line distance from "this" PaTPar (X,Y,Z) to PaTPar P. | |
| void | AddNoise (float x, float RadLen, bool reverse_ms=false) |
| Add multiple scattering "noise" to covariance matrix after propagation through a material. | |
| bool | Extrapolate (double Z, PaTPar &Hout, bool useMatMap=true, bool reverse_ms=false) const |
| Propagate charged particle trajectory parameters. | |
| bool | ExtrapNeutral (double Z, PaTPar &Hout) const |
| Propagate neutral particle trajectory parameters. | |
| double | Path () const |
| Returns trajectory length of previouse extrapolation. | |
| double | RadLenFr () const |
| Returns fractions of radiation length passed in previouse extrapolation. | |
| bool | FindCDA (PaTPar &H, float Z0=0, float Zmin=-1000, float Zmax=+1000, bool neutral1=false, bool neutral2=false) |
| Find closest distance of approach for "this" PaTPar and PaTPar "H". | |
| bool | Update (PaTPar &H1, PaTPar &Hout, double &Chi2) |
| do Kalman update of "this" state vector by "H1" | |
| bool | Update (const PaHit &h, PaTPar &Hout) |
| do Kalman update of "this" state vector by measurment (hit) "h" | |
| double | HitChi2 (PaHit &h) |
calculate increment for "this" state vector by measurment "h" (object of PaHit class) | |
| void | Set (double &x, PaMtx &V, PaMtx &M) |
| Pack vector and matrix into helix. | |
| void | Get (double &x, PaMtx &V, PaMtx &M) const |
| Upack helix to vector and matrix. | |
Trajectory parameters.
Class for charged particle trajectory parameters (X, Y, dX/dZ, dY/dZ, q/|P| at fixed Z position with corresponding covariance matrix.
Read and write access to parameters is provided by means of overloaded "operator ()".
E.g. if p is an object of this class, p(i) are references to parameters, p(i,j) - are references to covariance matrix elements.
i,j=1,2,3,4,5 and corresponds to X,Y,X',Y',q/|P| .
For example: p(0) is "fixed parameter" (i.e. Z position where trajectory parameters are defined), p(1) is X, p(3) is dX/dY, p(5) is q/P etc.
This class also could be used to store neutral particles parameters, assuming that 5-th parameter is just 1/P
(Warning: Do not use Extrapolate() in this case. Use ExtrapNeutral() instead.)
| void PaTPar::AddNoise | ( | float | x, | |
| float | RadLen, | |||
| bool | reverse_ms = false | |||
| ) |
Add multiple scattering "noise" to covariance matrix after propagation through a material.
| x | - thickness of material traversed | |
| RadLen | - radiation length of material traversed | |
| reverse_ms | - if set to true", "noise" will be _subtracted_ (for very special purposes) |
Referenced by Extrapolate(), and PaTrack::FullKF().
| double PaTPar::Azi | ( | bool | in_deg = false |
) | const |
Azi angle.
Angle between projection of
on plane X0Z and Z (rad/deg depending on parameter)
| TMatrix PaTPar::CovMatrix | ( | ) | const |
returns covariance matrix as TMatrix
| double PaTPar::Dip | ( | bool | in_deg = false |
) | const |
Dip angle.
Angle between
and it's projection on plane X0Z (rad/deg depending on parameter)
| bool PaTPar::ExtrapNeutral | ( | double | Z, | |
| PaTPar & | Hout | |||
| ) | const |
Propagate neutral particle trajectory parameters.
Perform straight line extrapolation of neutral particle parameters to specified "Z"
Result is stored in "Hout".
References Dist().
| bool PaTPar::Extrapolate | ( | double | Z, | |
| PaTPar & | Hout, | |||
| bool | useMatMap = true, |
|||
| bool | reverse_ms = false | |||
| ) | const |
Propagate charged particle trajectory parameters.
| Z | - z-coordinate of desired destination point of the propagation | |
| Hout | - resulting trajectory parameters at Z (if Z had been reached) | |
| useMatMap | - set to "false"to ignore multiple scattering and energy losses effects | |
| reverse_ms | - special purpose mode. Please always leave default (false). |
Function returns "false" is Z had not been reached.
References AddNoise(), Dist(), PaMaterialMaps::getdE(), PaMaterialMaps::getdEStraggling(), PaMaterialMaps::getRadLength(), HasMom(), PaSetup::MaterialMaps(), Mom(), Path(), and PaSetup::Ref().
Referenced by PaTrack::CanBeMuon(), PaAlgo::CrossCells(), PaTrack::CrossYokeSM2(), PaTrack::Extrapolate(), PaTrack::FullKF(), PaTrack::GetSmoothed(), and PaTrack::PointsHodoscopes().
| bool PaTPar::FindCDA | ( | PaTPar & | H, | |
| float | Z0 = 0, |
|||
| float | Zmin = -1000, |
|||
| float | Zmax = +1000, |
|||
| bool | neutral1 = false, |
|||
| bool | neutral2 = false | |||
| ) |
Find closest distance of approach for "this" PaTPar and PaTPar "H".
Function find such Z (within specified range) that distance between 2 trajectories propagated to this Z is minimal.
At the exit, "this" PaTPar and PaTPar "H" has it's values at the Z where they have minimal distance.
| H | - 2-d input PaTPar (first one is "this") | |
| Z0 | - starting value for minimization | |
| Zmin | - lower limit | |
| Zmax | - upper limit | |
| neutral1 | - to be set to "true" if PaTPar "this" is of neutral particle | |
| neutral2 | - to be set to "true" if PaTPar "H" is of neutral particle |
| double PaTPar::HitChi2 | ( | PaHit & | h | ) |
calculate
increment for "this" state vector by measurment "h" (object of PaHit class)
Referenced by PaTrack::FullKF(), and PaTrack::QuickKF().
| float & PaTPar::operator() | ( | const int | i, | |
| const int | j = 0 | |||
| ) |
Access to individual trajectory parameters and it's covariance matrix by "()" operator.
If "p" is an object of class PaTPar, then
, where i,j = 1,2,3,4,5 | double PaTPar::Phi | ( | bool | in_deg = false |
) | const |
angle.
Angle between projection of
on plane X0Y and X (rad/deg depending on parameter)
References DirCos().
| void PaTPar::Print | ( | int | level = 0, |
|
| string | str = "" | |||
| ) | const |
Print.
Print trajectory parameters
| level | if > 0 full cov. matrix is printed | |
| str | comment to be printed |
References Mom3().
Referenced by PaTrack::FullKF(), PaTrack::GetSmoothed(), PaMCtrack::Print(), PaTrack::QuickKF(), and Update().
| void PaTPar::Rotate | ( | double | ca, | |
| double | sa, | |||
| PaTPar & | Pout | |||
| ) | const |
Rotate to "wire reference system".
Rotate trajectory parameters (together with cov. matrix) to reference system rotation of which is defined by matrix:
cos(a) sin(a) 0 0 0
-sin(a) cos(a) 0 0 0
0 0 cos(a) sin(a) 0
0 0 -sin(a) cos(a) 0
0 0 0 0 1
| ca | - cos(a) | |
| sa | - sin(a) | |
| Pout | - resulting trajectory parameters. |
Referenced by Update().
| double PaTPar::Theta | ( | bool | in_deg = false |
) | const |
angle.
Angle between
and Z (rad/deg depending on parameter)
do Kalman update of "this" state vector by measurment (hit) "h"
Result is stored to "Hout".
References PaDetect::Ca(), PaHit::DetRef(), Print(), Rotate(), PaDetect::Sa(), PaHit::U(), and PaHit::V().
do Kalman update of "this" state vector by "H1"
Result is stored to "Hout". At the same time
increment is returned in "Chi2"
References Get(), PaMtx::i(), PaMtx::Print(), and Set().
Referenced by PaTrack::FullKF(), PaTrack::GetSmoothed(), and PaTrack::QuickKF().
1.6.2