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

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

                Author: ASF GitHub Bot
            Created on: 07/Jun/21 10:44
            Start Date: 07/Jun/21 10:44
    Worklog Time Spent: 10m 
      Work Description: darkma773r commented on a change in pull request #92:
URL: https://github.com/apache/commons-numbers/pull/92#discussion_r646473629



##########
File path: 
commons-numbers-arrays/src/test/java/org/apache/commons/numbers/arrays/ExtendedPrecisionTest.java
##########
@@ -102,6 +102,23 @@ void testSubNormalSplit() {
         final double lo2 = a - hi2;
         Assertions.assertEquals(a, hi2);
         Assertions.assertEquals(0, lo2);
+
+
         Assertions.assertTrue(Math.abs(hi2) > Math.abs(lo2));
     }
+
+    @Test
+    void testSquareLowUnscaled() {
+        assertSquareLowUnscaled(0.0, 1.0);
+        assertSquareLowUnscaled(0.0, -1.0);
+        assertSquareLowUnscaled(-1.4293872661474477E-16, Math.PI);

Review comment:
       I found why `BigDecimal` wasn't working for me: I was using 
`BigDecimal.valueOf()` to create instances instead of `new BigDecimal()`. 
Switching to the constructor to use the exact double representation fixed the 
issue. I'm switching to the `fma` version, however since that is simpler.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to 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: 607774)
    Time Spent: 4.5h  (was: 4h 20m)

> SafeNorm 3D overload
> --------------------
>
>                 Key: NUMBERS-156
>                 URL: https://issues.apache.org/jira/browse/NUMBERS-156
>             Project: Commons Numbers
>          Issue Type: Improvement
>            Reporter: Matt Juntunen
>            Priority: Major
>         Attachments: performance-all.png, performance-len-1-5.png, 
> performance2-1-5.png, performance2-all.png, performance3-1-5.png, 
> performance3-all.png, performance4-1-5.png, performance4-all.png, 
> performance5-1-5.png, performance5-all.png
>
>          Time Spent: 4.5h
>  Remaining Estimate: 0h
>
> We should create an overload of {{SafeNorm.value}} that accepts 3 arguments 
> to potentially improve performance for 3D vectors.



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

Reply via email to