@Test public void testDouble() { final LinearCongruentialRandom rnd = new LinearCongruentialRandom(1); for (final double aDOUBLE_TEST : DOUBLE_TEST) { final double g = rnd.nextDouble(); assertEquals(g, aDOUBLE_TEST, AIFH.DEFAULT_PRECISION); } }
@Override public final double nextDouble() { return (double) nextLong() / LinearCongruentialRandom.MAX_RAND; }
LinearCongruentialRandom extends AbstractBoxMuller { @Override public final double nextDouble() { return (double) nextLong() / LinearCongruentialRandom.MAX_RAND; } }
LinearCongruentialRandom extends AbstractBoxMuller { @Override public final double nextDouble() { return (double) nextLong() / LinearCongruentialRandom.MAX_RAND; } LinearCongruentialRandom(final long theSeed);  LinearCongruentialRandom();  LinearCongruentialRandom(final long theModulus,
                                    final long theMultiplier, final long theIncrement,
                                    final long theSeed); }
LinearCongruentialRandom extends AbstractBoxMuller { @Override public final double nextDouble() { return (double) nextLong() / LinearCongruentialRandom.MAX_RAND; } LinearCongruentialRandom(final long theSeed);  LinearCongruentialRandom();  LinearCongruentialRandom(final long theModulus,
                                    final long theMultiplier, final long theIncrement,
                                    final long theSeed); final long getIncrement(); final long getModulus(); final long getMultiplier(); final long getSeed(); @Override final double nextDouble(); @Override final long nextLong(); @Override boolean nextBoolean(); @Override float nextFloat(); @Override int nextInt(); }
LinearCongruentialRandom extends AbstractBoxMuller { @Override public final double nextDouble() { return (double) nextLong() / LinearCongruentialRandom.MAX_RAND; } LinearCongruentialRandom(final long theSeed);  LinearCongruentialRandom();  LinearCongruentialRandom(final long theModulus,
                                    final long theMultiplier, final long theIncrement,
                                    final long theSeed); final long getIncrement(); final long getModulus(); final long getMultiplier(); final long getSeed(); @Override final double nextDouble(); @Override final long nextLong(); @Override boolean nextBoolean(); @Override float nextFloat(); @Override int nextInt(); static final long DEFAULT_MOD1; static final long DEFAULT_MOD2; static final long DEFAULT_MULT; static final long DEFAULT_INC; static final long MAX_RAND; }