Class ConstValueDistribution<T>
Represents a probability distribution that contains only 1 value with 100% probability. Hence
this distribution always returns a single constant value - no uncertainty.
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 ConstValueDistribution<T> : Distribution<T>
Type Parameters
Name | Description |
---|---|
T | The type of the constant. |
Constructors
| Improve this Doc View SourceConstValueDistribution()
Initializes a new instance of the ConstValueDistribution<T> class.
Declaration
public ConstValueDistribution()
ConstValueDistribution(T)
Initializes a new instance of the ConstValueDistribution<T> class.
Declaration
public ConstValueDistribution(T value)
Parameters
Type | Name | Description |
---|---|---|
T | value | The single constant value. |
Properties
| Improve this Doc View SourceValue
Gets or sets the single constant value.
Declaration
public T Value { get; set; }
Property Value
Type | Description |
---|---|
T | The single constant value. The default is 0. |
Methods
| Improve this Doc View SourceNext(FastRandom)
Represents a probability distribution that contains only 1 value with 100% probability. Hence
this distribution always returns a single constant value - no uncertainty.
Declaration
public override T Next(FastRandom random)
Parameters
Type | Name | Description |
---|---|---|
Mars.Common.Core.Random.FastRandom | random |
Returns
Type | Description |
---|---|
T |
Overrides
Mars.Numerics.Statistics.Distribution<T>.Next(Mars.Common.Core.Random.FastRandom)