source: issm/trunk/test/NightlyRun/test237.m@ 20500

Last change on this file since 20500 was 20500, checked in by Mathieu Morlighem, 9 years ago

merged trunk-jpl and trunk for revision 20497

File size: 5.1 KB
Line 
1%Test Name: SquareShelfTranIspddIsdeltaSSA3d
2md=triangle(model(),'../Exp/Square.exp',600000.);%180000
3md=setmask(md,'all','');
4md=parameterize(md,'../Par/SquareShelf.par');
5
6%md.verbose=verbose('all');
7
8% Use of ispdd methods
9md.smb = SMBpdd();
10md.smb.isdelta18o=0;
11md.smb.ismungsm=1;
12
13% time steps and resolution
14md.timestepping.time_step=20;
15md.settings.output_frequency=1;
16md.timestepping.final_time=60;
17
18% creating Present day and lgm temperatures
19% Same temperature over the all region:
20tmonth(1:12)=238.15+20.;
21for imonth=0:11
22 md.smb.temperatures_presentday(1:md.mesh.numberofvertices,imonth+1)=tmonth(imonth+1);
23 md.smb.temperatures_lgm(1:md.mesh.numberofvertices,imonth+1)=tmonth(imonth+1)-20.;
24 % Time for the last line:
25 md.smb.temperatures_presentday(md.mesh.numberofvertices+1,imonth+1)=((imonth+1)/12);
26 md.smb.temperatures_lgm(md.mesh.numberofvertices+1,imonth+1)=((imonth+1)/12);
27end
28
29% creating initialization and spc temperatures initialization and spc
30md.thermal.spctemperature=mean(md.smb.temperatures_lgm(1:md.mesh.numberofvertices,1:12),2); %-10*ones(md.mesh.numberofvertices,1);
31md.thermal.spctemperature=repmat(md.thermal.spctemperature,1,md.timestepping.final_time/md.timestepping.time_step);
32itemp=0:md.timestepping.time_step:md.timestepping.final_time-md.timestepping.time_step;
33md.thermal.spctemperature(md.mesh.numberofvertices+1,:)=itemp;
34
35md.initialization.temperature=md.smb.temperatures_lgm(1:md.mesh.numberofvertices,1); %*ones(md.mesh.numberofvertices,1);
36md.smb = initialize(md.smb,md);
37
38% creating precipitation
39for imonth=0:11
40 md.smb.precipitations_presentday(1:md.mesh.numberofvertices,imonth+1)=-0.4*10^(-6)*md.mesh.y+0.5;
41 md.smb.precipitations_lgm(1:md.mesh.numberofvertices,imonth+1)=-0.4*10^(-6)*md.mesh.y+0.5;
42 % Time for the last line:
43 md.smb.precipitations_presentday(md.mesh.numberofvertices+1,imonth+1)=((imonth+1)/12);
44 md.smb.precipitations_lgm(md.mesh.numberofvertices+1,imonth+1)=((imonth+1)/12);
45end
46
47for iint=1:(md.timestepping.final_time/md.timestepping.time_step)+1
48 md.smb.Pfac(1,iint)=0.15*iint;
49 md.smb.Tdiff(1,iint)=0.15*iint;
50 md.smb.sealev(1,iint)=0.15*iint;
51 % Year of each data point
52 md.smb.Pfac(2,iint)=(iint-1)*20;
53 md.smb.Tdiff(2,iint)=(iint-1)*20;
54 md.smb.sealev(2,iint)=(iint-1)*20;
55end
56
57%
58md.transient.requested_outputs={'default','SmbMonthlytemperatures'};
59md=extrude(md,3,1);
60
61md=setflowequation(md,'SSA','all');
62md.cluster=generic('name',oshostname(),'np',1); % 3 for the cluster
63md=solve(md,TransientSolutionEnum);
64
65%Fields and tolerances to track changes
66field_names ={'Vx1','Vy1','Vz1','Vel1','Pressure1','Bed1','Surface1','Thickness1','Temperature1','BasalforcingsGroundediceMeltingRate1','SmbMonthlytemperatures1','SmbMassBalance1',...
67 'Vx2','Vy2','Vz2','Vel2','Pressure2','Bed2','Surface2','Thickness2','Temperature2','BasalforcingsGroundediceMeltingRate2','SmbMonthlytemperatures2','SmbMassBalance2',...
68 'Vx3','Vy3','Vz3','Vel3','Pressure3','Bed3','Surface3','Thickness3','Temperature3','BasalforcingsGroundediceMeltingRate3','SmbMonthlytemperatures3','SmbMassBalance3'};
69field_tolerances={...
70 1e-13,1e-13,1e-13,1e-13,1e-13,1e-8,1e-8,1e-8,1e-13,1e-8,1e-13,1e-13,...
71 1e-13,1e-13,1e-13,1e-13,1e-13,1e-8,1e-8,1e-8,1e-13,1e-7,1e-13,1e-13,...
72 1e-13,1e-13,1e-08,1e-13,1e-13,1e-8,1e-8,1e-8,1e-13,5e-7,1e-13,1e-13};
73field_values={...
74 (md.results.TransientSolution(1).Vx),...
75 (md.results.TransientSolution(1).Vy),...
76 (md.results.TransientSolution(1).Vz),...
77 (md.results.TransientSolution(1).Vel),...
78 (md.results.TransientSolution(1).Pressure),...
79 (md.results.TransientSolution(1).Base),...
80 (md.results.TransientSolution(1).Surface),...
81 (md.results.TransientSolution(1).Thickness),...
82 (md.results.TransientSolution(1).Temperature),...
83 (md.results.TransientSolution(1).BasalforcingsGroundediceMeltingRate),...
84 (md.results.TransientSolution(1).SmbMonthlytemperatures),...
85 (md.results.TransientSolution(1).SmbMassBalance),...
86 (md.results.TransientSolution(2).Vx),...
87 (md.results.TransientSolution(2).Vy),...
88 (md.results.TransientSolution(2).Vz),...
89 (md.results.TransientSolution(2).Vel),...
90 (md.results.TransientSolution(2).Pressure),...
91 (md.results.TransientSolution(2).Base),...
92 (md.results.TransientSolution(2).Surface),...
93 (md.results.TransientSolution(2).Thickness),...
94 (md.results.TransientSolution(2).Temperature),...
95 (md.results.TransientSolution(2).BasalforcingsGroundediceMeltingRate),...
96 (md.results.TransientSolution(2).SmbMonthlytemperatures),...
97 (md.results.TransientSolution(2).SmbMassBalance),...
98 (md.results.TransientSolution(3).Vx),...
99 (md.results.TransientSolution(3).Vy),...
100 (md.results.TransientSolution(3).Vz),...
101 (md.results.TransientSolution(3).Vel),...
102 (md.results.TransientSolution(3).Pressure),...
103 (md.results.TransientSolution(3).Base),...
104 (md.results.TransientSolution(3).Surface),...
105 (md.results.TransientSolution(3).Thickness),...
106 (md.results.TransientSolution(3).Temperature),...
107 (md.results.TransientSolution(3).BasalforcingsGroundediceMeltingRate),...
108 (md.results.TransientSolution(3).SmbMonthlytemperatures),...
109 (md.results.TransientSolution(3).SmbMassBalance),...
110 };
Note: See TracBrowser for help on using the repository browser.