3 |
|
|
4 |
#include "MDSIO_OPTIONS.h" |
#include "MDSIO_OPTIONS.h" |
5 |
|
|
6 |
|
C-- File mdsio_rw_field.F: old version of MDSIO READ/WRITE FIELD S/R with |
7 |
|
C fewer arguments (kept for backward compatibility): call new MDSIO S/R |
8 |
|
C with fixed additional arguments |
9 |
|
C-- Contents |
10 |
|
C-- o MDSREADFIELD |
11 |
|
C-- o MDSREADFIELD_LOC |
12 |
|
C-- o MDSWRITEFIELD |
13 |
|
C-- o MDSWRITEFIELD_LOC |
14 |
|
|
15 |
C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----| |
C---+----1----+----2----+----3----+----4----+----5----+----6----+----7-|--+----| |
16 |
|
|
17 |
SUBROUTINE MDSREADFIELD( |
SUBROUTINE MDSREADFIELD( |
35 |
C |
C |
36 |
C Routine now calls MDS_READ_FIELD, just a way to add 2 extra arguments |
C Routine now calls MDS_READ_FIELD, just a way to add 2 extra arguments |
37 |
C to the argument list. The 1rst new argument is to make the difference between |
C to the argument list. The 1rst new argument is to make the difference between |
38 |
C the vertical dimension (3rd dimension) of the output array and the number |
C the vertical dimension (3rd dimension) of the output array and the number |
39 |
C of levels to read in. This routine assumes they are the same. |
C of levels to read in. This routine assumes they are the same. |
40 |
C The 2nd new argument (useCurrentDir=.FALSE.) allows to read files from |
C The 2nd new argument (useCurrentDir=.FALSE.) allows to read files from |
41 |
C the "mdsioLocalDir" directory (if it is set). |
C the "mdsioLocalDir" directory (if it is set). |
55 |
INTEGER myThid |
INTEGER myThid |
56 |
C ------------------------------------------------------------------ |
C ------------------------------------------------------------------ |
57 |
CALL MDS_READ_FIELD( |
CALL MDS_READ_FIELD( |
58 |
I fName, filePrec, .FALSE., arrType, nNz, nNz, |
I fName, filePrec, .FALSE., arrType, nNz, 1, nNz, |
59 |
O arr, |
O arr, |
60 |
I irecord, myThid ) |
I irecord, myThid ) |
61 |
C ------------------------------------------------------------------ |
C ------------------------------------------------------------------ |
62 |
RETURN |
RETURN |
63 |
END |
END |
85 |
C |
C |
86 |
C Routine now calls MDS_READ_FIELD, just a way to add 2 extra arguments |
C Routine now calls MDS_READ_FIELD, just a way to add 2 extra arguments |
87 |
C to the argument list. The 1rst new argument is to make the difference between |
C to the argument list. The 1rst new argument is to make the difference between |
88 |
C the vertical dimension (3rd dimension) of the output array and the number |
C the vertical dimension (3rd dimension) of the output array and the number |
89 |
C of levels to read in. This routine assumes they are the same. |
C of levels to read in. This routine assumes they are the same. |
90 |
C The 2nd new argument (useCurrentDir=.FALSE.) forces to ignore the |
C The 2nd new argument (useCurrentDir=.FALSE.) forces to ignore the |
91 |
C "mdsioLocalDir" parameter and to always read from the current directory. |
C "mdsioLocalDir" parameter and to always read from the current directory. |
105 |
INTEGER myThid |
INTEGER myThid |
106 |
C ------------------------------------------------------------------ |
C ------------------------------------------------------------------ |
107 |
CALL MDS_READ_FIELD( |
CALL MDS_READ_FIELD( |
108 |
I fName, filePrec, .TRUE., arrType, nNz, nNz, |
I fName, filePrec, .TRUE., arrType, nNz, 1, nNz, |
109 |
O arr, |
O arr, |
110 |
I irecord, myThid ) |
I irecord, myThid ) |
111 |
C ------------------------------------------------------------------ |
C ------------------------------------------------------------------ |
112 |
RETURN |
RETURN |
113 |
END |
END |
161 |
C ------------------------------------------------------------------ |
C ------------------------------------------------------------------ |
162 |
CALL MDS_WRITE_FIELD( |
CALL MDS_WRITE_FIELD( |
163 |
I fName, filePrec, globalFile, .FALSE., |
I fName, filePrec, globalFile, .FALSE., |
164 |
I arrType, nNz, nNz, arr, irecord, |
I arrType, nNz, 1, nNz, arr, irecord, |
165 |
I myIter, myThid ) |
I myIter, myThid ) |
166 |
C ------------------------------------------------------------------ |
C ------------------------------------------------------------------ |
167 |
RETURN |
RETURN |
199 |
C The 2nd new argument (useCurrentDir=.TRUE.) forces to ignore the |
C The 2nd new argument (useCurrentDir=.TRUE.) forces to ignore the |
200 |
C "mdsioLocalDir" parameter and to always write to the current directory. |
C "mdsioLocalDir" parameter and to always write to the current directory. |
201 |
|
|
202 |
implicit none |
IMPLICIT NONE |
203 |
C Global variables / common blocks |
C Global variables / common blocks |
204 |
#include "SIZE.h" |
#include "SIZE.h" |
205 |
c #include "EEPARAMS.h" |
c #include "EEPARAMS.h" |
217 |
C ------------------------------------------------------------------ |
C ------------------------------------------------------------------ |
218 |
CALL MDS_WRITE_FIELD( |
CALL MDS_WRITE_FIELD( |
219 |
I fName, filePrec, globalFile, .TRUE., |
I fName, filePrec, globalFile, .TRUE., |
220 |
I arrType, nNz, nNz, arr, irecord, |
I arrType, nNz, 1, nNz, arr, irecord, |
221 |
I myIter, myThid ) |
I myIter, myThid ) |
222 |
C ------------------------------------------------------------------ |
C ------------------------------------------------------------------ |
223 |
RETURN |
RETURN |