corrected curve drawing