diff options
Diffstat (limited to 'Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/layered/CycleRemovalGansnerKNV1993.lua')
-rw-r--r-- | Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/layered/CycleRemovalGansnerKNV1993.lua | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/layered/CycleRemovalGansnerKNV1993.lua b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/layered/CycleRemovalGansnerKNV1993.lua index b480b7c4e70..e52b0d38d1a 100644 --- a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/layered/CycleRemovalGansnerKNV1993.lua +++ b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/layered/CycleRemovalGansnerKNV1993.lua @@ -23,10 +23,10 @@ function CycleRemovalGansnerKNV1993:run () -- -- ignore self-loops -- - -- merge multiple edges into one edge each, whose weight is the sum of the + -- merge multiple edges into one edge each, whose weight is the sum of the -- individual edge weights -- - -- ignore leaf nodes that are not part of the user-defined sets (their ranks + -- ignore leaf nodes that are not part of the user-defined sets (their ranks -- are trivially determined) -- -- ensure that supernodes S_min and S_max are assigned first and last ranks @@ -36,10 +36,10 @@ function CycleRemovalGansnerKNV1993:run () -- ensure the supernodes S_min and S_max are are the only nodes in these ranks -- for all nodes with indegree of 0, insert temporary edge (S_min, v) with delta=0 -- for all nodes with outdegree of 0, insert temporary edge (v, S_max) with delta=0 - + -- classify edges as tree/forward, cross and back edges using a DFS traversal local tree_or_forward_edges, cross_edges, back_edges = Simplifiers:classifyEdges(self.graph) - + -- reverse the back edges in order to make the graph acyclic for _,edge in ipairs(back_edges) do edge.reversed = true |