24 this->push_back(
Hit3D(v,x,y,z,t,sig_x,sig_y,sig_z,sig_t,w));
63 unsigned int i, i0, i1, i2;
64 unsigned int npts = 6;
68 for (i0=0; i0<hl.size(); ++i0) {
69 if (&h==&hl[i0])
break;
73 double Sw=0, Swx=0, Swy=0, Swxy=0, Swx2=0, wz;
75 for (i1=i0; i1!=0; --i1) {
76 if (fabs(h.
fZ-hl[i1].fZ)>
dz) { ++i1;
break; }
78 for (i2=i0; i2<hl.size(); ++i2) {
79 if (fabs(h.
fZ-hl[i2].fZ)>
dz)
break;
82 Sw = Swx = Swy = Swxy = Swx2 = 0;
83 for (i=i1; i<i2; ++
i) {
87 if (h.
fView==hl[i].fView)
continue;
88 if (fabs(h.
fZ-hl[i].fZ)<
dz) {
91 wz = hl[
i].fZ * hl[
i].fW;
95 Swy += hl[
i].fW*hl[
i].fX;
98 else if (hl[i].fView==
geo::kY) {
99 Swy += hl[
i].fW*hl[
i].fY;
119 double d = Sw*Swx2-Swx*Swx;
129 double m = (Sw*Swxy-Swx*Swy)/d;
130 double b = -(Swx*Swxy-Swx2*Swy)/d;
156 for (i=0; i<this->
size(); ++
i) {
157 (*interp)(hitlist[
i], hitlist);
static bool gsSortHit3DByZ(const Hit3D &h1, const Hit3D &h2)
enum geo::_plane_proj View_t
Enumerate the possible plane projections.
Vertical planes which measure X.
void(* Interp3D)(Hit3D &h, HitList3D &hl)
Horizontal planes which measure Y.
void CompleteOrtho(Interp3D interp=0)
Contain 3D hit information by extrapolating ortho view coordinate from surrounding points in the orth...
double fX
X coordinate of hit.
void gsDefaultInterp(Hit3D &h, HitList3D &hl)
geo::View_t fView
View hit belongs in (x or y)
double fT
time coordinate of hit
static bool gsSortHit3DByY(const Hit3D &h1, const Hit3D &h2)
void AddHit(geo::View_t, double x, double y, double z, double t, double sig_x, double sig_y, double sig_z, double sig_t, double w=1.0)
double fY
Y coordinate of hit.
Essential 3D information for tracking.
void SetHit(unsigned int i, geo::View_t, double x, double y, double z, double t, double sig_x, double sig_y, double sig_z, double sig_t, double w=1.0)
double fZ
Z coordinate of hit.