Changeset 4883 for issm/trunk/test/Validation/ISMIP/TestA/runme.m
- Timestamp:
- 07/29/10 12:42:22 (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk/test/Validation/ISMIP/TestA/runme.m
r899 r4883 12 12 md=extrude(md,10,1); 13 13 14 %Create dirichlet on the bed on top of the borders15 pos=find(md.gridonbed);16 md.gridondirichlet_diag(pos)=1;17 18 14 md=setelementstype(md,'pattyn','all'); 19 15 %md=setelementstype(md,'pattyn','all','stokes','all'); 20 16 21 17 %Create dirichlet on the bed only 22 md. gridondirichlet_diag=zeros(md.numberofgrids,1);18 md.spcvelocity=zeros(md.numberofgrids,6); 23 19 pos=find(md.gridonbed); 24 md. gridondirichlet_diag(pos)=1;20 md.spcvelocity(pos,1:2)=1; 25 21 26 22 %Create MPCs to have periodic boundary conditions 27 posx=find(md.x==0);28 posx2=find(md.x==max(md.x));29 30 posy=find(md.y==0 & md.x~=0 & md.x~=max(md.x)); %Don't take the same grids two times31 posy2=find(md.y==max(md.y) & md.x~=0 & md.x~=max(md.x));32 33 md.penalties=[posx,posx2;posy,posy2];23 %posx=find(md.x==0); 24 %posx2=find(md.x==max(md.x)); 25 % 26 %posy=find(md.y==0 & md.x~=0 & md.x~=max(md.x)); %Don't take the same grids two times 27 %posy2=find(md.y==max(md.y) & md.x~=0 & md.x~=max(md.x)); 28 % 29 %md.penalties=[posx,posx2;posy,posy2]; 34 30 35 31 %Compute the diagnostic 36 md=solve(md,'analysis_type','diagnostic','package','ice'); 32 md=solve(md,'analysis_type',DiagnosticSolutionEnum); 33 vx=zeros(md.numberofgrids,1); 34 vx(md.results.DiagnosticSolution.Vx.index)=md.results.DiagnosticSolution.Vx.value; 35 vy=zeros(md.numberofgrids,1); 36 vy(md.results.DiagnosticSolution.Vy.index)=md.results.DiagnosticSolution.Vy.value; 37 vz=zeros(md.numberofgrids,1); 38 vz(md.results.DiagnosticSolution.Vz.index)=md.results.DiagnosticSolution.Vz.value; 37 39 38 plotmodel(md,'data', md.results.diagnostic.vx,'data',md.results.diagnostic.vy,'data',md.results.diagnostic.vz,'layer#all',md.numlayers,'contourlevels',{9.2,18.4,27.6,46,73.6,82.8},'contourlevels',{0,-1.2,-0.9,-0.6,-0.3,1.2},'contourlevels',{-5.2,-3.9,-1.3,0,1.3,3.9,5.2})40 plotmodel(md,'data',vx,'data',vy,'data',vz,'layer#all',md.numlayers,'contourlevels',{9.2,18.4,27.6,46,73.6,82.8},'contourlevels',{0,-1.2,-0.9,-0.6,-0.3,1.2},'contourlevels',{-5.2,-3.9,-1.3,0,1.3,3.9,5.2})
Note:
See TracChangeset
for help on using the changeset viewer.