[23438] | 1 | %Test Name: SquareSheetShelfSteaEnthalpyHO3dDakotaSampNeff
|
---|
| 2 | md=triangle(model(),'../Exp/Square.exp',150000.);
|
---|
| 3 | md=setmask(md,'../Exp/SquareShelf.exp','');
|
---|
| 4 | md=parameterize(md,'../Par/SquareSheetShelf.par');
|
---|
| 5 | md=extrude(md,3,2.);
|
---|
| 6 | md=setflowequation(md,'HO','all');
|
---|
| 7 | md.cluster=generic('name',oshostname(),'np',3);
|
---|
| 8 | md.timestepping.time_step=0.;
|
---|
| 9 | md.thermal.isenthalpy=1;
|
---|
| 10 | md.thermal.isdynamicbasalspc=1;
|
---|
| 11 | md.initialization.waterfraction=zeros(md.mesh.numberofvertices,1);
|
---|
| 12 | md.initialization.watercolumn=zeros(md.mesh.numberofvertices,1);
|
---|
| 13 |
|
---|
| 14 | md.friction.coupling=3;
|
---|
| 15 | md.friction.effective_pressure=md.materials.rho_ice*md.constants.g*md.geometry.thickness+md.materials.rho_water*md.constants.g*md.geometry.base;
|
---|
| 16 |
|
---|
| 17 | %dakota version
|
---|
| 18 | version=IssmConfig('_DAKOTA_VERSION_'); version=version(1:3); version=str2num(version);
|
---|
| 19 |
|
---|
[24836] | 20 | %partitioning
|
---|
[25005] | 21 | npart=10;
|
---|
| 22 | partition=partitioner(md,'package','chaco','npart',npart,'weighting','on')-1;
|
---|
[24836] | 23 | md.qmu.isdakota=1;
|
---|
| 24 |
|
---|
[23438] | 25 | %variables
|
---|
[24836] | 26 | md.qmu.variables.neff=normal_uncertain('descriptor','scaled_FrictionEffectivePressure',...
|
---|
[25005] | 27 | 'mean',ones(npart,1),...
|
---|
| 28 | 'stddev',.05*ones(npart,1),...
|
---|
| 29 | 'partition',partition);
|
---|
[24870] | 30 | md.qmu.variables.geoflux=normal_uncertain('descriptor','scaled_BasalforcingsGeothermalflux',...
|
---|
[25005] | 31 | 'mean',ones(npart,1),...
|
---|
| 32 | 'stddev',.05*ones(npart,1),...
|
---|
| 33 | 'partition',partition);
|
---|
[23438] | 34 |
|
---|
| 35 | %responses
|
---|
[24839] | 36 | md.qmu.responses.MaxVel=response_function('descriptor','MaxVel');
|
---|
| 37 | md.qmu.responses.MassFlux1=response_function('descriptor','indexed_MassFlux_1');
|
---|
| 38 | md.qmu.responses.MassFlux2=response_function('descriptor','indexed_MassFlux_2');
|
---|
| 39 | md.qmu.responses.MassFlux3=response_function('descriptor','indexed_MassFlux_3');
|
---|
| 40 | md.qmu.responses.MassFlux4=response_function('descriptor','indexed_MassFlux_4');
|
---|
| 41 | md.qmu.responses.MassFlux5=response_function('descriptor','indexed_MassFlux_5');
|
---|
| 42 | md.qmu.responses.MassFlux6=response_function('descriptor','indexed_MassFlux_6');
|
---|
| 43 | md.qmu.responses.MassFlux7=response_function('descriptor','indexed_MassFlux_7');
|
---|
[23438] | 44 |
|
---|
| 45 | %mass flux profiles
|
---|
| 46 | md.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'};
|
---|
| 47 | md.qmu.mass_flux_profile_directory=pwd;
|
---|
| 48 |
|
---|
| 49 | md.qmu.method =dakota_method('nond_samp');
|
---|
| 50 | md.qmu.method(end)=dmeth_params_set(md.qmu.method(end),...
|
---|
| 51 | 'seed',1234,...
|
---|
| 52 | 'samples',20,...
|
---|
| 53 | 'sample_type','random');
|
---|
| 54 |
|
---|
| 55 | %% a variety of parameters
|
---|
| 56 | md.qmu.params.direct=true;
|
---|
| 57 | md.qmu.params.analysis_components='';
|
---|
| 58 | md.qmu.params.tabular_graphics_data=true;
|
---|
| 59 |
|
---|
| 60 | if version>=6,
|
---|
| 61 | md.qmu.params.analysis_driver='matlab';
|
---|
| 62 | md.qmu.params.evaluation_scheduling='master';
|
---|
| 63 | md.qmu.params.processors_per_evaluation=2;
|
---|
| 64 | else
|
---|
[23865] | 65 | md.qmu.params.analysis_driver='stressbalance';
|
---|
[23438] | 66 | md.qmu.params.evaluation_concurrency=1;
|
---|
| 67 | end
|
---|
| 68 |
|
---|
| 69 |
|
---|
| 70 | md.stressbalance.reltol=10^-5; %tighten for qmu analyses
|
---|
| 71 |
|
---|
| 72 | md=solve(md,'Steadystate','overwrite','y');
|
---|
| 73 |
|
---|
| 74 | %Fields and tolerances to track changes
|
---|
| 75 | md.qmu.results=md.results.dakota;
|
---|
| 76 |
|
---|
| 77 | %we put all the mean and stdev data in the montecarlo field, which we will use to test for success.
|
---|
| 78 | md.results.dakota.montecarlo=[];
|
---|
| 79 | for i=1:8,
|
---|
| 80 | md.results.dakota.montecarlo=[md.results.dakota.montecarlo md.results.dakota.dresp_out(i).mean];
|
---|
| 81 | end
|
---|
| 82 | for i=1:8,
|
---|
| 83 | md.results.dakota.montecarlo=[md.results.dakota.montecarlo md.results.dakota.dresp_out(i).stddev];
|
---|
| 84 | end
|
---|
| 85 | field_names ={'montecarlo'};
|
---|
[23445] | 86 | field_tolerances={2e-10};
|
---|
[23438] | 87 | field_values={...
|
---|
| 88 | md.results.dakota.montecarlo,...
|
---|
| 89 | };
|
---|
| 90 |
|
---|