In this link, it says that the gradient is as follow

The Gradient of the TV norm is $$ \mathrm{Grad}J(f)=\mathrm{div}\left(\frac{\nabla f}{\lVert\nabla f\rVert}\right). $$

From this other link, it also mentions that the derivative is as follow

Formally, we can write $\partial J(u)=-\mathrm{div}\left(\frac{\nabla u}{\lvert \nabla u\rvert}\right)$

I know how to calculate divergence, but I don't understand how the gradient of total variation is related to divergence.


I am by no means an expert on total variation, however I think you should check out this Wikipedia page. It doesn't directly answer your question, but I believe the lemma below illustrates the relationship between total variation and divergence.

There, it gives a lemma that follows from the Gauss-Ostrogradsky theorem and provides a proof for it,

$\int_{\Omega}f\,div(\phi) = -\int_{\Omega} \nabla f \cdot\phi$.

I think for some intution about divergence, it might be helpful to read Wikipedia's explanation.

  • $\begingroup$ Thanks. Long time ago, I have read the link on total variation and need read it again. I have another question. From the link, the definition of total variation for a differentiable function uses L2-norm. From some paper, I remember that the definition uses L1-norm. Does total variation have different definitions? $\endgroup$ – Jogging Song Jun 28 '16 at 2:05
  • $\begingroup$ I think they talk about both norms in the wikipedia page. I think (not certain) that the term total variation is sometimes used loosely and that the real "definition" is dependent upon what your application is. $\endgroup$ – Brady Sheehan Jun 28 '16 at 16:06
  • $\begingroup$ Both definitions of TV are used in Image Processing. Usually, authors do not make an effort in distinguishing them (because the results are very close). However, you may sometimes know which one was used by checking the names: the L2 version is called "isotropic TV" while the L1 version is called "anisotropic TV". $\endgroup$ – sansuiso Aug 22 '16 at 12:04

To obtain the Gradient of the TV norm, you should refer to the calculus of variations. By examining the TV minimization with Euler-Lagrange equation, e.g,, Eq. (2.5a) in [1], you would see the answer.

[1] Nonlinear total variation based noise removal algorithms, 1992.

  • $\begingroup$ Thank you for the answer. You could probably rewrite the mentioned equation to better the OP $\endgroup$ – Laurent Duval Apr 26 '17 at 13:01

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.