  We prove a comparison principle for the porous medium equation in more
general open sets in $\mathbb{R}^{n+1}$ than space-time cylinders. We apply
this result in two related contexts: we establish a connection between a
potential theoretic notion of the obstacle problem and a notion based on a
variational inequality. We also prove the basic properties of the PME capacity,
in particular that there exists a capacitary extremal which gives the capacity
for compact sets.
