|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.opttek.optquest.COptQuestVariable
public abstract class COptQuestVariable
COptQuestVariable is a pure virtual class that defines a decision variable.
| Constructor Summary | |
|---|---|
COptQuestVariable()
Default constructor |
|
COptQuestVariable(double lowerBound,
double upperBound)
Constructor that sets the lower bound and upper bound. |
|
COptQuestVariable(java.lang.String name)
Constructor that assigns a name to the variable. |
|
COptQuestVariable(java.lang.String name,
double lowerBound,
double upperBound)
Constructor that assigns a name to the variable and sets the lower bound and upper bound. |
|
| Method Summary | |
|---|---|
double |
GetBestValue()
Deprecated. Use COptQuestOptimization::GetBestSolution().GetVariableValue() |
double |
GetCurrentValue()
Deprecated. Use COptQuestOptimization::GetCurrentSolution().GetVariableValue(). |
double |
GetCurrentValue(int pID)
Deprecated. Use COptQuestSolution.GetVariableValue(). |
double |
GetDOELowerBound()
|
double |
GetDOEUpperBound()
|
double |
GetExclusiveLowerBoundAt(int index)
Returns the lower bound of the exclusive range identified by the index |
double |
GetExclusiveUpperBoundAt(int index)
Returns the upper bound of the exclusive range identified by the index |
double |
GetLowerBound()
|
java.lang.String |
GetName()
|
double |
GetNthBestValue()
Deprecated. Use COptQuestOptimization::GetNthBestSolution().GetVariableValue() |
int |
GetNumberOfExclusiveRanges()
Returns the number of exclusive ranges defined for this variable. |
int |
GetNumberOfObservations()
Returns the number of elements in the observations array. |
int |
GetNumberOfPeriods()
Returns the number of periods for project. |
double |
GetObservationAt(int index)
Returns the value of the observation at the specified index. |
double[] |
GetObservations()
Returns the array of observations set in the SetObservations() method |
double |
GetPeriodObservationAt(int periodNum,
int index)
Returns the value of the observations for the specified period and index |
double[] |
GetPeriodObservations(int periodNum)
Returns the array of observations for the requested period. |
double |
GetQuality(int qualityNum)
For internal use |
double |
GetResource(int resourceNum,
int periodNum)
For internal use |
double |
GetStepSize()
|
double |
GetSuggestedValue()
|
java.lang.String |
GetType()
|
double |
GetUpperBound()
|
void |
SetCurrentValue(double Value)
Deprecated. Use COptQuestSolution.SetVariableValue() Method that sets the current value of the variable. The user can call this method to modifiy a solution suggested by the OptQuest Engine or to set the value of a COptQuestUserControlledVariable whose value is always set by the user. |
void |
SetCurrentValue(int pID,
double Value)
Deprecated. Use COptQuestSolution.SetVariableValue() Method that sets the current value of the variable when using parallel optimization. The user can call this method to modifiy a solution suggested by the OptQuest Engine or to set the value of a COptQuestUserControlledVariable whose value is always set by the user. |
void |
SetExclusiveRange(double low,
double high)
Defines a range of values that will be excluded as possible solutions. |
void |
SetLowerBound(double lowerBound)
Sets the lower bound of the decision variable |
void |
SetName(java.lang.String name)
Assigns a name to the variable. |
void |
SetNumberOfPeriods(int numPeriods)
Sets the number of periods in the project. |
void |
SetNumberOfQualityMeasures(int numQualityMeasures)
For internal use |
void |
SetNumberOfResources(int numResources)
For internal use |
void |
SetObservations(int numObservations,
double[] observations)
Sets the observations for the project. |
void |
SetPeriodObservations(int numObservations,
int periodNum,
double[] observations)
Sets the observations by period for a portfolio optimization. |
void |
SetQuality(int qualityNum,
double amount)
For internal use |
void |
SetResource(int resourceNum,
int periodNum,
double amount)
For internal use |
void |
SetStepSize(double value)
|
void |
SetSuggestedValue(double Value)
Deprecated. Use COptQuestOptimization::CreateSolution() to create an empty solution. Use the COptQuestSolution::SetVariableValue() method to set the variable's value for the solution. Call COptQuestOptimization::AddSuggestedSolution() to add the completed soluition to the optmization problem. |
void |
SetUpperBound(double upperBound)
Sets the upper bound of the decision variable |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public COptQuestVariable(java.lang.String name)
name - alphanumeric name. Note: the name can contain blanks or special
characters. If the variable name is used in a COptQuestStringConstraint
equation, the name should be enclosed in square brackets [] in the
COptQuestStringConstraint string equation.public COptQuestVariable()
public COptQuestVariable(java.lang.String name,
double lowerBound,
double upperBound)
name - alphanumeric name. Note: the name can contain blanks or special
characters. If the variable name is used in a COptQuestStringConstraint
equation, the name should be enclosed in square brackets [] in the
COptQuestStringConstraint string equation.lowerBound - a value between -pow(2,31) and +pow(2,31)-1upperBound - a value between -pow(2,31) and +pow(2,31)-1
public COptQuestVariable(double lowerBound,
double upperBound)
lowerBound - a value between -pow(2,31) and +pow(2,31)-1upperBound - a value between -pow(2,31) and +pow(2,31)-1| Method Detail |
|---|
public void SetCurrentValue(double Value)
throws COptQuestException
Value - - value of the variable
COptQuestException
public void SetCurrentValue(int pID,
double Value)
throws COptQuestException
pID - parallel ID from COptQuestOptimization::Evaluate()Value - - value of the variable
COptQuestException
public void SetLowerBound(double lowerBound)
throws COptQuestException
lowerBound - a value between -pow(2,31) and +pow(2,31)-1
COptQuestException
public void SetUpperBound(double upperBound)
throws COptQuestException
upperBound - a value between -pow(2,31) and +pow(2,31)-1
COptQuestException
public void SetExclusiveRange(double low,
double high)
throws COptQuestException
low - - any value > low will be excludedhigh - - any value < high will be exluded
COptQuestExceptionpublic void SetSuggestedValue(double Value)
public void SetName(java.lang.String name)
name - = name of the variable.
public double GetCurrentValue()
throws COptQuestException
COptQuestException
public double GetCurrentValue(int pID)
throws COptQuestException
COptQuestExceptionpublic double GetBestValue()
public double GetLowerBound()
public double GetUpperBound()
public double GetDOEUpperBound()
public double GetDOELowerBound()
public double GetSuggestedValue()
public java.lang.String GetName()
public java.lang.String GetType()
public double GetStepSize()
public int GetNumberOfExclusiveRanges()
public double GetExclusiveLowerBoundAt(int index)
index - 0 based index
public double GetExclusiveUpperBoundAt(int index)
index - 0 based index
public double GetNthBestValue()
public void SetObservations(int numObservations,
double[] observations)
numObservations - - number of entries in the observations arrayobservations - - array representing the observations for the project.public int GetNumberOfObservations()
public double[] GetObservations()
public double GetObservationAt(int index)
throws COptQuestException
index - - value between 0 and the number of observations -1
COptQuestException
public double GetPeriodObservationAt(int periodNum,
int index)
throws COptQuestException
periodNum - - value between 1 and the total number of periods.index - - value between 0 and the number of observations -1
COptQuestException
public void SetNumberOfPeriods(int numPeriods)
throws COptQuestException
numPeriods - - value > 0
COptQuestExceptionpublic int GetNumberOfPeriods()
public void SetPeriodObservations(int numObservations,
int periodNum,
double[] observations)
throws COptQuestException
numObservations - - number of elements in the observations arrayperiodNum - - identifies the period number. The value must be
between 1 and the value set by the SetNumberOfPeriods() method.observations - - array representing the observations for the project.
COptQuestException - if the number of observations for this period
differs from the setting for another period.
public double[] GetPeriodObservations(int periodNum)
throws COptQuestException
periodNum - - Number from 1 to number of periods set by SetNumberOfPeriods();
COptQuestExceptionpublic void SetNumberOfResources(int numResources)
public void SetResource(int resourceNum,
int periodNum,
double amount)
public double GetResource(int resourceNum,
int periodNum)
public void SetNumberOfQualityMeasures(int numQualityMeasures)
public void SetQuality(int qualityNum,
double amount)
public double GetQuality(int qualityNum)
public void SetStepSize(double value)
throws COptQuestException
COptQuestException
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||