Skip to content Skip to navigation Skip to collection information

OpenStax_CNX

You are here: Home » Content » The Art of the PFUG » A Combinatorial Algorithm for Finding Maximum Cuts

Navigation

Table of Contents

Lenses

What is a lens?

Definition of a lens

Lenses

A lens is a custom view of the content in the repository. You can think of it as a fancy kind of list that will let you see content through the eyes of organizations and people you trust.

What is in a lens?

Lens makers point to materials (modules and collections), creating a guide that includes their own comments and descriptive tags about the content.

Who can create a lens?

Any individual member, a community, or a respected organization.

What are tags? tag icon

Tags are descriptors added by lens makers to help label content, attaching a vocabulary that is meaningful in the context of the lens.

This content is ...

Affiliated with (What does "Affiliated with" mean?)

This content is either by members of the organizations listed or about topics related to the organizations listed. Click each link to see a list of all content affiliated with the organization.
  • Rice Digital Scholarship

    This collection is included in aLens by: Digital Scholarship at Rice University

    Click the "Rice Digital Scholarship" link to see all content affiliated with them.

Also in these lenses

  • Lens for Engineering

    This module and collection are included inLens: Lens for Engineering
    By: Sidney Burrus

    Click the "Lens for Engineering" link to see all content selected in this lens.

Recently Viewed

This feature requires Javascript to be enabled.
 

A Combinatorial Algorithm for Finding Maximum Cuts

Module by: Stephen Kruzick. E-mail the authorEdited By: Stephen Kruzick

Summary: This report summarizes work done as part of the Wavelet Based Image Analysis PFUG under Rice University's VIGRE program. VIGRE is a program of Vertically Integrated Grants for Research and Education in the Mathematical Sciences under the direction of the National Science Foundation. A PFUG is a group of Postdocs, Faculty, Undergraduates and Graduate students formed round the study of a common problem. This module provides mathematical background on the maxcut problem and develops an exact branch and bound algorithm for the maximum cut of unweighted graphs that is designed for improved performance on sparse graphs.

Figure 1
Figure 1 (maxcut.png)

Introduction

Finding the maximum cut of a graph is a difficult to compute problem in combinatorial optimization with several applications in the world of engineering and physics. This research develops and evaluates an exact branch and bound algorithm for the maximum cut of unweighted graphs that is designed for improved performance on sparse graphs.

The module provides a general overview of the problem along with necessary mathematical background in "The Maxcut Problem" and a brief note on various approaches to the problem in "Several Algorithms". "A New Algorithm" describes a new algorithm for finding maximum cuts. Results of empirical performance evaluation appear in "Empirical Testing", which "Conclusion" further discusses.

The Maxcut Problem

Before discussing the maxcut problem, it is necessary to provide some background information regarding relevant concepts in graph theory, the most fundamental of which is the graph itself. A graph G(V,E)G(V,E) is an ordered pair comprised of a set of vertices V and a set of edges E that connect pairs of distinct vertices in V. Two examples are shown in Figure 2. Graphs may be either weighted, in which a real value is assigned to each edge, or unweighted, in which all edges have equal value. Although the former is more broadly applicable, further discussion will focus almost exclusively on the latter.

Figure 2: Two example graphs appear above.
Figure 2 (graph_example.png)

Unsurprisingly, a subgraph G1(V1,E1)G1(V1,E1) of graph G(V,E)G(V,E) is a graph with vertex set V1VV1V and edge set E1EE1E. Of particular usefulness will be the subgraph of G(V,E)G(V,E) induced by a given set of edges E1EE1E, known as edge induced subgraph, which consists of that given set of edges E1 along with all vertices V1=v|(u,v)E1,uVV1=v|(u,v)E1,uV that occur as an endpoint of at least one edge in E1. An example of an edge induced subgraph is shown in Figure 3.

Figure 3: The subgraph induced by the red colored edges is shown on the right.
Figure 3 (subgraph_example.png)

One class of graphs that will be especially important to discussion of the maxcut problem is bipartite graphs. A graph G(V,E)G(V,E) is bipartite, like the example in Figure 4, if there are sets V1,V2VV1,V2V such that V1V2=VV1V2=V, V1V2=V1V2=, and (u,v)E(u,v)E only if uV1,vV2uV1,vV2 or vV1,uV2vV1,uV2. Additionally, a graph is bipartite if and only if it has no subgraph that is a cycle of odd length.

Figure 4: In the above bipartite graph, the vertices are colored red or blue to highlight the vertex partitions.
Figure 4 (bipartite_example.png)

A cut of a graph can be informally understood and visualized as a closed curve crossing some realization of the graph where each edge can be crossed at most once, as seen in Figure 5. Notice that the curve partitions the graph vertices into two disjoint subsets located to each side of the curve.

Figure 5: The closed curve represented by the dotted line crossing the graph corresponds to a cut of the graph.
Figure 5 (cut_example_1.png)

Formally, a cut of a graph G(V,E)G(V,E) is a partition of the graph vertices into subsets V1,V2VV1,V2V such that V1V2=VV1V2=V and V1V2=V1V2=, as demonstrated by Figure 6. The corresponding cut set is the set of edges C such that C=(u,v)E|uV1,vV2C=(u,v)E|uV1,vV2. Hence, the cut set induces a bipartite subgraph.

Figure 6: The partitions of graph vertices that correspond to this cut are highlighted in red and blue.
Figure 6 (cut_example_2.png)

The size of a cut equals the sum of the weights of edges in the cut set, which in the case of unweighted graphs is simply the number of edges in the cut set. With this definition of size, the maximum cut of a graph, like those shown in Figure 7, is a cut not smaller than any other cut in the graph, and it corresponds to the largest bipartite subgraph of the graph. The maximum cut of a graph is not necessarily unique and is not unique in either of the examples.

Figure 7: Maximum cuts for the two example graphs are shown above.
Figure 7 (maxcut_example_1.png)

Alternatively, the problem can be formulated in terms of the edges in the complement of the cut set. The complement of a set of edges that intersects every odd cycle in a graph induces a graph with no subgraphs that are odd cycles, which is therefore a bipartite graph. Thus, the complement of the minimum set of edges intersecting every odd cycle induces the largest bipartite subgraph of the graph and hence is the maximum cut set, as illustrated in Figure 8.

Figure 8: The complement of the minimum set (red) of edges intersecting all odd cycles of a graph is the maximum cut set.
Figure 8 (maxcut_example_2.png)

Finding the maximum cut of a graph was one of the earliest problems proven to be np-complete, which, ignoring the formal details of what that means, indicates that no currently known algorithms terminate in a polynomial bounded number of operations in all cases [5]. There are, however, several types of graphs for which polynomial bounded solutions are known, such as graphs embeddable on the plane [2]. Since computing the maxcut of large graphs often requires extremely long lengths of time, randomized ρ-approximation algorithms, such as that of Goemans and Williamson, may be employed for situations in which optimality is not required and a good estimate will suffice [4].

Applications of the maxcut problem include minimization of number of holes on circuit boards or number of chip contacts in VLSI circuit layout design, energy minimization problems in computer vision programs, and modeling of the interactions of spin glasses with magnetic fields in statistical physics [1].

Several Algorithms

The most direct and straightforward way to find maximum cuts of a graph would be to perform an exhaustive search of all bipartitions of the graph vertices. The maximum cut may be found by iterating over all distinct bipartitions of the graph vertices, summing the weights of edges connecting vertices in opposite partitions to calculate the size of the corresponding cut, comparing this value to the largest cut size previously found, and updating the maximum accordingly.

The exhaustive algorithm, which has computational complexity O(|E|2|V|)O(|E|2|V|), examines the same number of bipartitions for a tree, for which the maximum cut always equals the number of edges, as it does for a complete graph on the same number of vertices. Thus, it is clear that the exhaustive algorithm is not completely satisfactory, especially for graphs with few edges relative to other graphs with a given number of vertices.

Several researchers have published algorithms that attempt to improve performance, especially focusing on sparse graphs. Notable approaches include those of Wheeler with O*(2|V|)O*(2|V|)[6], Fedin and Kulikov with O*(2|E|/4)O*(2|E|/4)[3], Croce, Kaminski, and Paschos with O*(2|V||E|/|V|+|E|)O*(2|V||E|/|V|+|E|), and Williams with O*(2ω|V|/3)O*(2ω|V|/3), ω<2.376ω<2.376[2]. Although the last algorithm has the best computational complexity, it requires exponential space while the others require only polynomial bounded space. Due to limited memory storage capacity, algorithms requiring only polynomial bounded space are highly preferable.

A New Algorithm

In attempt to improve performance for sparse graphs, this research presents a new exact algorithm for finding maximum cuts of unweighted graphs that will now be described. It requires polynomial bounded space and has computational complexity O(|E|2|E|)O(|E|2|E|). The general approach that this algorithm takes is to separate the graph into its connected components and calculate initial upper and lower bounds for the maximum cut of each connected component. Those initial bounds are then used with a branch and bound algorithm to find a maximum cut of each connected component, and the maximum cuts of the connected components are be combined to find the maximum cut of the original graph.

In order to accomplish this, let I be the set of edge induced subgraphs of graph G(V,E)G(V,E). Let E be indexed by Z[1,|E|]Z[1,|E|] according to some ordering. Let I be indexed by Z[0,2|E|-1]Z[0,2|E|-1] according to the bijective function f:Z[0,2|E|-1]If:Z[0,2|E|-1]I such that

f - 1 ( G 1 ( V 1 , E 1 ) ) = i = 1 | E | 0 e i E 1 2 | E | - i e i E 1 f - 1 ( G 1 ( V 1 , E 1 ) ) = i = 1 | E | 0 e i E 1 2 | E | - i e i E 1
(1)

This indexing provides the advantage that the size of each element is the number of zeros in the binary representation of the index. Thus, it enables the use of the edge and graph indices to rapidly eliminate subgraphs that cannot be bipartite and surpass the current lower bound for the maximum cut.

Within this framework, the algorithm searches for the lowest indexed element of I that is bipartite and larger than the current lower bound by iterating over the edges in order, adding each edge to the cut set if it passes a parity check and stopping when the final edge is reached or the number of edges not cut ensures the result will not exceed the lower bound. If such an element is found, the size of the graph is a new lower bound for the maximum cut, and the search continues by removing last cut edge with at least one vertex not colored by a lesser indexed edge before last two edges not in cut set. Continue iterating from that edge if such an edge is found, but terminate if no such edge exists or a cut equal to the upper bound is reached. Otherwise, the search ends and the final lower bound is the size of the maximum cut.

This process can be visualized as a directed graph, like those in Figure 9, Figure 10, and Figure 11, where each step represents a decision whether to include an edge in the cut set. A movement directly downward from a node indicates that the corresponding edge is not cut, while a movement diagonally downward indicates that the corresponding edge is cut. Each path from the top node to one of the bottom nodes corresponds to an edge induced subgraph of the graph being examined. The number of the final node reached (from left to right starting with 0) is the number of edges included. The algorithm seeks to find a path corresponding to a bipartite subgraph that leads farthest to the right. The red line to the left represents the lower bound, and all nodes below this line cannot be part of a path that leads farther right than the lower bound. The red line to the right represents the upper bound, and all nodes to the right of this line can only be a part of paths that exceed the upper bound. Therefore these regions need not be explored. An illustrative example, corresponding to an instance of K4 with an edge ordering conductive to demonstration where a lower bound of 2 and an upper bound of 4 have been initially calculated (poor lower bound chosen for purpose of demonstration), is shown in Figure 9, Figure 10, and Figure 11.

Figure 9: This image illustrates the process for a K4 (with poorly estimated lower bound for purposes of demonstration). Each step represents a decision on including the corresponding edge. Each path from top to bottom, like that in blue, corresponds to an edge induced subgraph. The red lines correspond to upper and lower bounds.
Figure 9 (illustration1.png)
Figure 10: The algorithm searches for paths that lead further to the right than previously found. There is no need to search in regions beyond the red lines indicating bounds, which have been updated from the initial lower bound after finding a larger solution in the previous figure.
Figure 10 (illustration2.png)
Figure 11: Finally, a solution leading further right is found. Because this solution is of equal size to the upper bound, the search ends since there cannot be a larger cut.
Figure 11 (illustration3.png)

Empirical Testing

This new algorithm was compared to the exhaustive algorithm for performance in empirical testing as shown in Figure 12. The image shows a plot of average runtime for graphs with |V|=20|V|=20 nodes and numbers of edges between 0 and 3|V|=603|V|=60. Each data point for each algorithm is the average of runtimes for five randomly generated graphs with the same number of vertices. In the testing, the new algorithm outperformed the exhaustive algorithm at low densities about until |E|<2.5|V||E|<2.5|V|, successfully improving performance over the exhaustive algorithm at sufficiently low densities. However, no comparison to other algorithms developed by other researchers has been performed, and the algorithm is not expected to match or improve upon their performance.

Figure 12: This image shows a plot of average runtime for graphs with |V|=20|V|=20 nodes and numbers of edges between 0 and 3|V|=603|V|=60. Each data point for each algorithm is the average of runtimes for five randomly generated graphs with the same number of vertices.
Figure 12 (test.png)

Conclusion

Finding the maximum cut of a graph is a difficult to compute problem in combinatorial optimization with several applications in the world of engineering and physics. This research develops and evaluates an exact branch and bound algorithm for the maximum cut of unweighted graphs that was designed for improved performance on sparse graphs. Although the algorithm developed provides a performance improvement over the exhaustive algorithm, it is not expected to perform as well or better than other algorithms developed by other researchers. Thus, further improvement of the algorithm, focusing on investigating the effect of edge orderings on the performance of the algorithm and finding additional measures to reduce the number of edge induced subgraphs traversed by the algorithm, and more extensive empirical evaluation are necessary.

References

  1. Barahona, Francisco et al. (1988). An Application of Combinatorial Optimization to Statistical Physics and Circuit Layout Design.
  2. Croce, Frederico and al, et. (2006). An Exact Algorithm for Maxcut in Sparse Graphs.
  3. Fedin, Sergey and Kulikov, Alexander. (2002). Time Algorithm for Max-cut.
  4. Goemans, Michael and Williamson, David. (1995). Improved Approximation Algorithms for Maximum Cut and Satisfiability Problems Using Semidefinite Programming.
  5. Karp, Richard. (1972). Reducibility Among Combinatorial Problems.
  6. Wheeler, John. (2004). An Investigation of the Maxcut Problem.

Collection Navigation

Content actions

Download:

Collection as:

PDF | EPUB (?)

What is an EPUB file?

EPUB is an electronic book format that can be read on a variety of mobile devices.

Downloading to a reading device

For detailed instructions on how to download this content's EPUB to your specific device, click the "(?)" link.

| More downloads ...

Module as:

PDF | EPUB (?)

What is an EPUB file?

EPUB is an electronic book format that can be read on a variety of mobile devices.

Downloading to a reading device

For detailed instructions on how to download this content's EPUB to your specific device, click the "(?)" link.

| More downloads ...

Add:

Collection to:

My Favorites (?)

'My Favorites' is a special kind of lens which you can use to bookmark modules and collections. 'My Favorites' can only be seen by you, and collections saved in 'My Favorites' can remember the last module you were on. You need an account to use 'My Favorites'.

| A lens I own (?)

Definition of a lens

Lenses

A lens is a custom view of the content in the repository. You can think of it as a fancy kind of list that will let you see content through the eyes of organizations and people you trust.

What is in a lens?

Lens makers point to materials (modules and collections), creating a guide that includes their own comments and descriptive tags about the content.

Who can create a lens?

Any individual member, a community, or a respected organization.

What are tags? tag icon

Tags are descriptors added by lens makers to help label content, attaching a vocabulary that is meaningful in the context of the lens.

| External bookmarks

Module to:

My Favorites (?)

'My Favorites' is a special kind of lens which you can use to bookmark modules and collections. 'My Favorites' can only be seen by you, and collections saved in 'My Favorites' can remember the last module you were on. You need an account to use 'My Favorites'.

| A lens I own (?)

Definition of a lens

Lenses

A lens is a custom view of the content in the repository. You can think of it as a fancy kind of list that will let you see content through the eyes of organizations and people you trust.

What is in a lens?

Lens makers point to materials (modules and collections), creating a guide that includes their own comments and descriptive tags about the content.

Who can create a lens?

Any individual member, a community, or a respected organization.

What are tags? tag icon

Tags are descriptors added by lens makers to help label content, attaching a vocabulary that is meaningful in the context of the lens.

| External bookmarks