The following pages contain a listing of the Fortran source for a program called INDEMO. It produces a plot of a spiral, with a logarithmic y-axis and an x-axis with the scale running right to left. The objective is to demonstrate the SNX_CURS input routine, and to show that data coordinates can be read in and used. Again, the source is distributed with the SNX software: in the directory NCAR_DIR on VAX/VMS and /star/starlink/lib/snx/examples on UNIX.
On VAX/VMS, this program may be compiled, linked and run using the command sequence
$ FORTRAN NCAR_DIR:INDEMO $ LINK INDEMO, NCAR_DIR:SNX_LINK/OPT, STAR_LINK/OPT $ RUN INDEMO
On UNIX, this program may already be installed in directory /star/bin/examples/snx. If it has been deinstalled and removed to save space, you can copy the entire source directory to a scratch dircetory, and with the SYSTEM environment variable set appropriately, build and run it thus:
% setenv SYSTEM alpha_OSF/1 % ./mk indemo % ./indemo
Give the SGS workstation name in response to the ``Workstation?" prompt. The graph will be plotted, and the cursor will appear. Adjust the cursor position and press the ``hit" key (normally numeric 1 and 2 on the keyboard). A cross will be drawn at the cursor position, and next to it a message giving the data coordinates at that point. The program will exit when a cursor ``hit" is made outside the plot bounds, or a zero cursor choice entered.
SNX --- Starlink Extensions to the NCAR Graphics Utilities