source: LMDZ4/trunk/libf/bibio/j4save.F @ 5444

Last change on this file since 5444 was 1425, checked in by lguez, 14 years ago

Replaced Numerical Recipes procedures for spline interpolation (not in
the public domain) by procedures from the Pchip package in the Slatec
library. This only affects the program "ce0l", not the program
"gcm". Tested on Brodie SX8 with "-debug" and "-prod", "-parallel
none" and "-parallel mpi". "start.nc" and "limit.nc" are
changed. "startphy.nc" is not changed. The relative change is of order
1e-7 or less. The revision makes the program faster (tested on Brodie
with "-prod -d 144x142x39", CPU time is 38 s, instead of 54
s). Procedures from Slatec are untouched, except for
"i1mach.F". Created procedures "pchfe_95" and "pchsp_95" which are
wrappers for "pchfe" and "pchsp" from Slatec. "pchfe_95" and
"pchsp_95" have a safer and simpler interface.

Replaced "make" by "sxgmake" in "arch-SX8_BRODIE.fcm". Added files for
compilation by FCM with "g95".

In "arch-linux-32bit.fcm", replaced "pgf90" by "pgf95". There was no
difference between "dev" and "debug" so added "-O1" to "dev". Added
debugging options. Removed "-Wl,-Bstatic
-L/usr/lib/gcc-lib/i386-linux/2.95.2", which usually produces an error
at link-time.

Bash is now ubiquitous while KornShell? is not so use Bash instead of
KornShell? in FCM.

Replaced some statements "write(6,*)" by "write(lunout,*)". Replaced
"stop" by "stop 1" in the case where "abort_gcm" is called with "ierr
/= 0". Removed "stop" statements at the end of procedures
"limit_netcdf" and main program "ce0l" (why not let the program end
normally?).

Made some arrays automatic instead of allocatable in "start_inter_3d".

Zeroed "wake_pe", "fm_therm", "entr_therm" and "detr_therm" in
"dyn3dpar/etat0_netcdf.F90". The parallel and sequential results of
"ce0l" are thus identical.

File size: 2.6 KB
Line 
1*DECK J4SAVE
2      FUNCTION J4SAVE (IWHICH, IVALUE, ISET)
3C***BEGIN PROLOGUE  J4SAVE
4C***SUBSIDIARY
5C***PURPOSE  Save or recall global variables needed by error
6C            handling routines.
7C***LIBRARY   SLATEC (XERROR)
8C***TYPE      INTEGER (J4SAVE-I)
9C***KEYWORDS  ERROR MESSAGES, ERROR NUMBER, RECALL, SAVE, XERROR
10C***AUTHOR  Jones, R. E., (SNLA)
11C***DESCRIPTION
12C
13C     Abstract
14C        J4SAVE saves and recalls several global variables needed
15C        by the library error handling routines.
16C
17C     Description of Parameters
18C      --Input--
19C        IWHICH - Index of item desired.
20C                = 1 Refers to current error number.
21C                = 2 Refers to current error control flag.
22C                = 3 Refers to current unit number to which error
23C                    messages are to be sent.  (0 means use standard.)
24C                = 4 Refers to the maximum number of times any
25C                     message is to be printed (as set by XERMAX).
26C                = 5 Refers to the total number of units to which
27C                     each error message is to be written.
28C                = 6 Refers to the 2nd unit for error messages
29C                = 7 Refers to the 3rd unit for error messages
30C                = 8 Refers to the 4th unit for error messages
31C                = 9 Refers to the 5th unit for error messages
32C        IVALUE - The value to be set for the IWHICH-th parameter,
33C                 if ISET is .TRUE. .
34C        ISET   - If ISET=.TRUE., the IWHICH-th parameter will BE
35C                 given the value, IVALUE.  If ISET=.FALSE., the
36C                 IWHICH-th parameter will be unchanged, and IVALUE
37C                 is a dummy parameter.
38C      --Output--
39C        The (old) value of the IWHICH-th parameter will be returned
40C        in the function value, J4SAVE.
41C
42C***SEE ALSO  XERMSG
43C***REFERENCES  R. E. Jones and D. K. Kahaner, XERROR, the SLATEC
44C                 Error-handling Package, SAND82-0800, Sandia
45C                 Laboratories, 1982.
46C***ROUTINES CALLED  (NONE)
47C***REVISION HISTORY  (YYMMDD)
48C   790801  DATE WRITTEN
49C   891214  Prologue converted to Version 4.0 format.  (BAB)
50C   900205  Minor modifications to prologue.  (WRB)
51C   900402  Added TYPE section.  (WRB)
52C   910411  Added KEYWORDS section.  (WRB)
53C   920501  Reformatted the REFERENCES section.  (WRB)
54C***END PROLOGUE  J4SAVE
55      LOGICAL ISET
56      INTEGER IPARAM(9)
57      SAVE IPARAM
58      DATA IPARAM(1),IPARAM(2),IPARAM(3),IPARAM(4)/0,2,0,10/
59      DATA IPARAM(5)/1/
60      DATA IPARAM(6),IPARAM(7),IPARAM(8),IPARAM(9)/0,0,0,0/
61C***FIRST EXECUTABLE STATEMENT  J4SAVE
62      J4SAVE = IPARAM(IWHICH)
63      IF (ISET) IPARAM(IWHICH) = IVALUE
64      RETURN
65      END
Note: See TracBrowser for help on using the repository browser.