0001
0002
0003 if ~exist ('scale', 'var')
0004 scale = 13
0005 else
0006 scale
0007 end
0008
0009 if exist ('np')
0010 scale = scale*p;
0011 end
0012
0013
0014 t0 = clock;
0015 [E, V] = gendata2 (scale);
0016 t0 = etime (clock, t0);
0017
0018
0019 disp ('Kernel 1');
0020 t1 = clock;
0021 G = kernel1 (E);
0022 t1 = etime (clock, t1);
0023
0024
0025 disp ('Kernel 2');
0026 t2 = clock;
0027 [maxwt, intedges] = kernel2 (G);
0028 t2 = etime (clock, t2);
0029
0030
0031 disp ('Kernel 3');
0032 t3 = clock;
0033 subgraphs = kernel3 (G, 3, intedges(:,2));
0034 t3 = etime (clock, t3);
0035
0036
0037 disp ('Kernel 4');
0038 t4 = clock;
0039 label = kernel4g (G);
0040 t4 = etime (clock, t4);
0041 [ign p] = sort(label);
0042
0043
0044 validate4 (G, label, V, 3);
0045
0046 fprintf ('Data generator time : %.2f seconds\n', t0);
0047 fprintf ('Kernel1 time : %.2f seconds\n', t1);
0048 fprintf ('Kernel2 time : %.2f seconds\n', t2);
0049 fprintf ('Kernel3 time : %.2f seconds\n', t3);
0050 fprintf ('Kernel4 time : %.2f seconds\n', t4);
0051 fprintf ('\n');