negative values, fix bugs