igraph-help
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[igraph] graph components


From: zhengjun chen
Subject: [igraph] graph components
Date: Wed, 25 Nov 2009 15:20:18 -0500

Hi,

I want to calculate the number of components in an undirected graph. 
I use the function in such way: 
igraph_integer_t num; // it is used to store the number of components
igraph_clusters(&graph,NULL,&clusters,&num,IGRAPH_WEAK);  
printf("number of components: %d\n",num);

But it always shows "number of components is: 0". Actually the number of components in my graph is two.

--
Thanks
zhengjun

Graduate research assistant
Dept of Computer Science and Engineering
Lehigh University

reply via email to

[Prev in Thread] Current Thread [Next in Thread]