Changeset 5555

Jul 22, 2008, 4:16:10 PM (11 years ago)

John added information on STS format to ANUGA manual

1 edited


  • anuga_core/documentation/user_manual/anuga_user_manual.tex

    r5508 r5555  
    20752075specified interpolation points from a NetCDF file (\code{filename})
    20762076and returns
    2077 a callable object. \code{filename} could be a \code{sww} file.
     2077a callable object. \code{filename} could be a \code{sww} or \code{sts} file.
    20782078Returns interpolated values based on the input
    20792079file using the underlying \code{interpolation\_function}.
    20872087for points at which values are sought.
     2089\code{boundary_polygon} is a list of coordinates specifying the vertices of the boundary. This must be the same polygon as used when calling \code{create_mesh_from_regions}. This argument can only be used when reading boundary data from the STS format.
    20892091The model time stored within the file function can be accessed using
    20902092the method \code{f.get\_time()}
    20932095The underlying algorithm used is as follows:\\
    20942096Given a time series (i.e.\ a series of values associated with
    2095 different times), whose values are either just numbers or a set of
     2097different times), whose values are either just numbers, a set of
    20962098 numbers defined at the vertices of a triangular mesh (such as those
    2097  stored in SWW files), \code{Interpolation\_function} is used to
     2099 stored in SWW files) or a set of
     2100 numbers defined at a number of points on the boundary (such as those
     2101 stored in STS files), \code{Interpolation\_function} is used to
    20982102 create a callable object that interpolates a value for an arbitrary
    20992103 time \code{t} within the model limits and possibly a point \code{(x,
    21072111 \code{quantities}. The optional arguments \code{vertex\_coordinates}
    21082112 and \code{triangles} represent the spatial mesh associated with the
    2109  quantity arrays. If omitted the function created by
    2110  \code{Interpolation\_function} will be a function of \code{t} only.
     2113 quantity arrays. If omitted the function must be created using an STS file
     2114 or a TMS file.
    21122116 Since, in practice, values need to be computed at specified points,
    22452249Module: \module{abstract\_2d\_finite\_volumes.generic\_boundary\_conditions}
    2247 This method may be used if the user wishes to apply a SWW file or
    2248 a time series file to a boundary segment or segments.
     2251This method may be used if the user wishes to apply a SWW file, STS file or
     2252a time series file (TMS) to a boundary segment or segments.
    22492253The boundary values are obtained from a file and interpolated to the
    22502254appropriate segments for each conserved quantity.
    2846 \code{.sww} & NetCDF format for storing model output
     2850\code{.sww} & NetCDF format for storing model output with mesh information
     2853\code{.sts} & NetCDF format for storing model ouput \code{f(t,x,y)} without any mesh information\\
    28492855\code{.tms} & NetCDF format for storing time series \code{f(t)}\\
    2922 \subsection{SWW and TMS Formats}
     2928\subsection{SWW, STS and TMS Formats}
    29232929\label{sec:sww format}
    2925 The SWW and TMS formats are both NetCDF formats, and are of key
     2931The SWW, STS and TMS formats are all NetCDF formats, and are of key
    29262932importance for \anuga.
    29602966for functions such as \function{file\_boundary} and
    29612967\function{file\_function}, described in Chapter \ref{ch:interface}.
     2969An STS file is used for storing a set of points and and associated set of times.
     2970It contains, in addition to dimension information, the following
     2973    \item \code{x} and \code{y}: coordinates of the points, represented as Numeric arrays
     2974    \item \code{elevation}, a Numeric array storing bed-elevations
     2975    % Refer here to the example to be provided in describing the simple example
     2976    \item \code{time}, a Numeric array containing times for model
     2977    evaluation
     2979The only difference between the STS format and the SWW format is the former does not contain a list specifying the points at the vertices of each of the triangles (\code{volumes}). Consequenlty information (arrays) stored within an STS file such as \code{elevation} can be accessed in exactly the same way as it would be extraced from an SWW file.
    29632981A TMS file is used to store time series data that is independent of
    30913109  Takes DEM data (a NetCDF file representation of data from a regular Digital
    30923110  Elevation Model) and converts it to PTS format.
     3111  \end{funcdesc}
     3113  \begin{funcdesc}{urs2sts}{basename_in, basename_out=None,
     3114            weights=None, verbose=False,
     3115            origin=None,mean_stage=0.0,
     3116            zscale=1.0, ordering_filename=None}
     3117  Module: \module{shallow\\_manager}
     3119  Takes urs data in (timeseries data in mux2 format) and converts it to STS format.
    30933120  \end{funcdesc}
    43454372G2 = Geospatial_data(file_name = 25m_dem_name + '.pts')
    43464373G = G1 + G2
    4347 G.export_points_file(combined_dem_name + ‘.pts’)
     4374G.export_points_file(combined_dem_name + ï¿œ.ptsï¿œ)
    43494376this is the basic way of combining data sets, however, the user will need to
Note: See TracChangeset for help on using the changeset viewer.