Formulation of the Denoising Problem
The problem is given by:
$$ \arg \min_{x} \frac{1}{2} {\left\| x - y \right\|}_{2}^{2} + \lambda \operatorname{TV} \left( x \right) = \arg \min_{x} \frac{1}{2} {\left\| x - y \right\|}_{2}^{2} + \lambda {\left\| D x \right\|}_{1} $$
Where $ D $ is the column stacked derivative operator.
In the above I used the Anisotropic TV Norm.
Solution by ADMM
The ADMM problem will be formulated as:
$$ $$
$$\begin{aligned}
\arg \min_{x, z} \quad & \frac{1}{2} {\left\| x - y \right\|}_{2}^{2} + \lambda {\left\| z \right\|}_{1} \\
\text{subject to} \quad & D x = z
\end{aligned}$$
The ADMM will have 3 steps:
vX = mC \ (vY + (paramRho * mD.' * (vZ - vU)));
.
vZ = ProxL1(mD * vX + vU, paramLambda / paramRho);
.
vU = vU + mD * vX - vZ;
.
Where mC = decomposition(mI + paramRho * (mD.' * mD), 'chol');
.
I coded this solution in a MATLAB function - SolveProxTvAdmm()
.
I compared it to a reference by CVX:
The full code is available on my StackExchange Signal Processing Q75231 GitHub Repository (Look at the SignalProcessing\Q75231
folder).
Remark: For the Deblurring problem, open a new question and I will post a code for it as well.