You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using maptile to compute tile bounds, if you try and compute a latitude for a tile that involves the equator, you'll end up with an inaccurate float as a result - instead of 0, you get -0.00000000000000038584785111248965 aka -3.8584785111248965e-16. Calculations that depends on this value then become inaccurate (e.g. 0 > -0.00000000000000038584785111248965 gives true) as do equality comparisons and so on.
Calculations involving the longitude don't appear affected and represent 0 accurately, and the resulting floating point for 0 always appears consistently at least. See below:
When using
maptile
to compute tile bounds, if you try and compute a latitude for a tile that involves the equator, you'll end up with an inaccurate float as a result - instead of0
, you get-0.00000000000000038584785111248965
aka-3.8584785111248965e-16
. Calculations that depends on this value then become inaccurate (e.g.0 > -0.00000000000000038584785111248965
givestrue
) as do equality comparisons and so on.Calculations involving the longitude don't appear affected and represent
0
accurately, and the resulting floating point for0
always appears consistently at least. See below:Tested with
orb
v0.11.1
and Go 1.23.3.The text was updated successfully, but these errors were encountered: