fixed bounds to work for all cases