We wish to find an optimal solution to an economic problem concerning allocation of a public good by some central, governing body, over a spatial dimension. In particular, this government is cost minimizing, so it wishes to provide the minimal amount of the public good necessary to achieve its desired outcome, while at the same time considering its dual of maximizing the benefit of the limited amount of good which it provides. This paper puts forth a straightforward, easily-implementable algorithm using only some linear algebra and graph theory to solve this problem with suitable generality for varied applications in public economics and beyond. In short, this algorithm, given a static, planar graph and a utility function solves for the con...