Package org.apache.commons.math.random

Examples of org.apache.commons.math.random.RandomDataImpl


import dclong.util.Timer;

public class TestSPTsRep {
  public static void main(String[] args) throws IOException{
    RandomGenerator rg = new Well44497b(31);
    RandomDataImpl rng = new RandomDataImpl(rg);
    int sizeOfEachDataSet = 26;
    int sizeOfFirstGroup = 5;
    int numberOfTests = 12625;
    Combination comb = new Combination(sizeOfEachDataSet,sizeOfFirstGroup);
    int[][] cs = comb.getCombinations(comb.getTotal().intValue());
View Full Code Here


import dclong.util.Timer;

public class TestSPTsImpl {
  public static void main(String[] args) throws IOException{
    RandomGenerator rg = new Well44497b(31);
    RandomDataImpl rng = new RandomDataImpl(rg);
//    int sizeOfEachDataSet = 16;
    int sizeOfEachDataSet = 26;
//    int sizeOfFirstGroup = 8;
    int sizeOfFirstGroup = 5;
//    int numberOfTests = 10000;
View Full Code Here

import dclong.util.Timer;

public class TestSPTsRunnable {
  public static void main(String[] args) throws IOException{
    RandomGenerator rg = new Well44497b(31);
    RandomDataImpl rng = new RandomDataImpl(rg);
//    int numberOfTests = 12625;
    int numberOfTests = 10000;
//    int sizeOfEachDataSet = 26;
    int sizeOfEachDataSet = 16;
//    int sizeOfFirstGroup = 5;
View Full Code Here

import dclong.util.Timer;

public class TestSPTsSimulation {
  public static void main(String[] args) throws IOException {
    RandomGenerator rg = new Well44497b(31);
    RandomDataImpl rng = new RandomDataImpl(rg);
    // warm up RNG to avoid overlap of the Table-2 job
    Timer timer = new Timer();
    int upperBound = Combination.choose(26, 5).intValue() - 1;
    for (int i = 0; i < 130000000; ++i) {
      for(int j=0; j<100; ++j){
        rng.nextInt(0, upperBound);
      }
    }
    timer.stop();
    System.out.println("Warm-up is done. The time used is " + timer.getElapsedTime()/60000d + " minutes.");
    // -------------------------------------------------------------
View Full Code Here

TOP

Related Classes of org.apache.commons.math.random.RandomDataImpl

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.