This routine receives data in the buffer ARRAY(1:NW), and processes the according the the value of the character steering variable DATA. Note that this routine, and routines it calls is independent of the detector simulation (ie. all communication between them is explicit, via arguments, and goes ONLY via ZAPRCS). Hence, if data was written to an external file, ZAPRCS can be called by a program reading that file. It is also trivial to let ZAPRCS run concurrently with the detector simulation, thus enabling a more efficient use of resource in a distributed computing environment.
DATA : Steering 'INIT' : first call, initialise 'LAST' : all data in this event has been delivered, analysis of the event can start. other : keyword describing the data. The unpacking is done by ZADECD, and the keywords are listed there. IREC : record length of data ARRAY : buffer of data-words. NW : number of words (should be a multiple of IREC)
(All these are filled in routines called by ZAPRCS) From /ZAEVT/ : TTRK, total number of particles. From /ZATRA/ : CHAG, charge of tracks; TKRP, perigee parameters of tracks; MASSCD, seen identity of tracks. From /ZATRS/ : PVEC, seen momentum of tracks. From /ZASTE/ : EVT, current event; TYPE, type of info on tracks; DOWNUP, method for vertex-fitting; DST, source of data.
To /ZATRS/ : CHA, charge of tracks; CD, seen identity of tracks. Other parts of /ZATRS/ are filled by calls to ZATRLD and ZAMKTK. At the end of the processing of the event INVTX, TKR and JETNB will be reset. To /ZAEVT/ : MTRK, number of seen tracks. NVTRK, the number of tracks in the vertex is initialised. The call to ZADECD fills other parts of /ZATRS/ To /ZASTE/ : EVT, current event number. The call ZAINI fills other parts of /ZASTE/ The call to ZADECD will fill /ZATRA/. At the end of the event TKRP and PSMEAR will be zeroed. To /ZADTH/ : the call to ZADEDC will fill it. At the end of the event RF, Z and MODNR will be zeroed.
(To do Analysis Initialisation.)
(To DECoDe data buffers.)
(To do TRack LoaD.)
(To MaKe TracK fit result.)
(To do Analysis of USER.)
(To get Calorimeter TYPe.)
(To get Mass VALue.)