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 15113 – NEMO

Changeset 15113


Ignore:
Timestamp:
2021-07-09T10:04:38+02:00 (3 years ago)
Author:
jchanut
Message:

Correct AGRIF divergence conserving interpolation with cyclic zooms (i.e. nbghostcells_x/nbghostcells_y_s /= nbghostcells), #2638

File:
1 edited

Legend:

Unmodified
Added
Removed
  • NEMO/trunk/src/NST/agrif_oce_interp.F90

    r14976 r15113  
    14181418            DO jj=j1,j2 
    14191419               IF (utint_stage(ji,jj)==0) THEN  
    1420                   zx = 2._wp*MOD(ABS(mig0(ji)-nbghostcells), INT(Agrif_Rhox()))/zrhox - 1._wp   
     1420                  zx = 2._wp*MOD(ABS(mig0(ji)-nbghostcells_x), INT(Agrif_Rhox()))/zrhox - 1._wp   
    14211421                  ubdy(ji,jj) = ubdy(ji,jj) + 0.25_wp*(1._wp-zx*zx) * ptab(ji,jj) &  
    14221422                              &         / zrhoy *r1_e2u(ji,jj) * umask(ji,jj,1)  
     
    15221522            DO jj=j1,j2 
    15231523               IF (vtint_stage(ji,jj)==0) THEN  
    1524                   zy = 2._wp*MOD(ABS(mjg0(jj)-nbghostcells), INT(Agrif_Rhoy()))/zrhoy - 1._wp   
     1524                  zy = 2._wp*MOD(ABS(mjg0(jj)-nbghostcells_y_s), INT(Agrif_Rhoy()))/zrhoy - 1._wp   
    15251525                  vbdy(ji,jj) = vbdy(ji,jj) + 0.25_wp*(1._wp-zy*zy) * ptab(ji,jj) &  
    15261526                              &         / zrhox * r1_e1v(ji,jj) * vmask(ji,jj,1)  
Note: See TracChangeset for help on using the changeset viewer.