[ 
https://issues.apache.org/jira/browse/NUMBERS-94?focusedWorklogId=198486&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-198486
 ]

ASF GitHub Bot logged work on NUMBERS-94:
-----------------------------------------

                Author: ASF GitHub Bot
            Created on: 14/Feb/19 05:25
            Start Date: 14/Feb/19 05:25
    Worklog Time Spent: 10m 
      Work Description: coveralls commented on issue #30: NUMBERS-94: 
PlaneAngle.normalize() fix for small numbers
URL: https://github.com/apache/commons-numbers/pull/30#issuecomment-463494611
 
 
   
   [![Coverage 
Status](https://coveralls.io/builds/21636143/badge)](https://coveralls.io/builds/21636143)
   
   Coverage increased (+0.01%) to 92.809% when pulling 
**00b2b5621ed39141d81b92b3fa3ba96a4e54c1c1 on darkma773r:numbers-94** into 
**463183281c06a2398a70a00651fbb5feab5b0413 on apache:master**.
   
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


Issue Time Tracking
-------------------

    Worklog Id:     (was: 198486)
    Time Spent: 20m  (was: 10m)

> PlaneAngle normalize fails for very small numbers.
> --------------------------------------------------
>
>                 Key: NUMBERS-94
>                 URL: https://issues.apache.org/jira/browse/NUMBERS-94
>             Project: Commons Numbers
>          Issue Type: Bug
>            Reporter: Matt Juntunen
>            Priority: Major
>          Time Spent: 20m
>  Remaining Estimate: 0h
>
> When the {{PlaneAngle.normalize()}} method is called to normalize between 0 
> and 1 turns and is passed a very small number compared to the 1, then the 
> method returns a number exactly equal to the angle upper bound. This breaks 
> the API contract since the return value must be strictly less than the upper 
> bound. Ex:
> {code:java}
> PlaneAngle angle = PlaneAngle.ofTurns(-1e-18);
> double normalized = angle.normalize(PlaneAngle.PI).toTurns();
> // normalized is equal to 1 but it should be 0 since 1 - 1e-18 = 1, which is 
> equivalent to 0 in turns
> {code}
> Pull request: https://github.com/apache/commons-numbers/pull/30



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to