While re-implementing the classic Chan-Vese Algorithm for image segmentation, I stumbled upon the following statement, which I have problems to understand:
Let $H: \mathbb{R} \to \mathbb{R}$ be the Heavyside-Function defined as $H(x) := 1$ for $x \ge 0$ and $H(x) := 0$ for $x<0$ and let $\delta_0$ be the 1-D delta distribution centered at 0. Let furthermore $\Omega \subset \mathbb{R}^n$ be a bounded domain with sufficiently smooth boundary $\partial \Omega$ and let $\varphi: \mathbb{R}^n \to \mathbb{R}$ be a smooth function for which holds that \begin{align} \varphi(x) > 0 \text{ for } & x \in \Omega, \\ \varphi(x) = 0 \text{ for } & x \in \partial \Omega, \\ \varphi(x) < 0 \text{ for }& x \in \mathbb{R}^n\setminus \Omega. \end{align} According to the classic Chan-Vese paper, it is supposed to hold (in the distributional sense) that: $$\tag{1} \text{Peri}(\Omega) = \int_{\mathbb{R}^n} \vert \nabla (H\circ \varphi) \vert \, dx = \int_{\mathbb{R}^n} (\delta_0\circ \varphi) \cdot \vert \nabla \varphi \vert \, dx $$ Now what is puzzling me is the following: I can see that the perimeter of $\Omega$ can be expressed as the total variation of $H\circ \varphi$. But this term seems to depends only on the sign of $\varphi$, whereas the third term seems to depend on the gradient of $\varphi$. Wouldn't a choice of $c \cdot \varphi$ for $c > 0$ result in a scaling of the third term but leave the perimeter untouched?
Comments are much appreciated.
Edit: Maybe it's a good idea to add the Chan-Vese Paper as a reference. Equation (1) can be found in: T. F. Chan and L. A. Vese, “Active contours without edges.,” IEEE Trans. on Image Process., vol. 10, no. 2, pp. 266–277, Feb. 2001.