(self)
return res
After a call to solve() yielding UNSAT, returns the unsat core as a
        dict of names to formulae
After a call to solve() yielding UNSAT, returns the unsat core as a
        dict of names to formulae
After a call to solve () yielding UNSAT returns the unsat core as a dict of names to formulae
def get_named_unsat_core(self):
        """After a call to solve() yielding UNSAT, returns the unsat core as a
        dict of names to formulae"""
        if self.options.unsat_cores_mode is None:
            raise SolverNotConfiguredForUnsatCoresError

        if self.last_result is not False:
            raise SolverStatusError("The last call to solve() was not" \
                                    " unsatisfiable")

        if self.last_command != "solve":
            raise SolverStatusError("The solver status has been modified by a" \
                                    " '%s' command after the last call to" \
                                    " solve()" % self.last_command)

        assumptions = self.z3.unsat_core()
        pysmt_assumptions = set(self.converter.back(t) for t in assumptions)

        res = {}
        n_ass_map = self._named_assertions_map()
        cnt = 0
        for key in pysmt_assumptions:
            if key in n_ass_map:
                (name, formula) = n_ass_map[key]
                if name is None:
                    name = "_a_%d" % cnt
                    cnt += 1
                res[name] = formula
        return res
def get_named_unsat_core ( self ) : if self . options . unsat_cores_mode is None : raise SolverNotConfiguredForUnsatCoresError if self . last_result is not False : raise SolverStatusError ( "The last call to solve() was not" " unsatisfiable" ) if self . last_command != "solve" : raise SolverStatusError ( "The solver status has been modified by a" " '%s' command after the last call to" " solve()" % self . last_command ) assumptions = self . z3 . unsat_core ( ) pysmt_assumptions = set ( self . converter . back ( t ) for t in assumptions ) res = { } n_ass_map = self . _named_assertions_map ( ) cnt = 0 for key in pysmt_assumptions : if key in n_ass_map : ( name , formula ) = n_ass_map [ key ] if name is None : name = "_a_%d" % cnt cnt += 1 res [ name ] = formula return res