Skip to main content
Tweeted twitter.com/StackSignals/status/1462526253412454401
added 707 characters in body
Source Link
bla
  • 588
  • 1
  • 4
  • 14

Following up from an answer by @Royi on adding weights to BPDN problem , I would like to use CVX to test this approach. How can we formulate in CVX the regularized LS L1 norm with weights given by a vector $c$, as follows:
$$ \arg \min_{\boldsymbol{x}} \frac{1}{2} {\left\| A \boldsymbol{x} - \boldsymbol{y} \right\|}_{ {C}^{-1} }^{2} + \lambda {\left\| \boldsymbol{x} \right\|}_{1} $$

Where $ C $ is the covariance matrix $ \operatorname{diag} \left( \boldsymbol{c} \right) $ ?

Here's a minimal example using Matlab:

% problem data A = [1 0 0 0.5;... 0 1 0.2 0.3;... 0 0.1 1 0.2]; x0 = [1 0 1 0]'; % original signal y = A*x0; % measurements with no noise w = randi(1e3,1,numel(y))'; % random weights vector y = y + 1./(sqrt(w)).*randn(numel(y),1); % measurements with weighted noise 

CVX that does not include the weights info would be:

lambda = 0.01; % regularization parameter cvx_precision high cvx_solver SeDuMi cvx_begin quiet variable x(size(A,2),1); minimize(norm(A*x-y)+lambda*norm(x1,1)) cvx_end x = 0.9864 -0.0281 1.0108 0 

Following up from an answer by @Royi on adding weights to BPDN problem , I would like to use CVX to test this approach. How can we formulate in CVX the regularized LS L1 norm with weights given by a vector $c$, as follows:
$$ \arg \min_{\boldsymbol{x}} \frac{1}{2} {\left\| A \boldsymbol{x} - \boldsymbol{y} \right\|}_{ {C}^{-1} }^{2} + \lambda {\left\| \boldsymbol{x} \right\|}_{1} $$

Where $ C $ is the covariance matrix $ \operatorname{diag} \left( \boldsymbol{c} \right) $ ?

Following up from an answer by @Royi on adding weights to BPDN problem , I would like to use CVX to test this approach. How can we formulate in CVX the regularized LS L1 norm with weights given by a vector $c$, as follows:
$$ \arg \min_{\boldsymbol{x}} \frac{1}{2} {\left\| A \boldsymbol{x} - \boldsymbol{y} \right\|}_{ {C}^{-1} }^{2} + \lambda {\left\| \boldsymbol{x} \right\|}_{1} $$

Where $ C $ is the covariance matrix $ \operatorname{diag} \left( \boldsymbol{c} \right) $ ?

Here's a minimal example using Matlab:

% problem data A = [1 0 0 0.5;... 0 1 0.2 0.3;... 0 0.1 1 0.2]; x0 = [1 0 1 0]'; % original signal y = A*x0; % measurements with no noise w = randi(1e3,1,numel(y))'; % random weights vector y = y + 1./(sqrt(w)).*randn(numel(y),1); % measurements with weighted noise 

CVX that does not include the weights info would be:

lambda = 0.01; % regularization parameter cvx_precision high cvx_solver SeDuMi cvx_begin quiet variable x(size(A,2),1); minimize(norm(A*x-y)+lambda*norm(x1,1)) cvx_end x = 0.9864 -0.0281 1.0108 0 
edited tags; edited tags
Link
Royi
  • 21k
  • 4
  • 200
  • 242

Solving a Weighted Basis Pursuit Denoising Problem (BPDN) with MATLAB / CVX for covariance matrix norm

Source Link
bla
  • 588
  • 1
  • 4
  • 14

CVX for covariance matrix norm

Following up from an answer by @Royi on adding weights to BPDN problem , I would like to use CVX to test this approach. How can we formulate in CVX the regularized LS L1 norm with weights given by a vector $c$, as follows:
$$ \arg \min_{\boldsymbol{x}} \frac{1}{2} {\left\| A \boldsymbol{x} - \boldsymbol{y} \right\|}_{ {C}^{-1} }^{2} + \lambda {\left\| \boldsymbol{x} \right\|}_{1} $$

Where $ C $ is the covariance matrix $ \operatorname{diag} \left( \boldsymbol{c} \right) $ ?