Search in sources :

Example 1 with AbstractSingleVariableConstraint

use of com.sri.ai.grinder.sgdpllt.core.constraint.AbstractSingleVariableConstraint in project aic-expresso by aic-sri-international.

the class AbstractSingleVariableNumericConstraintFeasibilityRegionStepSolver method makeUpperBoundsAndStrictness.

/** 
	 * A method setting {@link #upperBoundsIncludingImplicitOnes} and {@link #fromUpperBoundsIncludingImplicitOnesToStrictness}
	 * from constraint and variable's type.
	 * @param context
	 */
protected void makeUpperBoundsAndStrictness(Context context) {
    AbstractSingleVariableConstraint abstractSingleVariableConstraint = (AbstractSingleVariableConstraint) constraint;
    FunctionIterator<Expression, Pair<Expression, Boolean>> upperBoundsFromPositiveNormalizedAtomsIterator = functionIterator(predicateIterator(abstractSingleVariableConstraint.getPositiveNormalizedAtoms(), e -> e.hasFunctor(LESS_THAN)), // strict
    e -> processExplicitUpperBoundAndStrictnessPair(e.get(1), true, context));
    FunctionIterator<Expression, Pair<Expression, Boolean>> upperBoundsFromNegativeNormalizedAtomsIterator = functionIterator(predicateIterator(abstractSingleVariableConstraint.getNegativeNormalizedAtoms(), // not (X > Y) <=> X <= Y, so Y is a non-strict upper bound
    e -> e.hasFunctor(GREATER_THAN)), // non-strict
    e -> processExplicitUpperBoundAndStrictnessPair(e.get(1), false, context));
    Pair<Expression, Boolean> typeUpperBound = getTypeUpperBoundAndStrictness(context);
    Iterator<Pair<Expression, Boolean>> upperBoundsAndStrictnessIterator = new NestedIterator<>(upperBoundsFromPositiveNormalizedAtomsIterator, upperBoundsFromNegativeNormalizedAtomsIterator, typeUpperBound);
    upperBoundsIncludingImplicitOnes = arrayList();
    fromUpperBoundsIncludingImplicitOnesToStrictness = map();
    for (Pair<Expression, Boolean> boundAndStrictness : in(upperBoundsAndStrictnessIterator)) {
        Expression bound = boundAndStrictness.first;
        upperBoundsIncludingImplicitOnes.add(bound);
        Boolean strictness = boundAndStrictness.second;
        Boolean previousStrictness = fromUpperBoundsIncludingImplicitOnesToStrictness.get(bound);
        if (previousStrictness == null || (!previousStrictness && strictness)) {
            // if no strictness information so far, store current one; otherwise, only need to change it if previous occurrences were non-strict and this one is strict
            fromUpperBoundsIncludingImplicitOnesToStrictness.put(bound, strictness);
        }
    }
}
Also used : LESS_THAN_OR_EQUAL_TO(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.LESS_THAN_OR_EQUAL_TO) Expressions(com.sri.ai.expresso.helper.Expressions) NestedIterator(com.sri.ai.util.collect.NestedIterator) INFINITY(com.sri.ai.expresso.helper.Expressions.INFINITY) PairOf(com.sri.ai.util.base.PairOf) Expression(com.sri.ai.expresso.api.Expression) CartesianProductIterator(com.sri.ai.util.collect.CartesianProductIterator) PairOf.makePairOf(com.sri.ai.util.base.PairOf.makePairOf) ArrayList(java.util.ArrayList) Util.in(com.sri.ai.util.Util.in) Util.map(com.sri.ai.util.Util.map) Symbol(com.sri.ai.expresso.api.Symbol) Expressions.apply(com.sri.ai.expresso.helper.Expressions.apply) ConstantStepSolver(com.sri.ai.grinder.sgdpllt.theory.base.ConstantStepSolver) Map(java.util.Map) Pair.pair(com.sri.ai.util.base.Pair.pair) AbstractExpressionWithPropagatedLiteralsStepSolver(com.sri.ai.grinder.sgdpllt.core.solver.AbstractExpressionWithPropagatedLiteralsStepSolver) Util.arrayList(com.sri.ai.util.Util.arrayList) FunctionIterator(com.sri.ai.util.collect.FunctionIterator) LiteralStepSolver(com.sri.ai.grinder.sgdpllt.theory.base.LiteralStepSolver) Pair(com.sri.ai.util.base.Pair) Equality(com.sri.ai.grinder.sgdpllt.library.Equality) PredicateIterator.predicateIterator(com.sri.ai.util.collect.PredicateIterator.predicateIterator) Util.arrayListFrom(com.sri.ai.util.Util.arrayListFrom) Function(com.google.common.base.Function) Iterator(java.util.Iterator) Util.iterator(com.sri.ai.util.Util.iterator) Util.list(com.sri.ai.util.Util.list) MINUS_INFINITY(com.sri.ai.expresso.helper.Expressions.MINUS_INFINITY) AbstractSingleVariableConstraint(com.sri.ai.grinder.sgdpllt.core.constraint.AbstractSingleVariableConstraint) EQUALITY(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.EQUALITY) Context(com.sri.ai.grinder.sgdpllt.api.Context) GREATER_THAN_OR_EQUAL_TO(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.GREATER_THAN_OR_EQUAL_TO) Beta(com.google.common.annotations.Beta) TrueContext(com.sri.ai.grinder.sgdpllt.core.TrueContext) StepSolver(com.sri.ai.grinder.sgdpllt.api.StepSolver) Expressions.makeSymbol(com.sri.ai.expresso.helper.Expressions.makeSymbol) FunctionIterator.functionIterator(com.sri.ai.util.collect.FunctionIterator.functionIterator) ConstantExpressionStepSolver(com.sri.ai.grinder.sgdpllt.theory.base.ConstantExpressionStepSolver) LESS_THAN(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.LESS_THAN) AbstractSingleVariableDifferenceArithmeticConstraintFeasibilityRegionStepSolver(com.sri.ai.grinder.sgdpllt.theory.differencearithmetic.AbstractSingleVariableDifferenceArithmeticConstraintFeasibilityRegionStepSolver) MaximumExpressionStepSolver(com.sri.ai.grinder.sgdpllt.helper.MaximumExpressionStepSolver) Util(com.sri.ai.util.Util) PairOfElementsInListIterator(com.sri.ai.util.collect.PairOfElementsInListIterator) FunctorConstants(com.sri.ai.grinder.sgdpllt.library.FunctorConstants) GREATER_THAN(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.GREATER_THAN) ExpressionLiteralSplitterStepSolver(com.sri.ai.grinder.sgdpllt.api.ExpressionLiteralSplitterStepSolver) Expression(com.sri.ai.expresso.api.Expression) NestedIterator(com.sri.ai.util.collect.NestedIterator) AbstractSingleVariableConstraint(com.sri.ai.grinder.sgdpllt.core.constraint.AbstractSingleVariableConstraint) Pair(com.sri.ai.util.base.Pair)

Example 2 with AbstractSingleVariableConstraint

use of com.sri.ai.grinder.sgdpllt.core.constraint.AbstractSingleVariableConstraint in project aic-expresso by aic-sri-international.

the class AbstractSingleVariableNumericConstraintFeasibilityRegionStepSolver method getDisequals.

protected ArrayList<Expression> getDisequals() {
    if (disequals == null) {
        AbstractSingleVariableConstraint abstractSingleVariableConstraint = (AbstractSingleVariableConstraint) constraint;
        Iterator<Expression> disequalsIterator = functionIterator(predicateIterator(abstractSingleVariableConstraint.getNegativeNormalizedAtoms(), // negative equality is disequality
        e -> e.hasFunctor(FunctorConstants.EQUALITY)), e -> e.get(1));
        disequals = arrayListFrom(disequalsIterator);
    }
    return disequals;
}
Also used : LESS_THAN_OR_EQUAL_TO(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.LESS_THAN_OR_EQUAL_TO) Expressions(com.sri.ai.expresso.helper.Expressions) NestedIterator(com.sri.ai.util.collect.NestedIterator) INFINITY(com.sri.ai.expresso.helper.Expressions.INFINITY) PairOf(com.sri.ai.util.base.PairOf) Expression(com.sri.ai.expresso.api.Expression) CartesianProductIterator(com.sri.ai.util.collect.CartesianProductIterator) PairOf.makePairOf(com.sri.ai.util.base.PairOf.makePairOf) ArrayList(java.util.ArrayList) Util.in(com.sri.ai.util.Util.in) Util.map(com.sri.ai.util.Util.map) Symbol(com.sri.ai.expresso.api.Symbol) Expressions.apply(com.sri.ai.expresso.helper.Expressions.apply) ConstantStepSolver(com.sri.ai.grinder.sgdpllt.theory.base.ConstantStepSolver) Map(java.util.Map) Pair.pair(com.sri.ai.util.base.Pair.pair) AbstractExpressionWithPropagatedLiteralsStepSolver(com.sri.ai.grinder.sgdpllt.core.solver.AbstractExpressionWithPropagatedLiteralsStepSolver) Util.arrayList(com.sri.ai.util.Util.arrayList) FunctionIterator(com.sri.ai.util.collect.FunctionIterator) LiteralStepSolver(com.sri.ai.grinder.sgdpllt.theory.base.LiteralStepSolver) Pair(com.sri.ai.util.base.Pair) Equality(com.sri.ai.grinder.sgdpllt.library.Equality) PredicateIterator.predicateIterator(com.sri.ai.util.collect.PredicateIterator.predicateIterator) Util.arrayListFrom(com.sri.ai.util.Util.arrayListFrom) Function(com.google.common.base.Function) Iterator(java.util.Iterator) Util.iterator(com.sri.ai.util.Util.iterator) Util.list(com.sri.ai.util.Util.list) MINUS_INFINITY(com.sri.ai.expresso.helper.Expressions.MINUS_INFINITY) AbstractSingleVariableConstraint(com.sri.ai.grinder.sgdpllt.core.constraint.AbstractSingleVariableConstraint) EQUALITY(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.EQUALITY) Context(com.sri.ai.grinder.sgdpllt.api.Context) GREATER_THAN_OR_EQUAL_TO(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.GREATER_THAN_OR_EQUAL_TO) Beta(com.google.common.annotations.Beta) TrueContext(com.sri.ai.grinder.sgdpllt.core.TrueContext) StepSolver(com.sri.ai.grinder.sgdpllt.api.StepSolver) Expressions.makeSymbol(com.sri.ai.expresso.helper.Expressions.makeSymbol) FunctionIterator.functionIterator(com.sri.ai.util.collect.FunctionIterator.functionIterator) ConstantExpressionStepSolver(com.sri.ai.grinder.sgdpllt.theory.base.ConstantExpressionStepSolver) LESS_THAN(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.LESS_THAN) AbstractSingleVariableDifferenceArithmeticConstraintFeasibilityRegionStepSolver(com.sri.ai.grinder.sgdpllt.theory.differencearithmetic.AbstractSingleVariableDifferenceArithmeticConstraintFeasibilityRegionStepSolver) MaximumExpressionStepSolver(com.sri.ai.grinder.sgdpllt.helper.MaximumExpressionStepSolver) Util(com.sri.ai.util.Util) PairOfElementsInListIterator(com.sri.ai.util.collect.PairOfElementsInListIterator) FunctorConstants(com.sri.ai.grinder.sgdpllt.library.FunctorConstants) GREATER_THAN(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.GREATER_THAN) ExpressionLiteralSplitterStepSolver(com.sri.ai.grinder.sgdpllt.api.ExpressionLiteralSplitterStepSolver) Expression(com.sri.ai.expresso.api.Expression) AbstractSingleVariableConstraint(com.sri.ai.grinder.sgdpllt.core.constraint.AbstractSingleVariableConstraint)

Example 3 with AbstractSingleVariableConstraint

use of com.sri.ai.grinder.sgdpllt.core.constraint.AbstractSingleVariableConstraint in project aic-expresso by aic-sri-international.

the class AbstractSingleVariableNumericConstraintFeasibilityRegionStepSolver method makeLowerBoundsAndStrictness.

/** 
	 * A method setting {@link #lowerBoundsIncludingImplicitOnes} and {@link #fromLowerBoundsIncludingImplicitOnesToStrictness}
	 * from constraint and variable's type.
	 * @param context
	 */
protected void makeLowerBoundsAndStrictness(Context context) {
    AbstractSingleVariableConstraint abstractSingleVariableConstraint = (AbstractSingleVariableConstraint) constraint;
    FunctionIterator<Expression, Pair<Expression, Boolean>> lowerBoundsAndStrictnessFromPositiveNormalizedAtomsIterator = functionIterator(predicateIterator(abstractSingleVariableConstraint.getPositiveNormalizedAtoms(), // X > Y, so Y is a strict lower bound
    e -> e.hasFunctor(GREATER_THAN)), // bound is strict
    e -> processExplicitLowerBoundAndStrictnessPair(e.get(1), true, context));
    FunctionIterator<Expression, Pair<Expression, Boolean>> lowerBoundsAndStrictnessFromNegativeNormalizedAtomsIterator = functionIterator(predicateIterator(abstractSingleVariableConstraint.getNegativeNormalizedAtoms(), e -> e.hasFunctor(LESS_THAN)), // not (X < Y) <=> X >= Y, so bound is non-strict
    e -> processExplicitLowerBoundAndStrictnessPair(e.get(1), false, context));
    Pair<Expression, Boolean> typeLowerBoundAndStrictness = getTypeLowerBoundAndStrictness(context);
    Iterator<Pair<Expression, Boolean>> lowerBoundsAndStrictnessIterator = new NestedIterator<>(lowerBoundsAndStrictnessFromPositiveNormalizedAtomsIterator, lowerBoundsAndStrictnessFromNegativeNormalizedAtomsIterator, typeLowerBoundAndStrictness);
    lowerBoundsIncludingImplicitOnes = arrayList();
    fromLowerBoundsIncludingImplicitOnesToStrictness = map();
    for (Pair<Expression, Boolean> boundAndStrictness : in(lowerBoundsAndStrictnessIterator)) {
        Expression bound = boundAndStrictness.first;
        lowerBoundsIncludingImplicitOnes.add(bound);
        Boolean strictness = boundAndStrictness.second;
        Boolean previousStrictness = fromLowerBoundsIncludingImplicitOnesToStrictness.get(bound);
        if (previousStrictness == null || (!previousStrictness && strictness)) {
            // if no strictness information so far, store current one; otherwise, only need to change it if previous occurrences were non-strict and this one is strict
            fromLowerBoundsIncludingImplicitOnesToStrictness.put(bound, strictness);
        }
    }
}
Also used : LESS_THAN_OR_EQUAL_TO(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.LESS_THAN_OR_EQUAL_TO) Expressions(com.sri.ai.expresso.helper.Expressions) NestedIterator(com.sri.ai.util.collect.NestedIterator) INFINITY(com.sri.ai.expresso.helper.Expressions.INFINITY) PairOf(com.sri.ai.util.base.PairOf) Expression(com.sri.ai.expresso.api.Expression) CartesianProductIterator(com.sri.ai.util.collect.CartesianProductIterator) PairOf.makePairOf(com.sri.ai.util.base.PairOf.makePairOf) ArrayList(java.util.ArrayList) Util.in(com.sri.ai.util.Util.in) Util.map(com.sri.ai.util.Util.map) Symbol(com.sri.ai.expresso.api.Symbol) Expressions.apply(com.sri.ai.expresso.helper.Expressions.apply) ConstantStepSolver(com.sri.ai.grinder.sgdpllt.theory.base.ConstantStepSolver) Map(java.util.Map) Pair.pair(com.sri.ai.util.base.Pair.pair) AbstractExpressionWithPropagatedLiteralsStepSolver(com.sri.ai.grinder.sgdpllt.core.solver.AbstractExpressionWithPropagatedLiteralsStepSolver) Util.arrayList(com.sri.ai.util.Util.arrayList) FunctionIterator(com.sri.ai.util.collect.FunctionIterator) LiteralStepSolver(com.sri.ai.grinder.sgdpllt.theory.base.LiteralStepSolver) Pair(com.sri.ai.util.base.Pair) Equality(com.sri.ai.grinder.sgdpllt.library.Equality) PredicateIterator.predicateIterator(com.sri.ai.util.collect.PredicateIterator.predicateIterator) Util.arrayListFrom(com.sri.ai.util.Util.arrayListFrom) Function(com.google.common.base.Function) Iterator(java.util.Iterator) Util.iterator(com.sri.ai.util.Util.iterator) Util.list(com.sri.ai.util.Util.list) MINUS_INFINITY(com.sri.ai.expresso.helper.Expressions.MINUS_INFINITY) AbstractSingleVariableConstraint(com.sri.ai.grinder.sgdpllt.core.constraint.AbstractSingleVariableConstraint) EQUALITY(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.EQUALITY) Context(com.sri.ai.grinder.sgdpllt.api.Context) GREATER_THAN_OR_EQUAL_TO(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.GREATER_THAN_OR_EQUAL_TO) Beta(com.google.common.annotations.Beta) TrueContext(com.sri.ai.grinder.sgdpllt.core.TrueContext) StepSolver(com.sri.ai.grinder.sgdpllt.api.StepSolver) Expressions.makeSymbol(com.sri.ai.expresso.helper.Expressions.makeSymbol) FunctionIterator.functionIterator(com.sri.ai.util.collect.FunctionIterator.functionIterator) ConstantExpressionStepSolver(com.sri.ai.grinder.sgdpllt.theory.base.ConstantExpressionStepSolver) LESS_THAN(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.LESS_THAN) AbstractSingleVariableDifferenceArithmeticConstraintFeasibilityRegionStepSolver(com.sri.ai.grinder.sgdpllt.theory.differencearithmetic.AbstractSingleVariableDifferenceArithmeticConstraintFeasibilityRegionStepSolver) MaximumExpressionStepSolver(com.sri.ai.grinder.sgdpllt.helper.MaximumExpressionStepSolver) Util(com.sri.ai.util.Util) PairOfElementsInListIterator(com.sri.ai.util.collect.PairOfElementsInListIterator) FunctorConstants(com.sri.ai.grinder.sgdpllt.library.FunctorConstants) GREATER_THAN(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.GREATER_THAN) ExpressionLiteralSplitterStepSolver(com.sri.ai.grinder.sgdpllt.api.ExpressionLiteralSplitterStepSolver) Expression(com.sri.ai.expresso.api.Expression) NestedIterator(com.sri.ai.util.collect.NestedIterator) AbstractSingleVariableConstraint(com.sri.ai.grinder.sgdpllt.core.constraint.AbstractSingleVariableConstraint) Pair(com.sri.ai.util.base.Pair)

Example 4 with AbstractSingleVariableConstraint

use of com.sri.ai.grinder.sgdpllt.core.constraint.AbstractSingleVariableConstraint in project aic-expresso by aic-sri-international.

the class AbstractSingleVariableNumericConstraintFeasibilityRegionStepSolver method getNonEqualityComparisons.

protected ArrayList<Expression> getNonEqualityComparisons(Context context) {
    if (nonEqualityComparisons == null) {
        AbstractSingleVariableConstraint abstractSingleVariableConstraint = (AbstractSingleVariableConstraint) constraint;
        Iterator<Expression> fromPositiveNormalizedAtoms = predicateIterator(abstractSingleVariableConstraint.getPositiveNormalizedAtoms(), e -> !e.hasFunctor(FunctorConstants.EQUALITY));
        Iterator<Expression> fromNegativeNormalizedAtoms = functionIterator(// negative normalized atom is never an equality
        abstractSingleVariableConstraint.getNegativeNormalizedAtoms(), e -> abstractSingleVariableConstraint.getTheory().getLiteralNegation(e, context));
        Pair<Expression, Boolean> typeLowerBoundAndStrictness = getTypeLowerBoundAndStrictness(context);
        Expression typeLowerBound = typeLowerBoundAndStrictness.first;
        boolean typeLowerBoundIsStrict = typeLowerBoundAndStrictness.second;
        String greaterThanOperator = typeLowerBoundIsStrict ? GREATER_THAN : GREATER_THAN_OR_EQUAL_TO;
        Expression variableIsGreaterThanTypeLowerBound = apply(greaterThanOperator, getConstraint().getVariable(), typeLowerBound);
        Pair<Expression, Boolean> typeUpperBoundAndStrictness = getTypeUpperBoundAndStrictness(context);
        Expression typeUpperBound = typeUpperBoundAndStrictness.first;
        boolean typeUpperBoundIsStrict = typeUpperBoundAndStrictness.second;
        String lessThanOperator = typeUpperBoundIsStrict ? LESS_THAN : LESS_THAN_OR_EQUAL_TO;
        Expression variableIsLessThanOrEqualToTypeUpperBound = apply(lessThanOperator, getConstraint().getVariable(), typeUpperBound);
        Iterator<Expression> all = new NestedIterator<Expression>(fromPositiveNormalizedAtoms, fromNegativeNormalizedAtoms, variableIsGreaterThanTypeLowerBound, variableIsLessThanOrEqualToTypeUpperBound);
        nonEqualityComparisons = arrayListFrom(all);
    }
    return nonEqualityComparisons;
}
Also used : Expression(com.sri.ai.expresso.api.Expression) NestedIterator(com.sri.ai.util.collect.NestedIterator) AbstractSingleVariableConstraint(com.sri.ai.grinder.sgdpllt.core.constraint.AbstractSingleVariableConstraint)

Example 5 with AbstractSingleVariableConstraint

use of com.sri.ai.grinder.sgdpllt.core.constraint.AbstractSingleVariableConstraint in project aic-expresso by aic-sri-international.

the class AbstractSingleVariableNumericConstraintFeasibilityRegionStepSolver method getEquals.

protected ArrayList<Expression> getEquals() {
    if (equals == null) {
        AbstractSingleVariableConstraint abstractSingleVariableConstraint = (AbstractSingleVariableConstraint) constraint;
        Iterator<Expression> equalsIterator = functionIterator(predicateIterator(abstractSingleVariableConstraint.getPositiveNormalizedAtoms(), e -> e.hasFunctor(EQUALITY)), e -> e.get(1));
        equals = arrayListFrom(equalsIterator);
    }
    return equals;
}
Also used : LESS_THAN_OR_EQUAL_TO(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.LESS_THAN_OR_EQUAL_TO) Expressions(com.sri.ai.expresso.helper.Expressions) NestedIterator(com.sri.ai.util.collect.NestedIterator) INFINITY(com.sri.ai.expresso.helper.Expressions.INFINITY) PairOf(com.sri.ai.util.base.PairOf) Expression(com.sri.ai.expresso.api.Expression) CartesianProductIterator(com.sri.ai.util.collect.CartesianProductIterator) PairOf.makePairOf(com.sri.ai.util.base.PairOf.makePairOf) ArrayList(java.util.ArrayList) Util.in(com.sri.ai.util.Util.in) Util.map(com.sri.ai.util.Util.map) Symbol(com.sri.ai.expresso.api.Symbol) Expressions.apply(com.sri.ai.expresso.helper.Expressions.apply) ConstantStepSolver(com.sri.ai.grinder.sgdpllt.theory.base.ConstantStepSolver) Map(java.util.Map) Pair.pair(com.sri.ai.util.base.Pair.pair) AbstractExpressionWithPropagatedLiteralsStepSolver(com.sri.ai.grinder.sgdpllt.core.solver.AbstractExpressionWithPropagatedLiteralsStepSolver) Util.arrayList(com.sri.ai.util.Util.arrayList) FunctionIterator(com.sri.ai.util.collect.FunctionIterator) LiteralStepSolver(com.sri.ai.grinder.sgdpllt.theory.base.LiteralStepSolver) Pair(com.sri.ai.util.base.Pair) Equality(com.sri.ai.grinder.sgdpllt.library.Equality) PredicateIterator.predicateIterator(com.sri.ai.util.collect.PredicateIterator.predicateIterator) Util.arrayListFrom(com.sri.ai.util.Util.arrayListFrom) Function(com.google.common.base.Function) Iterator(java.util.Iterator) Util.iterator(com.sri.ai.util.Util.iterator) Util.list(com.sri.ai.util.Util.list) MINUS_INFINITY(com.sri.ai.expresso.helper.Expressions.MINUS_INFINITY) AbstractSingleVariableConstraint(com.sri.ai.grinder.sgdpllt.core.constraint.AbstractSingleVariableConstraint) EQUALITY(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.EQUALITY) Context(com.sri.ai.grinder.sgdpllt.api.Context) GREATER_THAN_OR_EQUAL_TO(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.GREATER_THAN_OR_EQUAL_TO) Beta(com.google.common.annotations.Beta) TrueContext(com.sri.ai.grinder.sgdpllt.core.TrueContext) StepSolver(com.sri.ai.grinder.sgdpllt.api.StepSolver) Expressions.makeSymbol(com.sri.ai.expresso.helper.Expressions.makeSymbol) FunctionIterator.functionIterator(com.sri.ai.util.collect.FunctionIterator.functionIterator) ConstantExpressionStepSolver(com.sri.ai.grinder.sgdpllt.theory.base.ConstantExpressionStepSolver) LESS_THAN(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.LESS_THAN) AbstractSingleVariableDifferenceArithmeticConstraintFeasibilityRegionStepSolver(com.sri.ai.grinder.sgdpllt.theory.differencearithmetic.AbstractSingleVariableDifferenceArithmeticConstraintFeasibilityRegionStepSolver) MaximumExpressionStepSolver(com.sri.ai.grinder.sgdpllt.helper.MaximumExpressionStepSolver) Util(com.sri.ai.util.Util) PairOfElementsInListIterator(com.sri.ai.util.collect.PairOfElementsInListIterator) FunctorConstants(com.sri.ai.grinder.sgdpllt.library.FunctorConstants) GREATER_THAN(com.sri.ai.grinder.sgdpllt.library.FunctorConstants.GREATER_THAN) ExpressionLiteralSplitterStepSolver(com.sri.ai.grinder.sgdpllt.api.ExpressionLiteralSplitterStepSolver) Expression(com.sri.ai.expresso.api.Expression) AbstractSingleVariableConstraint(com.sri.ai.grinder.sgdpllt.core.constraint.AbstractSingleVariableConstraint)

Aggregations

Expression (com.sri.ai.expresso.api.Expression)5 AbstractSingleVariableConstraint (com.sri.ai.grinder.sgdpllt.core.constraint.AbstractSingleVariableConstraint)5 Beta (com.google.common.annotations.Beta)4 Function (com.google.common.base.Function)4 Symbol (com.sri.ai.expresso.api.Symbol)4 Expressions (com.sri.ai.expresso.helper.Expressions)4 INFINITY (com.sri.ai.expresso.helper.Expressions.INFINITY)4 MINUS_INFINITY (com.sri.ai.expresso.helper.Expressions.MINUS_INFINITY)4 Expressions.apply (com.sri.ai.expresso.helper.Expressions.apply)4 Expressions.makeSymbol (com.sri.ai.expresso.helper.Expressions.makeSymbol)4 Context (com.sri.ai.grinder.sgdpllt.api.Context)4 ExpressionLiteralSplitterStepSolver (com.sri.ai.grinder.sgdpllt.api.ExpressionLiteralSplitterStepSolver)4 StepSolver (com.sri.ai.grinder.sgdpllt.api.StepSolver)4 TrueContext (com.sri.ai.grinder.sgdpllt.core.TrueContext)4 AbstractExpressionWithPropagatedLiteralsStepSolver (com.sri.ai.grinder.sgdpllt.core.solver.AbstractExpressionWithPropagatedLiteralsStepSolver)4 MaximumExpressionStepSolver (com.sri.ai.grinder.sgdpllt.helper.MaximumExpressionStepSolver)4 Equality (com.sri.ai.grinder.sgdpllt.library.Equality)4 FunctorConstants (com.sri.ai.grinder.sgdpllt.library.FunctorConstants)4 EQUALITY (com.sri.ai.grinder.sgdpllt.library.FunctorConstants.EQUALITY)4 GREATER_THAN (com.sri.ai.grinder.sgdpllt.library.FunctorConstants.GREATER_THAN)4