Function ADS::twoColoring(const Adjacency&)
Defined in File EasyCases.h
Function Documentation
-
inline std::optional<std::vector<int>> ADS::twoColoring(const Adjacency &G)
the side, 0 or 1, of each node of G, the ends of each edge apart, or nothing if G has an odd cycle; the diagonal of G is ignored, as by coloring() [see Problems.h]
- Pre:
G is unoriented, i.e., square and symmetric
- Post:
a coloring returned is proper with two colors