LOAD:subroutine

IATYPE

 IATYPE is an INTEGER*4 array, length 15, that indicates the type of each
 of the subroutine arguments ARGi.

       ARGi type    | IATYPE(i)
       -------------+----------
       unfilled     |  -99
       text         |   -1
       scalar       |    0
       vector       |    1
       matrix       |    2

ICODE

 ICODE is an INTEGER*4 array, dimensioned 3 by 15, that indicates the
 dimension of each of the subroutine arguments ARGi. Never extend
 variables beyond their original size as passed to the subroutine. If
 a variable is shortened inside the subroutine, the subroutine must
 update the new dimensions in the ICODE array, so that PHYSICA can
 reduce the variable dimensions appropriately. 
       ARGi   | ICODE(1,i)  ICODE(2,i)  ICODE(3,i)
       -------+-----------------------------------
       text   |  length        0           0
       scalar |    0           0           0
       vector |  length        0           0
       matrix |  nrows       ncolms        0

IUPDATE

 IUPDATE is an INTEGER*4 array, length 15, that the user routine sets
 to indicate to PHYSICA whether one of the ARGi arguments has been
 modified inside that subroutine. The default value for IUPDATE(i) is 0.
 Set IUPDATE(i) to 1 to indicate that the i'th argument, ARGi, has been
 modified. Never extend variables beyond their original size as passed to
 the subroutine.  If a variable is shortened inside the subroutine, the
 subroutine must update the new dimensions in the ICODE array, so that
 PHYSICA can reduce the variable dimensions appropriately. 

IER

 IER is an INTEGER*4 variable that defaults to the value 0.  Your
 routine can set to indicate to PHYSICA that an error has occured
 in the routine. Arithmetic errors, such as division by zero, over-
 underflow, will be asynchronously trapped. If other error tests are
 to be done inside the subroutine, the user flags the error by setting
 IER = -1 before the RETURN.  If the CALL command was executed from
 within a command macro, this error flag causes PHYSICA to abort that
 macro and control is passed back to the keyboard.

numeric_arguments

 All the numeric arguments of your subroutine, except for the integer
 arguments IATYPE, ICODE, IUPDATE, and IER, must be REAL*8. A character
 argument is passed as a LOGICAL*1 array. Dimension numeric array
 arguments with length 1, e.g.,  REAL*8 X(1), Y(1), Z(1)

character_arguments

 All the character arguments of your subroutine must be LOGICAL*1, and
 should be dimensioned 1, e.g., LOGICAL*1 LFILE(1).  You can convert
 this to a character string, e.g., CHARACTER*80 CFILE, using the
 following method:
                        LENF = ICODE(1,i)
                        DO I = 1, LENF
                          CFILE(I:I) = CHAR(LFILE(I))
                        END DO
 where LFILE is the i'th argument.

 The user must call the loaded subroutine or function with the correct
 number of arguments, else an addressing error will result, and the program
 may be corrupted.  Calling subroutines or functions with more than the
 number of arguments in the user coded routine will not result in an error,
 but the extra arguments will be ignored.