ParD3 Class

A 3-dimensional (array) parameter symbol, having three indices.

Parameters represents constants for the mathematical model, values of which can lazily be evaluated.

Definition

Namespace: Orx.MathProg
Assembly: Orx.MathProg (in Orx.MathProg.dll) Version: 1.0.0
C#
public class ParD3
Inheritance
Object    ParD3

Properties

Definition Definition of the variable.
Dimension Dimension of the parameter symbol.
Item Returns the parameter's value at the (i,j,k)-th position. Note that the indices can be any scalar (constant for the mathematical model) expression.

Consider for instance

C#
double GetOrderAmount(int timePeriod, int origin, int destination) => ...;
Set t = ...; // time periods
Set o = ...; // origins
Set d = o.Alias("d"); // destinations
ParD3 order = Parameter("order").Represents("order from origin o to destination d at time period t")
    .HasIndices(t, o, d).HasValues(new FunVec3<double>(GetOrderAmount));
Then:
  • order[2, 0, 1] is the order amount from origin 0 to destination 1 at time period 2,
  • order[t, o, d] is the order amount from origin o to destination d at time period t,
  • order[t - 1, 0, d] is the order amount from origin 0 to destination d at time period t - 1.
Key Key of the variable.
ValuesDefinition Definition of source of values of the parameter.

Methods

Equals
(Inherited from Object)
Finalize
(Inherited from Object)
GetHashCode
(Inherited from Object)
GetIndices Returns an immutable collection of the parameter indices.
GetType
(Inherited from Object)
MemberwiseClone
(Inherited from Object)
ToString
(Inherited from Object)

See Also