public class InterpolatingProverWithAssumptionsWrapper<T> extends BasicProverWithAssumptionsWrapper<T,InterpolatingProverEnvironment<T>> implements InterpolatingProverEnvironment<T>
BasicProverEnvironment.AllSatCallback<R>delegate, solverAssumptionsAsFormula| Constructor and Description |
|---|
InterpolatingProverWithAssumptionsWrapper(InterpolatingProverEnvironment<T> pDelegate,
FormulaManager pFmgr) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
clearAssumptions() |
BooleanFormula |
getInterpolant(List<T> pFormulasOfA)
Get an interpolant for two groups of formulas.
|
List<BooleanFormula> |
getSeqInterpolants(List<? extends Collection<T>> pPartitionedFormulas)
This method returns interpolants of an 'inductive sequence'.
|
List<BooleanFormula> |
getTreeInterpolants(List<? extends Collection<T>> pPartitionedFormulas,
int[] pStartOfSubTree)
Compute a sequence of interpolants.
|
protected void |
registerPushedFormula(T pPushResult)
overridden in sub-class.
|
addConstraint, allSat, close, getModel, getModelAssignments, getUnsatCore, isUnsat, isUnsatWithAssumptions, pop, push, unsatCoreOverAssumptionsclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitcheckTreeStructure, getSeqInterpolants0, getTreeInterpolants0, pushaddConstraint, allSat, close, getModel, getModelAssignments, getUnsatCore, isUnsat, isUnsatWithAssumptions, pop, push, unsatCoreOverAssumptionspublic InterpolatingProverWithAssumptionsWrapper(InterpolatingProverEnvironment<T> pDelegate, FormulaManager pFmgr)
public BooleanFormula getInterpolant(List<T> pFormulasOfA) throws SolverException, InterruptedException
InterpolatingProverEnvironmentBasicProverEnvironment.isUnsat() call that returned true.
There is no direct guarantee that the interpolants returned are part of an inductive sequence', however this seems to work for most (all?) solvers as long as the same proof is used, i.e. all interpolants are computed after the same SAT-check.
getInterpolant in interface InterpolatingProverEnvironment<T>pFormulasOfA - A list of values returned by InterpolatingProverEnvironment.push(BooleanFormula). All the
corresponding formulas from group A, the remaining formulas form group B.SolverException - if interpolant cannot be computed, for example because interpolation
procedure is incompleteInterruptedExceptionpublic List<BooleanFormula> getSeqInterpolants(List<? extends Collection<T>> pPartitionedFormulas) throws SolverException, InterruptedException
InterpolatingProverEnvironmentThe stack must contain exactly the partitioned formulas, but any order is allowed. For an input of N partitions we return N-1 interpolants.
getSeqInterpolants in interface InterpolatingProverEnvironment<T>AND(I_i, P_i)
=> I_(i+1) is satisfied for all i, where P_i is the conjunction of all formulas in
partition i.SolverException - if interpolant cannot be computed, for example because interpolation
procedure is incompleteInterruptedExceptionpublic List<BooleanFormula> getTreeInterpolants(List<? extends Collection<T>> pPartitionedFormulas, int[] pStartOfSubTree) throws SolverException, InterruptedException
InterpolatingProverEnvironmentExample:
A D | | B E | / C | F H | / G arrayIndex = [0,1,2,3,4,5,6,7] // only for demonstration, not needed partition = [A,B,D,E,C,F,H,G] // post-order of tree startOfSubTree = [0,0,2,2,0,0,6,0] // index of left-most leaf of the current element
getTreeInterpolants in interface InterpolatingProverEnvironment<T>pPartitionedFormulas - of formulaspStartOfSubTree - The start of the subtree containing the formula at this index as root.SolverException - if interpolant cannot be computed, for example because interpolation
procedure is incompleteInterruptedExceptionprotected void registerPushedFormula(T pPushResult)
BasicProverWithAssumptionsWrapperregisterPushedFormula in class BasicProverWithAssumptionsWrapper<T,InterpolatingProverEnvironment<T>>protected void clearAssumptions()
clearAssumptions in class BasicProverWithAssumptionsWrapper<T,InterpolatingProverEnvironment<T>>