Error when across the longitude 180

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

Moderators: arango, robertson

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

Error when across the longitude 180

#1 Unread post by marinekame »

Hello.

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/roms_oa.nc


Horizontal extrapolations

Temperature...

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)
datazgrid(k,:,:)=interp2(x,y,data,lon,lat,'cubic');

Error: make_clim (line 134)
ext_tracers(oaname,temp_month_data,temp_ann_data,...

------------------------------------------------------------------------------------

Thanks for any help.

User avatar
kate
Posts: 4088
Joined: Wed Jul 02, 2003 5:29 pm
Location: CFOS/UAF, USA

Re: Error when across the longitude 180

#2 Unread post by kate »

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