- #1
qwuasi
- 8
- 0
I have a mesh (2-by-2) which is numbered 1:16.
[URL]http://www.flickr.com/photos/moorekwesi/5454749337[/URL]
A = [1 2 5 6; 3 4 7 8;9 10 13 14;11 12 15 16] ;
i want to create a matrix of the nodes from the element and it's neighbouring nodes.
This is for a 2-by-2 and hope to implement it also for say 15-by-15.
>>
The 2-by-2 results
I2 = [A(1,:) A(2,1) A(2,3) A(3,1) A(3,2) ;
A(2,:) A(1,2) A(1,4) A(4,1) A(4,2) ;
A(3,:) A(4,1) A(4,3) A(1,3) A(1,4) ;
A(4,:) A(3,2) A(3,4) A(2,3) A(2,4)]
[URL]http://www.flickr.com/photos/moorekwesi/5454749337[/URL]
A = [1 2 5 6; 3 4 7 8;9 10 13 14;11 12 15 16] ;
i want to create a matrix of the nodes from the element and it's neighbouring nodes.
This is for a 2-by-2 and hope to implement it also for say 15-by-15.
>>
The 2-by-2 results
I2 = [A(1,:) A(2,1) A(2,3) A(3,1) A(3,2) ;
A(2,:) A(1,2) A(1,4) A(4,1) A(4,2) ;
A(3,:) A(4,1) A(4,3) A(1,3) A(1,4) ;
A(4,:) A(3,2) A(3,4) A(2,3) A(2,4)]
Last edited by a moderator: