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 9923 for NEMO/branches/2018/dev_r9838_ENHANCE04_MLF/src/OCE/SBC/fldread.F90 – NEMO

Ignore:
Timestamp:
2018-07-11T10:24:17+02:00 (6 years ago)
Author:
gm
Message:

#1911 (ENHANCE-04): step I.2: dev_r9838_ENHANCE04_MLF

File:
1 edited

Legend:

Unmodified
Added
Removed
  • NEMO/branches/2018/dev_r9838_ENHANCE04_MLF/src/OCE/SBC/fldread.F90

    r9807 r9923  
    180180      ! Note that shifting time to be centrered in the middle of sbc time step impacts only nsec_* variables of the calendar  
    181181      IF( present(kit) ) THEN   ! ignore kn_fsbc in this case 
    182          isecsbc = nsec_year + nsec1jan000 + (kit+it_offset)*NINT( rdt/REAL(nn_baro,wp) ) 
     182         isecsbc = nsec_year + nsec1jan000 + (kit+it_offset)*NINT( rn_Dt/REAL(nn_e,wp) ) 
    183183      ELSE                      ! middle of sbc time step 
    184          isecsbc = nsec_year + nsec1jan000 + NINT(0.5 * REAL(kn_fsbc - 1,wp) * rdt) + it_offset * NINT(rdt) 
     184         isecsbc = nsec_year + nsec1jan000 + NINT(0.5 * REAL(kn_fsbc - 1,wp) * rn_Dt) + it_offset * NINT(rn_Dt) 
    185185      ENDIF 
    186186      imf = SIZE( sd ) 
     
    213213               CALL fld_rec( kn_fsbc, sd(jf), kt_offset = it_offset, kit = kit )    ! update after record informations 
    214214 
    215                ! if kn_fsbc*rdt is larger than nfreqh (which is kind of odd), 
     215               ! if kn_fsbc*rn_Dt is larger than nfreqh (which is kind of odd), 
    216216               ! it is possible that the before value is no more the good one... we have to re-read it 
    217217               ! if before is not the last record of the file currently opened and after is the first record to be read 
     
    234234               IF( sd(jf)%ln_tint ) THEN 
    235235                   
    236                   ! if kn_fsbc*rdt is larger than nfreqh (which is kind of odd), 
     236                  ! if kn_fsbc*rn_Dt is larger than nfreqh (which is kind of odd), 
    237237                  ! it is possible that the before value is no more the good one... we have to re-read it 
    238238                  ! if before record is not just just before the after record... 
     
    267267                     ! year/month/week/day file to be not present. If the run continue further than the current 
    268268                     ! year/month/week/day, next year/month/week/day file must exist 
    269                      isecend = nsec_year + nsec1jan000 + (nitend - kt) * NINT(rdt)   ! second at the end of the run 
    270                      llstop = isecend > sd(jf)%nrec_a(2)                                   ! read more than 1 record of next year 
     269                     isecend = nsec_year + nsec1jan000 + (nitend - kt) * NINT(rn_Dt)   ! second at the end of the run 
     270                     llstop = isecend > sd(jf)%nrec_a(2)                                ! read more than 1 record of next year 
    271271                     ! we suppose that the date of next file is next day (should be ok even for weekly files...) 
    272272                     CALL fld_clopn( sd(jf), nyear  + COUNT((/llnxtyr /))                                           ,         & 
     
    485485      ENDIF 
    486486      IF( PRESENT(kt_offset) )   it_offset = kt_offset 
    487       IF( PRESENT(kit) ) THEN   ;   it_offset = ( kit + it_offset ) * NINT( rdt/REAL(nn_baro,wp) ) 
    488       ELSE                      ;   it_offset =         it_offset   * NINT(       rdt            ) 
     487      IF( PRESENT(kit) ) THEN   ;   it_offset = ( kit + it_offset ) * NINT( rn_Dt / REAL(nn_e,wp) ) 
     488      ELSE                      ;   it_offset =         it_offset   * NINT( rn_Dt                 ) 
    489489      ENDIF 
    490490      ! 
     
    563563         ELSE                                           ;   ztmp = REAL(nsec_year ,wp)  ! since 00h on Jan 1 of the current year 
    564564         ENDIF 
    565          ztmp = ztmp + 0.5 * REAL(kn_fsbc - 1, wp) * rdt + REAL( it_offset, wp )        ! centrered in the middle of sbc time step 
    566          ztmp = ztmp + 0.01 * rdt                                                       ! avoid truncation error  
     565         ztmp = ztmp + 0.5 * REAL(kn_fsbc - 1, wp) * rn_Dt + REAL( it_offset, wp )      ! centrered in the middle of sbc time step 
     566         ztmp = ztmp + 0.01 * rn_Dt                                                     ! avoid truncation error  
    567567         IF( sdjf%ln_tint ) THEN                ! time interpolation, shift by 1/2 record 
    568568            ! 
Note: See TracChangeset for help on using the changeset viewer.