I'm trying to find an efficient approach to minimising the sum of pseudo-huber penalty along a vector. Ideally I would like to be able to formulate this problem as a linear system of the form $\mathbf{Ax = b}$, which can be solved via the conjugate gradient method.
First let $h(x): \mathbb{R} \to\mathbb{R}$ be the psuedo-huber penalty
$h(x) = t^2 \left(\sqrt{1 + \left(\frac{x}{t}\right)^2} - 1 \right)$
which is smooth and convex. To find the minimum we take the first derivative and set it to zero
$\frac{\partial}{\partial x} h(x) = \frac{x}{\sqrt{1 + (\frac{x}{t})^2}} = 0 \; \therefore x = 0$
I wish to extend this to the case of vector input. Let $\| \mathbf{x} \|_{H}: \mathbb{R}^n \to \mathbb{R}$ be the pseudo-huber norm
$\| \mathbf{x} \|_{H} = \sum_{i=1}^n t^2 \sqrt{1 + \left(\frac{\mathbf{x_i}}{t}\right)^2} - t^2$
Since the psuedo-huber penalty is convex the sum should also be convex. So to find the minimum we take the same approach as before and set the first derivative to zero. The derivative of a summation can be written as the summation of derivatives:
$\frac{\partial}{\partial \mathbf x} \| \mathbf{x} \|_{H} = \sum_{i=1}^n \frac{\mathbf x_i}{\sqrt{1 + (\frac{\mathbf x_i}{t})^2}}$
Now we come to the real problem. Can one write $\frac{\partial}{\partial \mathbf x} \| \mathbf{x} \|_{H}$ in matrix notation? For example one might wish to minimise
$f(\mathbf x) = \| \mathbf{D x - s} \|_2^2 + \| \mathbf{x} \|_{H}$
Ideally we would like $\frac{\partial}{\partial \mathbf x} f(x) = 0$ to be of the form $\mathbf{Ax = b}$ so that we can solve it using the conjugate gradient method.
A more complete example would be:
$\min_{\mathbf{x}} \; g(\mathbf x) = \| \mathbf{D x - s} \|_2^2 + \| \mathbf{x} \|_{2} \\ \frac{\partial}{\partial \mathbf x} g(x) = 2(\mathbf{D x - s}) + 2 \mathbf x = 0 \\ (\mathbf D + \mathbf I)\mathbf x = \mathbf s$
Which is of the form $\mathbf{Ax = b}$.