From 7c479cf7d15f861b0a41a4b16ff4f90f884183e1 Mon Sep 17 00:00:00 2001 From: Sven Verdoolaege Date: Wed, 3 Jan 2007 18:14:23 +0100 Subject: [PATCH] decomposer.cc: short_vector: negate lambda if z is negated This is only needed for the primal decomposition, since the dual decomposition doesn't care about the signs of the coefficients in lambda, but it never seems to happen in practice. --- decomposer.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/decomposer.cc b/decomposer.cc index fff489b..69d6330 100644 --- a/decomposer.cc +++ b/decomposer.cc @@ -96,6 +96,7 @@ public: value_set_si(tmp, -1); Vector_Scale(z->p, z->p, tmp, z->Size-1); value_clear(tmp); + lambda = -lambda; } return z; } -- 2.11.4.GIT