Graph Algorithms for Functional Dependency Manipulation