bugfix for dual decomposition