Partition the shape coefficients of an imat_shp object to a smaller set.
t=partition(s,ctrace)
t=partition(s,nodelist)
t=partition(s,group)
The PARTITION functions will partition the supplied imat_shp object s to the supplied DOF list. The DOF list may be a list of coordinates supplied as an imat_ctrace object, a list of nodes supplied as a numeric vector, or an imat_group containing nodes. All shape attributes of the resulting imat_shp object t will be copied from the supplied imat_shp. Only nodes supplied in nodelist that match nodes in the shape will be present in the resulting shape object. If coordinates in the supplied ctrace do not match coordinates in the supplied imat_shp, an error will occur.
The supplied shape s can contain multiple shapes of different lengths and attributes, but performance will be much greater if the imat_shp contains shapes that all have the same number of nodes and DOF per node.
>> s=imat_shp(1);
>> s.shape=[1:9]*(1+1/9);
>> s.node=100:100:300
s =
IMAT Shape
with the following attributes:
Frequency Damping NumberNodes
------------------- ------------------- -------------------
1
0.01 3
>> list(s)
Shape 1 - 1.000000 Hz, 1.000000 %Cr damping
ID Line 1:
Node Disp-X
Disp-Y Disp-Z
-------------------------------------------------
100 1.1111 2.2222 3.3333
200 4.4444 5.5556 6.6667
300 7.7778 8.8889 10
>> t=partition(s,[100 300]); list(t)
Shape 1 - 1.000000 Hz, 1.000000 %Cr damping
ID Line 1:
Node Disp-X Disp-Y Disp-Z
-------------------------------------------------
100 1.1111 2.2222 3.3333
300 7.7778 8.8889 10
>> t=partition(s,imat_ctrace('100x','200y','300z')); list(t)
Shape 1 - 1.000000 Hz, 1.000000 %Cr damping
ID Line 1:
Node Disp-X Disp-Y Disp-Z
-------------------------------------------------
100 1.1111 0 0
200
0 5.5556 0
300
0 0 10
>>