1 import numpy as N
2 import pylab as P
3
4 import simple_ice_model_even_more
5
6
7
8
9
10
12
13 rho=920.
14 g_grav=9.8
15 A_rate=1.e-16
16 n_glen=3.
17
18
19 grid = 51
20 dt = 0.1
21 t_start = 0.
22 t_final = 1000.
23 times_out_delta_t = 10
24 t_steps = N.round((t_final-t_start)/dt)
25
26 xl = 0
27 xr =50e3
28 mass_b_0=4.
29 mass_b_1=0.2e-3
30 dbed_dx=0.025
31
32
33 tt = N.arange(t_start, t_final+dt, dt)
34
35 t_output_ind = N.where(N.mod(tt,times_out_delta_t)==0)
36
37 t_out = tt[t_output_ind]
38
39
40 xx = N.linspace(xl, xr, grid)
41
42 bed = -dbed_dx * xx
43
44 mass_b = mass_b_0 - mass_b_1*xx
45
46 thick_IC = xx*0
47
48
49 thick = simple_ice_model_even_more.simple_ice_model(
50 grid, dt, t_steps, t_out_ind, dx,
51 rho, g_grav, A_rate, n_glen,
52 xx, mass_b, bed,
53 thick,
54 thickr, thickl)
55
56 P.figure()
57 P.plot(xx/1e3, bed+thick[:,-1], 'b')
58 P.hold(True)
59 P.plot(xx/1e3, bed, 'r')
60 P.xlabel('x (km)')
61 P.ylabel('b+H (m)')
62
63 if __name__=='__main__':
64 run()
65 P.show()
66