source: trunk/anuga_work/development/sudi/sw_1d/shock_detector_shv/sf_parameters.py @ 7906

Last change on this file since 7906 was 7906, checked in by steve, 14 years ago

Adding sudi's code

File size: 664 bytes
Line 
1from Numeric import Float, sqrt
2from numpy import zeros
3from config import g
4from scipy import sin, cos, tan, arcsin, arccos, arctan, pi
5
6#h_0 = 5.0
7#h_1 = 10.0
8L=25.0
9N=400
10
11cell_len=L/N
12points=zeros(N+1, Float)
13for i in range(N+1):
14    points[i]=i*cell_len
15    #points[i] = i*cell_len - 0.5*L
16
17
18
19#delt = 0.0
20friction_slope = 0.0#0.05 #tan(delta) #0.05 # NOTE THAT friction_slope must less than bed_slope
21#thet = pi/36.0
22bed_slope = 0.0 #tan(theta) #0.1      # bottom slope, positive if it is increasing bottom.
23thet = arctan(bed_slope)
24
25F2 = g*cos(thet)*cos(thet)*friction_slope
26#c0 = sqrt(g*h_0)   # sound speed
27m = -1.0*g*bed_slope + F2   # auxiliary variable
Note: See TracBrowser for help on using the repository browser.