fix for incorrect bounds of curve problem