source: issm/trunk/test/NightlyRun/test417.m

Last change on this file was 26744, checked in by Mathieu Morlighem, 3 years ago

merged trunk-jpl and trunk for revision 26742

File size: 3.3 KB
RevLine 
[19105]1%Test Name: SquareSheetShelfDiadSSA3dDakotaSamp
[13975]2md=triangle(model(),'../Exp/Square.exp',150000.);
[9641]3md=setmask(md,'../Exp/SquareShelf.exp','');
[5118]4md=parameterize(md,'../Par/SquareSheetShelf.par');
[16137]5md=setflowequation(md,'SSA','all');
[8589]6md.cluster=generic('name',oshostname(),'np',3);
[9636]7md.materials.rho_ice=10^7; %involved in the mass flux, make it easy
[9691]8md.geometry.thickness(:)=1; %make it easy
[20500]9md.geometry.surface=md.geometry.base+md.geometry.thickness;
[5118]10
11%constrain all velocities to 1 m/yr, in the y-direction
[16137]12md.stressbalance.spcvx(:)=0;
13md.stressbalance.spcvy(:)=1;
14md.stressbalance.spcvz(:)=0;
[5118]15
16%Dakota options
[20500]17
18%dakota version
19version=IssmConfig('_DAKOTA_VERSION_'); version=version(1:3); version=str2num(version);
20
[25836]21%partitioning
22npart=20;
[26744]23[partition,md]=partitioner(md,'package','chaco','npart',npart,'weighting','on');
24partition=partition-1;
[25836]25md.qmu.isdakota=1;
[5118]26
[25836]27md.qmu.variables.drag_coefficient=normal_uncertain('descriptor','scaled_FrictionCoefficient',...
28 'mean',ones(npart,1),...
29 'stddev',.01*ones(npart,1),...
30 'partition',partition);
[5118]31
[25836]32md.qmu.responses.MaxVel=response_function('descriptor','MaxVel');
33md.qmu.responses.MassFlux1=response_function('descriptor','indexed_MassFlux_1');
34md.qmu.responses.MassFlux2=response_function('descriptor','indexed_MassFlux_2');
35md.qmu.responses.MassFlux3=response_function('descriptor','indexed_MassFlux_3');
36md.qmu.responses.MassFlux4=response_function('descriptor','indexed_MassFlux_4');
37md.qmu.responses.MassFlux5=response_function('descriptor','indexed_MassFlux_5');
38md.qmu.responses.MassFlux6=response_function('descriptor','indexed_MassFlux_6');
39md.qmu.responses.MassFlux7=response_function('descriptor','indexed_MassFlux_7');
40
[5118]41%mass flux profiles
[11176]42md.qmu.mass_flux_profiles={'../Exp/MassFlux1.exp','../Exp/MassFlux2.exp','../Exp/MassFlux3.exp','../Exp/MassFlux4.exp','../Exp/MassFlux5.exp','../Exp/MassFlux6.exp','../Exp/Square.exp'};
[9652]43md.qmu.mass_flux_profile_directory=pwd;
[5118]44
45
46%% nond_sampling study
47
[9652]48md.qmu.method =dakota_method('nond_samp');
49md.qmu.method(end)=dmeth_params_set(md.qmu.method(end),...
[5118]50'seed',1234,...
51'samples',20,...
52'sample_type','lhs');
53
54%% a variety of parameters
[24313]55md.qmu.params.interval_type='forward';
[18301]56md.qmu.params.direct=true;
57md.qmu.params.tabular_graphics_data=true;
[5118]58
[20500]59if version>=6,
60 md.qmu.params.analysis_driver='matlab';
61 md.qmu.params.evaluation_scheduling='master';
62 md.qmu.params.processors_per_evaluation=2;
63else
64 md.qmu.params.analysis_driver='stressbalance';
65 md.qmu.params.evaluation_concurrency=1;
66end
67
68
[5118]69
[16137]70md.stressbalance.reltol=10^-5; %tighten for qmu analyses
[5118]71
[21341]72md=solve(md,'Stressbalance','overwrite','y');
[5118]73
74%Fields and tolerances to track changes
[13021]75md.qmu.results=md.results.dakota;
[5118]76
77%ok, mass flux of 3 profiles should be -3 Gt/yr -3 Gt/yr and the sum, which is -6 Gt/yr
78%we recover those mass fluxes through the mean of the response.
79%also, we recover the max velo, which should be 1m/yr.
80%we put all that data in the montecarlo field, which we will use to test for success.
81%also, check that the stddev are 0.
82md.results.dakota.montecarlo=[];
[11176]83for i=1:8,
[5118]84 md.results.dakota.montecarlo=[md.results.dakota.montecarlo md.results.dakota.dresp_out(i).mean];
85end
[11176]86for i=1:8,
[5118]87 md.results.dakota.montecarlo=[md.results.dakota.montecarlo md.results.dakota.dresp_out(i).stddev];
88end
89field_names ={'montecarlo'};
90field_tolerances={1e-11};
91field_values={...
92 md.results.dakota.montecarlo,...
93 };
Note: See TracBrowser for help on using the repository browser.