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 13295 for NEMO/trunk/src/OCE/TRA/trabbl.F90 – NEMO

Ignore:
Timestamp:
2020-07-10T20:24:21+02:00 (4 years ago)
Author:
acc
Message:

Replace do-loop macros in the trunk with alternative forms with greater flexibility for extra halo applications. This alters a lot of routines but does not change any behaviour or results. do_loop_substitute.h90 is greatly simplified by this change. SETTE results are identical to those with the previous revision

File:
1 edited

Legend:

Unmodified
Added
Removed
  • NEMO/trunk/src/OCE/TRA/trabbl.F90

    r13237 r13295  
    192192      DO jn = 1, kjpt                                     ! tracer loop 
    193193         !                                                ! =========== 
    194          DO_2D_11_11 
     194         DO_2D( 1, 1, 1, 1 ) 
    195195            ik = mbkt(ji,jj)                             ! bottom T-level index 
    196196            zptb(ji,jj) = pt(ji,jj,ik,jn)                ! bottom before T and S 
    197197         END_2D 
    198198         !                
    199          DO_2D_00_00 
     199         DO_2D( 0, 0, 0, 0 ) 
    200200            ik = mbkt(ji,jj)                            ! bottom T-level index 
    201201            pt_rhs(ji,jj,ik,jn) = pt_rhs(ji,jj,ik,jn)                                                  & 
     
    343343      ENDIF 
    344344      !                                        !* bottom variables (T, S, alpha, beta, depth, velocity) 
    345       DO_2D_11_11 
     345      DO_2D( 1, 1, 1, 1 ) 
    346346         ik = mbkt(ji,jj)                             ! bottom T-level index 
    347347         zts (ji,jj,jp_tem) = ts(ji,jj,ik,jp_tem,Kbb) ! bottom before T and S 
     
    358358      IF( nn_bbl_ldf == 1 ) THEN          !   diffusive bbl   ! 
    359359         !                                !-------------------! 
    360          DO_2D_10_10 
     360         DO_2D( 1, 0, 1, 0 ) 
    361361            !                                                   ! i-direction 
    362362            za = zab(ji+1,jj,jp_tem) + zab(ji,jj,jp_tem)              ! 2*(alpha,beta) at u-point 
     
    388388         ! 
    389389         CASE( 1 )                                   != use of upper velocity 
    390             DO_2D_10_10 
     390            DO_2D( 1, 0, 1, 0 ) 
    391391               !                                                  ! i-direction 
    392392               za = zab(ji+1,jj,jp_tem) + zab(ji,jj,jp_tem)               ! 2*(alpha,beta) at u-point 
     
    417417         CASE( 2 )                                 != bbl velocity = F( delta rho ) 
    418418            zgbbl = grav * rn_gambbl 
    419             DO_2D_10_10 
     419            DO_2D( 1, 0, 1, 0 ) 
    420420               !                                                  ! i-direction 
    421421               ! down-slope T-point i/k-index (deep)  &   up-slope T-point i/k-index (shelf) 
     
    509509      ! 
    510510      !                             !* vertical index of  "deep" bottom u- and v-points 
    511       DO_2D_10_10 
     511      DO_2D( 1, 0, 1, 0 ) 
    512512         mbku_d(ji,jj) = MAX(  mbkt(ji+1,jj  ) , mbkt(ji,jj)  )   ! >= 1 as mbkt=1 over land 
    513513         mbkv_d(ji,jj) = MAX(  mbkt(ji  ,jj+1) , mbkt(ji,jj)  ) 
     
    520520      !                             !* sign of grad(H) at u- and v-points; zero if grad(H) = 0 
    521521      mgrhu(:,:) = 0   ;   mgrhv(:,:) = 0 
    522       DO_2D_10_10 
     522      DO_2D( 1, 0, 1, 0 ) 
    523523         IF( gdept_0(ji+1,jj,mbkt(ji+1,jj)) - gdept_0(ji,jj,mbkt(ji,jj)) /= 0._wp ) THEN 
    524524            mgrhu(ji,jj) = INT(  SIGN( 1.0_wp, gdept_0(ji+1,jj,mbkt(ji+1,jj)) - gdept_0(ji,jj,mbkt(ji,jj)) )  ) 
     
    530530      END_2D 
    531531      ! 
    532       DO_2D_10_10 
     532      DO_2D( 1, 0, 1, 0 ) 
    533533         e3u_bbl_0(ji,jj) = MIN( e3u_0(ji,jj,mbkt(ji+1,jj  )), e3u_0(ji,jj,mbkt(ji,jj)) ) 
    534534         e3v_bbl_0(ji,jj) = MIN( e3v_0(ji,jj,mbkt(ji  ,jj+1)), e3v_0(ji,jj,mbkt(ji,jj)) ) 
Note: See TracChangeset for help on using the changeset viewer.