Changeset 12350


Ignore:
Timestamp:
2020-01-29T12:08:08+01:00 (9 months ago)
Author:
smueller
Message:

Rectification of a defect that halved the maximum length of the interval between restarts in model runs with enabled temporal interpolation of forcing fields (field-information flag ln_tint set to .true.)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • NEMO/branches/2019/dev_r11943_MERGE_2019/src/OCE/SBC/fldread.F90

    r12340 r12350  
    906906      ENDIF 
    907907      ! 
    908       IF( sdjf%ln_tint ) THEN   ! record time defined in the middle of the record 
    909          sdjf%nrecsec(1:sdjf%nreclast) = 0.5 * ( sdjf%nrecsec(0:sdjf%nreclast-1) + sdjf%nrecsec(1:sdjf%nreclast) ) 
     908      IF( sdjf%ln_tint ) THEN   ! record time defined in the middle of the record, computed using an implementation 
     909                                ! of the rounded average that is valid over the full integer range 
     910         sdjf%nrecsec(1:sdjf%nreclast) = sdjf%nrecsec(0:sdjf%nreclast-1) / 2 + sdjf%nrecsec(1:sdjf%nreclast) / 2 + & 
     911            & MAX( MOD( sdjf%nrecsec(0:sdjf%nreclast-1), 2 ), MOD( sdjf%nrecsec(1:sdjf%nreclast), 2 ) ) 
    910912      END IF 
    911913      ! 
Note: See TracChangeset for help on using the changeset viewer.