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.
Changeset 10332 for NEMO/trunk/src/ICE/icedyn_rhg_evp.F90 – NEMO

Ignore:
Timestamp:
2018-11-19T13:02:15+01:00 (5 years ago)
Author:
mathiot
Message:

Fix #2161

File:
1 edited

Legend:

Unmodified
Added
Removed
  • NEMO/trunk/src/ICE/icedyn_rhg_evp.F90

    r10069 r10332  
    2626   USE sbc_ice , ONLY : utau_ice, vtau_ice, snwice_mass, snwice_mass_b 
    2727   USE ice            ! sea-ice: ice variables 
     28   USE icevar         ! ice_var_sshdyn 
    2829   USE icedyn_rdgrft  ! sea-ice: ice strength 
    2930   USE bdy_oce , ONLY : ln_bdy  
     
    143144      REAL(wp), DIMENSION(jpi,jpj) ::   zs1, zs2, zs12                  ! stress tensor components 
    144145      REAL(wp), DIMENSION(jpi,jpj) ::   zu_ice, zv_ice, zresr           ! check convergence 
    145       REAL(wp), DIMENSION(jpi,jpj) ::   zpice                           ! array used for the calculation of ice surface slope: 
     146      REAL(wp), DIMENSION(jpi,jpj) ::   zssh_lead_m                     ! array used for the calculation of ice surface slope: 
    146147      !                                                                 !    ocean surface (ssh_m) if ice is not embedded 
    147148      !                                                                 !    ice top surface if ice is embedded    
     
    261262      !------------------------------------------------------------------------------! 
    262263 
    263       IF( ln_ice_embd ) THEN             !== embedded sea ice: compute representative ice top surface ==! 
    264          !                                             
    265          ! average interpolation coeff as used in dynspg = (1/nn_fsbc)   * {SUM[n/nn_fsbc], n=0,nn_fsbc-1} 
    266          !                                               = (1/nn_fsbc)^2 * {SUM[n]        , n=0,nn_fsbc-1} 
    267          zintn = REAL( nn_fsbc - 1 ) / REAL( nn_fsbc ) * 0.5_wp      
    268          ! 
    269          ! average interpolation coeff as used in dynspg = (1/nn_fsbc)   *    {SUM[1-n/nn_fsbc], n=0,nn_fsbc-1} 
    270          !                                               = (1/nn_fsbc)^2 * (nn_fsbc^2 - {SUM[n], n=0,nn_fsbc-1}) 
    271          zintb = REAL( nn_fsbc + 1 ) / REAL( nn_fsbc ) * 0.5_wp 
    272          ! 
    273          zpice(:,:) = ssh_m(:,:) + ( zintn * snwice_mass(:,:) + zintb * snwice_mass_b(:,:) ) * r1_rau0 
    274          ! 
    275       ELSE                                    !== non-embedded sea ice: use ocean surface for slope calculation ==! 
    276          zpice(:,:) = ssh_m(:,:) 
    277       ENDIF 
     264      !== embedded sea ice: compute representative ice top surface      ==! 
     265      !== non-embedded sea ice: use ocean surface for slope calculation ==! 
     266      zssh_lead_m(:,:) = ice_var_sshdyn( ssh_m, snwice_mass, snwice_mass_b) 
    278267 
    279268      DO jj = 2, jpjm1 
     
    313302 
    314303            ! Surface pressure gradient (- m*g*GRAD(ssh)) at U-V points 
    315             zspgU(ji,jj)    = - zmassU * grav * ( zpice(ji+1,jj) - zpice(ji,jj) ) * r1_e1u(ji,jj) 
    316             zspgV(ji,jj)    = - zmassV * grav * ( zpice(ji,jj+1) - zpice(ji,jj) ) * r1_e2v(ji,jj) 
     304            zspgU(ji,jj)    = - zmassU * grav * ( zssh_lead_m(ji+1,jj) - zssh_lead_m(ji,jj) ) * r1_e1u(ji,jj) 
     305            zspgV(ji,jj)    = - zmassV * grav * ( zssh_lead_m(ji,jj+1) - zssh_lead_m(ji,jj) ) * r1_e2v(ji,jj) 
    317306 
    318307            ! masks 
Note: See TracChangeset for help on using the changeset viewer.