has_hamiltonian_circuit

Function has_hamiltonian_circuit 

Source
pub fn has_hamiltonian_circuit<N, E, Ix>(graph: &Graph<N, E, Ix>) -> bool
where N: Node + Debug, E: EdgeWeight, Ix: IndexType,
Expand description

Checks if a graph has a Hamiltonian circuit (cycle visiting every vertex exactly once)

§Arguments

  • graph - The graph to check

§Returns

  • bool - True if a Hamiltonian circuit exists