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.
icestp.F90 in branches/2017/dev_r8183_ICEMODEL/NEMOGCM/NEMO/LIM_SRC_3 – NEMO

source: branches/2017/dev_r8183_ICEMODEL/NEMOGCM/NEMO/LIM_SRC_3/icestp.F90 @ 8517

Last change on this file since 8517 was 8517, checked in by clem, 7 years ago

changes in style - part6 - one more round

File size: 22.2 KB
RevLine 
[8321]1MODULE icestp
2   !!======================================================================
3   !!                       ***  MODULE  icestp  ***
4   !! Surface module :  update the ocean surface boundary condition over ice
5   !!       &           covered area using LIM sea-ice model
6   !! Sea-Ice model  :  LIM-3 Sea ice model time-stepping
7   !!=====================================================================
8   !! History :  2.0  ! 2006-12  (M. Vancoppenolle) Original code
9   !!            3.0  ! 2008-02  (C. Talandier)  Surface module from icestp.F90
[8411]10   !!             -   ! 2008-04  (G. Madec)  sltyle and ice_ctl routine
[8321]11   !!            3.3  ! 2010-11  (G. Madec) ice-ocean stress always computed at each ocean time-step
12   !!            3.4  ! 2011-01  (A Porter)  dynamical allocation
[8426]13   !!             -   ! 2012-10  (C. Rousset)  add ice_dia
[8321]14   !!            3.6  ! 2014-07  (M. Vancoppenolle, G. Madec, O. Marti) revise coupled interface
15   !!            4.0  ! 2016-06  (L. Brodeau) new unified bulk routine (based on AeroBulk)
16   !!----------------------------------------------------------------------
17#if defined key_lim3
18   !!----------------------------------------------------------------------
[8486]19   !!   'key_lim3'                                    LIM 3.0 sea-ice model
[8321]20   !!----------------------------------------------------------------------
[8486]21   !!   ice_stp       : sea-ice model time-stepping and update ocean surf. boundary cond. over ice-covered area
22   !!   ice_init      :
23   !!   ice_run_init  :
[8321]24   !!----------------------------------------------------------------------
[8486]25   USE oce            ! ocean dynamics and tracers
26   USE dom_oce        ! ocean space and time domain
27   USE c1d            ! 1D vertical configuration
28   USE ice            ! sea-ice: variables
29   USE ice1D          ! sea-ice: thermodynamical 1D variables
[8321]30   !
[8486]31   USE sbc_oce        ! Surface boundary condition: ocean fields
32   USE sbc_ice        ! Surface boundary condition: ice   fields
33   USE iceforcing     ! sea-ice: Surface boundary condition       !!gm why not icesbc module name
[8321]34   !
[8486]35   USE phycst         ! Define parameters for the routines
36   USE eosbn2         ! equation of state
37   USE icerhg         ! sea-ice: rheology
38   USE iceadv         ! sea-ice: advection
[8516]39   USE icedyn         ! sea-ice: dynamics
[8486]40   USE icethd         ! sea-ice: thermodynamics
41   USE icerdgrft      ! sea-ice: ridging/rafting
42   USE iceupdate      ! sea-ice: sea surface boundary condition update
43   USE icedia         ! sea-ice: budget diagnostics
44   USE icewri         ! sea-ice: outputs
45   USE icerst         ! sea-ice: restarts
46   USE icecor         ! sea-ice: corrections
47   USE icevar         ! sea-ice: operations
48   USE icectl         ! sea-ice: control
[8321]49   ! MV MP 2016
[8486]50   USE limmp          ! sea-ice: melt ponds
[8321]51   ! END MV MP 2016
[8514]52   USE iceistate      ! sea-ice: initial state
[8486]53   USE icethd_sal     ! sea-ice: thermodynamics and salinity
[8505]54   USE iceitd         ! sea-ice: remapping thickness distribution
55   USE icealb         ! sea-ice: albedo
[8321]56   !
[8486]57   USE bdy_oce , ONLY : ln_bdy   ! flag for bdy
58   USE bdyice         ! unstructured open boundary data for sea-ice
[8321]59# if defined key_agrif
60   USE agrif_ice
61   USE agrif_lim3_update
62   USE agrif_lim3_interp
63# endif
[8486]64   !
65   USE in_out_manager ! I/O manager
66   USE iom            ! I/O manager library
67   USE prtctl         ! Print control
68   USE lib_fortran    !
69   USE lbclnk         ! lateral boundary condition - MPP link
70   USE lib_mpp        ! MPP library
71   USE timing         ! Timing
[8321]72
73   IMPLICIT NONE
74   PRIVATE
75
[8486]76   PUBLIC   ice_stp    ! called by sbcmod.F90
77   PUBLIC   ice_init   ! called by sbcmod.F90
[8321]78
79   !! * Substitutions
80#  include "vectopt_loop_substitute.h90"
81   !!----------------------------------------------------------------------
[8486]82   !! NEMO/ICE 4.0 , NEMO Consortium (2017)
[8321]83   !! $Id: icestp.F90 8319 2017-07-11 15:00:44Z clem $
84   !! Software governed by the CeCILL licence     (NEMOGCM/NEMO_CeCILL.txt)
85   !!----------------------------------------------------------------------
86CONTAINS
87
88   SUBROUTINE ice_stp( kt, ksbc )
89      !!---------------------------------------------------------------------
90      !!                  ***  ROUTINE ice_stp  ***
91      !!
[8486]92      !! ** Purpose :   sea-ice model time-stepping and update ocean surface
93      !!              boundary condition over ice-covered area
[8321]94      !!
95      !! ** Method  :   ice model time stepping
96      !!              - call the ice dynamics routine
97      !!              - call the ice advection/diffusion routine
98      !!              - call the ice thermodynamics routine
99      !!              - call the routine that computes mass and
100      !!                heat fluxes at the ice/ocean interface
101      !!              - save the outputs
102      !!              - save the outputs for restart when necessary
103      !!
104      !! ** Action  : - time evolution of the LIM sea-ice model
105      !!              - update all sbc variables below sea-ice:
106      !!                utau, vtau, taum, wndm, qns , qsr, emp , sfx
107      !!---------------------------------------------------------------------
108      INTEGER, INTENT(in) ::   kt      ! ocean time step
[8486]109      INTEGER, INTENT(in) ::   ksbc    ! flux formulation (user defined, bulk, or Pure Coupled)
110      !
111      INTEGER ::   jl   ! dummy loop index
[8321]112      !!----------------------------------------------------------------------
[8486]113      !
[8321]114      IF( nn_timing == 1 )   CALL timing_start('ice_stp')
[8486]115      !
116      !                                      !-----------------------!
117      IF( MOD( kt-1, nn_fsbc ) == 0 ) THEN   ! --- Ice time step --- !
118         !                                   !-----------------------!
119         !
[8498]120         kt_ice = kt                              ! -- Ice model time step
[8486]121         !
[8321]122# if defined key_agrif
123         IF( .NOT. Agrif_Root() )  lim_nbstep = MOD( lim_nbstep, Agrif_irhot() * Agrif_Parent(nn_fsbc) / nn_fsbc ) + 1
124# endif
[8498]125         u_oce(:,:) = ssu_m(:,:)                  ! -- mean surface ocean current
126         v_oce(:,:) = ssv_m(:,:)
127         !
128         CALL eos_fzp( sss_m(:,:) , t_bo(:,:) )   ! -- freezing temperature [Kelvin] (set to rt0 over land)
[8321]129         t_bo(:,:) = ( t_bo(:,:) + rt0 ) * tmask(:,:,1) + rt0 * ( 1._wp - tmask(:,:,1) )
130         !
[8498]131         CALL store_fields                        ! -- Store now ice values
[8486]132         !
[8321]133         !------------------------------------------------!
134         ! --- Dynamical coupling with the atmosphere --- !
135         !------------------------------------------------!
[8486]136         ! It provides the following fields used in sea ice model:
[8404]137         !    utau_ice, vtau_ice = surface ice stress [N/m2]
[8486]138         !------------------------------------------------!
139         CALL ice_forcing_tau( kt, ksbc, utau_ice, vtau_ice )
[8404]140                                     
[8486]141         !-------------------------------------!
142         ! --- ice dynamics and advection  --- !
143         !-------------------------------------!
144         CALL ice_diag0             ! set diag of mass, heat and salt fluxes to 0
145         CALL ice_rst_opn( kt )     ! Open Ice restart file (if necessary)
[8321]146         !
[8516]147         IF( ln_icedyn .AND. .NOT.lk_c1d )   CALL ice_dyn( kt )            ! -- Ice dynamics
[8486]148         !
149         !                          !==  lateral boundary conditions  ==!
[8321]150#if defined key_agrif
[8516]151         IF( .NOT. Agrif_Root()     )        CALL agrif_interp_lim3('T')   ! -- AGRIF
[8321]152#endif
[8516]153         IF( ln_icethd .AND. ln_bdy )        CALL bdy_ice( kt )            ! -- bdy ice thermo
[8486]154         !
155         !
156         !                          !==  previous lead fraction and ice volume for flux calculations
157         !
158         CALL ice_var_glo2eqv            ! ht_i and ht_s for ice albedo calculation
159         CALL ice_var_agg(1)             ! at_i for coupling
[8498]160         CALL store_fields               ! Store now ice values
[8321]161
162         !------------------------------------------------------!
163         ! --- Thermodynamical coupling with the atmosphere --- !
164         !------------------------------------------------------!
[8404]165         ! It provides the following fields used in sea ice model:
[8486]166         !    fr1_i0  , fr2_i0     = 1sr & 2nd fraction of qsr penetration in ice  [%]
167         !    emp_oce , emp_ice    = E-P over ocean and sea ice                    [Kg/m2/s]
168         !    sprecip              = solid precipitation                           [Kg/m2/s]
169         !    evap_ice             = sublimation                                   [Kg/m2/s]
170         !    qsr_tot , qns_tot    = solar & non solar heat flux (total)           [W/m2]
171         !    qsr_ice , qns_ice    = solar & non solar heat flux over ice          [W/m2]
172         !    dqns_ice             = non solar  heat sensistivity                  [W/m2]
173         !    qemp_oce, qemp_ice,  = sensible heat (associated with evap & precip) [W/m2]
174         !    qprec_ice, qevap_ice
175         !------------------------------------------------------!
[8516]176                                    CALL ice_forcing_flx( kt, ksbc )
[8321]177
178         !----------------------------!
179         ! --- ice thermodynamics --- !
180         !----------------------------!
[8514]181         IF( ln_icethd )            CALL ice_thd( kt )          ! -- Ice thermodynamics     
[8321]182
183         ! MV MP 2016
[8486]184         IF ( ln_pnd )              CALL lim_mp( kt )           ! -- Melt ponds
[8321]185         ! END MV MP 2016
186
[8514]187         IF( ln_icethd )            CALL ice_cor( kt , 2 )      ! -- Corrections
[8321]188         ! ---
189# if defined key_agrif
[8486]190         IF( .NOT. Agrif_Root() )   CALL agrif_update_lim3( kt )
[8321]191# endif
[8486]192                                    CALL ice_var_glo2eqv        ! necessary calls (at least for coupling)
193                                    CALL ice_var_agg( 2 )       ! necessary calls (at least for coupling)
194                                    !
[8321]195!! clem: one should switch the calculation of the fluxes onto the parent grid but the following calls do not work
196!!       moreover it should only be called at the update frequency (as in agrif_lim3_update.F90)
197!!# if defined key_agrif
198!!         IF( .NOT. Agrif_Root() )   CALL Agrif_ChildGrid_To_ParentGrid()
199!!# endif
[8486]200                                    CALL ice_update_flx( kt )   ! -- Update ocean surface mass, heat and salt fluxes
[8321]201!!# if defined key_agrif
202!!         IF( .NOT. Agrif_Root() )   CALL Agrif_ParentGrid_To_ChildGrid()
203!!# endif
[8514]204         IF( ln_icediahsb )         CALL ice_dia( kt )        ! -- Diagnostics and outputs
[8321]205         !
[8498]206                                    CALL ice_wri( 1 )         ! -- Ice outputs
[8321]207         !
[8486]208         IF( kt == nit000 .AND. ln_rstart )   &                !!gm  I don't understand the ln_rstart, if needed, add a comment, please
[8498]209            &                       CALL iom_close( numrir )  ! close input ice restart file
[8321]210         !
[8498]211         IF( lrst_ice )             CALL ice_rst_write( kt )  ! -- Ice restart file
[8321]212         !
[8514]213         IF( ln_icectl )            CALL ice_ctl( kt )        ! alerts in case of model crash
[8321]214         !
215      ENDIF   ! End sea-ice time step only
216
217      !-------------------------!
218      ! --- Ocean time step --- !
219      !-------------------------!
220      ! Update surface ocean stresses (only in ice-dynamic case) otherwise the atm.-ocean stresses are used everywhere
221      !    using before instantaneous surf. currents
[8512]222      IF( ln_icedyn )               CALL ice_update_tau( kt, ub(:,:,1), vb(:,:,1) )
[8321]223!!gm   remark, the ocean-ice stress is not saved in ice diag call above .....  find a solution!!!
224      !
225      IF( nn_timing == 1 ) CALL timing_stop('ice_stp')
226      !
227   END SUBROUTINE ice_stp
228
229
230   SUBROUTINE ice_init
231      !!----------------------------------------------------------------------
232      !!                  ***  ROUTINE ice_init  ***
233      !!
234      !! ** purpose :   Allocate all the dynamic arrays of the LIM-3 modules
235      !!----------------------------------------------------------------------
236      INTEGER :: ji, jj, ierr
237      !!----------------------------------------------------------------------
238      IF(lwp) WRITE(numout,*)
[8514]239      IF(lwp) WRITE(numout,*) 'ice_init: Arrays allocation & Initialization off all routines & init state' 
240      IF(lwp) WRITE(numout,*) '~~~~~~~~'
[8321]241      !
242      !                                ! Open the reference and configuration namelist files and namelist output file
243      CALL ctl_opn( numnam_ice_ref, 'namelist_ice_ref',    'OLD',     'FORMATTED', 'SEQUENTIAL', -1, numout, lwp )
244      CALL ctl_opn( numnam_ice_cfg, 'namelist_ice_cfg',    'OLD',     'FORMATTED', 'SEQUENTIAL', -1, numout, lwp )
245      IF(lwm) CALL ctl_opn( numoni, 'output.namelist.ice', 'UNKNOWN', 'FORMATTED', 'SEQUENTIAL', -1, numout, lwp, 1 )
246      !
247      CALL ice_run_init                ! set some ice run parameters
248      !
[8324]249      !                                ! Allocate the ice arrays (sbc_ice already allocated in sbc_init)
[8321]250      ierr =        ice_alloc        ()      ! ice variables
[8331]251      ierr = ierr + sbc_ice_alloc    ()      ! surface forcing
[8420]252      ierr = ierr + ice1D_alloc      ()      ! thermodynamics
[8512]253      ierr = ierr + ice_rdgrft_alloc ()      ! ridging/rafting
[8321]254      !
255      IF( lk_mpp    )   CALL mpp_sum( ierr )
256      IF( ierr /= 0 )   CALL ctl_stop('STOP', 'ice_init : unable to allocate ice arrays')
257      !
258      CALL ice_itd_init                ! ice thickness distribution initialization
259      !
[8517]260      IF( ln_icedyn )   THEN
261         CALL ice_dyn_init             ! set ice dynamics parameters
262         CALL ice_rdgrft_init          ! set ice ridging/rafting parameters
263         CALL ice_rhg_init             ! set ice rheology parameters
264         CALL ice_adv_init             ! set ice advection parameters
265      ENDIF
266
267      IF( ln_icethd ) THEN
268         CALL ice_thd_init             ! set ice thermodynics parameters
269         CALL ice_thd_sal_init         ! set ice salinity parameters
270      ENDIF
271   
[8321]272      ! MV MP 2016
273      CALL lim_mp_init                 ! set melt ponds parameters
274      ! END MV MP 2016
275      !                                ! Initial sea-ice state
276      IF( .NOT. ln_rstart ) THEN              ! start from rest: sea-ice deduced from sst
[8515]277         CALL ice_istate_init
[8514]278         CALL ice_istate
[8321]279      ELSE                                    ! start from a restart file
[8413]280         CALL ice_rst_read
[8321]281      ENDIF
[8424]282      CALL ice_var_agg(2)
283      CALL ice_var_glo2eqv
[8321]284      !
[8517]285      CALL ice_update_init             ! ice surface boundary condition
[8321]286      !
[8517]287      CALL ice_alb_init                ! ice surface albedo
[8321]288      !
[8517]289      CALL ice_dia_init                ! initialization for diags
[8505]290      !
[8517]291      fr_i  (:,:)   = at_i(:,:)        ! initialisation of sea-ice fraction
292      tn_ice(:,:,:) = t_su(:,:,:)      ! initialisation of surface temp for coupled simu
[8321]293      !
[8517]294      !                                ! set max concentration in both hemispheres
[8515]295      WHERE( gphit(:,:) > 0._wp )   ;   rn_amax_2d(:,:) = rn_amax_n  ! NH
296      ELSEWHERE                     ;   rn_amax_2d(:,:) = rn_amax_s  ! SH
297      END WHERE
[8321]298      !
299   END SUBROUTINE ice_init
300
301
302   SUBROUTINE ice_run_init
303      !!-------------------------------------------------------------------
304      !!                  ***  ROUTINE ice_run_init ***
305      !!
306      !! ** Purpose :   Definition some run parameter for ice model
307      !!
[8512]308      !! ** Method  :   Read the namice_run namelist and check the parameter
[8517]309      !!                values called at the first timestep (nit000)
[8321]310      !!
[8512]311      !! ** input   :   Namelist namice_run
[8321]312      !!-------------------------------------------------------------------
313      INTEGER  ::   ios                 ! Local integer output status for namelist read
[8517]314      NAMELIST/namice_run/ jpl, nlay_i, nlay_s, nn_monocat, ln_icedyn, ln_icethd, rn_amax_n, rn_amax_s,  &
315         &                 cn_icerst_in, cn_icerst_indir, cn_icerst_out, cn_icerst_outdir
[8321]316      !!-------------------------------------------------------------------
317      !
[8512]318      REWIND( numnam_ice_ref )      ! Namelist namice_run in reference namelist : Parameters for ice
319      READ  ( numnam_ice_ref, namice_run, IOSTAT = ios, ERR = 901)
320901   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namice_run in reference namelist', lwp )
[8321]321
[8512]322      REWIND( numnam_ice_cfg )      ! Namelist namice_run in configuration namelist : Parameters for ice
323      READ  ( numnam_ice_cfg, namice_run, IOSTAT = ios, ERR = 902 )
324902   IF( ios /= 0 ) CALL ctl_nam ( ios , 'namice_run in configuration namelist', lwp )
325      IF(lwm) WRITE ( numoni, namice_run )
[8321]326      !
[8486]327      IF(lwp) THEN                  ! control print
[8321]328         WRITE(numout,*)
329         WRITE(numout,*) 'ice_run_init : ice share parameters for dynamics/advection/thermo of sea-ice'
330         WRITE(numout,*) ' ~~~~~~'
[8512]331         WRITE(numout,*) '   Namelist namice_run : '
[8486]332         WRITE(numout,*) '      number of ice  categories                              jpl    = ', jpl
333         WRITE(numout,*) '      number of ice  layers                                  nlay_i = ', nlay_i
334         WRITE(numout,*) '      number of snow layers                                  nlay_s = ', nlay_s
335         WRITE(numout,*) '      virtual ITD mono-category param (1-4) or not (0)   nn_monocat = ', nn_monocat
[8517]336         WRITE(numout,*) '      Ice dynamics       (T) or not (F)                  ln_icedyn  = ', ln_icedyn
337         WRITE(numout,*) '      Ice thermodynamics (T) or not (F)                  ln_icethd  = ', ln_icethd
[8486]338         WRITE(numout,*) '      maximum ice concentration for NH                              = ', rn_amax_n 
339         WRITE(numout,*) '      maximum ice concentration for SH                              = ', rn_amax_s
[8321]340      ENDIF
341      !
[8517]342      !                                        !--- check consistency
[8486]343      IF ( jpl > 1 .AND. nn_monocat == 1 ) THEN
[8321]344         nn_monocat = 0
345         IF(lwp) WRITE(numout,*)
346         IF(lwp) WRITE(numout,*) '   nn_monocat forced to 0 as jpl>1, i.e. multi-category case is chosen'
347      ENDIF
[8486]348      IF ( jpl == 1 .AND. nn_monocat == 0 ) THEN
[8321]349         CALL ctl_stop( 'STOP', 'ice_run_init : if jpl=1 then nn_monocat should be between 1 and 4' )
350      ENDIF
351      !
[8514]352      IF( ln_bdy .AND. ln_icediachk )   CALL ctl_warn('ice_run_init: online conservation check does not work with BDY')
[8321]353      !
[8517]354      rdt_ice   = REAL(nn_fsbc) * rdt          !--- sea-ice timestep and inverse
[8486]355      r1_rdtice = 1._wp / rdt_ice
[8517]356      IF( lwp ) WRITE(numout,*) '   ice timestep rdt_ice = ', rdt_ice
[8321]357      !
[8517]358      r1_nlay_i = 1._wp / REAL( nlay_i, wp )   !--- inverse of nlay_i and nlay_s
[8486]359      r1_nlay_s = 1._wp / REAL( nlay_s, wp )
360      !
[8321]361   END SUBROUTINE ice_run_init
362
363
[8498]364   SUBROUTINE store_fields
[8321]365      !!----------------------------------------------------------------------
[8498]366      !!                  ***  ROUTINE store_fields  ***
[8321]367      !!
368      !! ** purpose :  store ice variables at "before" time step
369      !!----------------------------------------------------------------------
[8360]370      INTEGER  ::   ji, jj, jl      ! dummy loop index
371      !!----------------------------------------------------------------------
[8321]372      !
[8515]373      a_i_b  (:,:,:)   = a_i  (:,:,:)     ! ice area
374      v_i_b  (:,:,:)   = v_i  (:,:,:)     ! ice volume
375      v_s_b  (:,:,:)   = v_s  (:,:,:)     ! snow volume
376      smv_i_b(:,:,:)   = smv_i(:,:,:)     ! salt content
377      oa_i_b (:,:,:)   = oa_i (:,:,:)     ! areal age content
378      e_s_b  (:,:,:,:) = e_s  (:,:,:,:)   ! snow thermal energy
379      e_i_b  (:,:,:,:) = e_i  (:,:,:,:)   ! ice thermal energy
380      WHERE( a_i_b(:,:,:) >= epsi20 )
381         ht_i_b(:,:,:) = v_i_b (:,:,:) / a_i_b(:,:,:)   ! ice thickness
382         ht_s_b(:,:,:) = v_s_b (:,:,:) / a_i_b(:,:,:)   ! snw thickness
383      ELSEWHERE
384         ht_i_b(:,:,:) = 0._wp
385         ht_s_b(:,:,:) = 0._wp
386      END WHERE
[8321]387     
[8360]388      ! ice velocities & total concentration
[8515]389      at_i_b(:,:)  = SUM( a_i_b(:,:,:), dim=3 )
390      u_ice_b(:,:) = u_ice(:,:)
391      v_ice_b(:,:) = v_ice(:,:)
[8486]392      !
[8498]393   END SUBROUTINE store_fields
[8321]394
395
396   SUBROUTINE ice_diag0
397      !!----------------------------------------------------------------------
398      !!                  ***  ROUTINE ice_diag0  ***
399      !!
400      !! ** purpose :  set ice-ocean and ice-atm. fluxes to zeros at the beggining
401      !!               of the time step
402      !!----------------------------------------------------------------------
[8360]403      INTEGER  ::   ji, jj      ! dummy loop index
404      !!----------------------------------------------------------------------
[8515]405      sfx    (:,:) = 0._wp   ;
406      sfx_bri(:,:) = 0._wp   ;   sfx_lam(:,:) = 0._wp
407      sfx_sni(:,:) = 0._wp   ;   sfx_opw(:,:) = 0._wp
408      sfx_bog(:,:) = 0._wp   ;   sfx_dyn(:,:) = 0._wp
409      sfx_bom(:,:) = 0._wp   ;   sfx_sum(:,:) = 0._wp
410      sfx_res(:,:) = 0._wp   ;   sfx_sub(:,:) = 0._wp
411      !
412      wfx_snw(:,:) = 0._wp   ;   wfx_ice(:,:) = 0._wp
413      wfx_sni(:,:) = 0._wp   ;   wfx_opw(:,:) = 0._wp
414      wfx_bog(:,:) = 0._wp   ;   wfx_dyn(:,:) = 0._wp
415      wfx_bom(:,:) = 0._wp   ;   wfx_sum(:,:) = 0._wp
416      wfx_res(:,:) = 0._wp   ;   wfx_sub(:,:) = 0._wp
417      wfx_spr(:,:) = 0._wp   ;   wfx_lam(:,:) = 0._wp 
418      wfx_snw_dyn(:,:) = 0._wp ; wfx_snw_sum(:,:) = 0._wp
419      wfx_snw_sub(:,:) = 0._wp ; wfx_ice_sub(:,:) = 0._wp
420      wfx_snw_sni(:,:) = 0._wp 
421      ! MV MP 2016
422      wfx_pnd(:,:) = 0._wp
423      ! END MV MP 2016
424
425      hfx_thd(:,:) = 0._wp   ;
426      hfx_snw(:,:) = 0._wp   ;   hfx_opw(:,:) = 0._wp
427      hfx_bog(:,:) = 0._wp   ;   hfx_dyn(:,:) = 0._wp
428      hfx_bom(:,:) = 0._wp   ;   hfx_sum(:,:) = 0._wp
429      hfx_res(:,:) = 0._wp   ;   hfx_sub(:,:) = 0._wp
430      hfx_spr(:,:) = 0._wp   ;   hfx_dif(:,:) = 0._wp
431      hfx_err(:,:) = 0._wp   ;   hfx_err_rem(:,:) = 0._wp
432      hfx_err_dif(:,:) = 0._wp
433      wfx_err_sub(:,:) = 0._wp
434      !
435      afx_tot(:,:) = 0._wp   ;
436      !
437      diag_heat(:,:) = 0._wp ;   diag_smvi(:,:) = 0._wp
438      diag_vice(:,:) = 0._wp ;   diag_vsnw(:,:) = 0._wp
439
440      ! SIMIP diagnostics
441      diag_fc_bo(:,:)    = 0._wp ; diag_fc_su(:,:)    = 0._wp
442
443      tau_icebfr(:,:) = 0._wp; ! landfast ice param only (clem: important to keep the init here)
[8321]444     
445   END SUBROUTINE ice_diag0
446
447#else
448   !!----------------------------------------------------------------------
449   !!   Default option           Dummy module      NO LIM 3.0 sea-ice model
450   !!----------------------------------------------------------------------
451CONTAINS
452   SUBROUTINE ice_stp ( kt, ksbc )     ! Dummy routine
453      INTEGER, INTENT(in) ::   kt, ksbc
454      WRITE(*,*) 'ice_stp: You should not have seen this print! error?', kt
455   END SUBROUTINE ice_stp
456   SUBROUTINE ice_init                 ! Dummy routine
457   END SUBROUTINE ice_init
458#endif
459
460   !!======================================================================
461END MODULE icestp
Note: See TracBrowser for help on using the repository browser.