Two-dimensional (2-D) phase unwrapping, that is, deducing unambiguous phase values from a 2-D array of values known only modulo 2pi, is a key step in interpreting data acquired with synthetic aperture radar interferometry. Noting the recent network formulation of the phase unwrapping problem, we apply here some well-established ideas of network theory to formalize the problem, analyze its complexity, and derive algorithms for its solution. It has been suggested that the objective of phase unwrapping should be to minimize the total number of places where unwrapped and wrapped phase gradients differ. Here we use network constructions to show that this so-called minimum L0-norm problem is NP-hard, or one that complexity theory suggests is impossible for efficient algorithms to solve exactly. Therefore we must instead find approximate solutions; we present two new algorithms for doing so. The first uses the network ideas of shortest paths and spanning trees to improve on the Goldstein et al. residue-cut algorithm [Radio Sci. 23, 713 (1988)]. Our improved algorithm is very fast, provides complete coverage, and allows user-defined weights. With our second algorithm, we extend the ideas of linear network flow problems to the nonlinear L0 case. This algorithm yields excellent approximations to the minimum L0 norm. Using interferometric data, we demonstrate that our algorithms are highly competitive with other existing algorithms in speed and accuracy, outperforming them in the cases presented here.