pyproximal.projection.EuclideanBallProj#

class pyproximal.projection.EuclideanBallProj(center, radius)[source]#

Euclidean ball projection.

Parameters
centernp.ndarray or float

Center of the ball

radiusfloat

Radius

Notes

Given an Euclidean ball defined as:

\[\operatorname{Eucl}_{[c, r]} = \{ \mathbf{x}: l ||\mathbf{x} - \mathbf{c}||_2 \leq r \}\]

its orthogonal projection is:

\[P_{\operatorname{Eucl}_{[c, r]}} (\mathbf{x}) = \mathbf{c} + \frac{r} {max\{ ||\mathbf{x} - \mathbf{c}||_2^2, r\}}(\mathbf{x} - \mathbf{c})\]

Note the this is the proximal operator of the corresponding indicator function \(\mathcal{I}_{\operatorname{Eucl}_{[c, r]}}\).

Methods

__init__(center, radius)