New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
trcnam_pisces.F90 in branches/2016/dev_r7012_ROBUST5_CNRS/NEMOGCM/NEMO/TOP_SRC/PISCES – NEMO

source: branches/2016/dev_r7012_ROBUST5_CNRS/NEMOGCM/NEMO/TOP_SRC/PISCES/trcnam_pisces.F90 @ 7041

Last change on this file since 7041 was 7041, checked in by cetlod, 8 years ago

ROBUST5_CNRS : implementation of part I of new TOP interface - 1st step -, see ticket #1782

  • Property svn:keywords set to Id
File size: 4.3 KB
Line 
1MODULE trcnam_pisces
2   !!======================================================================
3   !!                      ***  MODULE trcnam_pisces  ***
4   !! TOP :   initialisation of some run parameters for PISCES bio-model
5   !!======================================================================
6   !! History :    -   !  1999-10 (M.A. Foujols, M. Levy) original code
7   !!              -   !  2000-01 (L. Bopp) hamocc3, p3zd
8   !!             1.0  !  2003-08 (C. Ethe)  module F90
9   !!             2.0  !  2007-12  (C. Ethe, G. Madec) from trcnam.pisces.h90
10   !!----------------------------------------------------------------------
11#if defined key_pisces 
12   !!----------------------------------------------------------------------
13   !!   'key_pisces'   :                                   PISCES bio-model
14   !!----------------------------------------------------------------------
15   !! trc_nam_pisces       : PISCES model namelist read
16   !!----------------------------------------------------------------------
17   USE oce_trc         ! Ocean variables
18   USE par_trc         ! TOP parameters
19   USE trc             ! TOP variables
20   USE sms_pisces      ! sms trends
21   USE trdtrc_oce
22   USE iom             ! I/O manager
23
24
25   IMPLICIT NONE
26   PRIVATE
27
28   PUBLIC   trc_nam_pisces   ! called by trcnam.F90 module
29
30
31   !!----------------------------------------------------------------------
32   !! NEMO/TOP 3.3 , NEMO Consortium (2010)
33   !! $Id$
34   !! Software governed by the CeCILL licence (NEMOGCM/NEMO_CeCILL.txt)
35   !!----------------------------------------------------------------------
36
37CONTAINS
38
39   SUBROUTINE trc_nam_pisces
40      !!----------------------------------------------------------------------
41      !!                     ***  trc_nam_pisces  *** 
42      !!
43      !! ** Purpose :   read PISCES namelist
44      !!
45      !! ** input   :   file 'namelist.trc.sms' containing the following
46      !!             namelist: natext, natbio, natsms
47      !!----------------------------------------------------------------------
48      !!
49      INTEGER :: jl, jn
50      INTEGER :: ios, ioptio                 ! Local integer output status for namelist read
51      CHARACTER(LEN=20)   ::   clname
52      !!
53      NAMELIST/nampismod/ln_p2z, ln_p4z
54      !!----------------------------------------------------------------------
55
56      IF(lwp) WRITE(numout,*)
57      clname = 'namelist_pisces'
58
59      IF(lwp) WRITE(numout,*) ' trc_nam_pisces : read PISCES namelist'
60      IF(lwp) WRITE(numout,*) ' ~~~~~~~~~~~~~~'
61      CALL ctl_opn( numnatp_ref, TRIM( clname )//'_ref', 'OLD'    , 'FORMATTED', 'SEQUENTIAL', -1, numout, .FALSE. )
62      CALL ctl_opn( numnatp_cfg, TRIM( clname )//'_cfg', 'OLD'    , 'FORMATTED', 'SEQUENTIAL', -1, numout, .FALSE. )
63      IF(lwm) CALL ctl_opn( numonp     , 'output.namelist.pis' , 'UNKNOWN', 'FORMATTED', 'SEQUENTIAL', -1, numout, .FALSE. )
64      !
65
66      REWIND( numnatp_ref )              ! Namelist nampisbio in reference namelist : Pisces variables
67      READ  ( numnatp_ref, nampismod, IOSTAT = ios, ERR = 901)
68901   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nampismod in reference namelist', lwp )
69
70      REWIND( numnatp_cfg )              ! Namelist nampisbio in configuration namelist : Pisces variables
71      READ  ( numnatp_cfg, nampismod, IOSTAT = ios, ERR = 902 )
72902   IF( ios /= 0 ) CALL ctl_nam ( ios , 'nampismod in configuration namelist', lwp )
73      IF(lwm) WRITE ( numonp, nampismod )
74
75      IF(lwp) THEN                         ! control print
76         WRITE(numout,*) ' Namelist : nampismod'
77         WRITE(numout,*) '    PISCES   model                 ln_p4z  =', ln_p4z
78         WRITE(numout,*) '    LOBSTER  model                 ln_p2z  =', ln_p2z
79      ENDIF
80   
81      ioptio = 0
82      IF( ln_p2z )    ioptio = ioptio + 1
83      IF( ln_p4z )    ioptio = ioptio + 1
84      !
85      IF( ioptio /= 1 )   CALL ctl_stop( 'Choose ONE PISCES model namelist nampismod' )
86       !
87   END SUBROUTINE trc_nam_pisces
88
89#else
90   !!----------------------------------------------------------------------
91   !!  Dummy module :                                   No PISCES bio-model
92   !!----------------------------------------------------------------------
93CONTAINS
94   SUBROUTINE trc_nam_pisces                      ! Empty routine
95   END  SUBROUTINE  trc_nam_pisces
96#endif 
97
98   !!======================================================================
99END MODULE trcnam_pisces
Note: See TracBrowser for help on using the repository browser.