#ifndef HIT_TRACK_STRUCT_H #define HIT_TRACK_STRUCT_H /* Rob Kutschke, Sept 24, 1998. Structure to define a hit generated by mcfast. ------------------------------------------------------- WARNING: if you change this file, also make sure you change hit_track_struct.inc ! -------------------------------------------------------- */ #include "const.h" #include "trk_channel_struct.h" typedef struct _hit_trk_s { int hep; /* Position of track in hepevt_ */ int trace; /* Position of hit in trace list */ trk_channel_s chan; /* Device dependent channel info. */ double pos[3]; /* See below. */ double dircos[3]; /* See below. */ double dircos2[3]; /* See below. */ double dtime_exact; /* Drift time before smearing */ double dtime; /* Drift time after smearing (if applicable) */ double dtime_sigma; /* Error in drift time (if applicable) */ double dmeas_exact; /* Measured quantity before smearing */ double dmeas; /* Measured quantity after smearing */ double dmeas_sigma; /* Error in measured quantity */ double dpix_exact[2]; /* Pixel meas. before smearing */ double dpix[2]; /* Pixel quantities after smearing */ double dpix_cov[2][2]; /* Covariance matrix of pixel meas. */ } hit_trk_s; /* The meaning of pos(3), dircos(3) and dircos2(3). dircos2(3) only has meaning for pixel detectors. It should be zeroed elsewhere. 1) For both axial and stereo wires in a drift chamber, pos(3) contains a point on the wire and dircos(3) contains a unit vector in the direction of the wire. The point can be anywhere on the wire. 2) For a barrel silicon strip detector, pos(3) contains the world coordinates the local origin (see below). Dircos(3) contains a unit vector in the direction of the measurement. 3) For a pixel detector, pos(3) contains the world coordinates of the local origin, dircos(3) contain a unit vector in the direction of the local x measurement and dircos2(3) contains a unit vector in the direction of the local y measurement. 4) For forward strip detectors (sidisk), pos(3) contains the position of the wafer local origin and dircos(3) contains a unit vector in the direction of the measurement. 5) For forward tracking chambers, pos(3) contains the wire local origin and dircos(3) contains a unit vector in the direction of the measurement. The wire local origin is a point on the wire which was hit. The direction of measurement is perpendicular to the wire direction and is in the plane of the device. See the relevant trk_make_*_hit.F routine for more details. For pixel detectors the pixels measure local coorindates (m,n). These are computed as: m = ( \vec{x} - \vec{x_0} ) \dot \hat{u} n = ( \vec{x} - \vec{x_0} ) \dot \hat{v} where, \vec{x} is the point that the track crosses the plane, \vec{x_0} is the local origin \vec{u} is a unit vector along the local x axis ( dircos ) \vec{v} is a univ vector along the local y axis ( dircos2 ) In the above equations, (m,n) are quantities measured in the local coordinate system of the plane but all other quantities are given in the world coordinate system. For other planar devices, silicon strips and forward trackers, the algebra is the same but only the component selected by dircos is meaningful. */ #endif /* * $Id$ * * $Log$ * Revision 1.1 2000/06/19 19:58:37 eugenio * Initial revision * * Revision 1.3 2000/01/20 17:23:59 kutschke * Updated comments. * * Revision 1.2 2000/01/20 01:06:32 mcbride * add 2nd dircos variable * * Revision 1.1 1998/09/25 02:43:23 kutschke * New file. Generated from .inc version. * * */