bugfix in localMinimum