avoid negative remaining columns (fixes #3)