PROJ_B1 - Projection onto a L1-ball

Usage

sol=proj_b1(x, ~, param)
[sol,infos]=proj_b1(x, ~, param)

Input parameters

x Input signal.
param Structure of parameters.

Output parameters

sol Solution.
info Structure summarizing informations at convergence

Description

proj_b1(x,~,param) solves:

\begin{equation*} sol = \min_z ||x - z||_2^2 \hspace{1cm} s.t. \hspace{1cm} \|w.*z\|_1 < \epsilon \end{equation*}

Remark: the projection is the proximal operator of the indicative function of \(||w.*z||_1 < \epsilon\). So it can be written:

\begin{equation*} prox_{f, \gamma }(x) \hspace{1cm} where \hspace{1cm} f= i_c(\|w.*z\|_1 < \epsilon) \end{equation*}

param is a Matlab structure containing the following fields:

  • param.epsilon : Radius of the L1 ball (default = 1).
  • param.weight : contain the weights (default ones).
  • param.verbose : 0 no log, 1 a summary at convergence, 2 print main steps (default: 1)

info is a Matlab structure containing the following fields:

  • info.algo : Algorithm used
  • info.iter : Number of iteration
  • info.time : Time of exectution of the function in sec.
  • info.final_eval : Final evaluation of the function
  • info.crit : Stopping critterion used

Rem: The input "~" is useless but needed for compatibility issue.

This code is partly borrowed from the SPGL toolbox!