Question: Determine whether a vertex lies on a cycle of given length

Given a graph G and a vertex u of G, the problem of determining whether there exists a cycle of length k starting at u is a common one in graph theory.

Mathematica provides a function Findcycle for this task, though I am not sure which algorithm it employs—perhaps depth-first search (DFS)? Maple, on the other hand, does not appear to have a corresponding built-in function.

Please Wait...