Tracking resolution estimator (REZEST)

From GlueXWiki
Revision as of 09:22, 17 March 2008 by Marki (Talk | contribs) (Getting the code: link to r3499, bug fix)

Jump to: navigation, search

The "rezest" package contains FORTRAN routines that calculate estimates of the momentum and angular resolutions for charged particles in GlueX. Simplifying assumptions are made and the resolutions functions are calculated analytically a là the Particle Data Group.

The principal subroutine is documented in the source code file rezest_fdc_cdc.F:

      SUBROUTINE REZEST_FDC_CDC(P, LAMBDA, M,
     X     DP_OVER_P, DPHI_TOT, DTHETA_TOT)
CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC
C
C This routine estimates the resolution in GlueX for charged particles
C in tranverse momentum, azimuthal angle, and polar angle.
C
C Input arguments, all REAL*4
C
C     P        Magnitude of total momentum (GeV/c)
C     LAMBDA   Dip angle, difference in polar angle in lab between track
C              and pi/2 (i. e., 90 degrees) (radians)
C     M        Mass of the particle (GeV/c^2)
C
C Output arguments, all REAL*4
C
C     DP_OVER_P  Relative resolution in transverse momentum ("sigma_{p_t}/p_t")
C     DPHI_TOT   Resolution in azimuthal angle ("sigma_phi")
C     DTHETA_TOT Resolution in polar angle ("sigma_theta")
C
C The routine combines the measurements in the FDC and CDC where
C appropriate. Parameters describing the geometry and materials are
C defined in the routine REZEST_COMPONENTS which appears below.
C

Getting the code

Two methods:

  1. Get the tar ball.
  2. Check it out from the subversion repository:
 svn checkout -r3499 https://halldsvn.jlab.org/repos/trunk/home/marki/gluex/rezest

Building the files

There is a simple makefile in the directory:

> cd <rezest directory>
> make
gfortran -g   -c -o rezest.o rezest.F
gfortran -g   -c -o rezest_fdc_cdc.o rezest_fdc_cdc.F
ar rcv librezest.a rezest.o rezest_fdc_cdc.o
a - rezest.o
a - rezest_fdc_cdc.o
gfortran -g   -c -o rezest_point.o rezest_point.F
gfortran -o rezest_point rezest_point.o -L. -lrezest
gfortran -g   -c -o rezest_point_comp.o rezest_point_comp.F
gfortran -o rezest_point_comp rezest_point_comp.o -L. -lrezest

This creates three files that you care about:

  1. librezest.a: the object library
  2. rezest_point: a binary
  3. rezest_point_comp: a binary

Using the files

librezest.a

Link this into your own program to retrieve resolution values.

rezest_point

This stand-alone binary will accept three arguments on standard input (space separated on a single line) and will write the resolution values on standard output.

Input:

  1. total magnitude of momentum in GeV/c
  2. dip angle in radians (see definition above in the source code snippet)
  3. mass in GeV/c2

Output:

  1. relative resolution in transverse momentum
  2. resolution in azimuthal angle
  3. resolution in polar angle

For example:

> rezest_point
1.0 1.22 0.139
  2.8597742E-02  1.6185496E-02  8.1181811E-04

says that a 1 GeV/c particle traveling in a direction 1.22 radians forward of the transverse direction with a mass of 139 MeV has an estimated \sigma _{{p_{t}}}/p_{t}=2.9\%, \sigma _{\phi }=16 mR, and \sigma _{\theta }=0.8 mR.

rezest_point_comp

Same as rezest_point except that the individual components of the resolution are listed. Note that the first three numbers being output are the same as for rezest_point.

Output:

  1. relative resolution in transverse momentum
  2. resolution in azimuthal angle
  3. resolution in polar angle
  4. resolution in curvature (1/R_{{{\rm {curvature}}}}) due to multiple scattering in the CDC in inverse meters
  5. same for FDC
  6. resolution in curvature due to position resolution in the CDC
  7. same for FDC
  8. total resolution in curvature in the CDC
  9. same for the FDC
  10. resolution in azimuthal angle (\phi ) due to multiple scattering in the CDC in radians
  11. same for FDC
  12. resolution in azimuthal angle due to position resolution in the CDC
  13. same for FDC
  14. resolution in azimuthal angle due to curvature resolution in the CDC
  15. same for FDC
  16. total resolution in azimuthal angle in the CDC
  17. same for the FDC
  18. resolution in polar angle (\theta ) due to multiple scattering in the CDC in radians
  19. same for FDC
  20. resolution in polar angle due to position resolution in the CDC in radians
  21. same for FDC
  22. total resolution in polar angle in the CDC
  23. same for the FDC

For example:

> rezest_point_comp
1.0 1.22 0.139
  2.8597742E-02  1.6185496E-02  8.1181811E-04  4.2887099E-02
  2.2642065E-02  1.3919008E-02  0.1605156      4.5089267E-02
  0.1621047      2.5197803E-03  3.1950074E-04  5.0111138E-04
  2.4516270E-03  1.7020071E-02  4.7496673E-02  1.7212879E-02
  4.7560975E-02  2.5197803E-03  3.1950074E-04  7.7741774E-04
  7.9118297E-04  2.6369814E-03  8.5325917E-04

(All values in the output actually appear on one line.)