commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Baljit Singh (JIRA)" <j...@apache.org>
Subject [jira] [Created] (MATH-1480) Overflow in Vector norm and distance
Date Wed, 10 Apr 2019 21:50:00 GMT
Baljit Singh created MATH-1480:
----------------------------------

             Summary: Overflow in Vector norm and distance
                 Key: MATH-1480
                 URL: https://issues.apache.org/jira/browse/MATH-1480
             Project: Commons Math
          Issue Type: Bug
            Reporter: Baljit Singh


In Euclidean Vector classes (Vector2D, Vector3D), norm() and distance() rely on Math.sqrt(),
which can overflow if the components of the vectors are large. Instead, they should rely on
SafeNorm.



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

Mime
View raw message