1 | MODULE trcnam_age |
---|
2 | !!====================================================================== |
---|
3 | !! *** MODULE trcnam_age *** |
---|
4 | !! TOP : initialisation of some run parameters for Age tracer |
---|
5 | !!====================================================================== |
---|
6 | !! History : 2.0 ! 2007-12 (C. Ethe, G. Madec) |
---|
7 | !!---------------------------------------------------------------------- |
---|
8 | #if defined key_age |
---|
9 | !!---------------------------------------------------------------------- |
---|
10 | !! 'key_age' AGE tracers |
---|
11 | !!---------------------------------------------------------------------- |
---|
12 | !! trc_nam_age : AGE tracer initialisation |
---|
13 | !!---------------------------------------------------------------------- |
---|
14 | USE oce_trc ! Ocean variables |
---|
15 | USE trcsms_age ! AGE specific variable |
---|
16 | |
---|
17 | IMPLICIT NONE |
---|
18 | PRIVATE |
---|
19 | |
---|
20 | PUBLIC trc_nam_age ! called by trcnam.F90 module |
---|
21 | |
---|
22 | !!---------------------------------------------------------------------- |
---|
23 | !! NEMO/TOP 3.3 , NEMO Consortium (2010) |
---|
24 | !! $Id$ |
---|
25 | !! Software governed by the CeCILL licence (NEMOGCM/NEMO_CeCILL.txt) |
---|
26 | !!---------------------------------------------------------------------- |
---|
27 | |
---|
28 | CONTAINS |
---|
29 | |
---|
30 | SUBROUTINE trc_nam_age |
---|
31 | !!------------------------------------------------------------------- |
---|
32 | !! *** ROUTINE trc_nam_age *** |
---|
33 | !! |
---|
34 | !! ** Purpose : Definition some run parameter for AGE model |
---|
35 | !! |
---|
36 | !! ** input : Namelist namage |
---|
37 | !!---------------------------------------------------------------------- |
---|
38 | INTEGER :: numnatg_ref = -1 ! Logical unit for reference AGE namelist |
---|
39 | INTEGER :: numnatg_cfg = -1 ! Logical unit for configuration AGE namelist |
---|
40 | INTEGER :: numong = -1 ! Logical unit for output namelist |
---|
41 | INTEGER :: ios ! Local integer output status for namelist read |
---|
42 | INTEGER :: jl, jn |
---|
43 | !! |
---|
44 | NAMELIST/namage/ rn_age_depth, rn_age_kill_rate |
---|
45 | !!---------------------------------------------------------------------- |
---|
46 | ! ! Open namelist files |
---|
47 | CALL ctl_opn( numnatg_ref, 'namelist_age_ref' , 'OLD', 'FORMATTED', 'SEQUENTIAL', -1, numout, .FALSE. ) |
---|
48 | CALL ctl_opn( numnatg_cfg, 'namelist_age_cfg' , 'OLD', 'FORMATTED', 'SEQUENTIAL', -1, numout, .FALSE. ) |
---|
49 | IF(lwm) CALL ctl_opn( numong, 'output.namelist.age', 'UNKNOWN', 'FORMATTED', 'SEQUENTIAL', -1, numout, .FALSE. ) |
---|
50 | |
---|
51 | REWIND( numnatg_ref ) ! Namelist namagedate in reference namelist : AGE parameters |
---|
52 | READ ( numnatg_ref, namage, IOSTAT = ios, ERR = 901) |
---|
53 | 901 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namage in reference namelist', lwp ) |
---|
54 | |
---|
55 | REWIND( numnatg_cfg ) ! Namelist namagedate in configuration namelist : AGE parameters |
---|
56 | READ ( numnatg_cfg, namage, IOSTAT = ios, ERR = 902 ) |
---|
57 | 902 IF( ios /= 0 ) CALL ctl_nam ( ios , 'namage in configuration namelist', lwp ) |
---|
58 | IF(lwm) WRITE ( numong, namage ) |
---|
59 | |
---|
60 | IF(lwp) THEN ! control print |
---|
61 | WRITE(numout,*) |
---|
62 | WRITE(numout,*) ' trc_nam_age: Read namage, namelist for Age passive tracer' |
---|
63 | WRITE(numout,*) ' ~~~~~~~' |
---|
64 | WRITE(numout,*) ' depth over which age tracer reset to zero rn_age_depth = ', rn_age_depth |
---|
65 | WRITE(numout,*) ' recip of relax. timescale (s) for age tracer shallower than age_depth rn_age_kill_rate = ', rn_age_kill_rate |
---|
66 | ENDIF |
---|
67 | |
---|
68 | IF(lwm) CALL FLUSH ( numong ) ! flush output namelist |
---|
69 | |
---|
70 | END SUBROUTINE trc_nam_age |
---|
71 | |
---|
72 | #else |
---|
73 | !!---------------------------------------------------------------------- |
---|
74 | !! Dummy module : No AGE |
---|
75 | !!---------------------------------------------------------------------- |
---|
76 | CONTAINS |
---|
77 | SUBROUTINE trc_nam_age ! Empty routine |
---|
78 | END SUBROUTINE trc_nam_age |
---|
79 | #endif |
---|
80 | |
---|
81 | !!====================================================================== |
---|
82 | END MODULE trcnam_age |
---|