Length parameter from Curve parameter space

Hi I noticed that Curve Parameter Space is not linear.
I wonder how to get the Length parameter that matches a given CurveParameterSpace t.

Basically, the opposite of https://developer.rhino3d.com/api/RhinoCommon/html/M_Rhino_Geometry_Curve_LengthParameter.htm

Thanks

I guess you’re looking for GetLength:

private void RunScript(Curve curve, double t, ref object length)
{
    length = curve.GetLength(new Interval(0, t));
}

GetLength.gh (2.9 KB)