Ignore:
Timestamp:
May 22, 2009, 4:40:11 PM (11 years ago)
Author:
rwilson
Message:

Fiddling with layout of user guide.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • anuga_core/documentation/user_manual/demos/cairns/project.py

    r6889 r7064  
    1 """Common filenames and locations for topographic data, meshes and outputs.
    2 """
     1"""Common filenames and locations for topographic data, meshes and outputs."""
    32
    43from anuga.utilities.polygon import read_polygon, plot_polygons, \
    54                                    polygon_area, is_inside_polygon
    65
    7                                    
    86#------------------------------------------------------------------------------
    97# Define scenario as either slide or fixed_wave.
    108#------------------------------------------------------------------------------
    11 #scenario = 'slide'
    129scenario = 'fixed_wave'
    13                                    
    14                                    
     10#scenario = 'slide'
     11
    1512#------------------------------------------------------------------------------
    1613# Filenames
    1714#------------------------------------------------------------------------------
    18 demname = 'cairns' 
     15demname = 'cairns'
    1916meshname = demname + '.msh'
    2017
    2118# Filename for locations where timeseries are to be produced
    2219gauge_filename = 'gauges.csv'
    23                                  
    24                                    
     20
    2521#------------------------------------------------------------------------------
    2622# Domain definitions
    2723#------------------------------------------------------------------------------
    28 
    2924# bounding polygon for study area
    3025bounding_polygon = read_polygon('extent.csv')
    3126
    32 A = polygon_area(bounding_polygon)/1000000.0
     27A = polygon_area(bounding_polygon) / 1000000.0
    3328print 'Area of bounding polygon = %.2f km^2' % A
    34 
    3529
    3630#------------------------------------------------------------------------------
    3731# Interior region definitions
    3832#------------------------------------------------------------------------------
    39 
    4033# Read interior polygons
    4134poly_cairns = read_polygon('cairns.csv')
     
    4740
    4841# Optionally plot points making up these polygons
    49 #plot_polygons([bounding_polygon,poly_cairns,poly_island0,poly_island1,\
    50 #               poly_island2,poly_island3,poly_shallow],\
    51 #               style='boundingpoly',verbose=False)
    52 
    53 
     42#plot_polygons([bounding_polygon, poly_cairns, poly_island0, poly_island1,
     43#               poly_island2, poly_island3, poly_shallow],
     44#               style='boundingpoly', verbose=False)
    5445
    5546# Define resolutions (max area per triangle) for each polygon
    56 default_res = 10000000 # Background resolution
     47default_res = 10000000    # Background resolution
    5748islands_res = 100000
    5849cairns_res = 100000
     
    6051
    6152# Define list of interior regions with associated resolutions
    62 interior_regions = [[poly_cairns, cairns_res],
     53interior_regions = [[poly_cairns,  cairns_res],
    6354                    [poly_island0, islands_res],
    6455                    [poly_island1, islands_res],
     
    6657                    [poly_island3, islands_res],
    6758                    [poly_shallow, shallow_res]]
    68 
    69 
    7059
    7160#------------------------------------------------------------------------------
     
    8069# Data for landslide
    8170#------------------------------------------------------------------------------
    82 slide_origin = [451871, 8128376] # Assume to be on continental shelf
     71slide_origin = [451871, 8128376]   # Assume to be on continental shelf
    8372slide_depth = 500.
    84 
    85 
    86 
    87 
    88 
Note: See TracChangeset for help on using the changeset viewer.