Class UniformDistributionD
Represents a uniform distribution that returns random values for a given interval
[MinValue, MaxValue] (double-precision).
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Mars.Numerics.Statistics
Assembly: Mars.Numerics.dll
Syntax
public class UniformDistributionD : Distribution<double>
Remarks
Every time Next(FastRandom) is called, a new random value from the interval
[MinValue, MaxValue] is returned. All values in this interval have
the same chance to be chosen.
Constructors
| Improve this Doc View SourceUniformDistributionD()
Initializes a new instance of the UniformDistributionD class.
Declaration
public UniformDistributionD()
Remarks
Every time Next(FastRandom) is called, a new random value from the interval
[MinValue, MaxValue] is returned. All values in this interval have
the same chance to be chosen.
|
Improve this Doc
View Source
UniformDistributionD(Double, Double)
Initializes a new instance of the UniformDistributionD class.
Declaration
public UniformDistributionD(double minValue, double maxValue)
Parameters
Type | Name | Description |
---|---|---|
System.Double | minValue | The minimum value. |
System.Double | maxValue | The maximum value. |
Remarks
Every time Next(FastRandom) is called, a new random value from the interval
[MinValue, MaxValue] is returned. All values in this interval have
the same chance to be chosen.
Properties
| Improve this Doc View SourceMaxValue
Gets or sets the maximum value.
Declaration
public double MaxValue { get; set; }
Property Value
Type | Description |
---|---|
System.Double | The maximum value. The default is 1. |
Remarks
Every time Next(FastRandom) is called, a new random value from the interval
[MinValue, MaxValue] is returned. All values in this interval have
the same chance to be chosen.
|
Improve this Doc
View Source
MinValue
Gets or sets the minimum value.
Declaration
public double MinValue { get; set; }
Property Value
Type | Description |
---|---|
System.Double | The minimum value. The default is -1. |
Remarks
Every time Next(FastRandom) is called, a new random value from the interval
[MinValue, MaxValue] is returned. All values in this interval have
the same chance to be chosen.
Methods
| Improve this Doc View SourceNext(FastRandom)
Represents a uniform distribution that returns random values for a given interval
[MinValue, MaxValue] (double-precision).
Declaration
public override double Next(FastRandom random)
Parameters
Type | Name | Description |
---|---|---|
Mars.Common.Core.Random.FastRandom | random |
Returns
Type | Description |
---|---|
System.Double |
Overrides
Mars.Numerics.Statistics.Distribution<System.Double>.Next(Mars.Common.Core.Random.FastRandom)
Remarks
Every time Next(FastRandom) is called, a new random value from the interval
[MinValue, MaxValue] is returned. All values in this interval have
the same chance to be chosen.