|
static double | NextDouble () |
| Returns a random double in the range [0.0 1.0) More...
|
|
static float | NextFloat () |
| Returns a random float in the range [0f 1f]. NOTE: 1 is inclusive, because of casting the double to a float rounding More...
|
|
static int | Next () |
| Returns a random integer More...
|
|
static int | Next (int min, int max) |
| Returns a random integer in the range [min max) More...
|
|
static double | RayleighDistribution (double input) |
| Translates an evenly distributed random number in the range [0,1) into a Rayleigh-Distributed one. Technically in the range [0, 8.49151] due to the largest double less than one. About half the range of inputs results in a value less than 1, and 85% are less than 2. More...
|
|
static float | RayleighDistribution (float input) |
| Translates an evenly distributed random number in the range [0,1) into a Rayleigh-Distributed one. Technically in the range [0, 8.49151] due to the largest double less than one. About half the range of inputs results in a value less than 1, and 85% are less than 2. More...
|
|
static double | NormalDistribution (double sigma, double mean, double input1, double input2) |
| Returns a normally distributed value with specified mean and deviation More...
|
|
static double | NormalDistribution (double input1, double input2) |
| Returns a normally distributed value with mean 0 and sigma 1 https://en.wikipedia.org/wiki/Normal_distribution#Generating_values_from_normal_distribution More...
|
|
static float | NextFloat (this Random random) |
| Retrieve the next double and cast it to a float. More...
|
|
Definition at line 7 of file CustomRandom.cs.
◆ Next() [1/2]
static int BGC.Mathematics.CustomRandom.Next |
( |
| ) |
|
|
inlinestatic |
◆ Next() [2/2]
static int BGC.Mathematics.CustomRandom.Next |
( |
int |
min, |
|
|
int |
max |
|
) |
| |
|
inlinestatic |
Returns a random integer in the range [min max)
Definition at line 65 of file CustomRandom.cs.
static object randLock
Lock used to protect multi-thread access to random
◆ NextDouble()
static double BGC.Mathematics.CustomRandom.NextDouble |
( |
| ) |
|
|
inlinestatic |
Returns a random double in the range [0.0 1.0)
Definition at line 31 of file CustomRandom.cs.
static object randLock
Lock used to protect multi-thread access to random
◆ NextFloat() [1/2]
static float BGC.Mathematics.CustomRandom.NextFloat |
( |
| ) |
|
|
inlinestatic |
Returns a random float in the range [0f 1f]. NOTE: 1 is inclusive, because of casting the double to a float rounding
Definition at line 43 of file CustomRandom.cs.
static object randLock
Lock used to protect multi-thread access to random
◆ NextFloat() [2/2]
static float BGC.Mathematics.CustomRandom.NextFloat |
( |
this Random |
random | ) |
|
|
static |
Retrieve the next double and cast it to a float.
- Parameters
-
- Returns
◆ NormalDistribution() [1/2]
static double BGC.Mathematics.CustomRandom.NormalDistribution |
( |
double |
sigma, |
|
|
double |
mean, |
|
|
double |
input1, |
|
|
double |
input2 |
|
) |
| |
|
static |
Returns a normally distributed value with specified mean and deviation
◆ NormalDistribution() [2/2]
static double BGC.Mathematics.CustomRandom.NormalDistribution |
( |
double |
input1, |
|
|
double |
input2 |
|
) |
| |
|
static |
◆ RayleighDistribution() [1/2]
static double BGC.Mathematics.CustomRandom.RayleighDistribution |
( |
double |
input | ) |
|
|
static |
◆ RayleighDistribution() [2/2]
static float BGC.Mathematics.CustomRandom.RayleighDistribution |
( |
float |
input | ) |
|
|
static |
Translates an evenly distributed random number in the range [0,1) into a Rayleigh-Distributed one. Technically in the range [0, 8.49151] due to the largest double less than one. About half the range of inputs results in a value less than 1, and 85% are less than 2.
- Parameters
-
input | Random input value. Should be in range [0 1] |
◆ _globalRand
Random BGC.Mathematics.CustomRandom._globalRand |
|
staticprivate |
◆ randLock
object BGC.Mathematics.CustomRandom.randLock = new object() |
|
staticprivate |
Lock used to protect multi-thread access to random
Definition at line 12 of file CustomRandom.cs.
◆ GlobalRand
Random BGC.Mathematics.CustomRandom.GlobalRand |
|
staticgetprivate |
The documentation for this class was generated from the following file: