Builds and solves a simple linear program
echo on
n = 100;
A = randn(0.5*n,n);
b = randn(0.5*n,1);
c = randn(n,1);
d = randn;
cvx_begin
variable x(n)
dual variables y z
minimize( c' * x + d )
subject to
y : A * x == b;
z : x >= 0;
cvx_end
echo off
Calling SDPT3: 100 variables, 50 equality constraints
------------------------------------------------------------
num. of constraints = 50
dim. of linear var = 100
*******************************************************************
SDPT3: Infeasible path-following algorithms
*******************************************************************
version predcorr gam expon scale_data
NT 1 0.000 1 0
it pstep dstep pinfeas dinfeas gap mean(obj) cputime
-------------------------------------------------------------------
0|0.000|0.000|6.9e+01|1.2e+01|1.4e+04| 3.663372e+01| 0:0:00| chol 1 1
1|0.670|0.488|2.3e+01|6.3e+00|7.8e+03| 2.938673e+01| 0:0:00| chol 1 1
2|1.000|0.669|1.6e-05|2.1e+00|3.2e+03| 6.122941e+01| 0:0:00| chol 1 1
3|1.000|0.747|4.5e-05|5.3e-01|9.3e+02| 1.603458e+01| 0:0:00| chol 1 1
4|0.517|0.514|2.8e-05|2.6e-01|5.2e+02|-1.074434e+02| 0:0:00| chol 1 1
5|0.593|0.182|1.1e-05|2.1e-01|8.5e+02|-1.084396e+03| 0:0:00| chol 1 1
6|0.319|0.063|8.1e-06|2.0e-01|3.7e+03|-9.393164e+03| 0:0:00| chol 1 1
7|0.310|0.098|5.2e-06|1.8e-01|1.8e+04|-1.318924e+05| 0:0:00| chol 1 1
8|0.021|0.028|5.2e-06|1.7e-01|6.3e+04|-8.746609e+05| 0:0:00| chol 1 1
9|1.000|0.023|4.5e-06|1.7e-01|1.7e+07|-7.446699e+08| 0:0:00| chol 2 2
10|1.000|0.003|3.4e-03|1.7e-01|1.0e+11|-6.030202e+12| 0:0:00| chol 2 2
stop: primal infeas has deteriorated too much, 3.6e+01
11|1.000|0.004|3.4e-03|1.7e-01|1.0e+11|-6.030202e+12| 0:0:00|
prim_inf,dual_inf,relgap = 3.44e-03, 1.68e-01, 8.52e-03
sqlp stop: dual problem is suspected of being infeasible
-------------------------------------------------------------------
number of iterations = 11
residual of dual infeasibility
certificate X = 4.43e-04
reldist to infeas. <= 6.73e-06
Total CPU time (secs) = 0.2
CPU time per iteration = 0.0
termination code = 2
DIMACS: 1.6e-05 0.0e+00 4.9e-01 0.0e+00 -1.0e+00 2.0e-01
-------------------------------------------------------------------
------------------------------------------------------------
Status: Unbounded
Optimal value (cvx_optval): -Inf