A Petri Net and Digraph-Theoretic Approach for Deadlock Avoidance in Flexible Manufacturing Systems