next up previous contents
Next: 4.1.1 PROGRAM ZXMAIN : Up: 4. Description of Routines. Previous: 4. Description of Routines.   Contents

4.1 Patch SGVSTEER : Over-all steering of the execution

This patch contains the Main program, which includes the calls to the appropriate initialisation routines, the main event loop, and termination routines. On VMS systems, the asyncronous error handler ZXERRH is established.

The main event loop (ZXLOOP) calls the event formating ZXCEST, which, in turn, calls the user event generator (ZEUGEN), and the detector simulation (ZDETSI). ZXLOOP the calls the routine that sends the data to the user analysis code (ZXSEND), and output routine (ZXEVOT). In addition, the random number generator seeds are output at regular intervals.

Entry point :

ZXMAIN (see 4.1.1)
(main program)

The code of this patch communicates with other patches as follows :

    ZXMAIN
      (initialisation:)
      ZXINI
        ZXRUIN
          ZEORD in SGVEVSIM
          ZDORD in SGVDETSIM
          ZAORD in SGVANA
        ZAPRCS in SGVANA

      (main event loop:)
      ZXLOOP
        ZXCEST
          ZEUGEN in SGVEVSIM
          ZDETSI in SGVDETSIM
        ZXSEND
          ZAPRZS in SGVANA

      (end-of-run:)
      ZXEND
        ZXRUEN
          ZARUEN in SGVANA

The communication with patches SGVEVSIM and SGVDETSIM is partly via the common-blocks in the deck ZXCDE, with the patch SGVANA only via arguments.



Subsections

Mikael Berggren 2003-03-27