Changeset 2780


Ignore:
Timestamp:
Apr 28, 2006, 3:37:51 PM (19 years ago)
Author:
howard
Message:

Added further material on file formats to Ch 5

File:
1 edited

Legend:

Unmodified
Added
Removed
  • documentation/user_manual/anuga_user_manual.tex

    r2779 r2780  
    15041504
    15051505
    1506 \subsection{Basic file conversions}
     1506
     1507
     1508\bigskip
     1509
     1510\subsection{SWW and TMS Formats}
     1511
     1512The SWW and TMS formats are both NetCDF formats, and are of key
     1513importance for \anuga.
     1514
     1515An SWW file is used for storing \anuga output.
     1516
     1517The contents of an SWW file may be viewed using the visualisation
     1518tool \code{swollen}, which creates an on-screen geometric
     1519representation. See section \ref{sec:swollen} (page
     1520\pageref{sec:swollen}) in Appendix \ref{ch:supportingtools} for more
     1521on \code{swollen}.
     1522
     1523Alternatively, there are tools, such as \code{ncdump}, that allow
     1524you to convert an NetCDF file into a readable format such as the
     1525Class Definition Language (CDL). The following is an excerpt from a
     1526CDL representation of the output file \file{bedslope.sww} generated
     1527from running the simple example \filename{bedslopephysical.py}.
     1528
     1529\verbatiminput{examples/bedslopeexcerpt.cdl}
     1530
     1531The data stored in an SWW file pertains to a specific set of points
     1532and timesteps and comprises the following:
     1533
     1534\begin{enumerate}
     1535    \item Dimension information, stored as a number of constants.
     1536    \item Variables \code{x} and \code{y}, storing coordinates of
     1537    the points, represented as Numeric arrays.
     1538    \item A variable \code{elevation}, storing bed-elevations at the
     1539    points, also as a Numeric array.
     1540    \item A variable \code{volumes}
     1541    \item A variable \code{time},
     1542\end{enumerate}
     1543
     1544
     1545
     1546\subsection{Meshfile Formats}
     1547
     1548A meshfile is a file that has a specific format suited to data used
     1549to specify a mesh suitable for use with \anuga. A meshfile can have
     1550one of two formats: it can be either a TSH file, which is an ASCII
     1551file, or an MSH file, which is a NetCDF file.
     1552
     1553A meshfile describes the outline of the mesh---the vertices and line
     1554segments that enclose the region in which the mesh is created---and
     1555the triangular mesh itself, which is specified by listing the
     1556triangles and their vertices, and the segments, which are those
     1557sides of the triangles that are associated with boundary conditions.
     1558
     1559In addition, a meshfile may contain `holes' and/or `regions'. A hole
     1560or region is defined by specifying a point and a number of segments
     1561that enclose the point. A hole represents an area where no mesh is
     1562to be created, while a region is a labelled area used for defining
     1563properties of a mesh, such as friction values.
     1564
     1565A meshfile can also contain a georeference, which describes an
     1566offset to be applied to $x$ and $y$ values---eg to the vertices.
     1567
     1568
     1569\subsection{Formats for Storing Arbitrary Points and Attributes}
     1570
     1571
     1572\subsection{ArcView Formats}
     1573
     1574
     1575\subsection{Other Formats}
     1576
     1577\subsection{Basic File Conversions}
    15071578
    15081579  \begin{funcdesc}{sww2dem}{basename_in, basename_out = None,
     
    15231594  Module: \module{pyvolution.data\_manager}
    15241595
    1525 
     1596  Takes data from an SWW file and converts it to DEM format (ASC or
     1597  ERS)
    15261598  \end{funcdesc}
    15271599
     
    15331605  Module: \module{pyvolution.data\_manager}
    15341606
    1535 
     1607  Takes DEM data (a NetCDF file representation of data from a regular Digital
     1608  Elevation Model) and converts it to PTS format.
    15361609  \end{funcdesc}
    15371610
    1538 \bigskip
    1539 
    1540 \subsection{SWW and TMS Formats}
    1541 
    1542 The SWW and TMS formats are both NetCDF formats, and are of key
    1543 importance for \anuga.
    1544 
    1545 The output from \anuga is stored in an SWW file. The contents may be
    1546 viewed using the visualisation tool \code{swollen}, which creates an
    1547 on-screen geometric representation. See section \ref{sec:swollen}
    1548 (page \pageref{sec:swollen}) in Appendix \ref{ch:supporting_tools}
    1549  for more on \code{swollen}.
    1550 
    1551 Alternatively, there are tools, such as \code{ncdump}, that allow
    1552 you to convert an NetCDF file into a readable format such as the
    1553 Class Definition Language (CDL). The following is an excerpt from a
    1554 CDL representation of the output file \file{bedslope.sww} generated
    1555 from running the simple example \filename{bedslopephysical.py}.
    1556 
    1557 \verbatiminput{examples/bedslopeexcerpt.cdl}
    1558 
    1559 
    1560 
    1561 \subsection{Meshfile Formats}
    1562 
    1563 A meshfile is a file of a specific format used for holding data that
    1564 specifies a mesh suitable for use with \anuga. A meshfile can have
    1565 one of two formats: it can be either a TSH file, which is an ASCII
    1566 file, or an MSH file, which is a NetCDF file.
    1567 
    1568 A meshfile describes the outline of the mesh---the vertices and line
    1569 segments that enclose the region in which the mesh is created---and
    1570 the triangular mesh itself, which is specified by listing the
    1571 triangles and their vertices, and the segments, which are those
    1572 sides of the triangles that are associated with boundary conditions.
    1573 
    1574 In addition, a meshfile may contain `holes' and/or `regions'. A hole
    1575 or region is defined by specifying a point and a number of segments
    1576 that enclose the point. A hole represents an area where no mesh is
    1577 to be created, while a region is a labelled area used for defining
    1578 properties of a mesh, such as friction values.
    1579 
    1580 A meshfile can also contain a georeference, which describes the
    1581 offset of the x,y values eg, the offset of the vertices.
    1582 
    1583 
    1584 \subsection{}
    15851611
    15861612
     
    16491675
    16501676\chapter{Supporting Tools}
    1651 \label{ch:supporting_tools}
     1677\label{ch:supportingtools}
    16521678
    16531679This section describes a number of supporting tools, supplied with \anuga, that offer a
Note: See TracChangeset for help on using the changeset viewer.