SSJ API Documentation
Stochastic Simulation in Java
Loading...
Searching...
No Matches
BetaSymmetricalGen.java
1/*
2 * Class: BetaSymmetricalGen
3 * Description: random variate generators for the symmetrical beta distribution
4 * Environment: Java
5 * Software: SSJ
6 * Copyright (C) 2001 Pierre L'Ecuyer and Universite de Montreal
7 * Organization: DIRO, Universite de Montreal
8 * @author Richard Simard
9 * @since
10 *
11 *
12 * Licensed under the Apache License, Version 2.0 (the "License");
13 * you may not use this file except in compliance with the License.
14 * You may obtain a copy of the License at
15 *
16 * http://www.apache.org/licenses/LICENSE-2.0
17 *
18 * Unless required by applicable law or agreed to in writing, software
19 * distributed under the License is distributed on an "AS IS" BASIS,
20 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
21 * See the License for the specific language governing permissions and
22 * limitations under the License.
23 *
24 */
25package umontreal.ssj.randvar;
26
27import umontreal.ssj.rng.*;
28import umontreal.ssj.probdist.*;
29
39public class BetaSymmetricalGen extends BetaGen {
40
46 public BetaSymmetricalGen(RandomStream s, double alpha) {
47 this(s, new BetaSymmetricalDist(alpha));
48 }
49
54 super(s, dist);
55 }
56
57 public static double nextDouble(RandomStream s, double alpha) {
58 return BetaSymmetricalDist.inverseF(alpha, s.nextDouble());
59 }
60
61}
Specializes the class BetaDist to the case of a symmetrical beta distribution over the interval ,...
double inverseF(double u)
Returns the inverse distribution function .
BetaGen(RandomStream s, double alpha, double beta, double a, double b)
Creates a new beta generator with parameters alpha and beta, over the interval.
Definition BetaGen.java:64
BetaSymmetricalGen(RandomStream s, BetaSymmetricalDist dist)
Creates a new generator for the distribution dist, using stream s.
BetaSymmetricalGen(RandomStream s, double alpha)
Creates a new symmetrical beta generator with parameters.
double nextDouble()
Generates a random number from the continuous distribution contained in this object.
This interface defines the basic structures to handle multiple streams of uniform (pseudo)random numb...
double nextDouble()
Returns a (pseudo)random number from the uniform distribution over the interval , using this stream,...