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 2013/08/10 01:39:25 UTC

svn commit: r1512535 - /commons/proper/math/trunk/src/main/java/org/apache/commons/math3/util/MathArrays.java

Author: erans
Date: Fri Aug  9 23:39:24 2013
New Revision: 1512535

URL: http://svn.apache.org/r1512535
Log:
MATH-1010
Make use of the RNG supplied as argument.

Modified:
    commons/proper/math/trunk/src/main/java/org/apache/commons/math3/util/MathArrays.java

Modified: commons/proper/math/trunk/src/main/java/org/apache/commons/math3/util/MathArrays.java
URL: http://svn.apache.org/viewvc/commons/proper/math/trunk/src/main/java/org/apache/commons/math3/util/MathArrays.java?rev=1512535&r1=1512534&r2=1512535&view=diff
==============================================================================
--- commons/proper/math/trunk/src/main/java/org/apache/commons/math3/util/MathArrays.java (original)
+++ commons/proper/math/trunk/src/main/java/org/apache/commons/math3/util/MathArrays.java Fri Aug  9 23:39:24 2013
@@ -1478,7 +1478,7 @@ public class MathArrays {
                     target = start;
                 } else {
                     // NumberIsTooLargeException cannot occur.
-                    target = new UniformIntegerDistribution(start, i).sample();
+                    target = new UniformIntegerDistribution(rng, start, i).sample();
                 }
                 final int temp = list[target];
                 list[target] = list[i];
@@ -1493,7 +1493,7 @@ public class MathArrays {
                     target = start;
                 } else {
                     // NumberIsTooLargeException cannot occur.
-                    target = new UniformIntegerDistribution(i, start).sample();
+                    target = new UniformIntegerDistribution(rng, i, start).sample();
                 }
                 final int temp = list[target];
                 list[target] = list[i];