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 9727 for NEMO/trunk/src/OCE/SBC/sbcblk.F90 – NEMO

Ignore:
Timestamp:
2018-06-01T18:52:17+02:00 (6 years ago)
Author:
mathiot
Message:

Fix for #2083 (surface flux not masked: bug if isf cavity) in trunk

File:
1 edited

Legend:

Unmodified
Added
Removed
  • NEMO/trunk/src/OCE/SBC/sbcblk.F90

    r9656 r9727  
    492492 
    493493      ! zqla used as temporary array, for rho*U (common term of bulk formulae): 
    494       zqla(:,:) = zrhoa(:,:) * zU_zu(:,:) 
     494      zqla(:,:) = zrhoa(:,:) * zU_zu(:,:) * tmask(:,:,1) 
    495495 
    496496      IF( ABS( rn_zu - rn_zqt) < 0.01_wp ) THEN 
     
    532532         &     * ( sf(jp_tair)%fnow(:,:,1) - rt0 ) * rcp                          & 
    533533         &     + sf(jp_snow)%fnow(:,:,1) * rn_pfac                                &   ! add solid  precip heat content at min(Tair,Tsnow) 
    534          &     * ( MIN( sf(jp_tair)%fnow(:,:,1), rt0_snow ) - rt0 ) * cpic * tmask(:,:,1) 
     534         &     * ( MIN( sf(jp_tair)%fnow(:,:,1), rt0_snow ) - rt0 ) * cpic 
     535      qns(:,:) = qns(:,:) * tmask(:,:,1) 
    535536      ! 
    536537#if defined key_si3 
     
    547548         CALL iom_put( "qsr_oce" ,   qsr  )                 ! output downward solar heat over the ocean 
    548549         CALL iom_put( "qt_oce"  ,   qns+qsr )              ! output total downward heat over the ocean 
    549          tprecip(:,:) = sf(jp_prec)%fnow(:,:,1) * rn_pfac   ! output total precipitation [kg/m2/s] 
    550          sprecip(:,:) = sf(jp_snow)%fnow(:,:,1) * rn_pfac   ! output solid precipitation [kg/m2/s] 
     550         tprecip(:,:) = sf(jp_prec)%fnow(:,:,1) * rn_pfac * tmask(:,:,1) ! output total precipitation [kg/m2/s] 
     551         sprecip(:,:) = sf(jp_snow)%fnow(:,:,1) * rn_pfac * tmask(:,:,1) ! output solid precipitation [kg/m2/s] 
    551552         CALL iom_put( 'snowpre', sprecip )                 ! Snow 
    552553         CALL iom_put( 'precip' , tprecip )                 ! Total precipitation 
     
    897898      END DO 
    898899      ! 
    899       tprecip(:,:) = sf(jp_prec)%fnow(:,:,1) * rn_pfac      ! total precipitation [kg/m2/s] 
    900       sprecip(:,:) = sf(jp_snow)%fnow(:,:,1) * rn_pfac      ! solid precipitation [kg/m2/s] 
     900      tprecip(:,:) = sf(jp_prec)%fnow(:,:,1) * rn_pfac * tmask(:,:,1)  ! total precipitation [kg/m2/s] 
     901      sprecip(:,:) = sf(jp_snow)%fnow(:,:,1) * rn_pfac * tmask(:,:,1)  ! solid precipitation [kg/m2/s] 
    901902      CALL iom_put( 'snowpre', sprecip )                    ! Snow precipitation 
    902903      CALL iom_put( 'precip' , tprecip )                    ! Total precipitation 
Note: See TracChangeset for help on using the changeset viewer.