FUNCTION    : FKHUNT(JPL,S,C,IERR)
 
AUTHOR : Stephen Burke
 
DATE : 26/07/93
 
LANGUAGE : FORTRAN
 
SHORT SUMMARY of PURPOSE:                                                
                                                                                
 Look for a new digitisation near a track. This is called by the                
 Kalman filter code if point acquisition is enabled and no hit is               
 already attached to the track at a given z plane.                              
                                                                                
LIST and DESCRIPTION of INPUT VARIABLES/ARGUMENTS:                       
                                                                                
 JPL - the z plane (1 to 72)                                                    
 S   - track parameters (REAL*8 5-vector)                                       
 C   - covariance matrix (REAL*8 5*5 matrix)                                    
                                                                                
LIST and DESCRIPTION of OUTPUT VARIABLES/ARGUMENTS:                      
                                                                                
 LMES(JPL) (in /FKFLAG/) is set .TRUE. if a measurement is found                
 in the correct cell, within a cut X2CUTN (in /FKRJCT/) of S, and               
 .TRUE. is returned as the function value. The measurement arrays               
 (WMES, CMES and HMES in /FKMEAS/) are filled appropriately. IRJCT(JPL)         
 (in /FKRJCT/) is set to zero. IDIGI(JPL) (in /FFGEO/) is set to the            
 digi pointer, signed according to the drift sign.                              
                                                                                
 IERR - error flag:                                                             
                                                                                
       IERR =   0 ; normal termination                                          
   ->  IERR = 101 ; invalid probability cut                                     
   ->  IERR = 103 ; invalid value in MES array                                  
   ->  IERR = 104 ; invalid value in MES array, or internal error               
       IERR =  12 ; covariance of residuals not positive definite               
                                                                                
   ->  Fatal errors                                                             
                                                                                
 Fatal errors all give a return value of .FALSE., and no changes                
 are made; they are consequently recoverable.                                   
                                                                                
 
CALLING TREE from FKHUNT :
 
  CALL FFPCEL      == tree ==>
  CALL FKERR       == tree ==>
  CALL FFPHNT      == tree ==>
  CALL FFRCEL      == tree ==>
  CALL FFRHNT      == tree ==>
  CALL FFPLAN      == tree ==>
  CALL FFRAD       == tree ==>
  CALL FFEVT0      == tree ==>
  CALL FFCORR      == tree ==>
  CALL FKLRSD      == tree ==>
  CALL FFCHTR      == tree ==>
  CALL FKANAL      == tree ==>
 
FUNCTIONS USED :
 
FKCHPR                                                                            
 
KEEP SEQUENCES USED :
 
 FKECODE FKNPL FFSTEE FFGEO FKFLAG FKMEAS FKCONS FKSMTH FKRJCT                                                
 FKDBG FFWBI FRLORA BCS FTANG STFUNCT                                                                         
 

Comments from FKHUNT