MODULE limsbc_2 !!====================================================================== !! *** MODULE limsbc_2 *** !! computation of the flux at the sea ice/ocean interface !!====================================================================== !! History : 00-01 (H. Goosse) Original code !! 02-07 (C. Ethe, G. Madec) re-writing F90 !! 06-07 (G. Madec) surface module !!---------------------------------------------------------------------- #if defined key_lim2 !!---------------------------------------------------------------------- !! 'key_lim2' LIM 2.0 sea-ice model !!---------------------------------------------------------------------- !!---------------------------------------------------------------------- !! lim_sbc_2 : flux at the ice / ocean interface !!---------------------------------------------------------------------- USE par_oce ! ocean parameters USE dom_oce ! ocean domain USE sbc_ice ! surface boundary condition USE sbc_oce ! surface boundary condition USE phycst ! physical constants USE ice_oce ! sea-ice variable USE ice_2 ! LIM sea-ice variables USE iceini_2 ! ??? USE dynspg_oce ! choice of the surface pressure gradient scheme USE lbclnk ! ocean lateral boundary condition USE in_out_manager ! I/O manager USE albedo ! albedo parameters USE prtctl ! Print control IMPLICIT NONE PRIVATE PUBLIC lim_sbc_2 ! called by sbc_ice_lim_2 REAL(wp) :: epsi16 = 1.e-16 ! constant values REAL(wp) :: rzero = 0.e0 REAL(wp) :: rone = 1.e0 !! * Substitutions # include "vectopt_loop_substitute.h90" !!---------------------------------------------------------------------- !! LIM 2.0, UCL-LOCEAN-IPSL (2006) !! $Id$ !! Software governed by the CeCILL licence (modipsl/doc/NEMO_CeCILL.txt) !!---------------------------------------------------------------------- CONTAINS SUBROUTINE lim_sbc_2( kt ) !!------------------------------------------------------------------- !! *** ROUTINE lim_sbc_2 *** !! !! ** Purpose : Update surface ocean boundary condition over areas !! that are at least partially covered by sea-ice !! !! ** Action : - comput. of the momentum, heat and freshwater/salt !! fluxes at the ice-ocean interface. !! - Update !! !! ** Outputs : - qsr : sea heat flux: solar !! - qns : sea heat flux: non solar !! - emp : freshwater budget: volume flux !! - emps : freshwater budget: concentration/dillution !! - utau : sea surface i-stress (ocean referential) !! - vtau : sea surface j-stress (ocean referential) !! - fr_i : ice fraction !! - tn_ice : sea-ice surface temperature !! - alb_ice : sea-ice alberdo (lk_cpl=T) !! !! References : Goosse, H. et al. 1996, Bul. Soc. Roy. Sc. Liege, 65, 87-90. !! Tartinville et al. 2001 Ocean Modelling, 3, 95-108. !!--------------------------------------------------------------------- INTEGER :: kt ! number of iteration !! INTEGER :: ji, jj ! dummy loop indices INTEGER :: ifvt, i1mfr, idfr ! some switches INTEGER :: iflt, ial, iadv, ifral, ifrdv REAL(wp) :: zqsr , zqns ! solar & non solar heat flux REAL(wp) :: zinda ! switch for testing the values of ice concentration REAL(wp) :: zfons ! salt exchanges at the ice/ocean interface REAL(wp) :: zemp ! freshwater exchanges at the ice/ocean interface REAL(wp) :: zfrldu, zfrldv ! lead fraction at U- & V-points REAL(wp) :: zutau , zvtau ! lead fraction at U- & V-points REAL(wp) :: zu_io , zv_io ! 2 components of the ice-ocean velocity #if defined key_coupled REAL(wp), DIMENSION(jpi,jpj) :: zalb ! albedo of ice under overcast sky REAL(wp), DIMENSION(jpi,jpj) :: zalbp ! albedo of ice under clear sky #endif REAL(wp) :: zsang, zmod, zfm REAL(wp), DIMENSION(jpi,jpj) :: ztio_u, ztio_v ! ocean stress below sea-ice !!--------------------------------------------------------------------- IF( kt == nit000 ) THEN IF(lwp) WRITE(numout,*) IF(lwp) WRITE(numout,*) 'lim_sbc_2 : LIM 2.0 sea-ice - surface boundary condition' IF(lwp) WRITE(numout,*) '~~~~~~~~~ ' ENDIF !------------------------------------------! ! heat flux at the ocean surface ! !------------------------------------------! !!gm !!gm CAUTION !!gm re-verifies the non solar expression, especially over open ocen !!gm DO jj = 1, jpj DO ji = 1, jpi zinda = 1.0 - MAX( rzero , SIGN( rone, - ( 1.0 - pfrld(ji,jj) ) ) ) ifvt = zinda * MAX( rzero , SIGN( rone, - phicif(ji,jj) ) ) i1mfr = 1.0 - MAX( rzero , SIGN( rone, - ( 1.0 - frld(ji,jj) ) ) ) idfr = 1.0 - MAX( rzero , SIGN( rone, frld(ji,jj) - pfrld(ji,jj) ) ) iflt = zinda * (1 - i1mfr) * (1 - ifvt ) ial = ifvt * i1mfr + ( 1 - ifvt ) * idfr iadv = ( 1 - i1mfr ) * zinda ifral = ( 1 - i1mfr * ( 1 - ial ) ) ifrdv = ( 1 - ifral * ( 1 - ial ) ) * iadv ! computation the solar flux at ocean surface zqsr = pfrld(ji,jj) * qsr(ji,jj) + ( 1. - pfrld(ji,jj) ) * fstric(ji,jj) ! computation the non solar heat flux at ocean surface zqns = - ( 1. - thcm(ji,jj) ) * zqsr & ! part of the solar energy used in leads & + iflt * ( fscmbq(ji,jj) + ffltbif(ji,jj) ) & & + ifral * ( ial * qcmif(ji,jj) + (1 - ial) * qldif(ji,jj) ) / rdt_ice & & + ifrdv * ( qfvbq(ji,jj) + qdtcn(ji,jj) ) / rdt_ice fsbbq(ji,jj) = ( 1.0 - ( ifvt + iflt ) ) * fscmbq(ji,jj) ! ??? qsr (ji,jj) = zqsr ! solar heat flux qns (ji,jj) = zqns - fdtcn(ji,jj) ! non solar heat flux END DO END DO !------------------------------------------! ! mass flux at the ocean surface ! !------------------------------------------! !!gm !!gm CAUTION !!gm re-verifies the emp & emps expression, especially the absence of 1-frld on zfm !!gm DO jj = 1, jpj DO ji = 1, jpi ! computing freshwater exchanges at the ice/ocean interface zemp = + emp(ji,jj) * frld(ji,jj) & ! e-p budget over open ocean fraction & - tprecip(ji,jj) * ( 1. - frld(ji,jj) ) & ! liquid precipitation reaches directly the ocean & + sprecip(ji,jj) * ( 1. - pfrld(ji,jj) ) & ! taking into account change in ice cover within the time step & + rdmsnif(ji,jj) / rdt_ice ! freshwaterflux due to snow melting ! ! ice-covered fraction: ! computing salt exchanges at the ice/ocean interface zfons = ( soce - sice ) * ( rdmicif(ji,jj) / rdt_ice ) ! converting the salt flux from ice to a freshwater flux from ocean zfm = zfons / ( sss_m(ji,jj) + epsi16 ) emps(ji,jj) = zemp + zfm ! surface ocean concentration/dilution effect (use on SSS evolution) emp (ji,jj) = zemp ! surface ocean volume flux (use on sea-surface height evolution) END DO END DO IF( lk_dynspg_rl ) emp (:,:) = emps(:,:) ! rigid-lid formulation : emp = emps !------------------------------------------! ! momentum flux at the ocean surface ! !------------------------------------------! IF ( ln_limdyn ) THEN ! Update the stress over ice-over area (only in ice-dynamic case) ! ! otherwise the atmosphere-ocean stress is used everywhere ! ... ice stress over ocean with a ice-ocean rotation angle (at I-point) !CDIR NOVERRCHK DO jj = 1, jpj !CDIR NOVERRCHK DO ji = 1, jpi ! ... change the cosinus angle sign in the south hemisphere zsang = SIGN(1.e0, gphif(ji,jj) ) * sangvg ! ... ice velocity relative to the ocean zu_io = ui_ice(ji,jj) - ui_oce(ji,jj) zv_io = vi_ice(ji,jj) - vi_oce(ji,jj) zmod = rhoco * SQRT( zu_io * zu_io + zv_io * zv_io ) ! ... ice stress over ocean with a ice-ocean rotation angle (at I-point) ztio_u(ji,jj) = zmod * ( cangvg * zu_io - zsang * zv_io ) ztio_v(ji,jj) = zmod * ( cangvg * zv_io + zsang * zu_io ) ! END DO END DO DO jj = 2, jpjm1 DO ji = fs_2, fs_jpim1 ! vertor opt. ! ... ice-cover wheighted ice-ocean stress at U and V-points (from I-point values) zutau = 0.5 * ( ztio_u(ji+1,jj) + ztio_u(ji+1,jj+1) ) zvtau = 0.5 * ( ztio_v(ji,jj+1) + ztio_v(ji+1,jj+1) ) ! ... open-ocean (lead) fraction at U- & V-points (from T-point values) zfrldu = 0.5 * ( frld (ji,jj) + frld (ji+1,jj ) ) zfrldv = 0.5 * ( frld (ji,jj) + frld (ji ,jj+1) ) ! update surface ocean stress utau(ji,jj) = zfrldu * utau(ji,jj) + ( 1. - zfrldu ) * zutau vtau(ji,jj) = zfrldv * vtau(ji,jj) + ( 1. - zfrldv ) * zvtau ! END DO END DO ! boundary condition on the stress (utau,vtau) CALL lbc_lnk( utau, 'U', -1. ) CALL lbc_lnk( vtau, 'V', -1. ) ENDIF !-----------------------------------------------! ! Storing the transmitted variables ! !-----------------------------------------------! fr_i (:,:) = 1.0 - frld(:,:) ! sea-ice fraction tn_ice(:,:) = sist(:,:) ! sea-ice surface temperature #if defined key_coupled !------------------------------------------------! ! Computation of snow/ice and ocean albedo ! !------------------------------------------------! zalb (:,:) = 0.e0 zalbp (:,:) = 0.e0 CALL albedo_ice( sist, hicif, hsnif, zalbp, zalb ) alb_ice(:,:) = 0.5 * zalbp(:,:) + 0.5 * zalb (:,:) ! Ice albedo (mean clear and overcast skys) #endif IF(ln_ctl) THEN CALL prt_ctl(tab2d_1=qsr , clinfo1=' lim_sbc: qsr : ', tab2d_2=qns , clinfo2=' qns : ') CALL prt_ctl(tab2d_1=emp , clinfo1=' lim_sbc: emp : ', tab2d_2=emps , clinfo2=' emps : ') CALL prt_ctl(tab2d_1=utau , clinfo1=' lim_sbc: utau : ', mask1=umask, & & tab2d_2=vtau , clinfo2=' vtau : ' , mask2=vmask ) CALL prt_ctl(tab2d_1=fr_i , clinfo1=' lim_sbc: fr_i : ', tab2d_2=tn_ice, clinfo2=' tn_ice : ') ENDIF END SUBROUTINE lim_sbc_2 #else !!---------------------------------------------------------------------- !! Default option : Dummy module NO LIM 2.0 sea-ice model !!---------------------------------------------------------------------- CONTAINS SUBROUTINE lim_sbc_2 ! Dummy routine END SUBROUTINE lim_sbc_2 #endif !!====================================================================== END MODULE limsbc_2