|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectchoco.AbstractEntity
choco.AbstractVar
choco.real.var.RealVarImpl
choco.palm.real.PalmRealVarImpl
public class PalmRealVarImpl
Default implementation of PaLM real variables.
Field Summary |
---|
Fields inherited from class choco.real.var.RealVarImpl |
---|
domain |
Fields inherited from class choco.AbstractVar |
---|
constraints, event, indices, name |
Fields inherited from class choco.AbstractEntity |
---|
hook, problem |
Fields inherited from interface choco.palm.real.PalmRealInterval |
---|
DOM, INF, SUP |
Constructor Summary | |
---|---|
PalmRealVarImpl(AbstractProblem pb,
java.lang.String name,
double a,
double b)
Creates a variable with the specified bounds and the specified name. |
Method Summary | |
---|---|
int |
addConstraint(Constraint c,
int varIdx)
Adds a new constraints, and makes it active if needed. |
Constraint |
getDecisionConstraint(int val)
Returns the decision constraint for the ith branch on the current domain. |
void |
resetExplanationOnInf()
Updates lower bound explanations: it removes not up-to-date explanations. |
void |
resetExplanationOnSup()
Updates upper bound explanations: it removes not up-to-date explanations. |
void |
restoreInf(double newValue)
Lower bound of the domain should be restored to the specified value. |
void |
restoreSup(double newValue)
Upper bound of the domain should be restored to the specified value. |
void |
self_explain(int select,
Explanation e)
Merge explanation of the specified part of the domain to a constraint collection. |
java.lang.String |
toString()
The name of the variable. |
void |
updateDecisionConstraints()
Updates decision constraints on this variable: it removes all erased constraints. |
Methods inherited from class choco.real.var.RealVarImpl |
---|
collectVars, fail, getDomain, getInf, getSup, getValue, intersect, intersect, isInstantiated, isolate, project, silentlyAssign, subExps, tighten |
Methods inherited from class choco.AbstractVar |
---|
addConstraint, eraseConstraint, getConstraint, getConstraintsIterator, getConstraintVector, getEvent, getIndexVector, getNbConstraints, getVarIndex |
Methods inherited from class choco.AbstractEntity |
---|
getProblem, pretty |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface choco.real.RealVar |
---|
getDomain, getValue, silentlyAssign |
Methods inherited from interface choco.real.RealExp |
---|
collectVars, isolate, project, subExps, tighten |
Methods inherited from interface choco.real.RealInterval |
---|
getInf, getSup, intersect, intersect |
Constructor Detail |
---|
public PalmRealVarImpl(AbstractProblem pb, java.lang.String name, double a, double b)
Method Detail |
---|
public java.lang.String toString()
toString
in class RealVarImpl
public void resetExplanationOnInf()
resetExplanationOnInf
in interface PalmRealVar
public void resetExplanationOnSup()
resetExplanationOnSup
in interface PalmRealVar
public void updateDecisionConstraints()
updateDecisionConstraints
in interface PalmRealVar
public void restoreInf(double newValue)
restoreInf
in interface PalmRealVar
public void restoreSup(double newValue)
restoreSup
in interface PalmRealVar
public void self_explain(int select, Explanation e)
self_explain
in interface ExplainedVar
self_explain
in interface PalmRealInterval
public Constraint getDecisionConstraint(int val)
PalmVar
getDecisionConstraint
in interface PalmVar
public int addConstraint(Constraint c, int varIdx)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |