pyproximal.Quadratic#
- class pyproximal.Quadratic(Op=None, b=None, c=0.0, niter=10, x0=None, warm=True)[source]#
Quadratic function proximal operator.
Proximal operator for a quadratic function: \(f(\mathbf{x}) = \frac{1}{2} \mathbf{x}^T \mathbf{Op} \mathbf{x} + \mathbf{b}^T \mathbf{x} + c\).
- Parameters
- Op
pylops.LinearOperator
, optional Linear operator (must be square)
- b
np.ndarray
, optional Vector
- c
float
, optional Scalar
- niter
int
, optional Number of iterations of iterative scheme used to compute the proximal
- x0
np.ndarray
, optional Initial vector
- warm
bool
, optional Warm start (
True
) or not (False
). Uses estimate from previous call ofprox
method.
- Op
- Raises
- ValueError
If
Op
is not square
Notes
The Quadratic proximal operator is defined as:
\[\prox_{\tau f}(\mathbf{x}) = \left(\mathbf{I} + \tau \mathbf{Op} \right)^{-1} \left(\mathbf{x} - \tau \mathbf{b}\right)\]when both
Op
andb
are provided. This formula shows that the proximal operator requires the solution of an inverse problem. If the operatorOp
is of kindexplicit=True
, we can solve this problem directly. On the other hand ifOp
is of kindexplicit=False
, an iterative solver is employed. In this case it is possible to provide a warm start via thex0
input parameter.When only
b
is provided, the proximal operator reduces to:\[\prox_{\mathbf{b}^T \mathbf{x} + c}(\mathbf{x}) = \mathbf{x} - \tau \mathbf{b}\]Finally if also
b
is not provided, the proximal operator of a constant function simply becomes \(\prox_c(\mathbf{x}) = \mathbf{x}\)Methods
__init__
([Op, b, c, niter, x0, warm])affine_addition
(v)Affine addition
chain
(g)Chain
grad
(x)Compute gradient
postcomposition
(sigma)Postcomposition
precomposition
(a, b)Precomposition
prox
(**kwargs)proxdual
(**kwargs)