parts(p) --- returns the parts of p in a cell array
0001 function cells = parts(p) 0002 % parts(p) --- returns the parts of p in a cell array 0003 0004 [m,n] = size(p.array); 0005 0006 cells = cell(1,m); 0007 0008 for k=1:m 0009 cells{k} = find(p.array(m+1-k,:)); 0010 end