You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by er...@apache.org on 2018/02/02 13:29:32 UTC

[37/50] commons-numbers git commit: Unnecessary instantiation.

Unnecessary instantiation.


Project: http://git-wip-us.apache.org/repos/asf/commons-numbers/repo
Commit: http://git-wip-us.apache.org/repos/asf/commons-numbers/commit/49ed2b81
Tree: http://git-wip-us.apache.org/repos/asf/commons-numbers/tree/49ed2b81
Diff: http://git-wip-us.apache.org/repos/asf/commons-numbers/diff/49ed2b81

Branch: refs/heads/feature__NUMBERS-51__field
Commit: 49ed2b81e8a086fd0a801ba2fa54a4f16827512f
Parents: 5dbfebe
Author: Gilles Sadowski <gi...@harfang.homelinux.org>
Authored: Thu Feb 1 13:09:33 2018 +0100
Committer: Gilles Sadowski <gi...@harfang.homelinux.org>
Committed: Thu Feb 1 13:09:33 2018 +0100

----------------------------------------------------------------------
 .../src/main/java/org/apache/commons/numbers/complex/Complex.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/commons-numbers/blob/49ed2b81/commons-numbers-complex/src/main/java/org/apache/commons/numbers/complex/Complex.java
----------------------------------------------------------------------
diff --git a/commons-numbers-complex/src/main/java/org/apache/commons/numbers/complex/Complex.java b/commons-numbers-complex/src/main/java/org/apache/commons/numbers/complex/Complex.java
index a56c641..d474c31 100644
--- a/commons-numbers-complex/src/main/java/org/apache/commons/numbers/complex/Complex.java
+++ b/commons-numbers-complex/src/main/java/org/apache/commons/numbers/complex/Complex.java
@@ -706,7 +706,7 @@ public class Complex implements Serializable  {
      */
     public Complex atan() {
         return this.add(I).divide(I.subtract(this)).log()
-            .multiply(I.divide(createComplex(2, 0)));
+            .multiply(I.multiply(0.5));
     }
 
     /**