reorganize
updated with cases to put on slides
implemented spline curve