Cross-section slices used to be defined in Length, for position and the value of offset and width. Therefore a Function<Length, Length> was chosen to replace it in function style. However, the position value is not clear. Is it position along the design line of the link, along the continuous center line of the cross-section element, along the flattened design line of the link, or along the flattened center line of the cross-section element?
To avoid confusion, a fractional double position is more clear. For simplicity, we will use Function<Double, Double> rather than Function<Double, Length>. Note that with this change, all geometry in CrossSectionGeometry is double-valued (including also OtsLine2d and Polygon2d).
This change has simplified temporary code. Now there is only temporary interface ContinuousLine.ContinuousDoubleFunction which FractionalLengthData implements. This changes conclusions mentioned in #169.
Cross-section slices used to be defined in
Length
, for position and the value of offset and width. Therefore aFunction<Length, Length>
was chosen to replace it in function style. However, the position value is not clear. Is it position along the design line of the link, along the continuous center line of the cross-section element, along the flattened design line of the link, or along the flattened center line of the cross-section element?To avoid confusion, a fractional
double
position is more clear. For simplicity, we will useFunction<Double, Double>
rather thanFunction<Double, Length>
. Note that with this change, all geometry inCrossSectionGeometry
isdouble
-valued (including alsoOtsLine2d
andPolygon2d
).