algorithm - Axiom resolution -


i try understand how axiom resolution works in prolog.

let's assume define 2 basic operations on natural numbers:

  • s(term) (stands successor) and

  • add(term, anotherterm).

the semantic of add given by

  • add (0, x1) -> x1

  • add (x1, 0) -> x1

  • add(s(x1), y1) -> s(add(x1, y1))

then, solve equation

add (x, add(y, z)) = s(0)

i imagine 1 strategy to

  • test if right hand side (rhs) of equation equal left hand side (lhs)

  • if not see if solution can find looking general unifier

  • if not try find axiom can used in equation. strategy doing job (for each axiom): try solve rhs of equation equals rhs of axiom. if there solution try solve lhs of equation equals lhs of axiom. if succeeds, have found right axiom.

  • eventually, if there no solution , lhs , rhs of equation same operation (i.e. same signature not same operands), apply algorithm on each operand , solution found if solution found each operand.

i think (simple) algorithm may work. however, know if has experience solving kind of problem? know can find documentation better algorithm?

thanks in advance

what looking called narrowing. implemented in functional-logic languages such curry, not in prolog itself.


Comments

Popular posts from this blog

asp.net - repeatedly call AddImageUrl(url) to assemble pdf document -

java - Android recognize cell phone with keyboard or not? -

iphone - How would you achieve a LED Scrolling effect? -