choco.kernel.solver
Interface Solver

All Superinterfaces:
IMeasures, IOptimizationMeasures, IPreSolveMeasures, IPretty, ISearchMeasures, ISolutionDisplay, ISolutionMeasures
All Known Implementing Classes:
AbstractLNSSolver, CPSolver, CPSolverDis, LNSCPSolver, PreProcessCPSolver

public interface Solver
extends ISolutionDisplay, IMeasures, IPretty

Created by IntelliJ IDEA. User: charles Date: 12 mars 2008 Time: 16:43:08 Interface for Solver class, declare main expected methods.


Field Summary
static SolutionCheckerEngine DEFAULT_SOLUTION_CHECKER
           
static Logger LOGGER
          Reference to an object for logging trace statements related to Abtract Solver (using the java.util.logging package)
 
Method Summary
<MV extends Variable,SV extends Var>
SV[]
_to(MV[] mv, SV[] sv)
           
<MV extends Variable,SV extends Var>
SV
_to(MV mv, SV sv)
           
 void addGoal(AbstractIntBranchingStrategy branching)
          Adds a new branching goal to the end of list of goals
 void attachGoal(AbstractIntBranchingStrategy branching)
          Deprecated. calls clearGoals() then addGoal(choco.kernel.solver.branch.AbstractIntBranchingStrategy)
 boolean checkDecisionVariables()
          Check wether every decisions variables are instantiated
 Boolean checkSolution()
          Solution checker.
 void clear()
          Removes all of the elements from this solver (optional operation).
 void clearGoals()
          Clears the list of goals defined
 IntDomainVar createBinTreeIntVar(String name, int[] sortedValues)
           
 IntDomainVar createBinTreeIntVar(String name, int min, int max)
           
 IntDomainVar createBooleanVar(String name)
           
 IntDomainVar createBoundIntVar(String name, int min, int max)
           
 SetVar createBoundSetVar(String name, int a, int b)
           
 IntDomainVar createEnumIntVar(String name, int[] sortedValues)
           
 IntDomainVar createEnumIntVar(String name, int min, int max)
           
 SetVar createEnumSetVar(String name, int a, int b)
           
 IntDomainVar createIntegerConstant(String name, int val)
           
 IntDomainVar createIntVar(String name, int domainType, int min, int max)
           
 RealConstant createRealConstant(String name, double val)
           
 RealConstant createRealIntervalConstant(double a, double b)
           
 RealVar createRealVal(String name, double min, double max)
           
 SetVar createSetVar(String name, int a, int b, int domainType)
           
 TaskVar createTaskVar(String name, IntDomainVar start, IntDomainVar end, IntDomainVar duration)
           
 RealConstant cst(double d)
          Makes a constant interval from a double d ([d,d]).
 RealConstant cst(double a, double b)
          Makes a constant interval between two doubles [a,b].
 SConstraint eq(IntExp x, int c)
           
 SConstraint eq(IntExp x, IntExp y)
           
 SConstraint eq(int c, IntExp x)
           
 SConstraint eq(RealVar r, IntDomainVar i)
           
 void eraseConstraint(SConstraint c)
           
 void generateSearchStrategy()
           
 SConstraint geq(IntExp x, int c)
           
 SConstraint geq(IntExp x, IntExp y)
           
 SConstraint geq(int c, IntExp x)
           
 Configuration getConfiguration()
          Return the current configuration of the solver
 DisposableIterator<SConstraint> getConstraintIterator()
           
 SConstraint getCstr(Constraint ic)
           
 AbstractGlobalSearchLimit getEncounteredLimit()
          If a limit has been encountered, return the involved limit
 IEnvironment getEnvironment()
          Returns the memory environment used by the model.
 boolean getFirstSolution()
          Deprecated.  
 int getHorizon()
          Deprecated.  
 IndexFactory getIndexfactory()
           
 Var getIntConstant(int i)
          Returns the constant corresponding to the int i.
 Collection<Integer> getIntConstantSet()
          Returns the collection of integer constant values
 AbstractIntSConstraint getIntConstraint(int i)
          Deprecated.  
 DisposableIterator<SConstraint> getIntConstraintIterator()
          Deprecated.  
 IntDomainVar[] getIntDecisionVars()
          get the list of decision integer variables.
 IntDomainVar getIntVar(int i)
          Network management: Retrieve a variable by its index (all integer variables of the model are numbered in sequence from 0 on)
 int getIntVarIndex(IntVar c)
           
 DisposableIterator<IntDomainVar> getIntVarIterator()
           
 IntDomainVar getIntVarQuick(int i)
           
 int getLoggingMaxDepth()
          Deprecated. 
 IntDomainVar getMakespan()
          Get the makespan variable if any
 int getMakespanValue()
          get the makespan value or +inf.
 Model getModel()
           
 int getNbBooleanVars()
          Returns the number of variables modelling boolean.
 int getNbConstants()
          retrieving the total number of constants
 int getNbConstraints()
          retrieving the total number of constraints over integers
 int getNbIntConstraints()
          retrieving the total number of constraints
 int getNbIntVars()
          retrieving the total number of integer variables
 int getNbRealVars()
          Returns the number of variables modelling real numbers.
 int getNbSetVars()
          Returns the number of variables modelling real numbers.
 int getNbSolutions()
          returns the number of solutions encountered during the search
 int getNbTaskVars()
          Returns the number of variables modelling tasks.
 int getNbVars()
          retrieving the total number of variables
 Var getObjective()
           
 Number getOptimumValue()
           
 double getPrecision()
          Deprecated.  
 PropagationEngine getPropagationEngine()
          Returns the propagation engine associated to the model
 Var getRealConstant(double i)
          Returns the constant corresponding to the real i.
 Collection<Double> getRealConstantSet()
          Returns the collection of real constant values
 RealVar[] getRealDecisionVars()
          get the list of decision real variables.
 RealVar getRealVar(int i)
          Returns a real variable.
 DisposableIterator<RealVar> getRealVarIterator()
           
 RealVar getRealVarQuick(int i)
           
 double getReduction()
          Deprecated.  
 AbstractGlobalSearchStrategy getSearchStrategy()
           
 SetVar[] getSetDecisionVars()
          get the list of decision set variables.
 SetVar getSetVar(int i)
          Returns a set variable.
 DisposableIterator<SetVar> getSetVarIterator()
           
 SetVar getSetVarQuick(int i)
           
 TaskVar[] getTaskDecisionVars()
          get the list of decision task variables.
 TaskVar getTaskVar(int i)
          Returns a task variable.
 DisposableIterator<TaskVar> getTaskVarIterator()
           
 TaskVar getTaskVarQuick(int i)
           
<MV extends Variable,SV extends Var>
SV[]
getVar(Class<SV> clazz, MV[] mv)
           
 IntDomainVar[] getVar(IntegerVariable... v)
           
 IntDomainVar getVar(IntegerVariable v)
           
<MV extends Variable,SV extends Var>
SV
getVar(MV v)
           
 RealVar[] getVar(RealVariable... v)
           
 RealVar getVar(RealVariable v)
           
 SetVar[] getVar(SetVariable... v)
           
 SetVar getVar(SetVariable v)
           
 TaskVar[] getVar(TaskVariable... v)
           
 TaskVar getVar(TaskVariable v)
           
 int getWorldIndex()
          returning the index of the current worl
 SConstraint gt(IntExp x, int c)
           
 SConstraint gt(IntExp x, IntExp y)
           
 SConstraint gt(int c, IntExp x)
           
 boolean isEncounteredLimit()
          Checks if a limit has been encountered
 Boolean isFeasible()
           
 boolean isOptimizationSolver()
           
 void launch()
          commands the strategy to start
 SConstraint leq(IntExp x, int c)
           
 SConstraint leq(IntExp x, IntExp y)
           
 SConstraint leq(int c, IntExp x)
           
 SConstraint lt(IntExp x, int c)
           
 SConstraint lt(IntExp x, IntExp y)
           
 SConstraint lt(int c, IntExp x)
           
 BinRelation makeBinRelation(int[] min, int[] max, List<int[]> mat, boolean feas)
           
 BinRelation makeBinRelation(int[] min, int[] max, List<int[]> mat, boolean feas, boolean bitset)
           
 LargeRelation makeLargeRelation(int[] min, int[] max, List<int[]> tuples, boolean feas)
           
 LargeRelation makeLargeRelation(int[] min, int[] max, List<int[]> tuples, boolean feas, int scheme)
           
 Boolean maximize(boolean restart)
           
 Boolean maximize(Var obj, boolean restart)
           
 Boolean minimize(boolean restart)
           
 Boolean minimize(Var obj, boolean restart)
           
 void monitorBackTrackLimit(boolean b)
          Deprecated. 
 void monitorFailLimit(boolean b)
          Monitor the fail limit (default to false)
 void monitorNodeLimit(boolean b)
          Deprecated. 
 void monitorTimeLimit(boolean b)
          Deprecated. 
 SConstraint neq(IntExp x, int c)
           
 SConstraint neq(IntExp x, IntExp y)
           
 SConstraint neq(int c, IntExp x)
           
 Boolean nextSolution()
           
 IntExp plus(IntExp v1, int v2)
           
 IntExp plus(IntExp v1, IntExp v2)
           
 IntExp plus(int v1, IntExp v2)
           
 void post(SConstraint c)
           
 void postCut(SConstraint c)
           
 void printRuntimeStatistics()
           
 void propagate()
          Propagation: Computes consistency on the model (the model may no longer be consistent since the last propagation because of listeners that have been posted and variables that have been reduced
 void read(Model m)
           
 Solution recordSolution()
          Record a solution by getting every variables' value.
 SConstraint relationTupleAC(IntDomainVar[] vs, LargeRelation rela)
           
 SConstraint relationTupleAC(IntDomainVar[] vs, LargeRelation rela, int ac)
           
 void restoreSolution(Solution sol)
          Restore a solution by setting value to every variable
 String runtimeStatistics()
           
 IntExp scalar(int[] lc, IntDomainVar[] lv)
           
 IntExp scalar(IntDomainVar[] lv, int[] lc)
           
 void setBackTrackLimit(int backtracklimit)
          Sets the backtrack limit i.e. the maximal number of backtracks before stopping the search algorithm
 void setCardReasoning(boolean creas)
          Deprecated. 
 void setDoMaximize(boolean doMaximize)
          Deprecated.  
 void setFailLimit(int failLimit)
          Sets the fail limit i.e. the maximal numnber of fails before stopping the search algorithm
 void setFeasible(Boolean b)
           
 void setFirstSolution(boolean firstSolution)
          Deprecated.  
 void setHorizon(int horizon)
          Deprecated.  
 void setIlogGoal(Goal ilogGoal)
           
 void setLoggingMaxDepth(int loggingMaxDepth)
          Deprecated. 
 void setModel(Model model)
           
 void setNodeLimit(int nodeLimit)
          Sets the node limit i.e. the maximal number of nodes explored by the search algorithm
 void setObjective(Var objective)
          Set the variable to optimize
 void setPrecision(double precision)
          Deprecated.  
 void setReduction(double reduction)
          Deprecated.  
 void setRestart(boolean restart)
          Deprecated. 
 void setRestartLimit(int restartLimit)
          Sets the restart limit i.e. the maximal number of restart performed during the search algorithm.
 void setSolutionDisplay(ISolutionDisplay solutionDisplay)
          Set Custom pretty print of solutions
 void setSolutionPoolCapacity(int capacity)
          Deprecated. 
 void setTimeLimit(int timeLimit)
          Sets the time limit i.e. the maximal time before stopping the search algorithm
 void setValIntIterator(ValIterator<IntDomainVar> valIterator)
          Sets the integer value iterator the search should use
 void setValIntSelector(ValSelector<IntDomainVar> valSelector)
          Sets the integer value selector the search should use
 void setValRealIterator(ValIterator<RealVar> realValIterator)
          Sets the real value iterator the search should use
 void setValRealSelector(ValSelector<RealVar> valSelector)
          Sets the integer value selector the search should use
 void setValSetIterator(ValIterator<SetVar> valIterator)
          Sets the integer value iterator the search should use
 void setValSetSelector(ValSelector<SetVar> setValIntSelector)
          Sets the integer value selector the search should use
 void setVarIntSelector(VarSelector<IntDomainVar> varSelector)
          Sets the integer variable selector the search olver should use.
 void setVarRealSelector(VarSelector<RealVar> realVarSelector)
          Sets the real variable selector the search strategy should use.
 void setVarSetSelector(VarSelector<SetVar> setVarIntSelector)
          Sets the set variable selector the search strategy should use.
 Boolean solve()
           
 Boolean solve(boolean all)
           
 Boolean solveAll()
           
 IntExp sum(IntExp... lv)
           
 void worldPop()
          popping one world from the stack: overrides AbstractModel.worldPop because the Model class adds the notion of static constraints that need be repropagated upon backtracking
 void worldPopDuringPropagation()
          poping the world during propagation
 void worldPopUntil(int n)
          Backtracks to a given level in the search tree.
 void worldPush()
          pushing one world on the stack
 void worldPushDuringPropagation()
          pushing the world during propagation
 
Methods inherited from interface choco.kernel.solver.search.ISolutionDisplay
solutionToString
 
Methods inherited from interface choco.kernel.solver.search.measure.IPreSolveMeasures
getInitialPropagationTimeCount, getReadingTimeCount
 
Methods inherited from interface choco.kernel.solver.search.measure.IOptimizationMeasures
getObjectiveValue, isObjectiveOptimal
 
Methods inherited from interface choco.kernel.solver.search.measure.ISolutionMeasures
existsSolution, getSolutionCount
 
Methods inherited from interface choco.kernel.solver.search.measure.ISearchMeasures
getBackTrackCount, getFailCount, getNodeCount, getRestartCount, getSolutionCount, getTimeCount
 
Methods inherited from interface choco.IPretty
pretty
 

Field Detail

DEFAULT_SOLUTION_CHECKER

static final SolutionCheckerEngine DEFAULT_SOLUTION_CHECKER

LOGGER

static final Logger LOGGER
Reference to an object for logging trace statements related to Abtract Solver (using the java.util.logging package)

Method Detail

clear

void clear()
Removes all of the elements from this solver (optional operation). The solver will be 'empty' after this call returns.


getIndexfactory

IndexFactory getIndexfactory()

getModel

Model getModel()

setModel

void setModel(Model model)

generateSearchStrategy

void generateSearchStrategy()

attachGoal

@Deprecated
void attachGoal(AbstractIntBranchingStrategy branching)
Deprecated. calls clearGoals() then addGoal(choco.kernel.solver.branch.AbstractIntBranchingStrategy)


addGoal

void addGoal(AbstractIntBranchingStrategy branching)
Adds a new branching goal to the end of list of goals

Parameters:
branching - new goal to add

clearGoals

void clearGoals()
Clears the list of goals defined


checkDecisionVariables

boolean checkDecisionVariables()
Check wether every decisions variables are instantiated

Returns:
true if all variables are instantiated

launch

void launch()
commands the strategy to start


getNbSolutions

int getNbSolutions()
returns the number of solutions encountered during the search

Returns:
the number of solutions to the model that were encountered during the search

monitorTimeLimit

@Deprecated
void monitorTimeLimit(boolean b)
Deprecated. 

Monitor the time limit (default to true)

Parameters:
b - indicates wether the search stategy monitor the time limit

monitorNodeLimit

@Deprecated
void monitorNodeLimit(boolean b)
Deprecated. 

Monitor the node limit (default to true)

Parameters:
b - indicates wether the search stategy monitor the node limit

monitorBackTrackLimit

@Deprecated
void monitorBackTrackLimit(boolean b)
Deprecated. 

Monitor the backtrack limit (default to false)

Parameters:
b - indicates wether the search stategy monitor the backtrack limit

monitorFailLimit

void monitorFailLimit(boolean b)
Monitor the fail limit (default to false)

Parameters:
b - indicates wether the search stategy monitor the fail limit

setTimeLimit

void setTimeLimit(int timeLimit)
Sets the time limit i.e. the maximal time before stopping the search algorithm


setNodeLimit

void setNodeLimit(int nodeLimit)
Sets the node limit i.e. the maximal number of nodes explored by the search algorithm


setBackTrackLimit

void setBackTrackLimit(int backtracklimit)
Sets the backtrack limit i.e. the maximal number of backtracks before stopping the search algorithm


setFailLimit

void setFailLimit(int failLimit)
Sets the fail limit i.e. the maximal numnber of fails before stopping the search algorithm


setRestartLimit

void setRestartLimit(int restartLimit)
Sets the restart limit i.e. the maximal number of restart performed during the search algorithm. The limit does not stop the search only the restart process.


getFirstSolution

boolean getFirstSolution()
Deprecated. 

Returns:
true if only the first solution must be found

setFirstSolution

void setFirstSolution(boolean firstSolution)
Deprecated. 

Sets wether only the first solution must be found


setVarIntSelector

void setVarIntSelector(VarSelector<IntDomainVar> varSelector)
Sets the integer variable selector the search olver should use.


setVarRealSelector

void setVarRealSelector(VarSelector<RealVar> realVarSelector)
Sets the real variable selector the search strategy should use.


setVarSetSelector

void setVarSetSelector(VarSelector<SetVar> setVarIntSelector)
Sets the set variable selector the search strategy should use.


setValIntIterator

void setValIntIterator(ValIterator<IntDomainVar> valIterator)
Sets the integer value iterator the search should use


setValRealIterator

void setValRealIterator(ValIterator<RealVar> realValIterator)
Sets the real value iterator the search should use


setValSetIterator

void setValSetIterator(ValIterator<SetVar> valIterator)
Sets the integer value iterator the search should use


setValIntSelector

void setValIntSelector(ValSelector<IntDomainVar> valSelector)
Sets the integer value selector the search should use


setValRealSelector

void setValRealSelector(ValSelector<RealVar> valSelector)
Sets the integer value selector the search should use


setValSetSelector

void setValSetSelector(ValSelector<SetVar> setValIntSelector)
Sets the integer value selector the search should use


getIntConstraintIterator

@Deprecated
DisposableIterator<SConstraint> getIntConstraintIterator()
Deprecated. 


getConstraintIterator

DisposableIterator<SConstraint> getConstraintIterator()

getIntVarIterator

DisposableIterator<IntDomainVar> getIntVarIterator()

getSetVarIterator

DisposableIterator<SetVar> getSetVarIterator()

getRealVarIterator

DisposableIterator<RealVar> getRealVarIterator()

getTaskVarIterator

DisposableIterator<TaskVar> getTaskVarIterator()

getPropagationEngine

PropagationEngine getPropagationEngine()
Returns the propagation engine associated to the model


setRestart

@Deprecated
void setRestart(boolean restart)
Deprecated. 

set the optimization strategy: - restart or not after each solution found

Parameters:
restart -

setDoMaximize

@Deprecated
void setDoMaximize(boolean doMaximize)
Deprecated. 

a boolean indicating if the strategy minize or maximize the objective function

Parameters:
doMaximize -

setObjective

void setObjective(Var objective)
Set the variable to optimize

Parameters:
objective - variable to optimize

getObjective

Var getObjective()

isOptimizationSolver

boolean isOptimizationSolver()

getOptimumValue

Number getOptimumValue()

setHorizon

void setHorizon(int horizon)
Deprecated. 

set the scheduling horizon.

Parameters:
horizon - scheduling horizon

getHorizon

int getHorizon()
Deprecated. 

get the scheduling horizon.


getMakespan

IntDomainVar getMakespan()
Get the makespan variable if any

Returns:
makespan variable

getMakespanValue

int getMakespanValue()
get the makespan value or +inf.

Returns:
makespan value

isEncounteredLimit

boolean isEncounteredLimit()
Checks if a limit has been encountered

Returns:
a boolean

getEncounteredLimit

AbstractGlobalSearchLimit getEncounteredLimit()
If a limit has been encountered, return the involved limit

Returns:
the limit encountered

getSearchStrategy

AbstractGlobalSearchStrategy getSearchStrategy()

post

void post(SConstraint c)

postCut

void postCut(SConstraint c)

getIntVar

IntDomainVar getIntVar(int i)
Network management: Retrieve a variable by its index (all integer variables of the model are numbered in sequence from 0 on)

Parameters:
i - index of the variable in the model
Returns:
number of integer variables

getIntVarQuick

IntDomainVar getIntVarQuick(int i)

getIntVarIndex

int getIntVarIndex(IntVar c)

getNbVars

int getNbVars()
retrieving the total number of variables

Returns:
the total number of variables in the model

getNbIntVars

int getNbIntVars()
retrieving the total number of integer variables

Returns:
the total number of integer variables in the model

getNbConstants

int getNbConstants()
retrieving the total number of constants

Returns:
the total number of constants in the model

getIntConstant

Var getIntConstant(int i)
Returns the constant corresponding to the int i.

Parameters:
i - object (value) of the constant represented as an instantiated "variable"
Returns:
the constant corresponding to the object i.

getRealConstant

Var getRealConstant(double i)
Returns the constant corresponding to the real i.

Parameters:
i - object (value) of the constant represented as an instantiated "variable"
Returns:
the constant corresponding to the object i.

getIntConstantSet

Collection<Integer> getIntConstantSet()
Returns the collection of integer constant values

Returns:
the set of values

getRealConstantSet

Collection<Double> getRealConstantSet()
Returns the collection of real constant values

Returns:
the set of values

getRealVar

RealVar getRealVar(int i)
Returns a real variable.

Parameters:
i - index of the variable
Returns:
the i-th real variable

getRealVarQuick

RealVar getRealVarQuick(int i)

getNbRealVars

int getNbRealVars()
Returns the number of variables modelling real numbers.

Returns:
number of real variables

getSetVar

SetVar getSetVar(int i)
Returns a set variable.

Parameters:
i - index of the variable
Returns:
the i-th real variable

getSetVarQuick

SetVar getSetVarQuick(int i)

getNbSetVars

int getNbSetVars()
Returns the number of variables modelling real numbers.

Returns:
number of set variables

getTaskVar

TaskVar getTaskVar(int i)
Returns a task variable.

Parameters:
i - index of the variable
Returns:
the i-th task variable

getTaskVarQuick

TaskVar getTaskVarQuick(int i)

getNbTaskVars

int getNbTaskVars()
Returns the number of variables modelling tasks.

Returns:
actual number of task vars

getNbBooleanVars

int getNbBooleanVars()
Returns the number of variables modelling boolean.

Returns:
the number of boolean variables.

getIntDecisionVars

IntDomainVar[] getIntDecisionVars()
get the list of decision integer variables.

Returns:
an unmodifiable list

getSetDecisionVars

SetVar[] getSetDecisionVars()
get the list of decision set variables.

Returns:
an unmodifiable list

getRealDecisionVars

RealVar[] getRealDecisionVars()
get the list of decision real variables.

Returns:
an unmodifiable list

getTaskDecisionVars

TaskVar[] getTaskDecisionVars()
get the list of decision task variables.

Returns:
an unmodifiable list

setPrecision

@Deprecated
void setPrecision(double precision)
Deprecated. 

Set the precision of the search for a real model.

Parameters:
precision - the new precision

getPrecision

@Deprecated
double getPrecision()
Deprecated. 

Get the precision of the search for a real model.

Returns:
the actual precision

setReduction

@Deprecated
void setReduction(double reduction)
Deprecated. 

Set the minimal width reduction between two propagations.

Parameters:
reduction - new width reduction

getReduction

@Deprecated
double getReduction()
Deprecated. 

Get the minimal width reduction between two propagations.

Returns:
width reduction

propagate

void propagate()
               throws ContradictionException
Propagation: Computes consistency on the model (the model may no longer be consistent since the last propagation because of listeners that have been posted and variables that have been reduced

Throws:
ContradictionException

maximize

Boolean maximize(boolean restart)

minimize

Boolean minimize(boolean restart)

maximize

Boolean maximize(Var obj,
                 boolean restart)

minimize

Boolean minimize(Var obj,
                 boolean restart)

setSolutionPoolCapacity

@Deprecated
void setSolutionPoolCapacity(int capacity)
Deprecated. 


printRuntimeStatistics

void printRuntimeStatistics()

runtimeStatistics

String runtimeStatistics()

setLoggingMaxDepth

@Deprecated
void setLoggingMaxDepth(int loggingMaxDepth)
Deprecated. 

set the maximal search depth for logging statements

See Also:
ChocoLogging

getLoggingMaxDepth

@Deprecated
int getLoggingMaxDepth()
Deprecated. 

get the maximal search depth for logging statements

See Also:
ChocoLogging

worldPush

void worldPush()
pushing one world on the stack


worldPop

void worldPop()
popping one world from the stack: overrides AbstractModel.worldPop because the Model class adds the notion of static constraints that need be repropagated upon backtracking


worldPopUntil

void worldPopUntil(int n)
Backtracks to a given level in the search tree.

Parameters:
n - number of world to pop

worldPushDuringPropagation

void worldPushDuringPropagation()
pushing the world during propagation


worldPopDuringPropagation

void worldPopDuringPropagation()
poping the world during propagation


recordSolution

Solution recordSolution()
Record a solution by getting every variables' value.

Returns:
the recorded solution

setSolutionDisplay

void setSolutionDisplay(ISolutionDisplay solutionDisplay)
Set Custom pretty print of solutions

Parameters:
solutionDisplay - the solution printer

restoreSolution

void restoreSolution(Solution sol)
Restore a solution by setting value to every variable

Parameters:
sol - solution to restore

getConfiguration

Configuration getConfiguration()
Return the current configuration of the solver

Returns:
the configuration

getEnvironment

IEnvironment getEnvironment()
Returns the memory environment used by the model.

Returns:
memory environment

setFeasible

void setFeasible(Boolean b)

getWorldIndex

int getWorldIndex()
returning the index of the current worl

Returns:
current world index

eraseConstraint

void eraseConstraint(SConstraint c)

getNbConstraints

int getNbConstraints()
retrieving the total number of constraints over integers

Returns:
the total number of constraints over integers in the model

getNbIntConstraints

int getNbIntConstraints()
retrieving the total number of constraints

Returns:
the total number of constraints in the model

getIntConstraint

@Deprecated
AbstractIntSConstraint getIntConstraint(int i)
Deprecated. 

Network management: Retrieve a constraint by its index.

Parameters:
i - index of the constraint in the model
Returns:
the ith constraint

plus

IntExp plus(IntExp v1,
            int v2)

plus

IntExp plus(int v1,
            IntExp v2)

plus

IntExp plus(IntExp v1,
            IntExp v2)

lt

SConstraint lt(IntExp x,
               int c)

lt

SConstraint lt(int c,
               IntExp x)

lt

SConstraint lt(IntExp x,
               IntExp y)

leq

SConstraint leq(IntExp x,
                int c)

leq

SConstraint leq(int c,
                IntExp x)

leq

SConstraint leq(IntExp x,
                IntExp y)

geq

SConstraint geq(IntExp x,
                int c)

geq

SConstraint geq(int c,
                IntExp x)

geq

SConstraint geq(IntExp x,
                IntExp y)

eq

SConstraint eq(IntExp x,
               IntExp y)

eq

SConstraint eq(IntExp x,
               int c)

eq

SConstraint eq(int c,
               IntExp x)

eq

SConstraint eq(RealVar r,
               IntDomainVar i)

gt

SConstraint gt(IntExp x,
               IntExp y)

gt

SConstraint gt(IntExp x,
               int c)

gt

SConstraint gt(int c,
               IntExp x)

neq

SConstraint neq(IntExp x,
                int c)

neq

SConstraint neq(int c,
                IntExp x)

neq

SConstraint neq(IntExp x,
                IntExp y)

scalar

IntExp scalar(int[] lc,
              IntDomainVar[] lv)

scalar

IntExp scalar(IntDomainVar[] lv,
              int[] lc)

sum

IntExp sum(IntExp... lv)

read

void read(Model m)

solve

Boolean solve(boolean all)

solve

Boolean solve()

solveAll

Boolean solveAll()

isFeasible

Boolean isFeasible()

checkSolution

Boolean checkSolution()
Solution checker. Usefull for debug and development.

Returns:
a boolean indicating wether the solution is correct or not.

nextSolution

Boolean nextSolution()

_to

<MV extends Variable,SV extends Var> SV _to(MV mv,
                                            SV sv)

_to

<MV extends Variable,SV extends Var> SV[] _to(MV[] mv,
                                              SV[] sv)

getVar

<MV extends Variable,SV extends Var> SV getVar(MV v)

getVar

<MV extends Variable,SV extends Var> SV[] getVar(Class<SV> clazz,
                                                 MV[] mv)

getVar

IntDomainVar getVar(IntegerVariable v)

getVar

IntDomainVar[] getVar(IntegerVariable... v)

getVar

RealVar getVar(RealVariable v)

getVar

RealVar[] getVar(RealVariable... v)

getVar

SetVar getVar(SetVariable v)

getVar

SetVar[] getVar(SetVariable... v)

getVar

TaskVar getVar(TaskVariable v)

getVar

TaskVar[] getVar(TaskVariable... v)

getCstr

SConstraint getCstr(Constraint ic)

setIlogGoal

void setIlogGoal(Goal ilogGoal)

createIntVar

IntDomainVar createIntVar(String name,
                          int domainType,
                          int min,
                          int max)

createBooleanVar

IntDomainVar createBooleanVar(String name)

createEnumIntVar

IntDomainVar createEnumIntVar(String name,
                              int min,
                              int max)

createBoundIntVar

IntDomainVar createBoundIntVar(String name,
                               int min,
                               int max)

createBinTreeIntVar

IntDomainVar createBinTreeIntVar(String name,
                                 int min,
                                 int max)

createEnumIntVar

IntDomainVar createEnumIntVar(String name,
                              int[] sortedValues)

createBinTreeIntVar

IntDomainVar createBinTreeIntVar(String name,
                                 int[] sortedValues)

createRealVal

RealVar createRealVal(String name,
                      double min,
                      double max)

createRealIntervalConstant

RealConstant createRealIntervalConstant(double a,
                                        double b)

cst

RealConstant cst(double d)
Makes a constant interval from a double d ([d,d]).

Parameters:
d - double
Returns:
constant interval

cst

RealConstant cst(double a,
                 double b)
Makes a constant interval between two doubles [a,b].

Parameters:
a - lower bound
b - upper bound
Returns:
constant interval

createSetVar

SetVar createSetVar(String name,
                    int a,
                    int b,
                    int domainType)

createBoundSetVar

SetVar createBoundSetVar(String name,
                         int a,
                         int b)

createEnumSetVar

SetVar createEnumSetVar(String name,
                        int a,
                        int b)

createTaskVar

TaskVar createTaskVar(String name,
                      IntDomainVar start,
                      IntDomainVar end,
                      IntDomainVar duration)

createIntegerConstant

IntDomainVar createIntegerConstant(String name,
                                   int val)

createRealConstant

RealConstant createRealConstant(String name,
                                double val)

setCardReasoning

@Deprecated
void setCardReasoning(boolean creas)
Deprecated. 


makeLargeRelation

LargeRelation makeLargeRelation(int[] min,
                                int[] max,
                                List<int[]> tuples,
                                boolean feas)

makeLargeRelation

LargeRelation makeLargeRelation(int[] min,
                                int[] max,
                                List<int[]> tuples,
                                boolean feas,
                                int scheme)

makeBinRelation

BinRelation makeBinRelation(int[] min,
                            int[] max,
                            List<int[]> mat,
                            boolean feas,
                            boolean bitset)

makeBinRelation

BinRelation makeBinRelation(int[] min,
                            int[] max,
                            List<int[]> mat,
                            boolean feas)

relationTupleAC

SConstraint relationTupleAC(IntDomainVar[] vs,
                            LargeRelation rela)

relationTupleAC

SConstraint relationTupleAC(IntDomainVar[] vs,
                            LargeRelation rela,
                            int ac)


Copyright © 2012. All Rights Reserved.