Literature study reveals the existence of many algorithms for detecting cycles (also known as circuits) in directed graphs. Majority of these algorithms can be classified into two groups: (1) traversal algorithms (e.g. variants of depth-first-search algorithms), and (2) matrix-based algorithms (manipulation of the adjacency matrix and its power series). Adjacency matrix based algorithms are computationally simple and more compact than the traversal algorithms. However, a Petri net, due to its bipartite nature, possesses sparse matrix as adjacency matrix. Hence, the matrix based algorithms become inefficient as the algorithm work through redundant data most of its running time. In this paper, we take a closer look into the structure of the adjacency matrix of a Petri net and then propose an algorithm for detecting existence of cycles; the proposed algorithm is computationally efficient as its works through non-redundant data only, as well as simple, easy to understand and easy to implement.
© 2001-2024 Fundación Dialnet · Todos los derechos reservados