Modulefpreviousupnextcontentsindex[BIG][Normal][small]
Next: 1.7 Modules - Algorithms - Utilities Up: 1 General Prev: 1.5 Dynamic arrays Index Contents


1.6 Data Structures

   

The modules communicate with each other via standardized Data Structures (DS). They are processed in blocks by utility subroutines to ensure simple manipulation. A DS may reside:

in main memory,
in the form of a set of dynamic arrays,
in secondary memory,
in the form of a file (an unformatted Fortran file consisting of several records).

Amongst the numerous advantages of Data Structures, let us note the following:

All Data Structures have a type, for example NOPO, MAIL, COOR, or B. The different arrays belonging to a DS of a given type are described in part iii of this user guide. If a DS is of a generic type, tysd, it can be manipulated in a module via the following variables:

CHARACTER*80 NOMFIC
:
The file name (see [Fortran 77], command: OPEN, specifier: FILE).
INTEGER NFtysd
:
The file unit number (see [Fortran 77], command: OPEN, specifier: UNIT). NFtysd = 0 signifies that the DS is in main memory.
INTEGER NItysd
:
An integer, called the level, which enables us to distinguish between two Data Structures of the same type, residing in main memory at the same time.

Remarks:

To conclude, the calling of a module which requires, for example, a NOPO type DS typically has the following form:

      ...
      CALL TRUNIT(NFNOPO)
      NINOPO = 0
      CALL LIBCAR(NOMFIC)
      CALL OUVRIS(NFNOPO, NOMFIC, 'OLD,UNFORMATTED', 0)
      CALL MODULE(M, NFNOPO, NINOPO, ...)
      ...


Modulefpreviousupnextcontentsindex[BIG][Normal][small]
Next: 1.7 Modules - Algorithms - Utilities Up: 1 General Prev: 1.5 Dynamic arrays Index Contents