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