Skip to content

precision issue with very small spoly #13

Description

@pdowler

I am trying to insert very small polygons. I can insert a polygon with micro-radians (1e-6) coordinate values:

select '{(0.0,-0.000001),(6.283184,0.0),(0.0,0.000001),(0.000001,0.0)}'::spoly;
                         spoly                         
-------------------------------------------------------
 {(0 , -1e-06),(6.283184 , 0),(0 , 1e-06),(1e-06 , 0)}

When I try nano-radians (1e-9) the parser seems to consider some points as equal:

select '{(0.0,-0.000000001),(6.283185306,0.0),(0.0,0.000000001),(0.000000001,0.0)}'::spoly;
ERROR:  spherepoly_from_array: more than two points needed

Are the parser/internals using single-precision/float instead of double?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions