igraph-help
[Top][All Lists]
Advanced

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

Re: [igraph] Limiting the number of cliques


From: Szabolcs Horvát
Subject: Re: [igraph] Limiting the number of cliques
Date: Sun, 27 Sep 2015 11:00:09 +0200

Hi Lorenzo,

You didn't mention which interface of igraph you are using, and also
whether you are looking for all complete subgraphs or only maximal
cliques.

I don't believe this is possible with the Python or R interfaces.

If you use the C interface, it seems to be possible for maximal
cliques, but only if using internal (non-public) functions.

Many of the functions dealing with maximal cliques seem to be
implemented in terms of igraph_i_maximal_cliques(), which takes a
callback function argument that will be invoked for every clique
found, and can request to terminate the search.  You could use this to
keep counting cliques until a certain point and then request a stop.

If you need *all* cliques, not just maximal ones, you can try the
Cliquer library which also uses a callback function, and is a bit
faster than igraph for counting all cliques (it's much slower for
maximal ones): http://users.aalto.fi/~pat/cliquer.html  This will also
require programming in C.

Szabolcs


On 27 September 2015 at 10:41, Lorenzo Isella <address@hidden> wrote:
> Dear All,
> My problem is the following (I can provide a snippet if it is needed):
> I have a very connected graph, so when I look for cliques of a certain
> size (let's say 10), the search goes on forever because there are
> literally millions of possibilities.
> I would like to know if there is a way to stop this search, for
> instance by telling igraph to stop whenever a certain number of
> cliques is found (or better: the minimum between the number I provide
> and the total number of cliques with 10 elements).
> Is it doable in igraph?
> Many thanks
>
> Lorenzo
>
> _______________________________________________
> igraph-help mailing list
> address@hidden
> https://lists.nongnu.org/mailman/listinfo/igraph-help



reply via email to

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