def backward(rules, query, *pmode): global known, kbase # avoid extra args kbase = rules known = Index().init([(['true'],['true'])]) try: for proof in AND(query, [], [(None, (None, {}))], 0): topenv = proof[0][1][1] report(kbase, topenv, query, pmode, proof[1:]) print 'no (more) solutions [backwrd7.py]' except stop_proof: pass
def backward(rules, query, *pmode): global known, kbase # avoid extra args backwrd1.kbase = rules # for rule browsing known, kbase = [['true']], rules # local to module try: for proof in AND(query, [], [(None, (None, {}))], 0): topenv = proof[0][1][1] report(topenv, query, pmode, proof[1:]) print 'no (more) solutions [backwrd7.py]' except stop_proof: pass
def backward(rules, query, *pmode): global known, kbase # avoid extra args kbase = rules known = Index().init([(['true'], ['true'])]) try: for proof in AND(query, [], [(None, (None, {}))], 0): topenv = proof[0][1][1] report(kbase, topenv, query, pmode, proof[1:]) print 'no (more) solutions [backwrd7.py]' except stop_proof: pass