Happy easters, everyone.
I am currently learning topological sort and having a question about what topological sort tries to really sort.
The Algorithm Design Manual describes topological sort in this way:
Topological sorting is the most important operation on directed acyclic graphs (DAGs). It orders the vertices on a line such that all directed edges go from left to right.
This bold part confuses me. So does the topological sorting sort vertices or all directed edges?
Let's take an example which is also in the book.
So for the above DAG, we can get a topological sort (G, A, B, C, F, E, D).
I can understand this sort. Not only the vertices are sorted, but the edges are also sorted, i.e., G->A->B->C->F->E->D, this matches the above ADM book description: all directed edges go from left to right
But what if I remove the edge of B->C? The resulting graph is still a DAG, but will the topological sort is still (G, A, B, C, F, E, D)?
If it is Yes, then I think the edges are not sorted, as A->B->C does not exist any more, instead, it is A->B and A->C. So, it this case still a valid topological sort? Can we still think (G, A, B, C, F, E, D) is a valid sort even if A is the parent of B and C?
Thanks