Defines derived graphs from existing graphs using maps and filters.
Defines derived graphs from existing graphs using maps and filters.
(bipartite-subgraph g subset)
Returns the subgraph of g containing only the edge subset E which lead outside of the given subset. The nodes of the resulting graph are the start and endpoints of these edges. The resulting graph is thus the bipartite graph (U,V,E) where U = subset, V = (map last E). (see https://en.wikipedia.org/wiki/Bipartite_graph).
Returns the subgraph of g containing only the edge subset E which lead outside of the given subset. The nodes of the resulting graph are the start and endpoints of these edges. The resulting graph is thus the bipartite graph (U,V,E) where U = subset, V = (map last E). (see https://en.wikipedia.org/wiki/Bipartite_graph).
(edges-filtered-by pred g)
Returns a new graph which has as nodes all nodes of g and edges which satisfy the predicate.
Returns a new graph which has as nodes all nodes of g and edges which satisfy the predicate.
(mapped-by f g)
Returns a Graph or a DiGraph which has as nodeset (set (map f (nodes g)). An edge [uu, vv] is an edge in the resulting graph iff g has an edge [u, v] such that [uu, vv] = [(f u), (f v)].
Returns a Graph or a DiGraph which has as nodeset (set (map f (nodes g)). An edge [uu, vv] is an edge in the resulting graph iff g has an edge [u, v] such that [uu, vv] = [(f u), (f v)].
(nodes-filtered-by pred g)
Returns a new graph which has as nodes all nodes of g which satisfy the predicate.
Returns a new graph which has as nodes all nodes of g which satisfy the predicate.
(subgraph-reachable-from g start)
Returns a subgraph of the given graph which contains all nodes and edges that can be reached from the given start node.
Returns a subgraph of the given graph which contains all nodes and edges that can be reached from the given start node.
(surroundings g subset)
Returns th subgraph of g containing nodes which belong to the given subset of g and direct successors of them.
Returns th subgraph of g containing nodes which belong to the given subset of g and direct successors of them.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close