Search found 1 match
- Mon Jan 30, 2012 10:42 am
- Forum: ROMS Bugs
- Topic: The perils of floating-point time-step arithmetic
- Replies: 14
- Views: 16517
Re: The perils of floating-point time-step arithmetic
Very interesting topic ! StartTime=0.0_r8 ! <-- not necessarily 0.0_r8, may be just time from the initial condition MaxDT=MAXVAL(dt) ntimes=(RunInterval+0.5*MaxDT)/MaxDT !<-- 0.5*MaxDT is added to make roundoff upward. MaxDT=RunInterval/dble(ntimes) !<-- this adjusts "dt" a little bit to make sure ...