Changeset 4869


Ignore:
Timestamp:
Nov 30, 2007, 4:02:48 PM (16 years ago)
Author:
sexton
Message:

updating Cairns demo for the usermanual

Location:
anuga_core
Files:
1 added
8 edited

Legend:

Unmodified
Added
Removed
  • anuga_core/documentation/user_manual/anuga_user_manual.tex

    r4853 r4869  
    12711271The user could develop a maximum absolute momentum or other expressions which can be
    12721272derived from the quantities.
     1273It must be noted here that depth is more meaningful when the elevation is positive
     1274(\code{depth} = \code{stage} &$-$& \code{elevation}) as it describes the water height
     1275above the available elevation. When the elevation is negative, depth is meauring the
     1276water height from the sea floor. With this in mind, maximum inundation maps are
     1277typically "clipped" to the coastline. However, the data input here did not contain a
     1278coastline.
    12731279
    12741280\begin{figure}[hbt]
     
    13101316
    13111317Here, the time series for the quantities stage and speed will be generated for
    1312 each gauge defined in the gauge file. Typically, stage is used over depth, particularly
    1313 for offshore gauges. In being able to interpret the output for onshore gauges however,
    1314 we use depth rather than stage. As an example output,
    1315 Figure \ref{fig:reef} shows the time series for the quantity stage (or depth for
    1316 onshore gauges) for the Elford Reef location for the slide scenario.
     1318each gauge defined in the gauge file. As described earlie, depth is more meaningful
     1319for onshore gauges, and stage is more appropriate for offshore gauges. However, the
     1320function used to generate the time series information at each gauge will plot
     1321stage or depth depending on the elevation at that gauge location. Note, if this is
     1322not required, users may update the relevation section of the function.
     1323
     1324As an example output,
     1325Figure \ref{fig:reef} shows the time series for the quantity stage for the
     1326Elford Reef location for each scenario (the elevation at this location is negative,
     1327thereby showing stage).
    13171328
    13181329\begin{figure}[hbt]
    1319 \centerline{\includegraphics[scale=0.5]{graphics/gaugeElfordReefslide.png}}
    1320 \caption{Time series information of the quantity depth for the Elford Reef location for the slide scenario.}
     1330\centerline{\includegraphics[scale=0.5]{graphics/gaugeElfordReefboth.png}}
     1331\caption{Time series information of the quantity stage for the Elford Reef location for the
     1332fixed wave and slide scenario.}
    13211333\label{fig:reef}
    13221334\end{figure}
    13231335
    1324 Note, the user may choose to compare the output for each scenario by updating
    1325 the \code{production\_dirs} as required. For example,
    1326 
    1327 {\small \begin{verbatim}
    1328 
    1329     production_dirs = {'slide': 'Slide',
    1330                        'fixed_wave': 'Fixed Wave'}
    1331 
    1332 \end{verbatim}}
    1333 
    1334 In this case, the time series output for Elford Reef would be:
     1336By contrast, the time series for depth is shown for the onshore location of the Cairns
     1337Airport for each scenario is Figure \ref{fig:airportboth}.
    13351338
    13361339\begin{figure}[hbt]
    1337 \centerline{\includegraphics[scale=0.5]{graphics/gaugeElfordReefboth.png}}
    1338 \caption{Time series information of the quantity depth for the Elford Reef location for the slide and fixed wave scenario.}
    1339 \label{fig:reefboth}
     1340\centerline{\includegraphics[scale=0.5]{graphics/gaugeCairnsAirportboth.png}}
     1341\caption{Time series information of the quantity depth for the Cairns Airport
     1342location for the slide and fixed wave scenario.}
     1343\label{fig:airportboth}
    13401344\end{figure}
    13411345
  • anuga_core/documentation/user_manual/demos/cairns/GetTimeseries.py

    r4856 r4869  
    2121
    2222# nominate directory location of sww file with associated attribute
    23 production_dirs = {#'slide': 'Slide',
     23production_dirs = {'slide': 'Slide',
    2424                   'fixed_wave': 'Fixed Wave'}
    2525
  • anuga_core/documentation/user_manual/demos/cairns/gauges.csv

    r4021 r4869  
    33360245.11,8142280.78,Trinity Beach,0
    44386133.51,8131751.05,Cairns Headland,0
    5 425759.74,8128812.23,Elford Reef,0
     5430250,8128812.23,Elford Reef,0
    66367771.61,8133933.82,Cairns Airport,0
  • anuga_core/documentation/user_manual/demos/cairns/runcairns.py

    r4858 r4869  
    2828from anuga.shallow_water import Time_boundary
    2929from anuga.shallow_water import File_boundary
     30from anuga.shallow_water import Transmissive_Momentum_Set_Stage_boundary
    3031from anuga.pmesh.mesh_interface import create_mesh_from_regions
    3132from anuga.shallow_water.data_manager import convert_dem_from_ascii2netcdf
     
    3940# Define scenario as either slide or fixed_wave.
    4041#------------------------------------------------------------------------------
    41 #scenario = 'slide'
    42 scenario = 'fixed_wave'
     42scenario = 'slide'
     43#scenario = 'fixed_wave'
    4344
    4445if os.access(scenario, os.F_OK) == 0:
     
    8889                         filename=meshname,
    8990                         interior_regions=interior_regions,
    90                          use_cache=True,
     91                         use_cache=False,
    9192                         verbose=True)
    9293
     
    133134                    verbose=True,
    134135                    alpha=0.1)
    135 
    136 
    137136
    138137#------------------------------------------------------------------------------
     
    166165if scenario == 'fixed_wave':
    167166    Bw = Transmissive_Momentum_Set_Stage_boundary(domain = domain,
    168                           f=lambda t: [(60<t<3660)*50, 0, 0])
     167                          function=lambda t: [(60<t<3660)*50, 0, 0])
    169168    domain.set_boundary({'ocean_east': Bw,
    170169                         'bottom': Bd,
  • anuga_core/source/anuga/fit_interpolate/interpolate.py

    r4856 r4869  
    558558
    559559                if verbose is True:
    560                     from anuga.utilities.polygon import plot_polygons
    561                     #out_interp_pts = take(interpolation_points,[indices])
    562                     title = 'Interpolation points fall outside specified mesh'
    563                     plot_polygons([mesh_boundary_polygon,interpolation_points,out_interp_pts],
    564                                          ['line','point','outside'],figname='points_boundary_out',label=title,verbose=verbose)
     560                    import sys
     561                    if sys.platform == 'win32':
     562                        from anuga.utilities.polygon import plot_polygons
     563                        #out_interp_pts = take(interpolation_points,[indices])
     564                        title = 'Interpolation points fall outside specified mesh'
     565                        plot_polygons([mesh_boundary_polygon,interpolation_points,out_interp_pts],
     566                                      ['line','point','outside'],figname='points_boundary_out',label=title,verbose=verbose)
    565567
    566568                # Joaquim Luis suggested this as an Exception, so
     
    574576            # Plot boundary and interpolation points
    575577            if verbose is True:
    576                 from anuga.utilities.polygon import plot_polygons
    577                 title = 'Interpolation function: Polygon and interpolation points'
    578                 plot_polygons([mesh_boundary_polygon,interpolation_points],
    579                                      ['line','point'],figname='points_boundary',label=title,verbose=verbose)
     578                import sys
     579                if sys.platform == 'win32':
     580                    from anuga.utilities.polygon import plot_polygons
     581                    title = 'Interpolation function: Polygon and interpolation points'
     582                    plot_polygons([mesh_boundary_polygon,interpolation_points],
     583                                         ['line','point'],figname='points_boundary',label=title,verbose=verbose)
    580584
    581585            m = len(self.interpolation_points)
Note: See TracChangeset for help on using the changeset viewer.