Changeset 9423


Ignore:
Timestamp:
2018-03-22T20:38:54+01:00 (2 years ago)
Author:
clem
Message:

small correction for the temperature diffusion when snow thickness is small

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2017/dev_merge_2017/NEMOGCM/NEMO/LIM_SRC_3/icethd_zdf_bl99.F90

    r9076 r9423  
    9595      REAL(wp) ::   ztsu_err  =  1.e-5_wp     ! range around which t_su is considered at 0C  
    9696      REAL(wp) ::   zdti_bnd  =  1.e-4_wp     ! maximal authorized error on temperature  
     97      REAL(wp) ::   zhs_min   =  0.01_wp      ! minimum snow thickness for conductivity calculation  
    9798      REAL(wp) ::   ztmelt_i                  ! ice melting temperature 
    9899      REAL(wp) ::   zdti_max                  ! current maximal error on temperature  
     
    156157      END WHERE 
    157158      ! 
    158       WHERE( zh_s(1:npti) >= epsi10 )   ;   z1_h_s(1:npti) = 1._wp / zh_s(1:npti) 
     159      WHERE( zh_s(1:npti) > 0._wp   )       zh_s(1:npti) = MAX( zhs_min * r1_nlay_s, zh_s(1:npti) ) 
     160      ! 
     161      WHERE( zh_s(1:npti) > 0._wp   )   ;   z1_h_s(1:npti) = 1._wp / zh_s(1:npti) 
    159162      ELSEWHERE                         ;   z1_h_s(1:npti) = 0._wp 
    160163      END WHERE 
     
    182185         DO ji = 1, npti 
    183186            !                             ! radiation transmitted below the layer-th snow layer 
    184             zradtr_s(ji,jk) = zradtr_s(ji,0) * EXP( - zraext_s * zh_s(ji) * REAL(jk) ) 
     187            zradtr_s(ji,jk) = zradtr_s(ji,0) * EXP( - zraext_s * h_s_1d(ji) * r1_nlay_s * REAL(jk) ) 
    185188            !                             ! radiation absorbed by the layer-th snow layer 
    186189            zradab_s(ji,jk) = zradtr_s(ji,jk-1) - zradtr_s(ji,jk) 
     
    798801            !--- Snow-ice interfacial temperature (diagnostic SIMIP) 
    799802            zfac = rn_cnd_s * zh_i(ji) + ztcond_i(ji,1) * zh_s(ji) 
    800             IF( zh_s(ji) >= 1.e-3 .AND. zfac > epsi10 ) THEN 
     803            IF( h_s_1d(ji) >= zhs_min ) THEN 
    801804               t_si_1d(ji) = ( rn_cnd_s       * zh_i(ji) * t_s_1d(ji,1) +   & 
    802                   &            ztcond_i(ji,1) * zh_s(ji) * t_i_1d(ji,1) ) / zfac 
     805                  &            ztcond_i(ji,1) * zh_s(ji) * t_i_1d(ji,1) ) / MAX( epsi10, zfac ) 
    803806            ELSE 
    804807               t_si_1d(ji) = t_su_1d(ji) 
Note: See TracChangeset for help on using the changeset viewer.