Next: ``HAC'' parameters
Up: General Comments
Previous: Name conventions
  Contents
  Index
Including ALPHA features in Fortran code
In addition to subroutines, the ALPHA package contains include files
which have to be included at the beginning of
user subroutines or functions.
There are several such includes, three of them being the following:
- QCDE
- COMMONs, DIMENSIONs, EQUIVALENCEs, PARAMETERs, DATAs,
type declarations (all ALPHA symbols starting with C or X are
individually declared as CHARACTER or LOGICAL, respectively).
- QMACRO
statement function definitions (from the user's point of
view, statement functions look exactly like ``normal'' Fortran
functions, but their execution is faster).
- QDECL
Contains all integer/real declarations of all ALPHA internal variables,
to be put in the code by people intending to use IMPLICIT NONE.
The BOS array RW(...) and IW(...), as well as
the BMACRO statement functions (RTABL, etc.), are included in QCDE
and
QMACRO.
These sets of statements can be included in user subroutines
by machine-dependent
Fortran statements or by CVS statements, as shown below.
Fortran includes for DEC machines:
INCLUDE 'PHYINC:QCDE.INC'
INCLUDE 'PHYINC:QMACRO.INC'
Fortran includes for UNIX Machines:
INCLUDE '$ALEPH/phy/qcde.inc'
INCLUDE '$ALEPH/phy/qmacro.inc'
CVS statements for CVS source files, on all machines:
#include "qdecl.h"
#include "qcde.h"
#include "qmacro.h"
- Important!
- The following sequence of statements must be observed:
- SUBROUTINE or FUNCTION statement
- QDECL, if you need it (e.g.if you want to use IMPLICIT NONE)
- QCDE
- your own variable declarations, COMMONs, DIMENSIONs, etc.
- your own DATA statements
- QMACRO
- your own statement function definitions (if any)
- your executable Fortran statements
If you don't do so, you may end up with specially unintelligible Fortran compiler
diagnostics...
Next: ``HAC'' parameters
Up: General Comments
Previous: Name conventions
  Contents
  Index
Joel Closier
2000-02-07