vendor/scs/test/problem_utils.h in scs-0.4.0 vs vendor/scs/test/problem_utils.h in scs-0.4.1

- old
+ new

@@ -188,10 +188,11 @@ pobj = xt_p_x / 2. + ctx; dobj = -xt_p_x / 2. - bty; /************** OPTIMALITY ****************/ + /* TODO: the MAX expansion computes these norms many times */ grl = MAX(MAX(ABS(xt_p_x), ABS(ctx)), ABS(bty)); prl = MAX(MAX(NORM(b, m), NORM(s, m)), NORM(ax, m)); drl = MAX(MAX(NORM(c, n), NORM(px, n)), NORM(aty, n)); /**************** CLEANUP *****************/ @@ -213,10 +214,10 @@ 1e-9 * (1 + ABS(pobj))); mu_assert_less("Dual obj ERROR", ABS(dobj - info->dobj), 1e-9 * (1 + ABS(dobj))); /* slightly looser tol */ mu_assert_less("Complementary slackness ERROR", ABS(sty), - 1e-8 * MAX(NORM(s, m), NORM(y, m))); + 5e-8 * MAX(NORM(s, m), NORM(y, m))); mu_assert_less("s cone dist ERROR", ABS(sdist), 1e-5); mu_assert_less("y cone dist ERROR", ABS(ydist), 1e-5); mu_assert_less("Primal feas ERROR", res_pri, stgs->eps_abs + stgs->eps_rel * prl);