algorithm - Least common ancestor of multiple nodes in DAG -


How do I get at least the common ancestors of multiple nodes in a guided esaic graph?

I have found some papers on this topic, but they are all looking for LCA in the DAG for the two nodes.

What are the best algorithms for multiple nodes?

You may modify the algorithm which is used for trees that Accepts DAG as well.

As you know, there is an algorithm for finding the LCA in pre-processed trees of o (nlgn) and O (1) each The query, therefore k is required to find the LCA of the nodes o (k) more information about this algorithm can be found.


Comments

Popular posts from this blog

Python SQLAlchemy:AttributeError: Neither 'Column' object nor 'Comparator' object has an attribute 'schema' -

java - How not to audit a join table and related entities using Hibernate Envers? -

mongodb - CakePHP paginator ignoring order, but only for certain values -