23 _dr(0),_phi0(0),_dz(0),_tanl(0),
31 fitter(& T3DLine::_fitter);
40 _phi0(a.helix().phi0()),
42 _tanl(a.helix().tanl()),
44 _pivot(a.helix().pivot()){
46 _cos_phi0 =
cos(_phi0);
47 _sin_phi0 =
sin(_phi0);
50 fitter(& T3DLine::_fitter);
65 _chi2(a.chi2()),_ndf(a.ndf()),
69 _cos_phi0 =
cos(_phi0);
70 _sin_phi0 =
sin(_phi0);
73 fitter(& T3DLine::_fitter);
122 a[0]=_dr;
a[1]=_phi0;
a[2]=1e-10;
a[3]=_dz;
a[4]=_tanl;
137 std::cout<<
"error at T3DLine::reducedchi2 ndf=0"<<std::endl;
144 double tx= _pivot.x() + _dr * _cos_phi0 -
t * _sin_phi0;
145 double ty= _pivot.y() + _dr * _sin_phi0 +
t * _cos_phi0;
146 double tz= _pivot.z() + _dz +
t * _tanl;
152 double tx= _pivot.x() + _dr * _cos_phi0;
153 double ty= _pivot.y() + _dr * _sin_phi0;
154 double tz= _pivot.z() + _dz;
164 double dr=(_pivot.x()-newpivot.x())*_cos_phi0
165 +(_pivot.y()-newpivot.y())*_sin_phi0 + _dr;
166 double dz=_pivot.z()-newpivot.z()+_dz
167 +_tanl*((_pivot.x()-newpivot.x())*_sin_phi0
168 +(newpivot.y()-_pivot.y())*_cos_phi0);
176 double t_dr,
double t_phi0,
double t_dz,
double t_tanl){
183 _cos_phi0 =
cos(_phi0);
184 _sin_phi0 =
sin(_phi0);
192 _cos_phi0 =
cos(_phi0);
193 _sin_phi0 =
sin(_phi0);
206 HepPoint3D wireBackwardPosition =
w.backwardPosition();
216 if(!doSagCorrection){
223 double onWire_y = onWire.y();
224 double onWire_z = onWire.z();
228 w.wirePosition(onWire_z,xw,wireBackwardPosition,(
HepVector3D&)
v);
231 if(fabs(onWire_y - onWire.y())<0.0001)
break;
232 onWire_y = onWire.y();
233 onWire_z = onWire.z();
250 const double v_k =
v.dot(
k);
251 const double v_2 =
v.mag2();
252 const double k_2 =
k.mag2();
253 const double tk = v_k*v_k - v_2*k_2;
254 if(tk==0)
return(-1);
258 const double t = dx.dot( v_2 *
k - v_k *
v)/tk;
259 const double s = dx.dot( v_k *
k - k_2 *
v)/tk;
262 onTrack =
x0 +
t *
k;
273 const double t = dx.dot(
k)/
k.mag2();
275 onTrack =
x0 +
t *
k;
double sin(const BesAngle a)
double cos(const BesAngle a)
**********Class see also m_nmax DOUBLE PRECISION m_amel DOUBLE PRECISION m_x2 DOUBLE PRECISION m_alfinv DOUBLE PRECISION m_Xenph INTEGER m_KeyWtm INTEGER m_idyfs DOUBLE PRECISION m_zini DOUBLE PRECISION m_q2 DOUBLE PRECISION m_Wt_KF DOUBLE PRECISION m_WtCut INTEGER m_KFfin *COMMON c_KarLud $ !Input CMS energy[GeV] $ !CMS energy after beam spread beam strahlung[GeV] $ !Beam energy spread[GeV] $ !z boost due to beam spread $ !electron beam mass *ff pair spectrum $ !minimum v
CLHEP::HepSymMatrix SymMatrix
const HepPoint3D ORIGIN
Constants.
A class to fit a TTrackBase object to a 3D line.
A class to represent a track in tracking.
void set(const HepPoint3D &, double t_dr, double t_phi0, double t_dz, double t_tanl)
set track parameters,pivot
double sinPhi0(void) const
HepPoint3D x(double) const
returns position on 3D line
double cosPhi0(void) const
double dr(void) const
Track parameters.
double reducedchi2(void) const
returns reduced-chi2
int approach_point(const HepPoint3D &, HepPoint3D &onTrack) const
caluculate closest point between a point and this track
HepPoint3D x0(void) const
returns 3D line component x(t)=x0 + t * k
Helix helix(void) const
approximated helix class
int approach(TMLink &, bool sagCorrection=true) const
calculates the closest approach to a wire in real space. Results are stored in TMLink....
double chi2(void) const
returns chi2.
int approach_line(const HepPoint3D &, const HepVector3D &, HepPoint3D &onLine, HepPoint3D &onTrack) const
caluculate closest points between a line and this track
HepVector3D k(void) const
const HepPoint3D & pivot(void) const
pivot position
const SymMatrix & Ea(void) const
returns error matrix
unsigned ndf(void) const
returns NDF
virtual ~T3DLine()
Destructor.
A class to represent a wire in MDC.
A class to relate TMDCWireHit and TTrack objects.
const HepPoint3D & positionOnWire(void) const
returns the closest point on wire to a track.
const HepPoint3D & positionOnTrack(void) const
returns the closest point on track to wire.
const TMDCWire *const wire(void) const
returns a pointer to a wire.
A virtual class for a track class in tracking.
const TMFitter *const fitter(void) const
returns a pointer to a default fitter.
A class to represent a track in tracking.