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 4634 for branches/2013/dev_r4028_CNRS_LIM3/NEMOGCM/NEMO/OPA_SRC/trc_oce.F90 – NEMO

Ignore:
Timestamp:
2014-05-12T22:46:18+02:00 (10 years ago)
Author:
clem
Message:

major changes in heat budget

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2013/dev_r4028_CNRS_LIM3/NEMOGCM/NEMO/OPA_SRC/trc_oce.F90

    r3770 r4634  
    271271      ! 
    272272      ! Level of light extinction 
     273!cr      pjl = jpkm1 
     274!cr      DO jk = jpkm1, 1, -1 
     275!cr         zem = MAXVAL( fsdepw(:,:,jk+1) * tmask(:,:,jk) ) 
     276!cr         IF( zem >= zhext )   pjl = jk                       ! last T-level reached by Qsr 
     277!cr      END DO 
    273278      pjl = jpkm1 
    274279      DO jk = jpkm1, 1, -1 
    275          zem = MAXVAL( fsdepw(:,:,jk+1) * tmask(:,:,jk) ) 
    276          IF( zem >= zhext )   pjl = jk                       ! last T-level reached by Qsr 
     280         IF(SUM(tmask(:,:,jk)) > 0 ) THEN 
     281            zem = MAXVAL( fsdepw(:,:,jk+1) * tmask(:,:,jk) ) 
     282            IF( zem >= zhext )   pjl = jk                       ! last T-level reached by Qsr 
     283         ELSE 
     284            pjl = jk                                            ! or regional sea-bed depth  
     285         ENDIF 
    277286      END DO 
    278287      ! 
Note: See TracChangeset for help on using the changeset viewer.