Due to a shift in policy, from 0900 GMT on Wednesday 14th July 2021, we will be disabling ssh access to the server for external users. External users who wish to continue to access code repositories on the server will need to switch to using https. This can be accomplished in the following way: 1) On the repo on gitlab, use the clone dialogue and select ‘Clone with HTTPS’ to get the address of the repo; 2) From within the checkout of your repo run: $ git remote set-url origin HTTPS_ADDRESS. Here, replace HTTPS_ADDRESS with the address you have just copied from GitLab. Pulls and pushes will now require you to enter a username and password rather than using a ssh key. If you would prefer not to enter a password each time, you might consider caching your login credentials.

Commit e8d720fd authored by Pierre Cazenave's avatar Pierre Cazenave

Update the documentation to reflect new functions. Also add a dependency graph...

Update the documentation to reflect new functions. Also add a dependency graph for the functions in the toolbox
parent 4032b7ca
/* Created by mdot for Matlab */
digraph m2html {
README [URL="README.html"];
example_surface_plot [URL="example_surface_plot.html"];
}
\ No newline at end of file
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/REC-html40/loose.dtd">
<html>
<head>
<title>Dependency Graph for fvcom_postproc</title>
<meta name="keywords" content="dependency, graph, dependence, fvcom_postproc">
<meta name="description" content="Dependency graph for fvcom_postproc">
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="generator" content="m2html v1.5 &copy; 2003-2005 Guillaume Flandin">
<meta name="robots" content="index, follow">
<link type="text/css" rel="stylesheet" href="../m2html.css">
</head>
<body>
<a name="_top"></a>
<table width="100%"><tr><td align="left"><a href="../index.html"><img alt="<" border="0" src="../left.png">&nbsp;Master index</a></td>
<td align="right"><a href="index.html">Index for fvcom_postproc&nbsp;<img alt=">" border="0" src="../right.png"></a></td></tr></table>
<h1>Dependency Graph for fvcom_postproc</h1>
<center>
<img src="graph.png" usemap="#mainmap" alt="Dependency Graph for fvcom_postproc" border="2" style="color:#000;">
<map name="mainmap">
<area shape="poly" id="node1" href="README.html" title="README" alt="" coords="144,31 141,23 131,16 116,10 96,6 75,5 53,6 34,10 18,16 8,23 5,31 8,39 18,46 34,51 53,55 75,56 96,55 116,51 131,46 141,39">
<area shape="poly" id="node2" href="example_surface_plot.html" title="example_surface_plot" alt="" coords="426,31 420,23 402,16 373,10 337,6 297,5 257,6 221,10 193,16 174,23 168,31 174,39 193,46 221,51 257,55 297,56 337,55 373,51 402,46 420,39">
</map>
</center>
<hr><address>Generated on Tue 04-Jun-2013 12:12:56 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
</body>
</html>
\ No newline at end of file
<area shape="poly" id="node1" href="README.html" title="README" alt="" coords="144,31 141,23 131,16 116,10 96,6 75,5 53,6 34,10 18,16 8,23 5,31 8,39 18,46 34,51 53,55 75,56 96,55 116,51 131,46 141,39">
<area shape="poly" id="node2" href="example_surface_plot.html" title="example_surface_plot" alt="" coords="426,31 420,23 402,16 373,10 337,6 297,5 257,6 221,10 193,16 174,23 168,31 174,39 193,46 221,51 257,55 297,56 337,55 373,51 402,46 420,39">
......@@ -25,7 +25,10 @@
<h2>Subsequent directories:</h2>
<ul style="list-style-image:url(../matlabicon.gif)">
<li>plots</li><li>surface_plots</li><li>transect_plots</li></ul>
<hr><address>Generated on Mon 04-Feb-2013 14:22:26 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
<h2>Dependency Graph</h2>
<ul style="list-style-image:url(../simulinkicon.gif)">
<li>View the <a href="graph.html">Graph</a>.</li>
</ul>
<hr><address>Generated on Tue 04-Jun-2013 12:12:54 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
</body>
</html>
\ No newline at end of file
......@@ -24,13 +24,13 @@
<div class="box"><strong>Add a set of river nodes comprising a single river to Mesh structure</strong></div>
<h2><a name="_synopsis"></a>SYNOPSIS <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2>
<div class="box"><strong>function [Mobj] = add_river_nodes(Mobj,Nlist,RiverName) </strong></div>
<div class="box"><strong>function [Mobj] = add_river_nodes_list(Mobj,Nlist,RiverName) </strong></div>
<h2><a name="_description"></a>DESCRIPTION <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2>
<div class="fragment"><pre class="comment"> Add a set of river nodes comprising a single river to Mesh structure
Using a set of user-defined nodes
[Mobj] = add_river_nodes(Mobj)
[Mobj] = add_river_nodes(Mobj,Nlist,RiverName)
DESCRIPTION:
Select using ginput the set of nodes comprising a river
......@@ -43,7 +43,7 @@
Mobj = Matlab mesh object with an additional river nodelist
EXAMPLE USAGE
Mobj = add_river_nodes(Mobj,'Potomac')
Mobj = add_river_nodes(Mobj, [146, 3004], 'Potomac')
Author(s):
Geoff Cowles (University of Massachusetts Dartmouth)
......@@ -54,7 +54,7 @@
Revision history
==============================================================================</pre></div>
==========================================================================</pre></div>
<!-- crossreference -->
<h2><a name="_cross"></a>CROSS-REFERENCE INFORMATION <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2>
......@@ -69,12 +69,12 @@ This function is called by:
<h2><a name="_source"></a>SOURCE CODE <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2>
<div class="fragment"><pre>0001 <a name="_sub0" href="#_subfunctions" class="code">function [Mobj] = add_river_nodes(Mobj,Nlist,RiverName)</a>
<div class="fragment"><pre>0001 <a name="_sub0" href="#_subfunctions" class="code">function [Mobj] = add_river_nodes_list(Mobj,Nlist,RiverName)</a>
0002
0003 <span class="comment">% Add a set of river nodes comprising a single river to Mesh structure</span>
0004 <span class="comment">% Using a set of user-defined nodes</span>
0005 <span class="comment">%</span>
0006 <span class="comment">% [Mobj] = add_river_nodes(Mobj)</span>
0006 <span class="comment">% [Mobj] = add_river_nodes(Mobj,Nlist,RiverName)</span>
0007 <span class="comment">%</span>
0008 <span class="comment">% DESCRIPTION:</span>
0009 <span class="comment">% Select using ginput the set of nodes comprising a river</span>
......@@ -87,7 +87,7 @@ This function is called by:
0016 <span class="comment">% Mobj = Matlab mesh object with an additional river nodelist</span>
0017 <span class="comment">%</span>
0018 <span class="comment">% EXAMPLE USAGE</span>
0019 <span class="comment">% Mobj = add_river_nodes(Mobj,'Potomac')</span>
0019 <span class="comment">% Mobj = add_river_nodes(Mobj, [146, 3004], 'Potomac')</span>
0020 <span class="comment">%</span>
0021 <span class="comment">% Author(s):</span>
0022 <span class="comment">% Geoff Cowles (University of Massachusetts Dartmouth)</span>
......@@ -98,57 +98,57 @@ This function is called by:
0027 <span class="comment">%</span>
0028 <span class="comment">% Revision history</span>
0029 <span class="comment">%</span>
0030 <span class="comment">%==============================================================================</span>
0031 subname = <span class="string">'add_river_nodes'</span>;
0030 <span class="comment">%==========================================================================</span>
0031 subname = <span class="string">'add_river_nodes_list'</span>;
0032 <span class="keyword">global</span> ftbverbose
0033 <span class="keyword">if</span>(ftbverbose)
0034 fprintf(<span class="string">'\n'</span>)
0035 fprintf([<span class="string">'begin : '</span> subname <span class="string">'\n'</span>])
0036 <span class="keyword">end</span>;
0033 <span class="keyword">if</span> ftbverbose
0034 fprintf(<span class="string">'\n'</span>)
0035 fprintf([<span class="string">'begin : '</span> subname <span class="string">'\n'</span>])
0036 <span class="keyword">end</span>
0037
0038 <span class="comment">%------------------------------------------------------------------------------</span>
0038 <span class="comment">%--------------------------------------------------------------------------</span>
0039 <span class="comment">% Get a unique list and make sure they are in the range of node numbers</span>
0040 <span class="comment">%------------------------------------------------------------------------------</span>
0040 <span class="comment">%--------------------------------------------------------------------------</span>
0041 Nlist = unique(Nlist);
0042
0043 <span class="keyword">if</span>(max(Nlist) &gt; Mobj.nVerts);
0044 fprintf(<span class="string">'your river node number(s) exceed the total number of nodes in the domain\n'</span>);
0045 fprintf(<span class="string">'stop screwing around\n'</span>);
0046 error(<span class="string">'stopping...\n'</span>)
0047 <span class="keyword">end</span>;
0043 <span class="keyword">if</span> max(Nlist) &gt; Mobj.nVerts
0044 fprintf(<span class="string">'your river node number(s) exceed the total number of nodes in the domain\n'</span>);
0045 fprintf(<span class="string">'stop screwing around\n'</span>);
0046 error(<span class="string">'stopping...\n'</span>)
0047 <span class="keyword">end</span>
0048
0049 <span class="comment">%------------------------------------------------------------------------------</span>
0049 <span class="comment">%--------------------------------------------------------------------------</span>
0050 <span class="comment">% Plot the mesh</span>
0051 <span class="comment">%------------------------------------------------------------------------------</span>
0051 <span class="comment">%--------------------------------------------------------------------------</span>
0052
0053 <span class="keyword">if</span>(lower(Mobj.nativeCoords(1:3)) == <span class="string">'car'</span>)
0054 x = Mobj.x;
0055 y = Mobj.y;
0053 <span class="keyword">if</span> strcmpi(Mobj.nativeCoords(1:3), <span class="string">'car'</span>)
0054 x = Mobj.x;
0055 y = Mobj.y;
0056 <span class="keyword">else</span>
0057 x = Mobj.lon;
0058 y = Mobj.lat;
0059 <span class="keyword">end</span>;
0057 x = Mobj.lon;
0058 y = Mobj.lat;
0059 <span class="keyword">end</span>
0060
0061 figure
0062 patch(<span class="string">'Vertices'</span>,[x,y],<span class="string">'Faces'</span>,Mobj.tri,<span class="keyword">...</span>
0063 <span class="string">'Cdata'</span>,Mobj.h,<span class="string">'edgecolor'</span>,<span class="string">'k'</span>,<span class="string">'facecolor'</span>,<span class="string">'interp'</span>);
0064 hold on;
0062 patch(<span class="string">'Vertices'</span>, [x,y], <span class="string">'Faces'</span>, Mobj.tri,<span class="keyword">...</span>
0063 <span class="string">'Cdata'</span>, Mobj.h, <span class="string">'edgecolor'</span>, <span class="string">'k'</span>, <span class="string">'facecolor'</span>, <span class="string">'interp'</span>);
0064 hold on
0065
0066 plot(x(Nlist),y(Nlist),<span class="string">'ro'</span>);
0067 title(<span class="string">'river nodes'</span>);
0066 plot(x(Nlist), y(Nlist), <span class="string">'ro'</span>)
0067 title(<span class="string">'river nodes'</span>)
0068
0069 <span class="comment">% add to mesh object</span>
0070 npts = numel(Nlist);
0071 Mobj.nRivers = Mobj.nRivers + 1;
0072 Mobj.nRivNodes(Mobj.nRivers) = npts;
0073 Mobj.riv_nodes(Mobj.nRivers,1:npts) = Nlist;
0073 Mobj.riv_nodes(Mobj.nRivers, 1:npts) = Nlist;
0074 Mobj.riv_name{Mobj.nRivers} = RiverName;
0075
0076
0077 <span class="keyword">if</span>(ftbverbose)
0078 fprintf([<span class="string">'end : '</span> subname <span class="string">'\n'</span>])
0079 <span class="keyword">end</span>;
0077 <span class="keyword">if</span> ftbverbose
0078 fprintf([<span class="string">'end : '</span> subname <span class="string">'\n'</span>])
0079 <span class="keyword">end</span>
0080</pre></div>
<hr><address>Generated on Tue 18-Dec-2012 12:37:31 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
<hr><address>Generated on Tue 04-Jun-2013 12:12:57 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
</body>
</html>
\ No newline at end of file
......@@ -159,7 +159,7 @@ This function is called by:
0084 Mobj.sponge_name{Mobj.nSponge} = SpongeName;
0085 Mobj.sponge_fac(Mobj.nSponge) = SpongeCoeff;
0086
0087 <span class="keyword">if</span> max(size(SpongeRadius))==1 <span class="comment">% if you have a constant sponge radius</span>
0087 <span class="keyword">if</span> numel(unique(SpongeRadius)) == 1 <span class="comment">% if you have a constant sponge radius</span>
0088 Mobj.sponge_rad(Mobj.nSponge) = SpongeRadius;
0089 <span class="keyword">else</span> <span class="comment">% if you have a variable sponge radius</span>
0090 Mobj.sponge_rad(Mobj.nSponge,1:npts) = SpongeRadius;
......@@ -169,6 +169,6 @@ This function is called by:
0094 fprintf([<span class="string">'end : '</span> subname <span class="string">'\n'</span>])
0095 <span class="keyword">end</span>
0096</pre></div>
<hr><address>Generated on Mon 04-Feb-2013 14:22:28 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
<hr><address>Generated on Tue 04-Jun-2013 12:12:57 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
</body>
</html>
\ No newline at end of file
......@@ -169,7 +169,14 @@ This function is called by:
0090 inc = inc + 1;
0091 <span class="keyword">end</span>
0092
0093 Mobj.stations = out;</pre></div>
<hr><address>Generated on Tue 18-Dec-2012 12:37:31 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
0093 <span class="keyword">if</span> ~isempty(out)
0094 Mobj.stations = out;
0095 <span class="keyword">else</span>
0096 Mobj.stations = [];
0097 <span class="keyword">if</span> ftbverbose
0098 fprintf(<span class="string">'No stations found within the model domain.\n'</span>)
0099 <span class="keyword">end</span>
0100 <span class="keyword">end</span></pre></div>
<hr><address>Generated on Tue 04-Jun-2013 12:12:57 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
</body>
</html>
\ No newline at end of file
......@@ -105,7 +105,7 @@ This function is called by:
0031 <span class="comment">%</span>
0032 <span class="comment">%==============================================================================</span>
0033
0034 warning off
0034 <span class="comment">%warning off</span>
0035
0036 subname = <span class="string">'add_var_FVCOM_river'</span>;
0037 <span class="keyword">global</span> ftbverbose;
......@@ -172,6 +172,6 @@ This function is called by:
0098 fprintf([<span class="string">'end : '</span> subname <span class="string">'\n'</span>])
0099 <span class="keyword">end</span>;
0100</pre></div>
<hr><address>Generated on Tue 18-Dec-2012 12:37:31 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
<hr><address>Generated on Tue 04-Jun-2013 12:12:57 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
</body>
</html>
\ No newline at end of file
......@@ -56,7 +56,7 @@
<h2><a name="_cross"></a>CROSS-REFERENCE INFORMATION <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2>
This function calls:
<ul style="list-style-image:url(../matlabicon.gif)">
<li><a href="add_coriolis.html" class="code" title="function [Mobj] = add_coriolis(Mobj,cortype,fval)">add_coriolis</a> Generate latitude used for FVCOM Coriolis file</li><li><a href="add_obc_nodes_list.html" class="code" title="function [Mobj] = add_obc_nodes_list(Mobj,Nlist,ObcName,ObcType,plotFig)">add_obc_nodes_list</a> Add a set of obc nodes comprising a single obc boundary to Mesh structure</li><li><a href="add_river_nodes_list.html" class="code" title="function [Mobj] = add_river_nodes(Mobj,Nlist,RiverName)">add_river_nodes_list</a> Add a set of river nodes comprising a single river to Mesh structure</li><li><a href="elems2nodes.html" class="code" title="function [fieldout] = elems2nodes(fieldin,Mobj)">elems2nodes</a> Transfer a field from elements to vertices</li><li><a href="estimate_ts.html" class="code" title="function [Mobj] = estimate_ts(Mobj,u,zeta)">estimate_ts</a> Estimate time step at each node</li><li><a href="example_FVCOM_river.html" class="code" title="function example_FVCOM_river()">example_FVCOM_river</a> example file for dumping an FVCOM river file and adding sediment concentration</li><li><a href="example_FVCOM_tsobc.html" class="code" title="function example_FVCOM_tsobc(basename,time,nSiglay)">example_FVCOM_tsobc</a> example file for dumping a file to force temperature and salinity at the open b.</li><li><a href="example_FVCOM_wind_ts.html" class="code" title="function example_FVCOM_wind_ts">example_FVCOM_wind_ts</a> example file for FVCOM, time-varying/spatially constant wind forcing as stress</li><li><a href="nodes2elems.html" class="code" title="function [fieldout] = nodes2elems(fieldin,Mobj)">nodes2elems</a> Transfer a field from vertices to elements</li><li><a href="plot_field.html" class="code" title="function plot_field(Mobj,PlotField,varargin)">plot_field</a> Plot the mesh, user defined field, open boundary nodes, and river points</li><li><a href="read_sms_mesh.html" class="code" title="function [Mobj] = read_sms_mesh(varargin)">read_sms_mesh</a> Read sms mesh files into Matlab mesh object</li><li><a href="set_spectide.html" class="code" title="function set_spectide(Mobj,nComps,SpectralFile,MyTitle)">set_spectide</a> Setup spectral tides on the open boundary and dump a spectral file</li><li><a href="setup_metrics.html" class="code" title="function [Mobj] = setup_metrics(Mobj)">setup_metrics</a> Setup metrics for mesh object Mesh</li><li><a href="smoothfield.html" class="code" title="function [field] = smoothfield(fieldin,Mobj,SmoothFactor,nLoops,SmoothPts)">smoothfield</a> Smooth a vertex-based field using averages</li><li><a href="write_FVCOM_bath.html" class="code" title="function write_FVCOM_bath(Mobj,filename)">write_FVCOM_bath</a> Write bathymetry to FVCOM format bathymetry file</li><li><a href="write_FVCOM_bedflag.html" class="code" title="function write_FVCOM_bedflag(bedflag,filename,mytitle)">write_FVCOM_bedflag</a> Dump spatially-variable flag (bedflag) to FVCOM forcing file</li><li><a href="write_FVCOM_cor.html" class="code" title="function write_FVCOM_cor(Mobj,filename)">write_FVCOM_cor</a> Write coriolis to FVCOM format coriolis file</li><li><a href="write_FVCOM_grid.html" class="code" title="function write_FVCOM_grid(Mobj,filename)">write_FVCOM_grid</a> Write grid and connectivity to FVCOM format grid file</li><li><a href="write_FVCOM_obc.html" class="code" title="function write_FVCOM_obc(Mobj,filename)">write_FVCOM_obc</a> Write FVCOM format open boundary node list file</li><li><a href="write_FVCOM_sponge.html" class="code" title="function write_FVCOM_sponge(Mobj,filename)">write_FVCOM_sponge</a> Write FVCOM format sponge layer file</li><li><a href="write_FVCOM_z0.html" class="code" title="function write_FVCOM_z0(z0,filename,mytitle)">write_FVCOM_z0</a> Dump spatially-variable or uniform bottom roughness (z0) to FVCOM forcing</li></ul>
<li><a href="add_coriolis.html" class="code" title="function [Mobj] = add_coriolis(Mobj,cortype,fval)">add_coriolis</a> Generate latitude used for FVCOM Coriolis file</li><li><a href="add_obc_nodes_list.html" class="code" title="function [Mobj] = add_obc_nodes_list(Mobj,Nlist,ObcName,ObcType,plotFig)">add_obc_nodes_list</a> Add a set of obc nodes comprising a single obc boundary to Mesh structure</li><li><a href="add_river_nodes_list.html" class="code" title="function [Mobj] = add_river_nodes_list(Mobj,Nlist,RiverName)">add_river_nodes_list</a> Add a set of river nodes comprising a single river to Mesh structure</li><li><a href="elems2nodes.html" class="code" title="function [fieldout] = elems2nodes(fieldin,Mobj)">elems2nodes</a> Transfer a field from elements to vertices</li><li><a href="estimate_ts.html" class="code" title="function [Mobj] = estimate_ts(Mobj,u,zeta)">estimate_ts</a> Estimate time step at each node</li><li><a href="example_FVCOM_river.html" class="code" title="function example_FVCOM_river()">example_FVCOM_river</a> example file for dumping an FVCOM river file and adding sediment concentration</li><li><a href="example_FVCOM_tsobc.html" class="code" title="function example_FVCOM_tsobc(basename,time,nSiglay)">example_FVCOM_tsobc</a> example file for dumping a file to force temperature and salinity at the open b.</li><li><a href="example_FVCOM_wind_ts.html" class="code" title="function example_FVCOM_wind_ts">example_FVCOM_wind_ts</a> example file for FVCOM, time-varying/spatially constant wind forcing as stress</li><li><a href="nodes2elems.html" class="code" title="function [fieldout] = nodes2elems(fieldin,Mobj)">nodes2elems</a> Transfer a field from vertices to elements</li><li><a href="plot_field.html" class="code" title="function plot_field(Mobj,PlotField,varargin)">plot_field</a> Plot the mesh, user defined field, open boundary nodes, and river points</li><li><a href="read_sms_mesh.html" class="code" title="function [Mobj] = read_sms_mesh(varargin)">read_sms_mesh</a> Read sms mesh files into Matlab mesh object</li><li><a href="set_spectide.html" class="code" title="function set_spectide(Mobj,nComps,SpectralFile,MyTitle)">set_spectide</a> Setup spectral tides on the open boundary and dump a spectral file</li><li><a href="setup_metrics.html" class="code" title="function [Mobj] = setup_metrics(Mobj)">setup_metrics</a> Setup metrics for mesh object Mesh</li><li><a href="smoothfield.html" class="code" title="function [field] = smoothfield(fieldin,Mobj,SmoothFactor,nLoops,SmoothPts)">smoothfield</a> Smooth a vertex-based field using averages</li><li><a href="write_FVCOM_bath.html" class="code" title="function write_FVCOM_bath(Mobj,filename)">write_FVCOM_bath</a> Write bathymetry to FVCOM format bathymetry file</li><li><a href="write_FVCOM_bedflag.html" class="code" title="function write_FVCOM_bedflag(bedflag,filename,mytitle)">write_FVCOM_bedflag</a> Dump spatially-variable flag (bedflag) to FVCOM forcing file</li><li><a href="write_FVCOM_cor.html" class="code" title="function write_FVCOM_cor(Mobj,filename)">write_FVCOM_cor</a> Write coriolis to FVCOM format coriolis file</li><li><a href="write_FVCOM_grid.html" class="code" title="function write_FVCOM_grid(Mobj,filename)">write_FVCOM_grid</a> Write grid and connectivity to FVCOM format grid file</li><li><a href="write_FVCOM_obc.html" class="code" title="function write_FVCOM_obc(Mobj,filename)">write_FVCOM_obc</a> Write FVCOM format open boundary node list file</li><li><a href="write_FVCOM_sponge.html" class="code" title="function write_FVCOM_sponge(Mobj,filename)">write_FVCOM_sponge</a> Write FVCOM format sponge layer file</li><li><a href="write_FVCOM_z0.html" class="code" title="function write_FVCOM_z0(z0,filename,mytitle)">write_FVCOM_z0</a> Dump spatially-variable or uniform bottom roughness (z0) to FVCOM forcing</li></ul>
This function is called by:
<ul style="list-style-image:url(../matlabicon.gif)">
</ul>
......@@ -119,7 +119,7 @@ This function is called by:
0052 <a href="plot_field.html" class="code" title="function plot_field(Mobj,PlotField,varargin)">plot_field</a>(Mobj,Mobj.h,<span class="string">'title'</span>,<span class="string">'smoothed bathymetry'</span>);
0053
0054 <span class="comment">% setup spatially variable bottom roughness and dump to file</span>
0055 hc = <a href="nodes2elems.html" class="code" title="function [fieldout] = nodes2elems(fieldin,Mobj)">nodes2elems</a>(Mobj.h,Mobj);
0055 hc = <a href="nodes2elems.html" class="code" title="function [fieldout] = nodes2elems(fieldin,Mobj)">nodes2elems</a>(Mobj.h,Mobj);
0056 z0 = .008*ones(Mobj.nElems,1);
0057 deep = find(hc &gt; 5.);
0058 z0(deep) = .004;
......@@ -129,7 +129,7 @@ This function is called by:
0062
0063 <span class="comment">% add a river to the domain</span>
0064 <span class="comment">%[Mobj] = add_river_nodes_graphic(Mobj,'tstRiver');</span>
0065 [Mobj] = <a href="add_river_nodes_list.html" class="code" title="function [Mobj] = add_river_nodes(Mobj,Nlist,RiverName)">add_river_nodes_list</a>(Mobj,[838,844,845],<span class="string">'tstRiver'</span>);
0065 [Mobj] = <a href="add_river_nodes_list.html" class="code" title="function [Mobj] = add_river_nodes_list(Mobj,Nlist,RiverName)">add_river_nodes_list</a>(Mobj,[838,844,845],<span class="string">'tstRiver'</span>);
0066
0067 <span class="comment">% add an open boundary to the Mesh</span>
0068 [Mobj] = <a href="add_obc_nodes_list.html" class="code" title="function [Mobj] = add_obc_nodes_list(Mobj,Nlist,ObcName,ObcType,plotFig)">add_obc_nodes_list</a>(Mobj,[1:25],<span class="string">'OpenOcean'</span>,1);
......@@ -185,6 +185,6 @@ This function is called by:
0118 <a href="write_FVCOM_cor.html" class="code" title="function write_FVCOM_cor(Mobj,filename)">write_FVCOM_cor</a>(Mobj,<span class="string">'tst_cor.dat'</span>)
0119
0120</pre></div>
<hr><address>Generated on Tue 18-Dec-2012 12:37:31 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
<hr><address>Generated on Tue 04-Jun-2013 12:12:57 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
</body>
</html>
\ No newline at end of file
......@@ -50,7 +50,7 @@
<h2><a name="_cross"></a>CROSS-REFERENCE INFORMATION <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2>
This function calls:
<ul style="list-style-image:url(../matlabicon.gif)">
<li><a href="add_var_FVCOM_river.html" class="code" title="function add_var_FVCOM_river(RiverFile,VarName,VarLongName,VarUnits,VarData)">add_var_FVCOM_river</a> add time dependent scalar variable to a Riverfile</li><li><a href="write_FVCOM_river.html" class="code" title="function write_FVCOM_river(RiverFile,RiverName,nRivnodes,time,flux,temp,salt,RiverInfo1,RiverInfo2)">write_FVCOM_river</a> write FVCOM 3.x NetCDF river file</li></ul>
<li><a href="add_var_FVCOM_river.html" class="code" title="function add_var_FVCOM_river(RiverFile,VarName,VarLongName,VarUnits,VarData)">add_var_FVCOM_river</a> add time dependent scalar variable to a Riverfile</li><li><a href="write_FVCOM_river.html" class="code" title="function write_FVCOM_river(RiverFile,RiverName,time,flux,temp,salt,RiverInfo1,RiverInfo2)">write_FVCOM_river</a> Write FVCOM 3.x NetCDF river file</li></ul>
This function is called by:
<ul style="list-style-image:url(../matlabicon.gif)">
<li><a href="example.html" class="code" title="">example</a> example demonstrating reading in a 2DM file and constructing a model</li></ul>
......@@ -103,7 +103,7 @@ This function is called by:
0042 RiverName = <span class="string">'tstRiver'</span>;
0043
0044
0045 <a href="write_FVCOM_river.html" class="code" title="function write_FVCOM_river(RiverFile,RiverName,nRivnodes,time,flux,temp,salt,RiverInfo1,RiverInfo2)">write_FVCOM_river</a>(RiverFile,RiverName,nRivnodes,time,flux,temp,salt,RiverInfo1,RiverInfo2)
0045 <a href="write_FVCOM_river.html" class="code" title="function write_FVCOM_river(RiverFile,RiverName,time,flux,temp,salt,RiverInfo1,RiverInfo2)">write_FVCOM_river</a>(RiverFile,RiverName,nRivnodes,time,flux,temp,salt,RiverInfo1,RiverInfo2)
0046
0047 <span class="comment">% add sediment to the file</span>
0048 VarName = <span class="string">'fine_sand'</span>;
......@@ -123,6 +123,6 @@ This function is called by:
0062 VarUnits = <span class="string">'kgm^-3'</span>;
0063 VarData = .333*sedload;
0064 <a href="add_var_FVCOM_river.html" class="code" title="function add_var_FVCOM_river(RiverFile,VarName,VarLongName,VarUnits,VarData)">add_var_FVCOM_river</a>(RiverFile,VarName,VarLongName,VarUnits,VarData)</pre></div>
<hr><address>Generated on Tue 18-Dec-2012 12:37:31 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
<hr><address>Generated on Tue 04-Jun-2013 12:12:57 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
</body>
</html>
\ No newline at end of file
......@@ -97,7 +97,7 @@ This function is called by:
0027 <span class="comment">%</span>
0028 <span class="comment">%==============================================================================</span>
0029
0030 warning off;
0030 <span class="comment">%warning off;</span>
0031
0032
0033 subname = <span class="string">'example_FVCOM_tsobc'</span>;
......@@ -197,7 +197,7 @@ This function is called by:
0127 netcdf.putAtt(nc,netcdf.getConstant(<span class="string">'NC_GLOBAL'</span>),<span class="string">'type'</span>,<span class="string">'FVCOM RIVER FORCING FILE'</span>)
0128 netcdf.putAtt(nc,netcdf.getConstant(<span class="string">'NC_GLOBAL'</span>),<span class="string">'title'</span>,<span class="string">'simple open boundary hydrography test'</span>)
0129 netcdf.putAtt(nc,netcdf.getConstant(<span class="string">'NC_GLOBAL'</span>),<span class="string">'type'</span>,<span class="string">'FVCOM TIME SERIES OBC TS FILE'</span>)
0130 netcdf.putAtt(nc,netcdf.getConstant(<span class="string">'NC_GLOBAL'</span>),<span class="string">'history'</span>,<span class="string">'generated using the fvcom-toolbox'</span>)
0130 netcdf.putAtt(nc,netcdf.getConstant(<span class="string">'NC_GLOBAL'</span>),<span class="string">'history'</span>,<span class="string">'File generated using example_FVCOM_tsobc.m from the MATLAB fvcom-toolbox'</span>)
0131
0132
0133 <span class="comment">% define dimensions</span>
......@@ -276,6 +276,6 @@ This function is called by:
0206 netcdf.close(nc);
0207
0208 <span class="keyword">if</span>(ftbverbose); fprintf([<span class="string">'end : '</span> subname <span class="string">'\n'</span>]);<span class="keyword">end</span>;</pre></div>
<hr><address>Generated on Tue 18-Dec-2012 12:37:31 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
<hr><address>Generated on Tue 04-Jun-2013 12:12:57 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
</body>
</html>
\ No newline at end of file
......@@ -50,7 +50,8 @@
Revision history
==============================================================================</pre></div>
==============================================================================
warning off</pre></div>
<!-- crossreference -->
<h2><a name="_cross"></a>CROSS-REFERENCE INFORMATION <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2>
......@@ -91,7 +92,7 @@ This function is called by:
0024 <span class="comment">% Revision history</span>
0025 <span class="comment">%</span>
0026 <span class="comment">%==============================================================================</span>
0027 warning off
0027 <span class="comment">%warning off</span>
0028 subname = <span class="string">'example_FVCOM_wind_ts'</span>;
0029 <span class="keyword">global</span> ftbverbose;
0030 <span class="keyword">if</span>(ftbverbose);
......@@ -181,6 +182,6 @@ This function is called by:
0114
0115
0116</pre></div>
<hr><address>Generated on Tue 18-Dec-2012 12:37:31 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
<hr><address>Generated on Tue 04-Jun-2013 12:12:57 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
</body>
</html>
\ No newline at end of file
......@@ -50,7 +50,8 @@
Revision history
==============================================================================</pre></div>
==============================================================================
warning off</pre></div>
<!-- crossreference -->
<h2><a name="_cross"></a>CROSS-REFERENCE INFORMATION <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2>
......@@ -91,7 +92,7 @@ This function is called by:
0024 <span class="comment">% Revision history</span>
0025 <span class="comment">%</span>
0026 <span class="comment">%==============================================================================</span>
0027 warning off
0027 <span class="comment">%warning off</span>
0028 subname = <span class="string">'example_FVCOM_wind_ts'</span>;
0029 fprintf(<span class="string">'\n'</span>)
0030 fprintf([<span class="string">'begin : '</span> subname <span class="string">'\n'</span>])
......@@ -170,6 +171,6 @@ This function is called by:
0103
0104
0105</pre></div>
<hr><address>Generated on Tue 18-Dec-2012 12:37:31 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
<hr><address>Generated on Tue 04-Jun-2013 12:12:57 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
</body>
</html>
\ No newline at end of file
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/REC-html40/loose.dtd">
<html>
<head>
<title>Description of example_init_lag</title>
<meta name="keywords" content="example_init_lag">
<meta name="description" content="">
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="generator" content="m2html v1.5 &copy; 2003-2005 Guillaume Flandin">
<meta name="robots" content="index, follow">
<link type="text/css" rel="stylesheet" href="../m2html.css">
</head>
<body>
<a name="_top"></a>
<div><a href="../index.html">Home</a> &gt; <a href="index.html">fvcom_prepro</a> &gt; example_init_lag.m</div>
<!--<table width="100%"><tr><td align="left"><a href="../index.html"><img alt="<" border="0" src="../left.png">&nbsp;Master index</a></td>
<td align="right"><a href="index.html">Index for fvcom_prepro&nbsp;<img alt=">" border="0" src="../right.png"></a></td></tr></table>-->
<h1>example_init_lag
</h1>
<h2><a name="_name"></a>PURPOSE <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2>
<div class="box"><strong></strong></div>
<h2><a name="_synopsis"></a>SYNOPSIS <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2>
<div class="box"><strong>This is a script file. </strong></div>
<h2><a name="_description"></a>DESCRIPTION <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2>
<div class="fragment"><pre class="comment"></pre></div>
<!-- crossreference -->
<h2><a name="_cross"></a>CROSS-REFERENCE INFORMATION <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2>
This function calls:
<ul style="list-style-image:url(../matlabicon.gif)">
<li><a href="plot_field.html" class="code" title="function plot_field(Mobj,PlotField,varargin)">plot_field</a> Plot the mesh, user defined field, open boundary nodes, and river points</li><li><a href="read_fvcom_bath.html" class="code" title="function [h] = read_fvcom_bath(bathfile)">read_fvcom_bath</a> Read fvcom bathymetry file</li><li><a href="read_fvcom_mesh.html" class="code" title="function [Mobj] = read_fvcom_mesh(gridfile)">read_fvcom_mesh</a> Read fvcom mesh file into Matlab mesh object</li><li><a href="setup_metrics.html" class="code" title="function [Mobj] = setup_metrics(Mobj)">setup_metrics</a> Setup metrics for mesh object Mesh</li></ul>
This function is called by:
<ul style="list-style-image:url(../matlabicon.gif)">
</ul>
<!-- crossreference -->
<h2><a name="_source"></a>SOURCE CODE <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2>
<div class="fragment"><pre>0001 clear all; close all;
0002
0003 <span class="comment">% example script:</span>
0004 <span class="comment">% initialize the online Lagrangian tracking for Julian day (realtime) forcing</span>
0005 <span class="comment">%</span>
0006 <span class="comment">% Author(s):</span>
0007 <span class="comment">% Geoff Cowles (University of Massachusetts Dartmouth)</span>
0008 <span class="comment">%</span>
0009 <span class="comment">% Revision history</span>
0010 <span class="comment">%</span>
0011 <span class="comment">%==============================================================================</span>
0012 <span class="comment">%warning off</span>
0013 type = 2;
0014
0015 <span class="comment">% set mesh/bathymetry files</span>
0016 meshfile = <span class="string">'../Model_Maker/coos01_grd.dat'</span>;
0017 bathfile = <span class="string">'../Model_Maker/coos01_dep.dat'</span>;
0018 lagfile = <span class="string">'test_lag.nc'</span>;
0019
0020 <span class="comment">% start/end time for particles</span>
0021 tbeg = greg2mjulian(2008,01,01,0,0,0);
0022 tend = greg2mjulian(2008,02,01,0,0,0);
0023
0024 <span class="comment">% read in mesh and bathymetry</span>
0025 Mobj = <a href="read_fvcom_mesh.html" class="code" title="function [Mobj] = read_fvcom_mesh(gridfile)">read_fvcom_mesh</a>(meshfile);
0026 Mobj.h = <a href="read_fvcom_bath.html" class="code" title="function [h] = read_fvcom_bath(bathfile)">read_fvcom_bath</a>(bathfile); Mobj.have_bath = true;
0027 Mobj = <a href="setup_metrics.html" class="code" title="function [Mobj] = setup_metrics(Mobj)">setup_metrics</a>(Mobj);
0028
0029
0030 <span class="keyword">if</span>(type==1) <span class="comment">%initialize at all elements</span>
0031
0032 xc = Mobj.xc;
0033 yc = Mobj.yc;
0034 nLag = Mobj.nElems;
0035
0036 <span class="keyword">elseif</span>(type==2) <span class="comment">%initialize along a line of interest</span>
0037 nLag = 10;
0038 p1 = [1.188363e6,194497];
0039 p2 = [1.188548e6,194996];
0040 xp = p1(1):(p2(1)-p1(1))/(nLag-1):p2(1);
0041 yp = p1(2):(p2(2)-p1(2))/(nLag-1):p2(2);
0042
0043 <span class="keyword">end</span>;
0044
0045
0046 <span class="comment">% plot to check</span>
0047 <a href="plot_field.html" class="code" title="function plot_field(Mobj,PlotField,varargin)">plot_field</a>(Mobj,Mobj.h,<span class="string">'title'</span>,<span class="string">'domain'</span>,<span class="string">'withextra'</span>,false,<span class="string">'showgrid'</span>,false); hold on;
0048 plot(xp,yp,<span class="string">'ro'</span>);
0049
0050
0051 <span class="comment">% dump the initial particle position file</span>
0052 nc = netcdf(lagfile,<span class="string">'clobber'</span>);
0053 nc.references = <span class="string">'http://fvcom.smast.umassd.edu'</span>;
0054 nc.source = <span class="string">'lag_init.m'</span>;
0055 nc.info = <span class="string">'debugging '</span>;
0056
0057
0058
0059
0060
0061
0062 <span class="comment">% dimensions</span>
0063 nc(<span class="string">'nparticles'</span>) = nLag;
0064
0065 <span class="comment">% particle vars</span>
0066 nc{<span class="string">'x'</span>} = ncfloat(<span class="string">'nparticles'</span>);
0067 nc{<span class="string">'x'</span>}.long_name = <span class="string">'particle x position'</span>;
0068 nc{<span class="string">'x'</span>}.units = <span class="string">'m'</span>;
0069
0070 nc{<span class="string">'y'</span>} = ncfloat(<span class="string">'nparticles'</span>);
0071 nc{<span class="string">'y'</span>}.long_name = <span class="string">'particle y position'</span>;
0072 nc{<span class="string">'y'</span>}.units = <span class="string">'m'</span>;
0073
0074 nc{<span class="string">'z'</span>} = ncfloat(<span class="string">'nparticles'</span>);
0075 nc{<span class="string">'z'</span>}.long_name = <span class="string">'particle z position'</span>;
0076 nc{<span class="string">'z'</span>}.units = <span class="string">'m'</span>;
0077
0078 nc{<span class="string">'pathlength'</span>} = ncfloat(<span class="string">'nparticles'</span>);
0079 nc{<span class="string">'pathlength'</span>}.long_name = <span class="string">'particle integrated path length'</span>;
0080 nc{<span class="string">'pathlength'</span>}.units = <span class="string">'m'</span>;
0081
0082 nc{<span class="string">'tbeg'</span>} = ncfloat(<span class="string">'nparticles'</span>);
0083 nc{<span class="string">'tbeg'</span>}.long_name = <span class="string">'particle release time'</span>;
0084 nc{<span class="string">'tbeg'</span>}.units = <span class="string">'days since 1858-11-17 00:00:00'</span>;
0085 nc{<span class="string">'tbeg'</span>}.format = <span class="string">'modified julian day (MJD)'</span>;
0086 nc{<span class="string">'tbeg'</span>}.time_zone = <span class="string">'UTC'</span>;
0087
0088 nc{<span class="string">'tend'</span>} = ncfloat(<span class="string">'nparticles'</span>);
0089 nc{<span class="string">'tend'</span>}.long_name = <span class="string">'particle freeze time'</span>;
0090 nc{<span class="string">'tend'</span>}.units = <span class="string">'days since 1858-11-17 00:00:00'</span>;
0091 nc{<span class="string">'tend'</span>}.format = <span class="string">'modified julian day (MJD)'</span>;
0092 nc{<span class="string">'tend'</span>}.time_zone = <span class="string">'UTC'</span>;
0093
0094
0095 nc{<span class="string">'group'</span>} = ncint(<span class="string">'nparticles'</span>);
0096 nc{<span class="string">'group'</span>}.long_name = <span class="string">'particle group'</span>;
0097 nc{<span class="string">'group'</span>}.units = <span class="string">'-'</span>;
0098
0099 nc{<span class="string">'mark'</span>} = ncint(<span class="string">'nparticles'</span>);
0100 nc{<span class="string">'mark'</span>}.long_name = <span class="string">'particle mark'</span>;
0101 nc{<span class="string">'mark'</span>}.units = <span class="string">'-'</span>;
0102
0103 <span class="comment">% dump vars</span>
0104 nc{<span class="string">'x'</span>}(:) = xp;
0105 nc{<span class="string">'y'</span>}(:) = yp;
0106 nc{<span class="string">'z'</span>}(:) = 0.0;
0107 nc{<span class="string">'tbeg'</span>}(:) = tbeg;
0108 nc{<span class="string">'tend'</span>}(:) = tend;
0109 nc{<span class="string">'group'</span>}(:) = 1;
0110 nc{<span class="string">'mark'</span>}(:) = 0;
0111 nc{<span class="string">'pathlength'</span>}(:) = 0.0;
0112 close(nc);</pre></div>
<hr><address>Generated on Tue 04-Jun-2013 12:12:57 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address>
</body>
</html>
\ No newline at end of file
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/REC-html40/loose.dtd">
<html>
<head>
<title>Description of get_FVCOM_rivers</title>
<meta name="keywords" content="get_FVCOM_rivers">
<meta name="description" content="Extract river discharges from the supplied river positions for the FVCOM">
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="generator" content="m2html v1.5 &copy; 2003-2005 Guillaume Flandin">
<meta name="robots" content="index, follow">
<link type="text/css" rel="stylesheet" href="../m2html.css">
</head>
<body>
<a name="_top"></a>
<div><a href="../index.html">Home</a> &gt; <a href="index.html">fvcom_prepro</a> &gt; get_FVCOM_rivers.m</div>
<!--<table width="100%"><tr><td align="left"><a href="../index.html"><img alt="<" border="0" src="../left.png">&nbsp;Master index</a></td>
<td align="right"><a href="index.html">Index for fvcom_prepro&nbsp;<img alt=">" border="0" src="../right.png"></a></td></tr></table>-->
<h1>get_FVCOM_rivers
</h1>
<h2><a name="_name"></a>PURPOSE <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2>
<div class="box"><strong>Extract river discharges from the supplied river positions for the FVCOM</strong></div>
<h2><a name="_synopsis"></a>SYNOPSIS <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2>
<div class="box"><strong>function Mobj = get_FVCOM_rivers(Mobj, dist_thresh) </strong></div>
<h2><a name="_description"></a>DESCRIPTION <a href="#_top"><img alt="^" border="0" src="../up.png"></a></h2>
<div class="fragment"><pre class="comment"> Extract river discharges from the supplied river positions for the FVCOM
grid in Mobj.
get_FVCOM_rivers(Mobj, rivers, dist_thresh)
DESCRIPTION:
For the positioins in fvcom_xy, find the nearest unstructured grid node
and extract the river discharge from polcoms_flow. If dist_thresh is
specified, the river positions must fall within the specified distance.
If multiple rivers are assigned to the same node, their discharges are
summed. The resulting river name is generated from the contributing
rives, separated by a hyphen.
INPUT:
Mobj - MATLAB mesh object containing:
* have_lonlat - boolean to check for spherical coordinates.
* lon, lat - positions for the unstructured grid.
* tri - triangulation table for the unstructured grid.
* nVerts - number of nodes in the grid.
* read_obc_nodes - open boundary node IDs.
* rivers - river data struct with the following fields:
- year - start year of the river data time series.
- positions - river positions in lon, lat.
- names - list of river names (whose order must match the
positions in xy).
- discharge - river discharge data (again, order of columns