You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Baljit Singh (Jira)" <ji...@apache.org> on 2020/01/03 15:43:00 UTC

[jira] [Commented] (MATH-1507) Barycenter of a clockwise SphericalPolygonsSet is incorrect.

    [ https://issues.apache.org/jira/browse/MATH-1507?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17007576#comment-17007576 ] 

Baljit Singh commented on MATH-1507:
------------------------------------

When is the expected release of commons-geometry? I can't upgrade until that library is released.

> Barycenter of a clockwise SphericalPolygonsSet is incorrect.
> ------------------------------------------------------------
>
>                 Key: MATH-1507
>                 URL: https://issues.apache.org/jira/browse/MATH-1507
>             Project: Commons Math
>          Issue Type: Bug
>    Affects Versions: 3.6.1
>            Reporter: Baljit Singh
>            Priority: Major
>
> Let's say there is a circle on a spherical surface.
>  * The circle center is given by S2Point(theta=-0.6981, phi=0.87266). The radius is irrelevant.
>  * Let's discretize this circle into a polygon with 100 edges. Let's make the orientation {color:#ff0000}clockwise{color}.
>  * Since its a clockwise circle, from symmetry, we know that the barycenter would be around S2Point(theta=2.44346, phi=2.268928), which is just the reverse of the normal vector at the circle center.
>  * Using SphericalPolygonsSet, the calculated barycenter is S2Point(theta=2.4922, phi=0.69889).
>  
> A few things I've already tested:
>  * For counterclockwise, the result is correct.
>  * The perimeter and surface area of the polygon is correct for both counterclockwise and clockwise.
>  * The SphericalPolygonsSet barycenter seems to be a function of the circle radius. From symmetry, we know that there should be no dependence on the circle radius.
>  * The theta is kind of close. However, the phi is off about pi/2.
>  
>  
>  
>  



--
This message was sent by Atlassian Jira
(v8.3.4#803005)