Generated by DocFX

Class Interval

A simple parametric data representing an "interval" between two numbers.

Inheritance
System.Object
Interval
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()
Syntax
public class Interval

Constructors

| Improve this Doc View Source

Interval(Double, Double)

Creates an instance of an interval given a minimum and a maximum value.

Declaration
public Interval(double t0, double t1)
Parameters
Type Name Description
System.Double t0
System.Double t1

Properties

| Improve this Doc View Source

IsDecreasing

True if t0 is less than t1.

Declaration
public bool IsDecreasing { get; }
Property Value
Type Description
System.Boolean
| Improve this Doc View Source

IsIncreasing

True if t1 is greater than t0.

Declaration
public bool IsIncreasing { get; }
Property Value
Type Description
System.Boolean
| Improve this Doc View Source

IsSingleton

True if t0 == t1.

Declaration
public bool IsSingleton { get; }
Property Value
Type Description
System.Boolean
| Improve this Doc View Source

Length

Gets the length of the interval.
If the interval is decreasing, negative number will be returned.

Declaration
public double Length { get; }
Property Value
Type Description
System.Double
| Improve this Doc View Source

Max

Returns the largest value in the interval.

Declaration
public double Max { get; }
Property Value
Type Description
System.Double
| Improve this Doc View Source

Mid

Gets the value between the interval's min and max values.

Declaration
public double Mid { get; }
Property Value
Type Description
System.Double
| Improve this Doc View Source

Min

Returns the smallest value in the interval.

Declaration
public double Min { get; }
Property Value
Type Description
System.Double
| Improve this Doc View Source

T0

Gets the minimum value of the interval.

Declaration
public double T0 { get; }
Property Value
Type Description
System.Double
| Improve this Doc View Source

T1

Gets the maximum value of the interval.

Declaration
public double T1 { get; }
Property Value
Type Description
System.Double

Methods

| Improve this Doc View Source

Divide(Interval, Int32)

Computes a collection of evenly spaced numbers over a specified domain.

Declaration
public static IList<double> Divide(Interval domain, int step)
Parameters
Type Name Description
Interval domain

Numeric domain.

System.Int32 step

Number of steps.

Returns
Type Description
System.Collections.Generic.IList<System.Double>

A collection of equally spaced numbers.

| Improve this Doc View Source

ParameterAt(Double)

Converts normalized parameter to interval value, or pair of values.

Declaration
public double ParameterAt(double normalizedParameter)
Parameters
Type Name Description
System.Double normalizedParameter

The normalized parameter between 0 and 1.

Returns
Type Description
System.Double

Interval parameter t0*(1.0-normalizedParameter) + t1*normalizedParameter.