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.
usrdef_nam.F90 in NEMO/branches/2020/dev_r14116_HPC-04_mcastril_Mixed_Precision_implementation_final/tests/STATION_ASF/MY_SRC – NEMO

source: NEMO/branches/2020/dev_r14116_HPC-04_mcastril_Mixed_Precision_implementation_final/tests/STATION_ASF/MY_SRC/usrdef_nam.F90 @ 14644

Last change on this file since 14644 was 14644, checked in by sparonuz, 3 years ago

Merge trunk -r14642:HEAD

File size: 4.5 KB
RevLine 
[11637]1MODULE usrdef_nam
2   !!======================================================================
3   !!                     ***  MODULE usrdef_nam   ***
4   !!
5   !!                     ===  STATION_ASF configuration  ===
6   !!
7   !! User defined : set the domain characteristics of a user configuration
8   !!======================================================================
9   !! History :  4.0  ! 2016-03  (S. Flavoni, G. Madec)  Original code
[12629]10   !!            4.x  ! 2019-10  (L. Brodeau) for STATION_ASF (C1D meets SAS)
[11637]11   !!----------------------------------------------------------------------
12
13   !!----------------------------------------------------------------------
14   !!   usr_def_nam   : read user defined namelist and set global domain size
[14072]15   !!   usr_def_hgr   : initialize the horizontal mesh
[11637]16   !!----------------------------------------------------------------------
[14072]17   USE dom_oce  , ONLY: nimpp, njmpp       ! ocean space and time domain
[11637]18   USE par_oce        ! ocean space and time domain
19   USE phycst         ! physical constants
20   !
21   USE in_out_manager ! I/O manager
22   USE lib_mpp        ! MPP library
[14072]23
[11637]24   IMPLICIT NONE
25   PRIVATE
26
27   PUBLIC   usr_def_nam   ! called in nemogcm.F90 module
28
29   !                              !!* namusr_def namelist *!!
30   REAL(wp), PUBLIC::   rn_dept1   ! Depth (m) at which the SST is taken/measured == depth of first T point!
31
32   !!----------------------------------------------------------------------
33   !! NEMO/OCE 4.0 , NEMO Consortium (2018)
[14072]34   !! $Id: usrdef_nam.F90 13216 2020-07-02 09:25:49Z rblod $
[11637]35   !! Software governed by the CeCILL license (see ./LICENSE)
36   !!----------------------------------------------------------------------
37CONTAINS
38
[14644]39   SUBROUTINE usr_def_nam( cd_cfg, kk_cfg, kpi, kpj, kpk, ldIperio, ldJperio, ldNFold, cdNFtype )
[11637]40      !!----------------------------------------------------------------------
41      !!                     ***  ROUTINE dom_nam  ***
[14072]42      !!
[11637]43      !! ** Purpose :   read user defined namelist and define the domain size
44      !!
45      !! ** Method  :   read in namusr_def containing all the user specific namelist parameter
46      !!
[11831]47      !!                Here STATION_ASF configuration
[11637]48      !!
49      !! ** input   : - namusr_def namelist found in namelist_cfg
50      !!----------------------------------------------------------------------
[14644]51      CHARACTER(len=*), INTENT(out) ::   cd_cfg               ! configuration name
52      INTEGER         , INTENT(out) ::   kk_cfg               ! configuration resolution
53      INTEGER         , INTENT(out) ::   kpi, kpj, kpk        ! global domain sizes
54      LOGICAL         , INTENT(out) ::   ldIperio, ldJperio   ! i- and j- periodicity
55      LOGICAL         , INTENT(out) ::   ldNFold              ! North pole folding
56      CHARACTER(len=1), INTENT(out) ::   cdNFtype             ! Folding type: T or F
[11637]57      !
[11831]58      INTEGER ::   ios   ! Local integer
[11637]59      !!
60      NAMELIST/namusr_def/ rn_dept1
61      !!----------------------------------------------------------------------
62      !
63      READ  ( numnam_cfg, namusr_def, IOSTAT = ios, ERR = 902 )
[11831]64902   IF( ios /= 0 )   CALL ctl_nam ( ios , 'namusr_def in configuration namelist' )
[11637]65      !
[11831]66      IF(lwm)   WRITE( numond, namusr_def )
[11637]67      !
68      cd_cfg = 'STATION_ASF'               ! name & resolution (not used)
69      kk_cfg = 0
70
[12629]71      ! Global Domain size: STATION_ASF domain is 3 x 3 grid-points x 2 or vertical levels
[11637]72      kpi = 3
73      kpj = 3
[12629]74      kpk = 2    ! 2, rather than 1, because 1 would cause some issues... like overflow in array boundary indexes, etc...
[11637]75      !
76      !                             ! Set the lateral boundary condition of the global domain
[14644]77      ldIperio = .TRUE.    ;   ldJperio = .true.   ! C1D configuration : 3x3 basin with cyclic Est-West and Norht-South condition
78      ldNFold  = .FALSE.   ;   cdNFtype = '-'
[11637]79      !
[11831]80      !                             ! control print
81      IF(lwp) THEN
82         WRITE(numout,*) '   '
83         WRITE(numout,*) 'usr_def_nam  : read the user defined namelist (namusr_def) in namelist_cfg'
84         WRITE(numout,*) '~~~~~~~~~~~ '
85         WRITE(numout,*) '   Namelist namusr_def : STATION_ASF case'
86         WRITE(numout,*) '         Detpth of first T-point (bulk SST): rn_dept1 = ', rn_dept1
87         WRITE(numout,*) '         jpiglo, jpjglo  = ', kpi, kpj
88         WRITE(numout,*) '      number of model levels                              kpk = ', kpk
89         WRITE(numout,*) '   '
90      ENDIF
[11637]91      !
92   END SUBROUTINE usr_def_nam
93
94   !!======================================================================
95END MODULE usrdef_nam
Note: See TracBrowser for help on using the repository browser.