Changeset 704


Ignore:
Timestamp:
Dec 14, 2004, 10:21:40 AM (19 years ago)
Author:
ole
Message:

Added wind field to Merimbula script

Location:
inundation/ga/storm_surge/validation
Files:
3 added
1 edited

Legend:

Unmodified
Added
Removed
  • inundation/ga/storm_surge/validation/run_merimbula.py

    r694 r704  
    1313     Dirichlet_boundary, Wind_stress
    1414from pmesh2domain import pmesh_to_domain_instance
     15from util import File_function
    1516
    1617######################
     
    3233
    3334
    34 #Add lateral wind gusts bearing 135 degrees
    35 def gust(t,x,y):
    36     from math import sin, pi
    37     from Numeric import zeros, ones, Float
    38 
    39     N = len(x)
    40 
    41     tt = sin(2*pi*t/30)
    42 
    43     if tt > 0.98:
    44         return 24000*tt*ones(N, Float)
    45     else:
    46         return zeros(N, Float)
    47    
    48 domain.forcing_terms.append(Wind_stress(gust, 135))
     35#Add time dependent wind field from file
     36#Format is time [DD/MM/YY hh:mm:ss], speed [m/s] direction (degrees)
     37#See also README.txt
     38F = File_function('windstress_example.txt', domain)
     39domain.forcing_terms.append(Wind_stress(F))
    4940
    5041
     
    5243# Boundary conditions
    5344
    54 filename = 'Eden_Australia_31082004.txt'
    55 Bf = File_boundary(filename, domain)
    56 
    57 inflow_stage = 20.0
    58 Bd = Dirichlet_boundary([inflow_stage, 0.0, 0.0])
     45Bf = File_boundary('tide_example.txt', domain)
    5946Br = Reflective_boundary(domain)
    6047domain.set_boundary({'external': Br, 'open': Bf}) 
Note: See TracChangeset for help on using the changeset viewer.