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 13305 for NEMO/trunk/src – NEMO

Changeset 13305 for NEMO/trunk/src


Ignore:
Timestamp:
2020-07-14T19:12:25+02:00 (4 years ago)
Author:
acc
Message:

Trunk changes required to avoid issues with the outer halo in ORCA2_ICE_PISCES,
REPRO_8_4 tests with nn_hls=2. These changes ensure that tmask and output
from sbc_blk are set correctly in the outer halo. Failure to set valid
values in the outer halo can generate NaNs? which lead to OOB errors in the
XRGB lookup table used for the TRC optics.See #2366 for details. With these
changes all variants of the ORCA2_ICE_PISCES SETTE test will complete. There
are still differences between the 1 and 2 halo width runs but running with:
no land suppression; partial land suppression or full land suppression does
not alter either set of results. Likewise setting ln_nnogather either true
or false does not alter results. Differences in run.stat start after 140
timesteps and differences in tracer.stat start after 60 timesteps between
the different halo width sets. Equivalent tests with ln_icebergs = F show no
differences in run.stat but halo-width dependent differences in tracer.stat
persist (now after 64 timesteps).

Location:
NEMO/trunk/src/OCE
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • NEMO/trunk/src/OCE/DOM/dommsk.F90

    r13295 r13305  
    131131      ! 
    132132      tmask(:,:,:) = 0._wp 
    133       DO_2D( 1, 1, 1, 1 ) 
     133      DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    134134         iktop = k_top(ji,jj) 
    135135         ikbot = k_bot(ji,jj) 
  • NEMO/trunk/src/OCE/LBC/mppini.F90

    r13291 r13305  
    592592         WRITE(inum,'(6i8,a,3i8,a)') jpnij,jpimax,jpjmax,jpk,jpiglo,jpjglo,& 
    593593   &           ' ( local: ',narea,jpi,jpj,' )' 
    594          WRITE(inum,'(a)') 'nproc jpi jpj Nis0 Njs0 Nie0 Nje0 nimp njmp nono noso nowe noea nbondi nbondj ' 
     594         WRITE(inum,'(a)') 'nproc   jpi jpj Nis0 Njs0 Nie0 Nje0 nimp njmp nono noso nowe noea nbondi nbondj ' 
    595595 
    596596         DO jproc = 1, jpnij 
  • NEMO/trunk/src/OCE/SBC/sbcblk.F90

    r13295 r13305  
    568568      zwnd_j(:,:) = 0._wp 
    569569      CALL wnd_cyc( kt, zwnd_i, zwnd_j )    ! add analytical tropical cyclone (Vincent et al. JGR 2012) 
    570       DO_2D( 1, 1, 1, 1 ) 
     570      DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    571571         zwnd_i(ji,jj) = pwndi(ji,jj) + zwnd_i(ji,jj) 
    572572         zwnd_j(ji,jj) = pwndj(ji,jj) + zwnd_j(ji,jj) 
     
    576576#else 
    577577      ! ... scalar wind module at T-point (not masked) 
    578       DO_2D( 1, 1, 1, 1 ) 
     578      DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    579579         wndm(ji,jj) = SQRT(  pwndi(ji,jj) * pwndi(ji,jj) + pwndj(ji,jj) * pwndj(ji,jj)  ) 
    580580      END_2D 
     
    628628         !     use scalar version of gamma_moist() ... 
    629629         IF( ln_tpot ) THEN 
    630             DO_2D( 1, 1, 1, 1 ) 
     630            DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    631631               ztpot(ji,jj) = ptair(ji,jj) + gamma_moist( ptair(ji,jj), zqair(ji,jj) ) * rn_zqt 
    632632            END_2D 
     
    690690 
    691691      IF( ln_abl ) THEN         !==  ABL formulation  ==!   multiplication by rho_air and turbulent fluxes computation done in ablstp 
    692          DO_2D( 1, 1, 1, 1 ) 
     692         DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    693693            zztmp = zU_zu(ji,jj) 
    694694            wndm(ji,jj)   = zztmp                   ! Store zU_zu in wndm to compute ustar2 in ablmod 
     
    710710         pevp(:,:) = pevp(:,:) * tmask(:,:,1) 
    711711 
    712          DO_2D( 1, 1, 1, 1 ) 
     712         DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    713713            IF( wndm(ji,jj) > 0._wp ) THEN 
    714714               zztmp = taum(ji,jj) / wndm(ji,jj) 
     
    828828 
    829829      ! use scalar version of L_vap() for AGRIF compatibility 
    830       DO_2D( 1, 1, 1, 1 ) 
     830      DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    831831         zqla(ji,jj) = - L_vap( ztskk(ji,jj) ) * pevp(ji,jj)    ! Latent Heat flux !!GS: possibility to add a global qla to avoid recomputation after abl update 
    832832      END_2D 
     
    933933      ! ------------------------------------------------------------ ! 
    934934      ! C-grid ice dynamics :   U & V-points (same as ocean) 
    935       DO_2D( 1, 1, 1, 1 ) 
     935      DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    936936         wndm_ice(ji,jj) = SQRT( pwndi(ji,jj) * pwndi(ji,jj) + pwndj(ji,jj) * pwndj(ji,jj) ) 
    937937      END_2D 
     
    978978         zztmp1 = 11637800.0_wp 
    979979         zztmp2 =    -5897.8_wp 
    980          DO_2D( 1, 1, 1, 1 ) 
     980         DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    981981            pcd_dui(ji,jj) = zcd_dui (ji,jj) 
    982982            pseni  (ji,jj) = wndm_ice(ji,jj) * Ch_ice(ji,jj) 
     
    12331233         ! 
    12341234         DO jl = 1, jpl 
    1235             DO_2D( 1, 1, 1, 1 ) 
     1235            DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    12361236               zhe = ( rn_cnd_s * phi(ji,jj,jl) + rcnd_i * phs(ji,jj,jl) ) * zfac                            ! Effective thickness 
    12371237               IF( zhe >=  zfac2 )   zgfac(ji,jj,jl) = MIN( 2._wp, 0.5_wp * ( 1._wp + LOG( zhe * zfac3 ) ) ) ! Enhanced conduction factor 
     
    12481248      ! 
    12491249      DO jl = 1, jpl 
    1250          DO_2D( 1, 1, 1, 1 ) 
     1250         DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    12511251            ! 
    12521252            zkeff_h = zfac * zgfac(ji,jj,jl) / &                                    ! Effective conductivity of the snow-ice system divided by thickness 
  • NEMO/trunk/src/OCE/SBC/sbcblk_phy.F90

    r13295 r13305  
    181181      !!---------------------------------------------------------------------------------- 
    182182      ! 
    183       DO_2D( 1, 1, 1, 1 ) 
     183      DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    184184         ztc  = ptak(ji,jj) - rt0   ! air temp, in deg. C 
    185185         ztc2 = ztc*ztc 
     
    270270      INTEGER  ::   ji, jj         ! dummy loop indices 
    271271      !!---------------------------------------------------------------------------------- 
    272       DO_2D( 1, 1, 1, 1 ) 
     272      DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    273273         gamma_moist_vctr(ji,jj) = gamma_moist_sclr( ptak(ji,jj), pqa(ji,jj) ) 
    274274      END_2D 
     
    315315      !!------------------------------------------------------------------- 
    316316      ! 
    317       DO_2D( 1, 1, 1, 1 ) 
     317      DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    318318         ! 
    319319         zqa = (1._wp + rctv0*pqa(ji,jj)) 
     
    351351      !!------------------------------------------------------------------- 
    352352      ! 
    353       DO_2D( 1, 1, 1, 1 ) 
     353      DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    354354         ! 
    355355         zqa = 0.5_wp*(pqa(ji,jj)+pssq(ji,jj))                                        ! ~ mean q within the layer... 
     
    448448      !!---------------------------------------------------------------------------------- 
    449449      ! 
    450       DO_2D( 1, 1, 1, 1 ) 
     450      DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    451451         ! 
    452452         ze_sat =  e_sat_sclr( ptak(ji,jj) ) 
     
    473473      !!---------------------------------------------------------------------------------- 
    474474      ! 
    475       DO_2D( 1, 1, 1, 1 ) 
     475      DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    476476         ze = prha(ji,jj)*e_sat_sclr(ptak(ji,jj)) 
    477477         q_air_rh(ji,jj) = ze*reps0/(pslp(ji,jj) - (1. - reps0)*ze) 
     
    511511      INTEGER  ::   ji, jj     ! dummy loop indices 
    512512      !!---------------------------------------------------------------------------------- 
    513       DO_2D( 1, 1, 1, 1 ) 
     513      DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    514514 
    515515         zdt = pTa(ji,jj) - pTs(ji,jj) ;  zdt = SIGN( MAX(ABS(zdt),1.E-6_wp), zdt ) 
     
    621621      IF( PRESENT(pfact_evap) ) zfact_evap = pfact_evap 
    622622 
    623       DO_2D( 1, 1, 1, 1 ) 
     623      DO_2D( nn_hls, nn_hls, nn_hls, nn_hls ) 
    624624 
    625625         CALL BULK_FORMULA_SCLR( pzu, pTs(ji,jj), pqs(ji,jj), pTa(ji,jj), pqa(ji,jj), & 
Note: See TracChangeset for help on using the changeset viewer.