Hi All,
I am having a problem running CVX with norms in my objective function or constraints. CVX works fine when solving most problems, but whenever I try to incorporate a norm in any way, I get the error “Attempt to execute SCRIPT norms as a function:”. I tried to create the simplest example possible:
close all;
clear all;
clc;
cvx_begin
variable x
minimize norm(x,1)
cvx_end
The code should return some optimal value essentially zero (running the code on a peer’s computer returned +2.37836e-09), but instead the following is returned in the console:
Attempt to execute SCRIPT norms as a function:
/Users/***/***/***/***/norms.m
Error in cvx/svec (line 17)
z = y .* norms( xR, nrm, 2 );
Error in cvx/norm (line 46)
x = svec( x, p );
Error in minimize (line 14)
x = evalin( 'caller', sprintf( '%s ', varargin{:} ) );
Error in cvxproblem (line 6)
minimize norm(x,1)
Nobody I asked, including experienced MATLAB users, has been able to explain the error and I simply do not know how to fix it. I am running CVX version 3 (29 June 2007) and MATLAB R2015a on a 2015 Macbook Pro. If anyone has any tips or fixes, I would be forever grateful!
Thanks,
Kevin