Using Michael E2's answer, I performed a manual arclength parameterisation by solving the differential equation (or: finding the inverse of a function whose derivative is known).
I compared the results with the built-in arclength mesh-sampling. Unexpectedly, they are not the same (see green and red points on plot).
Using the built-in function is no solution to this problem, because I need this method for some other sampling based on specific parameterisations (other than arclength).
Here's the code:
ptsp = {{0, 0}, {0, 2}, {3, 2}, {1, -2}, {4, -2}, {4, 0}}; g = BSplineFunction[ptsp, SplineWeights -> {1, 1, 15, 15, 1, 1}, SplineDegree -> 3]; ClearAll[s, t]; dg[t_?NumericQ] := If[t - 1. <= 0, g'[t], g'[1]]; tfn = NDSolveValue[{t'[s] == 1/Norm[dg[t[s]]], t[0] == 0, WhenEvent[t[s] == 1, "StopIntegration"]}, t, {s, 0, 1 + NIntegrate[Norm[g'[t]], {t, 0, 1}]}]; ParametricPlot[g[t], {t, 0, 1}, MeshFunctions -> {"ArcLength"}, Mesh -> {20-1}, MeshStyle -> {PointSize[0.015], Green}, PlotStyle -> {Black} Epilog -> { PointSize[0.013], Red, Point[g /@ tfn[Rescale[Range[0, 1, 1/20], {0, 1}, First@tfn["Domain"]]]], PointSize[0.01], Gray, Point[g /@ Range[0, 1, 1/20]] } ] I also tried other methods, like this answer, which gave the same wrong result.
Does anyone have an idea why this happens for this specific B-Spline?




