# Equivalent constraints leading to different results

Hello, possibly really dumb question.

My original constraint is

|f|<=f_lim, f being the variable

which solves just fine.

Then I modified the constraint to
-f_lim<=f<=f_lim

and the solver status = fails

The code is here:

``````cvx_begin
variables f(10) a(10) b(10)
minimize(sum(a+b))
subject to
A*f == -F
L.'*(a-b) <= 0.2
for k=1:10
norm([b(k) C(k)*f(k)]) <= a(k)

% This leads to infeasibility in this problem
% -f_lim(k)*(a(k)-b(k)) <= f(k) <= f_lim(k)*(a(k)-b(k))

% This solves, the results are verified to be correct
abs(f(k)) <= f_lim(k)*(a(k)-b(k))
end
cvx_end
``````

The data is here:
data.mat

Any ideas?

Tim

It may help if you show all your code, including input data. I.e., provide reproducible code. Have you looked at the solver output (iterations)? Have you tried more than one solver?

Just as an example of how I am in the dark right now,

``````|f|<=f_lim
``````

is not CVX code, and i don’t know what your code actually is, or even the dimension of f.

Hey Mark, thanks for your reply. I’ve updated my post to include a workable code as well as the data necessary.

Both constraints are included.