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.
icedyn_rhg.F90 in branches/2017/dev_merge_2017/NEMOGCM/NEMO/ICE_SRC – NEMO

source: branches/2017/dev_merge_2017/NEMOGCM/NEMO/ICE_SRC/icedyn_rhg.F90 @ 9570

Last change on this file since 9570 was 9570, checked in by nicolasmartin, 6 years ago

Global renaming for core routines (./NEMO)

  • Folders
    • LIM_SRC_3 -> ICE_SRC
    • OPA_SRC -> OCE_SRC
  • CPP key: key_lim3 -> key_si3
  • Modules, (sub)routines and variables names
    • MPI: mpi_comm_opa -> mpi_comm_oce, MPI_COMM_OPA -> MPI_COMM_OCE, mpi_init_opa -> mpi_init_oce
    • AGRIF: agrif_opa_* -> agrif_oce_*, agrif_lim3_* -> agrif_si3_* and few more
    • TOP-PISCES: p.zlim -> p.zice, namp.zlim -> namp.zice
  • Comments
    • NEMO/OPA -> NEMO/OCE
    • ESIM|LIM3 -> SI3
File size: 7.5 KB
Line 
1MODULE icedyn_rhg
2   !!======================================================================
3   !!                     ***  MODULE  icedyn_rhg  ***
4   !!   Sea-Ice dynamics : master routine for rheology
5   !!======================================================================
6   !! history :  1.0  ! 2002-08  (C. Ethe, G. Madec)  original VP code
7   !!            3.0  ! 2007-03  (MA Morales Maqueda, S. Bouillon, M. Vancoppenolle)  LIM3: EVP-Cgrid
8   !!            3.5  ! 2011-02  (G. Madec) dynamical allocation
9   !!----------------------------------------------------------------------
10#if defined key_si3
11   !!----------------------------------------------------------------------
12   !!   'key_si3'                                       SI3 sea-ice model
13   !!----------------------------------------------------------------------
14   !!    ice_dyn_rhg      : computes ice velocities
15   !!    ice_dyn_rhg_init : initialization and namelist read
16   !!----------------------------------------------------------------------
17   USE phycst         ! physical constants
18   USE dom_oce        ! ocean space and time domain
19   USE ice            ! sea-ice: variables
20   USE icedyn_rhg_evp ! sea-ice: EVP rheology
21   USE icectl         ! sea-ice: control prints
22   !
23   USE in_out_manager ! I/O manager
24   USE lib_mpp        ! MPP library
25   USE lib_fortran    ! fortran utilities (glob_sum + no signed zero)
26   USE timing         ! Timing
27
28   IMPLICIT NONE
29   PRIVATE
30
31   PUBLIC   ice_dyn_rhg        ! called by icestp.F90
32   PUBLIC   ice_dyn_rhg_init   ! called by icestp.F90
33
34   INTEGER ::              nice_rhg   ! choice of the type of rheology
35   !                                        ! associated indices:
36   INTEGER, PARAMETER ::   np_rhgEVP = 1   ! EVP rheology
37!! INTEGER, PARAMETER ::   np_rhgEAP = 2   ! EAP rheology
38
39   ! ** namelist (namrhg) **
40   LOGICAL ::   ln_rhg_EVP       ! EVP rheology
41   !
42   !! * Substitutions
43#  include "vectopt_loop_substitute.h90"
44   !!----------------------------------------------------------------------
45   !! NEMO/ICE 4.0 , NEMO Consortium (2017)
46   !! $Id: icedyn_rhg.F90 8378 2017-07-26 13:55:59Z clem $
47   !! Software governed by the CeCILL licence     (NEMOGCM/NEMO_CeCILL.txt)
48   !!----------------------------------------------------------------------
49CONTAINS
50
51   SUBROUTINE ice_dyn_rhg( kt )
52      !!-------------------------------------------------------------------
53      !!               ***  ROUTINE ice_dyn_rhg  ***
54      !!               
55      !! ** Purpose :   compute ice velocity
56      !!
57      !! ** Action  : comupte - ice velocity (u_ice, v_ice)
58      !!                      - 3 components of the stress tensor (stress1_i, stress2_i, stress12_i)
59      !!                      - shear, divergence and delta (shear_i, divu_i, delta_i)
60      !!--------------------------------------------------------------------
61      INTEGER, INTENT(in) ::   kt     ! ice time step
62      !!--------------------------------------------------------------------
63      ! controls
64      IF( ln_timing    )   CALL timing_start('icedyn_rhg')                                                             ! timing
65      IF( ln_icediachk )   CALL ice_cons_hsm(0, 'icedyn_rhg', rdiag_v, rdiag_s, rdiag_t, rdiag_fv, rdiag_fs, rdiag_ft) ! conservation
66      !
67      IF( kt == nit000 .AND. lwp ) THEN
68         WRITE(numout,*)
69         WRITE(numout,*)'ice_dyn_rhg: sea-ice rheology'
70         WRITE(numout,*)'~~~~~~~~~~~'
71      ENDIF
72
73      ! --------
74      ! Rheology
75      ! --------   
76      SELECT CASE( nice_rhg )
77      !                                !------------------------!
78      CASE( np_rhgEVP )                ! Elasto-Viscous-Plastic !
79         !                             !------------------------!
80         CALL ice_dyn_rhg_evp( kt, stress1_i, stress2_i, stress12_i, shear_i, divu_i, delta_i )
81         !         
82      END SELECT
83      !
84      IF( lrst_ice ) THEN                       !* write EVP fields in the restart file
85         IF( ln_rhg_EVP )   CALL rhg_evp_rst( 'WRITE', kt )
86      ENDIF
87      !
88      ! controls
89      IF( ln_icediachk )   CALL ice_cons_hsm(1, 'icedyn_rhg', rdiag_v, rdiag_s, rdiag_t, rdiag_fv, rdiag_fs, rdiag_ft) ! conservation
90      IF( ln_ctl       )   CALL ice_prt3D   ('icedyn_rhg')                                                             ! prints
91      IF( ln_timing    )   CALL timing_stop ('icedyn_rhg')                                                             ! timing
92      !
93   END SUBROUTINE ice_dyn_rhg
94
95
96   SUBROUTINE ice_dyn_rhg_init
97      !!-------------------------------------------------------------------
98      !!                  ***  ROUTINE ice_dyn_rhg_init  ***
99      !!
100      !! ** Purpose : Physical constants and parameters linked to the ice
101      !!      dynamics
102      !!
103      !! ** Method  :  Read the namdyn_rhg namelist and check the ice-dynamic
104      !!       parameter values called at the first timestep (nit000)
105      !!
106      !! ** input   :   Namelist namdyn_rhg
107      !!-------------------------------------------------------------------
108      INTEGER ::   ios, ioptio   ! Local integer output status for namelist read
109      !!
110      NAMELIST/namdyn_rhg/  ln_rhg_EVP, ln_aEVP, rn_creepl, rn_ecc , nn_nevp, rn_relast
111      !!-------------------------------------------------------------------
112      !
113      REWIND( numnam_ice_ref )         ! Namelist namdyn_rhg in reference namelist : Ice dynamics
114      READ  ( numnam_ice_ref, namdyn_rhg, IOSTAT = ios, ERR = 901)
115901   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namdyn_rhg in reference namelist', lwp )
116      REWIND( numnam_ice_cfg )         ! Namelist namdyn_rhg in configuration namelist : Ice dynamics
117      READ  ( numnam_ice_cfg, namdyn_rhg, IOSTAT = ios, ERR = 902 )
118902   IF( ios >  0 ) CALL ctl_nam ( ios , 'namdyn_rhg in configuration namelist', lwp )
119      IF(lwm) WRITE ( numoni, namdyn_rhg )
120      !
121      IF(lwp) THEN                     ! control print
122         WRITE(numout,*)
123         WRITE(numout,*) 'ice_dyn_rhg_init: ice parameters for ice dynamics '
124         WRITE(numout,*) '~~~~~~~~~~~~~~~'
125         WRITE(numout,*) '   Namelist : namdyn_rhg:'
126         WRITE(numout,*) '      rheology EVP (icedyn_rhg_evp)                        ln_rhg_EVP = ', ln_rhg_EVP
127         WRITE(numout,*) '         use adaptive EVP (aEVP)                           ln_aEVP    = ', ln_aEVP
128         WRITE(numout,*) '         creep limit                                       rn_creepl  = ', rn_creepl
129         WRITE(numout,*) '         eccentricity of the elliptical yield curve        rn_ecc     = ', rn_ecc
130         WRITE(numout,*) '         number of iterations for subcycling               nn_nevp    = ', nn_nevp
131         WRITE(numout,*) '         ratio of elastic timescale over ice time step     rn_relast  = ', rn_relast
132      ENDIF
133      !
134      !                             !== set the choice of ice advection ==!
135      ioptio = 0 
136      IF( ln_rhg_EVP ) THEN   ;   ioptio = ioptio + 1   ;   nice_rhg = np_rhgEVP    ;   ENDIF
137!!    IF( ln_rhg_EAP ) THEN   ;   ioptio = ioptio + 1   ;   nice_rhg = np_rhgEAP    ;   ENDIF
138      IF( ioptio /= 1 )   CALL ctl_stop( 'ice_dyn_rhg_init: choose one and only one ice rheology' )
139      !
140      IF( ln_rhg_EVP  )   CALL rhg_evp_rst( 'READ' )  !* read or initialize all required files
141      !
142   END SUBROUTINE ice_dyn_rhg_init
143
144#else
145   !!----------------------------------------------------------------------
146   !!   Default option         Empty module           NO SI3 sea-ice model
147   !!----------------------------------------------------------------------
148#endif 
149
150   !!======================================================================
151END MODULE icedyn_rhg
Note: See TracBrowser for help on using the repository browser.