Bug fix and improvement on class 'Curve'.
Minor fixes, improvements and cleaning up.