make curve and implementation separate