source: issm/trunk/test/Validation/EISMINT/MassConservation/runme.m@ 3573

Last change on this file since 3573 was 3573, checked in by Mathieu Morlighem, 15 years ago

Added Mass conservation test 2

File size: 1.7 KB
Line 
1%This test is a test from the EISMINT for Ice shelves
2% Vincent Rommelaere 1996
3
4%The goal is to test the prognostic model
5%md=bamg(model,'domain','DomainOutline.exp','hmax',4550);
6md=bamg(model,'domain','DomainOutline.exp','hmax',3000);
7md=geography(md,'all','');
8md=parameterize(md,'Square.par');
9md=setelementstype(md,'macayeal','all');
10
11%Evolution of the ice shelf
12md.ndt=500;
13md.dt=1;
14md.artificial_diffusivity=0; %Better result with no artificial diffusivity
15
16%0launch transient solution
17%md=solve(md,'analysis_type','transient');
18%FOR NOW:
19md.cluster=oshostname();
20md.np=8;
21i=0;
22time=0;
23md.dummy=struct();
24pos=find(md.y>199999.9);
25connectivity=full(sparse(md.elements(:),1,1));
26while(time<500),
27 disp(['step ' num2str(i) '/' num2str(500/md.dt)]);
28 i=i+1;
29 time=time+md.dt;
30 md=solve(md,'analysis_type','prognostic2','package','ice');
31 %thickness=full(sparse(reshape(md.elements',3*md.numberofelements,1),1,md.results.prognostic2.thickness));
32 %md.thickness=thickness./connectivity;
33 md.thickness=md.results.prognostic2.thickness;
34 md.thickness(pos)=500+100*sin(2*pi*time/200)*ones(size(pos,1),1);
35 md.surface=md.bed+md.thickness;
36 md.dummy(i).thickness=md.thickness;
37 %plotmodel(md,'data',md.thickness,'sectionvalue','CrossLine.exp')
38end
39
40%plot results
41plotmodel(md,'data',[md.thickness 500+100*sin(2*pi/200*(500-md.y/400))],'sectionvalue','CrossLine.exp')
42
43%Don't forget to add these lines in icetransient2d.m, just before the computation of the thickness to change the thickness on the upper boundary condition
44%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
45%pos=find(m_p.ys~=0);
46%m_p.ys(pos)=500+500/5*sin(2*pi*time/(200*md.yts))*ones(size(pos,1),1);
47%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
Note: See TracBrowser for help on using the repository browser.