Changeset 9733 for issm/trunk/src/m/model/mesh/findsegments.m
- Timestamp:
- 09/09/11 14:58:09 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified issm/trunk/src/m/model/mesh/findsegments.m ¶
r9729 r9733 19 19 error(' ''mesh.elementconnectivity'' option does not have thge right size.'); 20 20 else 21 mesh.elementconnectivity=ElementConnectivity(md. elements,md.mesh.vertexconnectivity);21 mesh.elementconnectivity=ElementConnectivity(md.mesh.elements,md.mesh.vertexconnectivity); 22 22 end 23 23 end … … 43 43 44 44 %get nodes of el1 45 nods1=md. elements(el1,:);45 nods1=md.mesh.elements(el1,:); 46 46 47 47 %find the common vertices to the two elements connected to el1 (1 or 2) 48 flag=intersect(md. elements(els2(1),:),md.elements(els2(2),:));48 flag=intersect(md.mesh.elements(els2(1),:),md.mesh.elements(els2(2),:)); 49 49 50 50 %get the vertices on the boundary and build segment … … 53 53 54 54 %swap segment nodes if necessary 55 ord1=find(nods1(1)==md. elements(el1,:));56 ord2=find(nods1(2)==md. elements(el1,:));55 ord1=find(nods1(1)==md.mesh.elements(el1,:)); 56 ord2=find(nods1(2)==md.mesh.elements(el1,:)); 57 57 if ( (ord1==1 & ord2==2) | (ord1==2 & ord2==3) | (ord1==3 & ord2==1) ), 58 58 temp=segments(count,1); … … 66 66 else 67 67 %get nodes of el1 68 nods1=md. elements(el1,:);68 nods1=md.mesh.elements(el1,:); 69 69 70 70 %find the vertex the el1 to not share with els2 71 flag=setdiff(nods1,md. elements(els2,:));71 flag=setdiff(nods1,md.mesh.elements(els2,:)); 72 72 73 73 for j=1:3, … … 78 78 79 79 %swap segment nodes if necessary 80 ord1=find(nods(1)==md. elements(el1,:));81 ord2=find(nods(2)==md. elements(el1,:));80 ord1=find(nods(1)==md.mesh.elements(el1,:)); 81 ord2=find(nods(2)==md.mesh.elements(el1,:)); 82 82 if ( (ord1==1 & ord2==2) | (ord1==2 & ord2==3) | (ord1==3 & ord2==1) ), 83 83 temp=segments(count,1);
Note:
See TracChangeset
for help on using the changeset viewer.