unification 0.1.3

  • README.md
  • Changelog.md
  • Example
  • Installing
  • Versions
  • 50


Unification is an implementation of logical first-order unification.

A first-order unification procedure unify is given by this library. It can be applied on two terms of type Termtype that are also given by the library.

The solution of a unification problem is a substitution, that is, a mapping assigning a symbolic value to each variable of the problem's expressions.

The unification procedure reports unsolvability for a given problem or computes the complete and minimal substitution set containing the most general unifier. This is a set covering all solutions containing no redundant members.


import "package:tailcalls/tailcalls.dart";
import "package:unification/unification.dart";

var test = unify(
      new List()
          new Tupl(
            new Term("b0", [new Term("b1", []),new Term("b2", [])]),
            new Term("b0", [new Term("b1", []),new Term("b2", [])]),
var mgu = test;

Read more about unification in logic on Wikipedia.



  • Initial release.


  • Updated to use Dart 2.1.0
  • Added Examples


  • Fixed dependencies.


  • Fixed some minor issues discovered by pana.


  • term data structures into separate file.
  • improved comments and docs.


import '../lib/unification.dart';
import 'dart:collection';

void main() {

  var res1 = unify(
        new Tupl(
          new Var("a"),

  var res2 = unify(
        new Tupl(
          new Var("a"),
          new Var("b"),

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:

  unification: ^0.1.3

2. Install it

You can install packages from the command line:

with pub:

$ pub get

with Flutter:

$ flutter packages get

Alternatively, your editor might support pub get or flutter packages get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:

import 'package:unification/unification.dart';
Version Uploaded Documentation Archive
0.1.3 Oct 18, 2018 Go to the documentation of unification 0.1.3 Download unification 0.1.3 archive
0.1.2 Sep 29, 2018 Go to the documentation of unification 0.1.2 Download unification 0.1.2 archive
0.1.1 Sep 28, 2018 Go to the documentation of unification 0.1.1 Download unification 0.1.1 archive
0.1.0 Sep 28, 2018 Go to the documentation of unification 0.1.0 Download unification 0.1.0 archive
0.0.1+2 Sep 28, 2018 Go to the documentation of unification 0.0.1+2 Download unification 0.0.1+2 archive
0.0.1+1 Dec 16, 2017 Go to the documentation of unification 0.0.1+1 Download unification 0.0.1+1 archive
0.0.1 Dec 16, 2017 Go to the documentation of unification 0.0.1 Download unification 0.0.1 archive
Describes how popular the package is relative to other packages. [more]
Code health derived from static analysis. [more]
Reflects how tidy and up-to-date the package is. [more]
Weighted score of the above. [more]
Learn more about scoring.

We analyzed this package on Dec 5, 2018, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.1.0
  • pana: 0.12.7


Detected platforms: Flutter, web, other

No platform restriction found in primary library package:unification/unification.dart.

Health suggestions

Format bin/main.dart.

Run dartfmt to format bin/main.dart.

Format bin/main2.dart.

Run dartfmt to format bin/main2.dart.

Format bin/main3.dart.

Run dartfmt to format bin/main3.dart.


Package Constraint Resolved Available
Direct dependencies
Dart SDK >=1.8.0 <= 3.0.0
tailcalls ^0.1.1 0.1.1
Dev dependencies
test any