On this page
What is the max-cut problem?
Take a graph: vertices joined by edges. Colour each vertex gold or pink. An edge is cut when its two ends get different colours. The max-cut problem asks for the colouring that cuts as many edges as possible; with weights on the edges, it asks for the largest total weight crossing the split, as Michel Goemans and David Williamson define it in their 1995 paper in the Journal of the ACM.
That paper notes that max-cut is one of Karp's original NP-complete problems, and that it stays NP-complete even when every edge has weight 1. So nobody knows a fast method that always finds the best cut. Instead we ask for a ρ-approximation: a fast method guaranteed at least a fraction ρ of the best.
How does a coin flip give a 1/2-approximation?
Flip a fair coin for every vertex. Each edge is cut with probability 1/2. By linearity of expectation (see our guide to linearity of expectation), the expected number of cut edges is m/2, where m is the number of edges. No cut can exceed m, so on average you get at least half the best.
The Goemans–Williamson paper credits Sahni and Gonzales (1976) with a 1/2-approximation that is essentially equivalent to this coin flip, and says no one improved that constant for nearly twenty years.
Why does local search also cut half the edges?
Start from any split. If a vertex has more uncut edges than cut ones, move it across: the cut grows, so this stops within m moves. Then every vertex has at least half its edges cut. Summing over vertices counts each edge twice, so at least m/2 edges are cut, with no randomness.
How does the Goemans–Williamson algorithm reach 0.878?
Write each vertex's side as a number y = +1 or −1. Edge ij is cut exactly when y_i y_j = −1, so the cut size is the sum over edges of (1 − y_i y_j)/2.
The Goemans–Williamson algorithm works in three steps:
Relax: replace each number y_i by a unit vector v_i, and the product by the dot product, then maximise the sum of (1 − v_i·v_j)/2. Every real cut is still allowed (all vectors on one line), so this optimum is an upper bound on the max cut.
Solve: the table of dot products must be a positive semidefinite matrix (see how to test whether a matrix is positive definite), so this is a semidefinite program, which the paper notes can be solved to any accuracy in polynomial time.
Round: pick a random vector r and put vertex i on the gold side if v_i·r ≥ 0, so a random hyperplane through the origin splits the vectors.
Two vectors at angle θ end up on opposite sides with probability θ/π, while they contributed (1 − cos θ)/2 to the relaxation. The paper proves the worst ratio between the two, α = min over 0 < θ ≤ π of (2/π)·θ/(1 − cos θ), is greater than 0.87856. So the expected cut is at least 0.878 times the relaxation, hence at least 0.878 times the max cut.
Worked example: what happens on a 5-cycle?
Take the ring 1-2-3-4-5-1. Going round, you switch colour at every cut edge and end where you started, so cuts are even. The max cut is 4.
Coin flip: each of the 5 edges is cut with probability 1/2, so you expect 2.5.
Local search: a cut of 2 leaves some vertex with both edges uncut, so it moves. Every stopping point cuts 4.
Relaxation: place the five vectors in a plane, 144° apart, with vertex k at angle 144k°. Each edge gives (1 − cos 144°)/2 ≈ 0.9045, so the relaxation is about 4.523, above the true 4.
Rounding: each edge is separated with probability 144/180 = 0.8, so the expected cut is 5 × 0.8 = 4. Since no cut beats 4, every hyperplane gives exactly 4.
The ratio 4/4.523 ≈ 0.884 matches the 5-cycle value 32/(25 + 5√5) ≈ 0.88445 in the Goemans–Williamson paper, close to α.
Is 0.878 the best anyone can do?
Possibly. Khot, Kindler, Mossel and O'Donnell showed in SIAM Journal on Computing (2007) that if the Unique Games Conjecture holds, beating about 0.878567 by any fixed margin is hard, so Goemans–Williamson would be optimal. That conjecture is unproven.
How should you practise this?
Coin-flip a triangle: expect 1.5 cut edges; the best is 2.
Run local search on a 4-cycle coloured gold, gold, pink, pink: no vertex moves, so it stops at 2 of the best 4.
Draw the five 144° vectors, pick any line through the centre, and count cut edges. You should always get 4.
Compare the max-flow min-cut theorem, where the smallest cut is the easy problem.
For the building blocks, theFermi Concept Library covers every concept in mathematics and computing, and the Fermi Problem Library has a step-by-step solver that explains the reasoning when your expectation or matrix work goes wrong.



