Home > matgraph > @graph > omega.m

omega

PURPOSE ^

[w,S] = omega(g) --- clique number

SYNOPSIS ^

function [w,S] = omega(g)

DESCRIPTION ^

 [w,S] = omega(g) --- clique number
 Returns w, the size of a largest clique, and S, a largest clique.
 Note: Uses integer programming so may run slowly (if at all) on larger
 graphs. 

 REQUIRES THE OPTIMIZATION TOOLBOX

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function [w,S] = omega(g)
0002 % [w,S] = omega(g) --- clique number
0003 % Returns w, the size of a largest clique, and S, a largest clique.
0004 % Note: Uses integer programming so may run slowly (if at all) on larger
0005 % graphs.
0006 %
0007 % REQUIRES THE OPTIMIZATION TOOLBOX
0008 
0009 % Note: Our implementation is simply alpha(-g).
0010 
0011 h = graph;
0012 copy(h,g);
0013 complement(h);
0014 [w,S] = alpha(h);
0015 free(h);

Generated on Thu 13-Mar-2008 14:23:52 by m2html © 2003