Package jline.opt.variables
Class ServerAllocation
java.lang.Object
jline.opt.variables.DecisionVariable
jline.opt.variables.ServerAllocation
Optimize the number of servers at a station. Encodes an integer server count
in [minServers, maxServers] via a rounded linear map. Mirrors native-Python
ServerAllocation.-
Field Summary
Fields inherited from class jline.opt.variables.DecisionVariable
dimension, name -
Constructor Summary
ConstructorsConstructorDescriptionServerAllocation(Station station, int minServers, int maxServers) ServerAllocation(Station station, int minServers, int maxServers, String name) -
Method Summary
Modifier and TypeMethodDescriptionvoidApply a decoded value to a (copied) model.decode(double[] x) Decode the encoded slice (lengthDecisionVariable.getDimension()) to a value.double[][]Bounds per encoded dimension, each {low, high}.intintType identifier used by decomposition and the gradient dispatcher.Methods inherited from class jline.opt.variables.DecisionVariable
connectionMatrix, getDimension, getName, indexOfNode, resolveClass, resolveNode, unitBounds
-
Constructor Details
-
ServerAllocation
-
ServerAllocation
-
-
Method Details
-
getStation
-
getMinServers
public int getMinServers() -
getMaxServers
public int getMaxServers() -
getBounds
public double[][] getBounds()Description copied from class:DecisionVariableBounds per encoded dimension, each {low, high}. Standard is {0,1}.- Specified by:
getBoundsin classDecisionVariable
-
decode
Description copied from class:DecisionVariableDecode the encoded slice (lengthDecisionVariable.getDimension()) to a value.- Specified by:
decodein classDecisionVariable
-
apply
Description copied from class:DecisionVariableApply a decoded value to a (copied) model.- Specified by:
applyin classDecisionVariable
-
getVariableType
Description copied from class:DecisionVariableType identifier used by decomposition and the gradient dispatcher.- Specified by:
getVariableTypein classDecisionVariable
-