igraph-help
[Top][All Lists]
Advanced

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

Re: [igraph] (no subject)


From: Tamas Nepusz
Subject: Re: [igraph] (no subject)
Date: Tue, 10 Mar 2020 17:29:15 +0100

So I need to use the  Deep First Search algorithm from a random node and stop the algorithm when the sum of node or vertices weights in the DFS sub-graph achieve a certain limit.

Could you please help me telling if it is possible with the dfs igraph function?
Are you working from C? If so, you can use the "in_callback" and "out_callback" arguments of igraph_dfs to call arbitrary functions when the DFS starts visiting a node or when the DFS is done with a node and its subgraph. You can also return a non-zero value from the callback functions to request igraph to terminate the search.

Documentation here:

https://igraph.org/c/doc/igraph-Visitors.html#igraph_dfs
https://igraph.org/c/doc/igraph-Visitors.html#igraph_dfshandler_t

T.

reply via email to

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