Closed peterjamesnugent closed 6 months ago
With three equidistant points you can this line: https://github.com/BHoM/BHoM_Engine/blob/5b19bd49fcd5f09c2103c0ebf8074ce4ee0dd1ce/Geometry_Engine/Compute/FitLine.cs#L67
To produce NaN because you're dividing by 0, i.e. p2 = 0.
NaN
p2 = 0
See test script.
A line through the middle of all three points.
#3278-FitLineEdgeCase
Description:
With three equidistant points you can this line: https://github.com/BHoM/BHoM_Engine/blob/5b19bd49fcd5f09c2103c0ebf8074ce4ee0dd1ce/Geometry_Engine/Compute/FitLine.cs#L67
To produce
NaN
because you're dividing by 0, i.e.p2 = 0
.Steps to reproduce:
See test script.
Expected behaviour:
A line through the middle of all three points.
Test file(s):
#3278-FitLineEdgeCase