Measuring the distance from [60.512651558965445, 6.67020027525723] to [60.512651558965445, 6.670200191438198] returns a NaN result.
The expression Math.sin(lat1) * Math.sin(lat2) + Math.cos(lat1) * Math.cos(lat2) * Math.cos(lon1 - lon2) gives a result of 1.0000000000000002 which is not defined for the arccosine function Math.acos to which this result is sent.
Measuring the distance from
[60.512651558965445, 6.67020027525723]to[60.512651558965445, 6.670200191438198]returns aNaNresult.The expression
Math.sin(lat1) * Math.sin(lat2) + Math.cos(lat1) * Math.cos(lat2) * Math.cos(lon1 - lon2)gives a result of 1.0000000000000002 which is not defined for the arccosine functionMath.acosto which this result is sent.