splinebox.spline_curves.Spline.

arc_length_to_parameter#

Spline.arc_length_to_parameter(s, atol=0.0001)#

Convert the arc length s to the coresponding value in parameter space.

Parameters:
sfloat or np.array

Length on curve.

atolfloat

The ablsolute error tolerance.

Examples

>>> spline = splinebox.Spline(M=4, basis_function=splinebox.B3(), closed=False)
>>> spline.control_points=np.array([[2], [3], [2], [6], [1], [2]])
>>> spline.arc_length_to_parameter(2.2)
2.12
>>> spline.arc_length(0, 2.12)
2.2

Measure the curvature of a peptide

Measure the curvature of a peptide