Error when across the longitude 180

Discussion of how to use ROMS on different regional and basin scale applications.

Moderators: arango, robertson

Post Reply
Posts: 16
Joined: Tue Mar 22, 2016 5:21 pm
Location: Japan Weather Association

Error when across the longitude 180

#1 Post by marinekame » Fri Mar 03, 2017 3:01 am


I am a ROMSTOOLS user.
I want to analyze the region from 170E to 170W across the 180E.
Therefore I set lonmin=170 and lonmax=190 in the romstools_param.m.
But, when I ran make_clim after make_forcing, the following errors occurred.
Would you please tell me how to solve this problem ?

Create the OA file...

Creating the file : /home/mathuser/work/roms/Roms_tools/Run/ROMS_FILES/

Horizontal extrapolations


Ext tracers: Roa = 0 km - default value = NaN
Ext tracers: horizontal interpolation of the seasonal data

time index: 1 of total: 12
Error: griddedInterpolant

Error: interp2>makegriddedinterp (line 228)
F = griddedInterpolant(varargin{:});

Error: interp2 (line 128)
F = makegriddedinterp({X, Y}, V, method,extrap);

Error: ext_tracers (line 162)

Error: make_clim (line 134)


Thanks for any help.

User avatar
Posts: 3718
Joined: Wed Jul 02, 2003 5:29 pm
Location: IMS/UAF, USA

Re: Error when across the longitude 180

#2 Post by kate » Fri Mar 03, 2017 7:20 am

I am not a ROMSTOOLS user, nor is this the forum run by the developers of it. Still, I have run Arctic domains that need to interpolate over the full range of longitude. In general, you want to be consistent, say with a grid that has longitude values between 0 and 360, bathymetry with longitude values between 0 and 360, ditto the T and S fields you are interpolating from. It could just as well be -180 to 180, but still be consistent. I have Python or NCL scripts to convert my grid from one convention to the other, that being easier than converting SODA or whatever. Our MERRA scripts convert from the range (-180,180) to (0,360) as part of the download process.

Then you still need tools that can deal with the dateline or the prime meridian, whichever. For scrip, there's a periodic flag that needs to be set. It's probably true for any other interpolating tool as well. My branch of ROMS has a flag for dealing with periodic forcing when ROMS is interpolating internally, but I don't think the trunk code has it. Note to Hernan for his Arctic plans... :mrgreen:

Post Reply