kodkod.engine.ucore
Class HybridStrategy

java.lang.Object
  extended by kodkod.engine.ucore.HybridStrategy
All Implemented Interfaces:
ReductionStrategy

public final class HybridStrategy
extends java.lang.Object
implements ReductionStrategy

A hybrid strategy for generating unsat cores that are minimal when mapped back onto the logic level. Specifically, let C be a core that is minimal according to this strategy, and let F(C) be the top-level logic constraints corresponding to C. Then, this strategy guarantees that there is no clause c in C such that F(C - c) is a strict subset of F(C). Note that this does not guarantee that F(C) itself is minimal. In other words, there could be an f in F(C) such that F(C) - f is unsatisfiable. To get a minimal logic core, use MinTopStrategy.

This strategy will work properly only on CNFs generated by the kodkod Translator.

Author:
Emina Torlak
See Also:
MinTopStrategy

Constructor Summary
HybridStrategy(TranslationLog log)
          Constructs a hybrid strategy that will use the given translation log to relate the cnf clauses back to the logic constraints from which they were generated.
 
Method Summary
 IntSet next(ResolutionTrace trace)
          Returns the next subtrace of the specified trace to be analyzed, given as a set of indices into the trace.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HybridStrategy

public HybridStrategy(TranslationLog log)
Constructs a hybrid strategy that will use the given translation log to relate the cnf clauses back to the logic constraints from which they were generated.

Method Detail

next

public IntSet next(ResolutionTrace trace)
Returns the next subtrace of the specified trace to be analyzed, given as a set of indices into the trace. If there are no more subtraces to be analyzed (i.e. the given trace is minimal according to the minimality measure used by this strategy), returns the empty set.

Specified by:
next in interface ReductionStrategy
Returns:
this.nexts'[#this.nexts-1]
See Also:
ReductionStrategy.next(kodkod.engine.satlab.ResolutionTrace)