Table of Contents

Struct NumericRange

Namespace
Lime
Assembly
Lime.dll

Representation of numeric range of numbers around median.

public struct NumericRange : IEquatable<NumericRange>
Implements
Inherited Members

Constructors

NumericRange(float, float)

public NumericRange(float median, float dispersion)

Parameters

median float
dispersion float

Fields

Dispersion

[YuzuMember]
public float Dispersion

Field Value

float

Median

[YuzuMember]
public float Median

Field Value

float

Properties

this[int]

Gets or sets the component by its index.

public float this[int component] { get; set; }

Parameters

component int

Property Value

float

Methods

Equals(NumericRange)

Indicates whether the current object is equal to another object of the same type.

public bool Equals(NumericRange rhs)

Parameters

rhs NumericRange

Returns

bool

true if the current object is equal to the other parameter; otherwise, false.

GetHashCode()

Returns the hash code for this instance.

public override int GetHashCode()

Returns

int

A 32-bit signed integer that is the hash code for this instance.

NormalRandomNumber()

Returns random number from a normal distribution with given median and variance (dispersion)

public float NormalRandomNumber()

Returns

float

NormalRandomNumber(IRandom)

public float NormalRandomNumber(IRandom rng)

Parameters

rng IRandom

Returns

float

NormalRandomNumber(Random)

public float NormalRandomNumber(Random rng)

Parameters

rng Random

Returns

float

ToString()

Returns the fully qualified type name of this instance.

public override string ToString()

Returns

string

The fully qualified type name.

UniformRandomNumber()

Returns random number from uniform distribution with given median and range (note that Dispersion here is not the actual variance of a distribution but half of the range).

public float UniformRandomNumber()

Returns

float

UniformRandomNumber(IRandom)

public float UniformRandomNumber(IRandom rng)

Parameters

rng IRandom

Returns

float

UniformRandomNumber(Random)

public float UniformRandomNumber(Random rng)

Parameters

rng Random

Returns

float

Operators

operator ==(NumericRange, NumericRange)

public static bool operator ==(NumericRange lhs, NumericRange rhs)

Parameters

lhs NumericRange
rhs NumericRange

Returns

bool

operator !=(NumericRange, NumericRange)

public static bool operator !=(NumericRange lhs, NumericRange rhs)

Parameters

lhs NumericRange
rhs NumericRange

Returns

bool