1%SJGET_EXAMPLE a demo for SJget. 2% This example script gets the index file of the SJSU Singular matrix collection, 3% and then loads in all symmetric non-binary matrices, in increasing order of 4% number of rows in the matrix. 5% 6% Example: 7% type SJget_example ; % to see an example of how to use SJget 8% 9% See also SJget, SJweb, SJgrep. 10 11% Derived from the ssget toolbox on March 18, 2008. 12% Copyright 2007, Tim Davis, University of Florida. 13 14% modified by L. Foster 09/17/2008 15 16type SJget_example ; 17 18index = SJget ; 19% find all symmetric matrices that are not binary, 20% have at least 4000 column and have a gap in the singular 21% values at the numerical rank of at least 1000 22f = find (index.numerical_symmetry == 1 & ~index.isBinary & ... 23 index.ncols >= 4000 & index.gap >= 1000 ); 24% sort by the dimension of the numerical null space 25[y, j] = sort (index.ncols (f) - index.numrank (f) ) ; 26f = f (j) ; 27 28for i = f 29 fprintf ('Loading %s%s%s, please wait ...\n', ... 30 index.Group {i}, filesep, index.Name {i}) ; 31 Problem = SJget (i,index) ; 32 %display the problem structure 33 disp (Problem) ; 34 % display a plot of the singular values 35 SJplot(Problem) ; 36 shg 37 disp(' ') 38 disp(['dim. of numerical null space = ', ... 39 num2str(index.ncols (i) - index.numrank (i))]); 40 disp(' ') 41 pause(1) 42 %display the web page with matrix details 43 SJweb (i) ; 44 pause(1) 45end 46 47