Ocean Modeling Discussion

ROMS/TOMS

Search for:
It is currently Tue Jun 25, 2019 6:23 pm




Post new topic Reply to topic  [ 2 posts ] 

All times are UTC

Author Message
PostPosted: Tue Jan 22, 2019 3:29 am 
Offline

Joined: Tue Oct 07, 2008 11:27 am
Posts: 23
Location: MetService - New Zealand
Hi All,

I've recently bumped into an issue when restarting forecast simulations that run 2x daily, e.g. when restart files have the first time record at a fraction of a day (12 h, for example). I've tracked it down and found a possible typo on dateclock.F 430:436, as below.

Code:
!
!  Fractional date number (units=second).
!
      DateNumber(2)=REAL(MyDay,dp)*86400.0_dp+                          &
     &              REAL(MyHour,dp)*360.0_dp+                           &
     &              REAL(MyMinutes,dp)*60.0_dp+                         &
     &              MySeconds


The multiplier for the number of seconds in an hour is missing a "0". This causes the below bit of the code from mod_netcdf.F 5275:5277 to add an inconsistent offset to the time array.

Code:
DO i=1,Asize(1)
    A(i)=(my_Rdate(2)+A(i))-Rdate(2)
END DO


Which crashes the initialization in check_multifile.F. Below are the relevant snippets of ROMS stdout and ncdump.

Code:
 NLM: GET_STATE - Reading state initial conditions,                       2019-01-21 13:12:00.00
                   (Grid 01, t = -0.4500, File: tinyapp2d20190122_00z_rst.nc, Rec=0001, Index=1)
                - free-surface
                   (Min = -3.92467349E-02 Max =  5.34361359E-02)
                - vertically integrated u-momentum component
                   (Min = -5.60959179E-02 Max =  8.09049525E-03)
                - vertically integrated v-momentum component
                   (Min = -6.47255244E-02 Max =  3.94585012E-03)

 CHECK_MULTIFILE - Error while processing Forcing multi-files:
                   data does not include initialization time = 2019-01-21 13:12:00.00


Code:
ncdump -v ocean_time -t tinyapp2d20190122_00z_rst.nc

      :CPP_options = "ROMS2D_NO-TIDE_NO-OBC, ANA_FSOBC, ANA_M2OBC, ASSUMED_SHAPE, ATM_PRESS, !BOUNDARY_A !COLLECT_ALL..., CURVGRID, DOUBLE_PRECISION, GLS_MIXING, KANTHA_CLAYSON, MASKING, MPI, NONLINEAR, NO_LBC_ATT, N2S2_HORAVG, PERFECT_RESTART, PROFILE, K_GSCHEME, RADIATION_2D, REDUCE_ALLGATHER, !RST_SINGLE, SPHERICAL, STATIONS, UV_ADV, UV_COR, UV_LDRAG, UV_VIS2" ;
data:

 ocean_time = "2019-01-22", "2019-01-22 12", "2019-01-23", "2019-01-23 12",
    "2019-01-24", "2019-01-24 12" ;



Because hour=0 cancels it out, this doesn't affect simulations that start flush in "0h", which are largely the most common case for hydrodynamical applications I guess.

I've applied this fix locally here and tested it, it works fine.

Cheers,
Rafael


Top
 Profile  
Reply with quote  
PostPosted: Tue Jan 22, 2019 9:22 pm 
Offline
Site Admin
User avatar

Joined: Wed Feb 26, 2003 4:41 pm
Posts: 1076
Location: IMCS, Rutgers University
Indeed, good catch :!: Thank you for reporting this bug. I will update the code soon.


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group