fn find_starting_orbit<T: core::graph::Vertex>(
    orbits_after_partition: &Vec<core::orbit_ops::Orbit>,
    vv: &core::graph::VertexVec<T>
) -> (core::orbit_ops::Orbit, Vec<Vec<usize>>) {
    let mut orbits_cloned = orbits_after_partition.to_vec();
    orbits_cloned.sort_by_cached_key(
        |orbit| max_graph_distance_inside_orbit(orbit, vv)
    );

    for orbit in orbits_cloned.iter() {
        if vv[orbit[0]].degree() == 1 {
            continue;
        }

        if get_breakable_neighbours(orbit[0], orbit, vv).len() > 0 {
            return (orbit.clone(), orbit.iter().map(|&vi| get_breakable_neighbours(vi, orbit, vv)).collect());
        }
    }

    (vec![], vec![])
}
/// return start orbit and mapping starting vertices
return start orbit and mapping starting vertices
return start orbit and mapping starting vertices
fn find_starting_orbit<T: core::graph::Vertex>(
    orbits_after_partition: &Vec<core::orbit_ops::Orbit>,
    vv: &core::graph::VertexVec<T>
) -> (core::orbit_ops::Orbit, Vec<Vec<usize>>) {
    let mut orbits_cloned = orbits_after_partition.to_vec();
    orbits_cloned.sort_by_cached_key(
        |orbit| max_graph_distance_inside_orbit(orbit, vv)
    );
    for orbit in orbits_cloned.iter() {
        if vv[orbit[0]].degree() == 1 {
            continue;
        }
        if get_breakable_neighbours(orbit[0], orbit, vv).len() > 0 {
            return (orbit.clone(), orbit.iter().map(|&vi| get_breakable_neighbours(vi, orbit, vv)).collect());
        }
    }
    (vec![], vec![])
}
fn find_starting_orbit < T : core :: graph :: Vertex > ( orbits_after_partition : & Vec < core :: orbit_ops :: Orbit > , vv : & core :: graph :: VertexVec < T > ) -> ( core :: orbit_ops :: Orbit , Vec < Vec < usize > > ) { let mut orbits_cloned = orbits_after_partition . to_vec ( ) ; orbits_cloned . sort_by_cached_key ( | orbit | max_graph_distance_inside_orbit ( orbit , vv ) ) ; for orbit in orbits_cloned . iter ( ) { if vv [ orbit [ 0 ] ] . degree ( ) == 1 { continue ; } if get_breakable_neighbours ( orbit [ 0 ] , orbit , vv ) . len ( ) > 0 { return ( orbit . clone ( ) , orbit . iter ( ) . map ( | & vi | get_breakable_neighbours ( vi , orbit , vv ) ) . collect ( ) ) ; } } ( vec ! [ ] , vec ! [ ] ) }
return start orbit and mapping starting vertices
return start orbit and mapping starting vertices
orbits_after_partition
&Vec<core::orbit_ops::Orbit>
vv
&core::graph::VertexVec<T>
orbits_after_partition
&Vec<core::orbit_ops::Orbit>
vv
&core::graph::VertexVec<T>