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

Changeset 12256


Ignore:
Timestamp:
2019-12-16T13:52:49+01:00 (4 years ago)
Author:
smasson
Message:

rev12232_dev_r12072_MERGE_OPTION2_2019: bugfix in fldread offset in bdy, see #2263. all sette tests ok

Location:
NEMO/branches/2019/dev_r12072_MERGE_OPTION2_2019/src
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • NEMO/branches/2019/dev_r12072_MERGE_OPTION2_2019/src/OCE/BDY/bdydta.F90

    r12246 r12256  
    7575CONTAINS 
    7676 
    77    SUBROUTINE bdy_dta( kt, pt_offset ) 
     77   SUBROUTINE bdy_dta( kt ) 
    7878      !!---------------------------------------------------------------------- 
    7979      !!                   ***  SUBROUTINE bdy_dta  *** 
     
    8585      !!---------------------------------------------------------------------- 
    8686      INTEGER, INTENT(in)           ::   kt           ! ocean time-step index  
    87       REAL(wp),INTENT(in), OPTIONAL ::   pt_offset    ! time offset in units of timesteps 
    8887      ! 
    8988      INTEGER ::  jbdy, jfld, jstart, jend, ib, jl    ! dummy loop indices 
     
    210209         ! read/update all bdy data 
    211210         ! ------------------------ 
    212          CALL fld_read( kt, 1, bf_alias, pt_offset = pt_offset ) 
     211         ! BDY: use pt_offset=0.5 as applied at the end of the step and fldread is referenced at the middle of the step 
     212         CALL fld_read( kt, 1, bf_alias, pt_offset = 0.5_wp ) 
    213213 
    214214         ! apply some corrections in some specific cases... 
     
    341341         ELSE ! Add tides if not split-explicit free surface else this is done in ts loop 
    342342            ! 
    343             CALL bdy_dta_tides( kt=kt, pt_offset=pt_offset ) 
     343            ! BDY: use pt_offset=1.0 as applied at the end of the step and bdy_dta_tides is referenced at the middle of the step 
     344            CALL bdy_dta_tides( kt=kt, pt_offset = 1._wp ) 
    344345         ENDIF 
    345346      ENDIF 
  • NEMO/branches/2019/dev_r12072_MERGE_OPTION2_2019/src/OCE/SBC/fldread.F90

    r12251 r12256  
    163163 
    164164      IF( nn_components == jp_iam_sas ) THEN   ;   zt_offset = REAL( nn_fsbc, wp ) 
    165       ELSE                                      ;   zt_offset = 0. 
     165      ELSE                                     ;   zt_offset = 0. 
    166166      ENDIF 
    167167      IF( PRESENT(pt_offset) )   zt_offset = pt_offset 
  • NEMO/branches/2019/dev_r12072_MERGE_OPTION2_2019/src/OCE/step.F90

    r12246 r12256  
    114114      IF( ln_tide    )   CALL tide_update( kstp )                ! update tide potential 
    115115      IF( ln_apr_dyn )   CALL sbc_apr ( kstp )                   ! atmospheric pressure (NB: call before bdy_dta which needs ssh_ib)  
    116       IF( ln_bdy     )   CALL bdy_dta ( kstp, pt_offset = 1. )   ! update dynamic & tracer data at open boundaries 
     116      IF( ln_bdy     )   CALL bdy_dta ( kstp )                   ! update dynamic & tracer data at open boundaries 
    117117      IF( ln_isf     )   CALL isf_stp ( kstp )                   ! ice shelf/ocean boundary condition 
    118118                         CALL sbc     ( kstp )                   ! Sea Boundary Condition (including sea-ice) 
  • NEMO/branches/2019/dev_r12072_MERGE_OPTION2_2019/src/SAS/step.F90

    r12246 r12256  
    9696      !           From SAS: ocean bdy data are wrong  (but we do not care) and ice bdy data are OK.   
    9797      !           This is not clean and should be changed in the future.  
    98       IF( ln_bdy     )       CALL bdy_dta ( kstp, pt_offset=1. )   ! update dynamic & tracer data at open boundaries 
     98      IF( ln_bdy     )       CALL bdy_dta( kstp )         ! update dynamic & tracer data at open boundaries 
    9999      ! ==> 
    100100                             CALL sbc    ( kstp )         ! Sea Boundary Condition (including sea-ice) 
  • NEMO/branches/2019/dev_r12072_MERGE_OPTION2_2019/src/TOP/trcbc.F90

    r12246 r12256  
    364364      IF( PRESENT(jit) ) THEN  
    365365         ! 
    366          ! OPEN boundary conditions (use pt_offset=1. as they are applied at the end of the step) 
     366         ! BDY: use pt_offset=0.5 as applied at the end of the step and fldread is referenced at the middle of the step 
    367367         IF( nb_trcobc > 0 ) THEN 
    368368           if (lwp) write(numout,'(a,i5,a,i10)') '   reading OBC data for ', nb_trcobc ,' variable(s) at step ', kt 
    369            CALL fld_read( kt=kt, kn_fsbc=1, sd=sf_trcobc, kit=jit, pt_offset=1.) 
     369           CALL fld_read( kt=kt, kn_fsbc=1, sd=sf_trcobc, kit=jit, pt_offset = 0.5_wp ) 
    370370         ENDIF 
    371371         ! 
     
    384384      ELSE 
    385385         ! 
    386          ! OPEN boundary conditions (use pt_offset=1. as they are applied at the end of the step) 
     386         ! BDY: use pt_offset=0.5 as applied at the end of the step and fldread is referenced at the middle of the step 
    387387         IF( nb_trcobc > 0 ) THEN 
    388388           if (lwp) write(numout,'(a,i5,a,i10)') '   reading OBC data for ', nb_trcobc ,' variable(s) at step ', kt 
    389            CALL fld_read( kt=kt, kn_fsbc=1, sd=sf_trcobc, pt_offset=1.) 
     389           CALL fld_read( kt=kt, kn_fsbc=1, sd=sf_trcobc, pt_offset = 0.5_wp ) 
    390390         ENDIF 
    391391         ! 
Note: See TracChangeset for help on using the changeset viewer.