API for clojure.core.unify - Unification library 0.5.8 (in development)

by Michael Fogus

Full namespace name: clojure.core.unify

Overview

A unification library for Clojure.

Public Variables and Functions



extract-lvars

function
Usage: (extract-lvars form)
       (extract-lvars lv-fn form)
Takes a datastructure and returns a distinct set of the logical
variables found within.

    
    
    Source
  


flatten-bindings

function
Usage: (flatten-bindings binds)
       (flatten-bindings variable? binds)
Flattens recursive bindings in the given map to the same ground (if possible).

    
    
    Source
  


make-occurs-subst-fn

function
Usage: (make-occurs-subst-fn variable-fn)
Given a function to recognize unification variables, returns a function that
will attempt to substitute unification bindings between two expressions.
This function uses an 'occurs check' methodology for detecting cycles.

    
    
    Source
  


make-occurs-unifier-fn

function
Usage: (make-occurs-unifier-fn variable-fn)
Given a function to recognize unification variables, returns a function to
perform the unification of two expressions. This function uses an 'occurs check'
methodology for detecting cycles.

    
    
    Source
  


make-occurs-unify-fn

function
Usage: (make-occurs-unify-fn variable-fn)
Given a function to recognize unification variables, returns a function to
return a bindings map for two expressions.  This function uses an 'occurs check'
methodology for detecting cycles.

    
    
    Source
  


make-subst-fn

function
Usage: (make-subst-fn variable-fn)
Given a function to recognize unification variables, returns a function that
will attempt to substitute unification bindings between two expressions.

    
    
    Source
  


make-unifier-fn

function
Usage: (make-unifier-fn variable-fn)
Given a function to recognize unification variables, returns a function to
perform the unification of two expressions.

    
    
    Source
  


make-unify-fn

function
Usage: (make-unify-fn variable-fn)
Given a function to recognize unification variables, returns a function to
return a bindings map for two expressions.

    
    
    Source
  


subst

function
Usage: (subst expression bindings)
Attempts to substitute the bindings in the appropriate locations in the given expression.

    
    
    Source
  


unifier

function
Usage: (unifier expression1 expression2)
Attempts the entire unification process from garnering the bindings to substituting
the appropriate bindings.  Note: This function is implemented with an occurs-check.

    
    
    Source
  


unifier-

function
Usage: (unifier- expression1 expression2)
Attempts the entire unification process from garnering the bindings to substituting
the appropriate bindings.  Note: This function is implemented **without** an occurs-check.

    
    
    Source
  


unify

function
Usage: (unify expression1 expression2)
Attempt to unify x and y with the given bindings (if any). Potentially returns a map of the 
unifiers (bindings) found.  Will throw an `IllegalStateException` if the expressions
contain a cycle relationship.  Will also throw an `IllegalArgumentException` if the
sub-expressions clash.  Note: This function is implemented with an occurs-check.

    
    
    Source
  


unify-

function
Usage: (unify- expression1 expression2)
Attempt to unify x and y with the given bindings (if any). Potentially returns a map of the 
unifiers (bindings) found.  Will throw an `IllegalStateException` if the expressions
contain a cycle relationship.  Will also throw an `IllegalArgumentException` if the
sub-expressions clash.  Note: This function is implemented **without** an occurs-check.

    
    
    Source
  
Logo & site design by Tom Hickey.
Clojure auto-documentation system by Tom Faulhaber.