choco.palm.real.exp
Class AbstractPalmRealBinTerm
java.lang.Object
choco.AbstractEntity
choco.real.exp.AbstractRealCompoundTerm
choco.real.exp.AbstractRealBinTerm
choco.palm.real.exp.AbstractPalmRealBinTerm
- All Implemented Interfaces:
- Entity, PalmRealInterval, RealExp, RealInterval
- Direct Known Subclasses:
- PalmRealMinus, PalmRealMult, PalmRealPlus
public abstract class AbstractPalmRealBinTerm
- extends AbstractRealBinTerm
- implements PalmRealInterval
Abstract implementation of a real binary term (like addition for instance).
Method Summary |
void |
intersect(RealInterval interval,
int index)
Updates the interval such that this interval is
included in the interval parameter. |
void |
self_explain(int select,
Explanation e)
Explains the state of this expression (lower/upper bounds or all domain). |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
explanationOnInf
protected Explanation explanationOnInf
- Explanation of the last lower bound affectation.
explanationOnSup
protected Explanation explanationOnSup
- Explanation of the last upper bound affectation.
AbstractPalmRealBinTerm
public AbstractPalmRealBinTerm(AbstractProblem pb,
RealExp exp1,
RealExp exp2)
- Creates an abstract binary term with the two sub-expressions.
- Parameters:
pb
- the problem of this constraintexp1
- the first expression operandexp2
- the second expression operand
intersect
public void intersect(RealInterval interval,
int index)
throws ContradictionException
- Updates the interval such that this interval is
included in the interval parameter.
- Specified by:
intersect
in interface RealInterval
- Overrides:
intersect
in class AbstractRealCompoundTerm
- Parameters:
interval
- The interval this expression should be included inindex
- The index of the constraint responsible of this reduction
- Throws:
ContradictionException
- if a domain becomes empty or if a
contradiction can be infered
self_explain
public void self_explain(int select,
Explanation e)
- Explains the state of this expression (lower/upper bounds or all domain).
- Specified by:
self_explain
in interface PalmRealInterval
- Parameters:
select
- Specifies which part of the domain should be explained.e
- Specifies the explanation in which these explaining
constraints should be added.