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 6795 for branches/UKMO/dev_r5518_GO6_package/NEMOGCM/NEMO – NEMO

Ignore:
Timestamp:
2016-07-06T16:59:16+02:00 (8 years ago)
Author:
davestorkey
Message:

Merge in changes from 3.6 stable branch to rev6770. This update doesn't change results for standard GO6 configurations.
Custom merge into /branches/UKMO/dev_r5518_GO6_package/NEMOGCM: r6770 cf. r6692 of /branches/2015/nemo_v3_6_STABLE/NEMOGCM@6794

Location:
branches/UKMO/dev_r5518_GO6_package/NEMOGCM/NEMO
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • branches/UKMO/dev_r5518_GO6_package/NEMOGCM/NEMO/LIM_SRC_3/limistate.F90

    r6498 r6795  
    246246               ztest_1 = 1 
    247247            ELSE  
    248               ! this write is useful 
    249               IF(lwp)  WRITE(numout,*) ' * TEST1 AREA NOT CONSERVED *** zA_cons = ', zA_cons,' zat_i_ini = ',zat_i_ini(i_hemis)  
    250248               ztest_1 = 0 
    251249            ENDIF 
     
    258256               ztest_2 = 1 
    259257            ELSE 
    260               ! this write is useful 
    261               IF(lwp)  WRITE(numout,*) ' * TEST2 VOLUME NOT CONSERVED *** zV_cons = ', zV_cons, & 
    262                             ' zvt_i_ini = ', zvt_i_ini(i_hemis) 
    263258               ztest_2 = 0 
    264259            ENDIF 
     
    268263               ztest_3 = 1 
    269264            ELSE 
    270                ! this write is useful 
    271                IF(lwp) WRITE(numout,*) ' * TEST 3 THICKNESS OF THE LAST CATEGORY OUT OF BOUNDS *** zh_i_ini(i_fill,i_hemis) = ', & 
    272                zh_i_ini(i_fill,i_hemis), ' hi_max(jpl-1) = ', hi_max(i_fill-1) 
    273265               ztest_3 = 0 
    274266            ENDIF 
     
    278270            DO jl = 1, jpl 
    279271               IF ( za_i_ini(jl,i_hemis) .LT. 0._wp ) THEN  
    280                   ! this write is useful 
    281                   IF(lwp) WRITE(numout,*) ' * TEST 4 POSITIVITY NOT OK FOR CAT ', jl, ' WITH A = ', za_i_ini(jl,i_hemis) 
    282272                  ztest_4 = 0 
    283273               ENDIF 
  • branches/UKMO/dev_r5518_GO6_package/NEMOGCM/NEMO/OPA_SRC/DYN/dynzdf_imp.F90

    r6486 r6795  
    323323            ze3va =  ( 1._wp - r_vvl ) * fse3v_n(ji,jj,1) + r_vvl   * fse3v_a(ji,jj,1)  
    324324            va(ji,jj,1) = va(ji,jj,1) + p2dt * 0.5_wp * ( vtau_b(ji,jj) + vtau(ji,jj) )   & 
    325                &                                      / ( ze3va * rau0 )  
     325               &                                      / ( ze3va * rau0 ) * vmask(ji,jj,1) 
    326326#else 
    327327            va(ji,jj,1) = vb(ji,jj,1) & 
    328328               &                   + p2dt *(va(ji,jj,1) +  0.5_wp * ( vtau_b(ji,jj) + vtau(ji,jj) )   & 
    329                &                                                       / ( fse3v(ji,jj,1) * rau0     ) ) 
     329               &                                      / ( fse3v(ji,jj,1) * rau0     ) * vmask(ji,jj,1) ) 
    330330#endif 
    331331         END DO 
  • branches/UKMO/dev_r5518_GO6_package/NEMOGCM/NEMO/OPA_SRC/SBC/sbccpl.F90

    r6755 r6795  
    16181618      !!             ***  ROUTINE sbc_cpl_ice_flx  *** 
    16191619      !! 
    1620       !! ** Purpose :   provide the heat and freshwater fluxes of the  
    1621       !!              ocean-ice system. 
     1620      !! ** Purpose :   provide the heat and freshwater fluxes of the ocean-ice system 
    16221621      !! 
    16231622      !! ** Method  :   transform the fields received from the atmosphere into 
    16241623      !!             surface heat and fresh water boundary condition for the  
    16251624      !!             ice-ocean system. The following fields are provided: 
    1626       !!              * total non solar, solar and freshwater fluxes (qns_tot,  
     1625      !!               * total non solar, solar and freshwater fluxes (qns_tot,  
    16271626      !!             qsr_tot and emp_tot) (total means weighted ice-ocean flux) 
    16281627      !!             NB: emp_tot include runoffs and calving. 
    1629       !!              * fluxes over ice (qns_ice, qsr_ice, emp_ice) where 
     1628      !!               * fluxes over ice (qns_ice, qsr_ice, emp_ice) where 
    16301629      !!             emp_ice = sublimation - solid precipitation as liquid 
    16311630      !!             precipitation are re-routed directly to the ocean and  
    1632       !!             runoffs and calving directly enter the ocean. 
    1633       !!              * solid precipitation (sprecip), used to add to qns_tot  
     1631      !!             calving directly enter the ocean (runoffs are read but included in trasbc.F90) 
     1632      !!               * solid precipitation (sprecip), used to add to qns_tot  
    16341633      !!             the heat lost associated to melting solid precipitation 
    16351634      !!             over the ocean fraction. 
    1636       !!       ===>> CAUTION here this changes the net heat flux received from 
    1637       !!             the atmosphere 
    1638       !! 
    1639       !!                  - the fluxes have been separated from the stress as 
    1640       !!                 (a) they are updated at each ice time step compare to 
    1641       !!                 an update at each coupled time step for the stress, and 
    1642       !!                 (b) the conservative computation of the fluxes over the 
    1643       !!                 sea-ice area requires the knowledge of the ice fraction 
    1644       !!                 after the ice advection and before the ice thermodynamics, 
    1645       !!                 so that the stress is updated before the ice dynamics 
    1646       !!                 while the fluxes are updated after it. 
     1635      !!               * heat content of rain, snow and evap can also be provided, 
     1636      !!             otherwise heat flux associated with these mass flux are 
     1637      !!             guessed (qemp_oce, qemp_ice) 
     1638      !! 
     1639      !!             - the fluxes have been separated from the stress as 
     1640      !!               (a) they are updated at each ice time step compare to 
     1641      !!               an update at each coupled time step for the stress, and 
     1642      !!               (b) the conservative computation of the fluxes over the 
     1643      !!               sea-ice area requires the knowledge of the ice fraction 
     1644      !!               after the ice advection and before the ice thermodynamics, 
     1645      !!               so that the stress is updated before the ice dynamics 
     1646      !!               while the fluxes are updated after it. 
     1647      !! 
     1648      !! ** Details 
     1649      !!             qns_tot = pfrld * qns_oce + ( 1 - pfrld ) * qns_ice   => provided 
     1650      !!                     + qemp_oce + qemp_ice                         => recalculated and added up to qns 
     1651      !! 
     1652      !!             qsr_tot = pfrld * qsr_oce + ( 1 - pfrld ) * qsr_ice   => provided 
     1653      !! 
     1654      !!             emp_tot = emp_oce + emp_ice                           => calving is provided and added to emp_tot (and emp_oce) 
     1655      !!                                                                      river runoff (rnf) is provided but not included here 
    16471656      !! 
    16481657      !! ** Action  :   update at each nf_ice time step: 
    16491658      !!                   qns_tot, qsr_tot  non-solar and solar total heat fluxes 
    16501659      !!                   qns_ice, qsr_ice  non-solar and solar heat fluxes over the ice 
    1651       !!                   emp_tot            total evaporation - precipitation(liquid and solid) (-runoff)(-calving) 
    1652       !!                   emp_ice            ice sublimation - solid precipitation over the ice 
    1653       !!                   dqns_ice           d(non-solar heat flux)/d(Temperature) over the ice 
    1654       !!                   sprecip             solid precipitation over the ocean   
     1660      !!                   emp_tot           total evaporation - precipitation(liquid and solid) (-calving) 
     1661      !!                   emp_ice           ice sublimation - solid precipitation over the ice 
     1662      !!                   dqns_ice          d(non-solar heat flux)/d(Temperature) over the ice 
     1663      !!                   sprecip           solid precipitation over the ocean   
    16551664      !!---------------------------------------------------------------------- 
    16561665      REAL(wp), INTENT(in   ), DIMENSION(:,:)   ::   p_frld     ! lead fraction                [0 to 1] 
     
    16621671      INTEGER ::   jl         ! dummy loop index 
    16631672      REAL(wp), POINTER, DIMENSION(:,:  ) ::   zcptn, ztmp, zicefr, zmsk, zsnw 
    1664       REAL(wp), POINTER, DIMENSION(:,:  ) ::   zemp_tot, zemp_ice, zemp_oce, ztprecip, zsprecip, zevap, zevap_ice, zdevap_ice 
     1673      REAL(wp), POINTER, DIMENSION(:,:  ) ::   zemp_tot, zemp_ice, zemp_oce, ztprecip, zsprecip, zevap_oce, zevap_ice, zdevap_ice 
    16651674      REAL(wp), POINTER, DIMENSION(:,:  ) ::   zqns_tot, zqns_oce, zqsr_tot, zqsr_oce, zqprec_ice, zqemp_oce, zqemp_ice 
    16661675      REAL(wp), POINTER, DIMENSION(:,:,:) ::   zqns_ice, zqsr_ice, zdqns_ice, zqevap_ice 
     
    16701679      ! 
    16711680      CALL wrk_alloc( jpi,jpj,     zcptn, ztmp, zicefr, zmsk, zsnw ) 
    1672       CALL wrk_alloc( jpi,jpj,     zemp_tot, zemp_ice, zemp_oce, ztprecip, zsprecip, zevap, zevap_ice, zdevap_ice ) 
     1681      CALL wrk_alloc( jpi,jpj,     zemp_tot, zemp_ice, zemp_oce, ztprecip, zsprecip, zevap_oce, zevap_ice, zdevap_ice ) 
    16731682      CALL wrk_alloc( jpi,jpj,     zqns_tot, zqns_oce, zqsr_tot, zqsr_oce, zqprec_ice, zqemp_oce, zqemp_ice ) 
    16741683      CALL wrk_alloc( jpi,jpj,jpl, zqns_ice, zqsr_ice, zdqns_ice, zqevap_ice ) 
     
    16791688      ! 
    16801689      !                                                      ! ========================= ! 
    1681       !                                                      !    freshwater budget      !   (emp) 
     1690      !                                                      !    freshwater budget      !   (emp_tot) 
    16821691      !                                                      ! ========================= ! 
    16831692      ! 
    1684       !                                                           ! total Precipitation - total Evaporation (emp_tot) 
    1685       !                                                           ! solid precipitation - sublimation       (emp_ice) 
    1686       !                                                           ! solid Precipitation                     (sprecip) 
    1687       !                                                           ! liquid + solid Precipitation            (tprecip) 
     1693      !                                                           ! solid Precipitation                                (sprecip) 
     1694      !                                                           ! liquid + solid Precipitation                       (tprecip) 
     1695      !                                                           ! total Evaporation - total Precipitation            (emp_tot) 
     1696      !                                                           ! sublimation - solid precipitation (cell average)   (emp_ice) 
    16881697      SELECT CASE( TRIM( sn_rcv_emp%cldes ) ) 
    16891698      CASE( 'conservative'  )   ! received fields: jpr_rain, jpr_snow, jpr_ievp, jpr_tevp 
     
    17171726         ENDIF 
    17181727#else          
    1719          zemp_ice(:,:) = frcv(jpr_ievp)%z3(:,:,1) - frcv(jpr_snow)%z3(:,:,1) 
     1728         zemp_ice(:,:) = ( frcv(jpr_ievp)%z3(:,:,1) - frcv(jpr_snow)%z3(:,:,1) ) * zicefr(:,:) 
    17201729#endif                   
    17211730            CALL iom_put( 'rain'         , frcv(jpr_rain)%z3(:,:,1)              )   ! liquid precipitation  
    17221731         IF( iom_use('hflx_rain_cea') )   & 
    1723             CALL iom_put( 'hflx_rain_cea', frcv(jpr_rain)%z3(:,:,1) * zcptn(:,:) )   ! heat flux from liq. precip.  
    1724          IF( iom_use('evap_ao_cea') .OR. iom_use('hflx_evap_cea') )   & 
    1725             ztmp(:,:) = frcv(jpr_tevp)%z3(:,:,1) - frcv(jpr_ievp)%z3(:,:,1) * zicefr(:,:) 
     1732            &  CALL iom_put( 'hflx_rain_cea',   frcv(jpr_rain)%z3(:,:,1) * zcptn(:,:)                                            )  ! heat flux from liq. precip.  
    17261733         IF( iom_use('evap_ao_cea'  ) )   & 
    1727             CALL iom_put( 'evap_ao_cea'  , ztmp                   )   ! ice-free oce evap (cell average) 
     1734            &  CALL iom_put( 'evap_ao_cea'  ,   frcv(jpr_tevp)%z3(:,:,1) - frcv(jpr_ievp)%z3(:,:,1) * zicefr(:,:)                )  ! ice-free oce evap (cell average) 
    17281735         IF( iom_use('hflx_evap_cea') )   & 
    1729             CALL iom_put( 'hflx_evap_cea', ztmp(:,:) * zcptn(:,:) )   ! heat flux from from evap (cell average) 
    1730       CASE( 'oce and ice'   )   ! received fields: jpr_sbpr, jpr_semp, jpr_oemp, jpr_ievp 
     1736            &  CALL iom_put( 'hflx_evap_cea', ( frcv(jpr_tevp)%z3(:,:,1) - frcv(jpr_ievp)%z3(:,:,1) * zicefr(:,:) ) * zcptn(:,:) )  ! heat flux from from evap (cell average) 
     1737      CASE( 'oce and ice' )   ! received fields: jpr_sbpr, jpr_semp, jpr_oemp, jpr_ievp 
    17311738         zemp_tot(:,:) = p_frld(:,:) * frcv(jpr_oemp)%z3(:,:,1) + zicefr(:,:) * frcv(jpr_sbpr)%z3(:,:,1) 
    1732          zemp_ice(:,:) = frcv(jpr_semp)%z3(:,:,1) 
     1739         zemp_ice(:,:) = frcv(jpr_semp)%z3(:,:,1) * zicefr(:,:) 
    17331740         zsprecip(:,:) = frcv(jpr_ievp)%z3(:,:,1) - frcv(jpr_semp)%z3(:,:,1) 
    17341741         ztprecip(:,:) = frcv(jpr_semp)%z3(:,:,1) - frcv(jpr_sbpr)%z3(:,:,1) + zsprecip(:,:) 
     
    17361743 
    17371744#if defined key_lim3 
    1738       ! zsnw = snow percentage over ice after wind blowing 
    1739       zsnw(:,:) = 0._wp 
    1740       CALL lim_thd_snwblow( p_frld, zsnw ) 
     1745      ! zsnw = snow fraction over ice after wind blowing 
     1746      zsnw(:,:) = 0._wp  ;  CALL lim_thd_snwblow( p_frld, zsnw ) 
    17411747       
    1742       ! --- evaporation (kg/m2/s) --- ! 
     1748      ! --- evaporation minus precipitation corrected (because of wind blowing on snow) --- ! 
     1749      zemp_ice(:,:) = zemp_ice(:,:) + zsprecip(:,:) * ( zicefr(:,:) - zsnw(:,:) )  ! emp_ice = A * sublimation - zsnw * sprecip 
     1750      zemp_oce(:,:) = zemp_tot(:,:) - zemp_ice(:,:)                                ! emp_oce = emp_tot - emp_ice 
     1751 
     1752      ! --- evaporation over ocean (used later for qemp) --- ! 
     1753      zevap_oce(:,:) = frcv(jpr_tevp)%z3(:,:,1) - frcv(jpr_ievp)%z3(:,:,1) * zicefr(:,:) 
     1754 
     1755      ! --- evaporation over ice (kg/m2/s) --- ! 
    17431756      zevap_ice(:,:) = frcv(jpr_ievp)%z3(:,:,1) 
    17441757      ! since the sensitivity of evap to temperature (devap/dT) is not prescribed by the atmosphere, we set it to 0 
     
    17461759      zdevap_ice(:,:) = 0._wp 
    17471760       
    1748       ! --- evaporation minus precipitation corrected for the effect of wind blowing on snow --- ! 
    1749       zemp_oce(:,:) = zemp_tot(:,:) - zemp_ice(:,:) - zsprecip * (1._wp - zsnw) 
    1750       zemp_ice(:,:) = zemp_ice(:,:) + zsprecip * (1._wp - zsnw)           
    1751  
    1752       ! Sublimation over sea-ice (cell average) 
    1753       IF( iom_use('subl_ai_cea') )  CALL iom_put( 'subl_ai_cea', zevap_ice(:,:) * zicefr(:,:) ) 
    1754       ! runoffs and calving (put in emp_tot) 
     1761      ! --- runoffs (included in emp later on) --- ! 
    17551762      IF( srcv(jpr_rnf)%laction )   rnf(:,:) = frcv(jpr_rnf)%z3(:,:,1) 
     1763 
     1764      ! --- calving (put in emp_tot and emp_oce) --- ! 
    17561765      IF( srcv(jpr_cal)%laction ) THEN  
    17571766         zemp_tot(:,:) = zemp_tot(:,:) - frcv(jpr_cal)%z3(:,:,1) 
     1767         zemp_oce(:,:) = zemp_oce(:,:) - frcv(jpr_cal)%z3(:,:,1) 
    17581768         CALL iom_put( 'calving_cea', frcv(jpr_cal)%z3(:,:,1) ) 
    17591769      ENDIF 
     
    17811791      ENDIF 
    17821792 
    1783                                      CALL iom_put( 'snowpre'    , sprecip                         )  ! Snow 
    1784       IF( iom_use('snow_ao_cea') )   CALL iom_put( 'snow_ao_cea', sprecip(:,:) * ( 1._wp - zsnw ) )  ! Snow over ice-free ocean  (cell average) 
    1785       IF( iom_use('snow_ai_cea') )   CALL iom_put( 'snow_ai_cea', sprecip(:,:) *           zsnw   )  ! Snow over sea-ice         (cell average)     
     1793      IF( iom_use('subl_ai_cea') )   CALL iom_put( 'subl_ai_cea', zevap_ice(:,:) * zicefr(:,:)         )  ! Sublimation over sea-ice (cell average) 
     1794                                     CALL iom_put( 'snowpre'    , sprecip(:,:)                         )  ! Snow 
     1795      IF( iom_use('snow_ao_cea') )   CALL iom_put( 'snow_ao_cea', sprecip(:,:) * ( 1._wp - zsnw(:,:) ) )  ! Snow over ice-free ocean  (cell average) 
     1796      IF( iom_use('snow_ai_cea') )   CALL iom_put( 'snow_ai_cea', sprecip(:,:) *           zsnw(:,:)   )  ! Snow over sea-ice         (cell average) 
    17861797#else 
    1787       ! Sublimation over sea-ice (cell average) 
    1788       IF( iom_use('subl_ai_cea') )  CALL iom_put( 'subl_ai_cea', frcv(jpr_ievp)%z3(:,:,1) * zicefr(:,:) ) 
    17891798      ! runoffs and calving (put in emp_tot) 
    17901799      IF( srcv(jpr_rnf)%laction )   rnf(:,:) = frcv(jpr_rnf)%z3(:,:,1) 
     
    18061815      ENDIF 
    18071816 
    1808          CALL iom_put( 'snowpre'    , sprecip                                )   ! Snow 
    1809       IF( iom_use('snow_ao_cea') )   & 
    1810          CALL iom_put( 'snow_ao_cea', sprecip(:,:) * p_frld(:,:)             )   ! Snow        over ice-free ocean  (cell average) 
    1811       IF( iom_use('snow_ai_cea') )   & 
    1812          CALL iom_put( 'snow_ai_cea', sprecip(:,:) * zicefr(:,:)             )   ! Snow        over sea-ice         (cell average) 
     1817      IF( iom_use('subl_ai_cea') )  CALL iom_put( 'subl_ai_cea', frcv(jpr_ievp)%z3(:,:,1) * zicefr(:,:) )  ! Sublimation over sea-ice (cell average) 
     1818                                    CALL iom_put( 'snowpre'    , sprecip(:,:)               )   ! Snow 
     1819      IF( iom_use('snow_ao_cea') )  CALL iom_put( 'snow_ao_cea', sprecip(:,:) * p_frld(:,:) )   ! Snow over ice-free ocean  (cell average) 
     1820      IF( iom_use('snow_ai_cea') )  CALL iom_put( 'snow_ai_cea', sprecip(:,:) * zicefr(:,:) )   ! Snow over sea-ice         (cell average) 
    18131821#endif 
    18141822 
     
    18161824      SELECT CASE( TRIM( sn_rcv_qns%cldes ) )                !   non solar heat fluxes   !   (qns) 
    18171825      !                                                      ! ========================= ! 
    1818       CASE( 'oce only' )                                     ! the required field is directly provided 
    1819          zqns_tot(:,:  ) = frcv(jpr_qnsoce)%z3(:,:,1) 
    1820       CASE( 'conservative' )                                      ! the required fields are directly provided 
    1821          zqns_tot(:,:  ) = frcv(jpr_qnsmix)%z3(:,:,1) 
     1826      CASE( 'oce only' )         ! the required field is directly provided 
     1827         zqns_tot(:,:) = frcv(jpr_qnsoce)%z3(:,:,1) 
     1828      CASE( 'conservative' )     ! the required fields are directly provided 
     1829         zqns_tot(:,:) = frcv(jpr_qnsmix)%z3(:,:,1) 
    18221830         IF ( TRIM(sn_rcv_qns%clcat) == 'yes' ) THEN 
    18231831            zqns_ice(:,:,1:jpl) = frcv(jpr_qnsice)%z3(:,:,1:jpl) 
    18241832         ELSE 
    1825             ! Set all category values equal for the moment 
    18261833            DO jl=1,jpl 
    1827                zqns_ice(:,:,jl) = frcv(jpr_qnsice)%z3(:,:,1) 
     1834               zqns_ice(:,:,jl) = frcv(jpr_qnsice)%z3(:,:,1) ! Set all category values equal 
    18281835            ENDDO 
    18291836         ENDIF 
    1830       CASE( 'oce and ice' )       ! the total flux is computed from ocean and ice fluxes 
    1831          zqns_tot(:,:  ) =  p_frld(:,:) * frcv(jpr_qnsoce)%z3(:,:,1) 
     1837      CASE( 'oce and ice' )      ! the total flux is computed from ocean and ice fluxes 
     1838         zqns_tot(:,:) =  p_frld(:,:) * frcv(jpr_qnsoce)%z3(:,:,1) 
    18321839         IF ( TRIM(sn_rcv_qns%clcat) == 'yes' ) THEN 
    18331840            DO jl=1,jpl 
     
    18361843            ENDDO 
    18371844         ELSE 
    1838             qns_tot(:,:   ) = qns_tot(:,:) + zicefr(:,:) * frcv(jpr_qnsice)%z3(:,:,1) 
     1845            qns_tot(:,:) = qns_tot(:,:) + zicefr(:,:) * frcv(jpr_qnsice)%z3(:,:,1) 
    18391846            DO jl=1,jpl 
    18401847               zqns_tot(:,:   ) = zqns_tot(:,:) + zicefr(:,:) * frcv(jpr_qnsice)%z3(:,:,1) 
     
    18421849            ENDDO 
    18431850         ENDIF 
    1844       CASE( 'mixed oce-ice' )     ! the ice flux is cumputed from the total flux, the SST and ice informations 
     1851      CASE( 'mixed oce-ice' )    ! the ice flux is cumputed from the total flux, the SST and ice informations 
    18451852! ** NEED TO SORT OUT HOW THIS SHOULD WORK IN THE MULTI-CATEGORY CASE - CURRENTLY NOT ALLOWED WHEN INTERFACE INITIALISED ** 
    18461853         zqns_tot(:,:  ) = frcv(jpr_qnsmix)%z3(:,:,1) 
    18471854         zqns_ice(:,:,1) = frcv(jpr_qnsmix)%z3(:,:,1)    & 
    18481855            &            + frcv(jpr_dqnsdt)%z3(:,:,1) * ( pist(:,:,1) - ( (rt0 + psst(:,:  ) ) * p_frld(:,:)   & 
    1849             &                                                   +          pist(:,:,1)  * zicefr(:,:) ) ) 
     1856            &                                           + pist(:,:,1) * zicefr(:,:) ) ) 
    18501857      END SELECT 
    18511858!!gm 
     
    18571864!! similar job should be done for snow and precipitation temperature 
    18581865      !                                      
    1859       IF( srcv(jpr_cal)%laction ) THEN                            ! Iceberg melting  
    1860          ztmp(:,:) = frcv(jpr_cal)%z3(:,:,1) * lfus               ! add the latent heat of iceberg melting  
    1861          zqns_tot(:,:) = zqns_tot(:,:) - ztmp(:,:) 
    1862          IF( iom_use('hflx_cal_cea') )   & 
    1863             CALL iom_put( 'hflx_cal_cea', ztmp + frcv(jpr_cal)%z3(:,:,1) * zcptn(:,:) )   ! heat flux from calving 
    1864       ENDIF 
    1865  
    1866       ztmp(:,:) = p_frld(:,:) * zsprecip(:,:) * lfus 
    1867       IF( iom_use('hflx_snow_cea') )    CALL iom_put( 'hflx_snow_cea', ztmp + sprecip(:,:) * zcptn(:,:) )   ! heat flux from snow (cell average) 
     1866      IF( srcv(jpr_cal)%laction ) THEN   ! Iceberg melting  
     1867         zqns_tot(:,:) = zqns_tot(:,:) - frcv(jpr_cal)%z3(:,:,1) * lfus  ! add the latent heat of iceberg melting 
     1868                                                                         ! we suppose it melts at 0deg, though it should be temp. of surrounding ocean 
     1869         IF( iom_use('hflx_cal_cea') )   CALL iom_put( 'hflx_cal_cea', - frcv(jpr_cal)%z3(:,:,1) * lfus )   ! heat flux from calving 
     1870      ENDIF 
    18681871 
    18691872#if defined key_lim3       
    1870       ! --- evaporation --- ! 
    1871       zevap(:,:) = zemp_tot(:,:) + ztprecip(:,:) ! evaporation over ocean 
    1872  
    18731873      ! --- non solar flux over ocean --- ! 
    18741874      !         note: p_frld cannot be = 0 since we limit the ice concentration to amax 
     
    18771877 
    18781878      ! --- heat flux associated with emp (W/m2) --- ! 
    1879       zqemp_oce(:,:) = -      zevap(:,:)                   * p_frld(:,:)      *   zcptn(:,:)   &      ! evap 
    1880          &             + ( ztprecip(:,:) - zsprecip(:,:) )                    *   zcptn(:,:)   &      ! liquid precip 
    1881          &             +   zsprecip(:,:)                   * ( 1._wp - zsnw ) * ( zcptn(:,:) - lfus ) ! solid precip over ocean 
     1879      zqemp_oce(:,:) = -  zevap_oce(:,:)                                      *   zcptn(:,:)   &       ! evap 
     1880         &             + ( ztprecip(:,:) - zsprecip(:,:) )                    *   zcptn(:,:)   &       ! liquid precip 
     1881         &             +   zsprecip(:,:)                   * ( 1._wp - zsnw ) * ( zcptn(:,:) - lfus )  ! solid precip over ocean + snow melting 
    18821882!      zqemp_ice(:,:) = -   frcv(jpr_ievp)%z3(:,:,1)        * zicefr(:,:)      *   zcptn(:,:)   &      ! ice evap 
    18831883!         &             +   zsprecip(:,:)                   * zsnw             * ( zcptn(:,:) - lfus ) ! solid precip over ice 
    18841884      zqemp_ice(:,:) =      zsprecip(:,:)                   * zsnw             * ( zcptn(:,:) - lfus ) ! solid precip over ice (only) 
    1885                                                                                                        ! qevap_ice=0 since we consider Tice=0°C 
     1885                                                                                                       ! qevap_ice=0 since we consider Tice=0degC 
    18861886       
    1887       ! --- heat content of precip over ice in J/m3 (to be used in 1D-thermo) --- ! 
     1887      ! --- enthalpy of snow precip over ice in J/m3 (to be used in 1D-thermo) --- ! 
    18881888      zqprec_ice(:,:) = rhosn * ( zcptn(:,:) - lfus ) 
    18891889 
    18901890      ! --- heat content of evap over ice in W/m2 (to be used in 1D-thermo) --- ! 
    18911891      DO jl = 1, jpl 
    1892          zqevap_ice(:,:,jl) = 0._wp ! should be -evap * ( ( Tice - rt0 ) * cpic ) but we do not have Tice, so we consider Tice=0°C 
     1892         zqevap_ice(:,:,jl) = 0._wp ! should be -evap * ( ( Tice - rt0 ) * cpic ) but we do not have Tice, so we consider Tice=0degC 
    18931893      END DO 
    18941894 
     
    19161916         qemp_ice (:,:  ) = zqemp_ice (:,:  ) 
    19171917      ENDIF 
     1918 
     1919      !! clem: we should output qemp_oce and qemp_ice (at least) 
     1920      IF( iom_use('hflx_snow_cea') )   CALL iom_put( 'hflx_snow_cea', sprecip(:,:) * ( zcptn(:,:) - Lfus ) )   ! heat flux from snow (cell average) 
     1921      !! these diags are not outputed yet 
     1922!!      IF( iom_use('hflx_rain_cea') )   CALL iom_put( 'hflx_rain_cea', ( tprecip(:,:) - sprecip(:,:) ) * zcptn(:,:) )   ! heat flux from rain (cell average) 
     1923!!      IF( iom_use('hflx_snow_ao_cea') ) CALL iom_put( 'hflx_snow_ao_cea', sprecip(:,:) * ( zcptn(:,:) - Lfus ) * (1._wp - zsnw(:,:)) ) ! heat flux from snow (cell average) 
     1924!!      IF( iom_use('hflx_snow_ai_cea') ) CALL iom_put( 'hflx_snow_ai_cea', sprecip(:,:) * ( zcptn(:,:) - Lfus ) * zsnw(:,:) ) ! heat flux from snow (cell average) 
     1925 
    19181926#else 
    19191927      ! clem: this formulation is certainly wrong... but better than it was... 
     
    19211929         &          - ztmp(:,:)                           &            ! remove the latent heat flux of solid precip. melting 
    19221930         &          - (  zemp_tot(:,:)                    &            ! remove the heat content of mass flux (assumed to be at SST) 
    1923          &             - zemp_ice(:,:) * zicefr(:,:)  ) * zcptn(:,:)  
     1931         &             - zemp_ice(:,:) ) * zcptn(:,:)  
    19241932 
    19251933     IF( ln_mixcpl ) THEN 
     
    20412049 
    20422050      CALL wrk_dealloc( jpi,jpj,     zcptn, ztmp, zicefr, zmsk, zsnw ) 
    2043       CALL wrk_dealloc( jpi,jpj,     zemp_tot, zemp_ice, zemp_oce, ztprecip, zsprecip, zevap, zevap_ice, zdevap_ice ) 
     2051      CALL wrk_dealloc( jpi,jpj,     zemp_tot, zemp_ice, zemp_oce, ztprecip, zsprecip, zevap_oce, zevap_ice, zdevap_ice ) 
    20442052      CALL wrk_dealloc( jpi,jpj,     zqns_tot, zqns_oce, zqsr_tot, zqsr_oce, zqprec_ice, zqemp_oce, zqemp_ice ) 
    20452053      CALL wrk_dealloc( jpi,jpj,jpl, zqns_ice, zqsr_ice, zdqns_ice, zqevap_ice ) 
  • branches/UKMO/dev_r5518_GO6_package/NEMOGCM/NEMO/OPA_SRC/TRA/traadv_tvd.F90

    r6793 r6795  
    469469         ! 
    470470         ztrs(:,:,:,1) = ptb(:,:,:,jn) 
     471         ztrs(:,:,1,2) = ptb(:,:,1,jn) 
     472         ztrs(:,:,1,3) = ptb(:,:,1,jn) 
    471473         zwzts(:,:,:) = 0._wp 
    472474 
Note: See TracChangeset for help on using the changeset viewer.