# agum

Unification and Matching in an Abelian Group

Latest on Hackage: | 2.7 |

This package is not currently in any snapshots. If you're interested in using it, we recommend adding it to Stackage Nightly. Doing so will make builds more reliable, and allow stackage.org to host generated Haddocks.

GPL licensed

Maintained by

**ramsdell@mitre.org**This package contains a library for unification and matching in

an Abelian group and a program that exercises the library.

$ agum

Abelian group unification and matching -- :? for help

agum> 2x+y=3z

Problem: 2x + y = 3z

Unifier: [x : g0,y : -2g0 + 3g2,z : g2]

Matcher: [x : g0,y : -2g0 + 3z]

agum> 2x=x+y

Problem: 2x = x + y

Unifier: [x : g1,y : g1]

Matcher: no solution

agum> 64x-41y=a

Problem: 64x - 41y = a

Unifier: [a : 64g1 - 41g2,x : g1,y : g2]

Matcher: [x : -16a - 41g6,y : -25a - 64g6]

agum> :quit

an Abelian group and a program that exercises the library.

$ agum

Abelian group unification and matching -- :? for help

agum> 2x+y=3z

Problem: 2x + y = 3z

Unifier: [x : g0,y : -2g0 + 3g2,z : g2]

Matcher: [x : g0,y : -2g0 + 3z]

agum> 2x=x+y

Problem: 2x = x + y

Unifier: [x : g1,y : g1]

Matcher: no solution

agum> 64x-41y=a

Problem: 64x - 41y = a

Unifier: [a : 64g1 - 41g2,x : g1,y : g2]

Matcher: [x : -16a - 41g6,y : -25a - 64g6]

agum> :quit

## Changes

2018-01-06 John D. Ramsdell <ramsdell@mitre.org>

* src/Algebra/AbelianGroup/Main.hs (readM): Adapted the code to

work when Monad no longer has a fail method.

2015-04-27 John D. Ramsdell <ramsdell@mitre.org>

* src/Algebra/AbelianGroup/Main.hs (AnsErr): Added Functor and

Applicative instance so that the code compiles in GHC 7.10.

Thanks go to Douglas McClean.

* agum.cabal (Version): Released as version 2.6

2013-02-21 John D. Ramsdell <ramsdell@mitre.org>

* agum.cabal (Location): Added repository location.

* agum.cabal (Version): Released as version 2.5

2012-02-29 John D. Ramsdell <ramsdell@mitre.org>

* agum.cabal (Version): Released as version 2.4. Also,

constrained the containers package to be 0.3 or greater.

* src/Algebra/AbelianGroup/UnificationMatching.hs: Replaced

occurrences of Data.Map.foldWithKey by Data.Map.foldrWithKey as

the former has been deprecated.

2010-06-21 John D. Ramsdell <ramsdell@mitre.org>

* agum.cabal (Version): Released as version 2.3.

* agum.cabal (Build-Depends): changes dependency to

base >= 3 && <5, containers

2009-09-17 John D. Ramsdell <ramsdell@mitre.org>

* agum.cabal (Version): Released as version 2.2.

2009-09-14 John D. Ramsdell <ramsdell@.mitre.org>

* src/Algebra/AbelianGroup/IntLinEq.hs: Integer solutions to

linear equation solver was placed in its own module.

2009-09-13 John D. Ramsdell <ramsdell@mitre.org>

* src/Algebra/AbelianGroup/UnificationMatching.hs (unify): Changed

the result to be a substitution since unification always succeeds.

2009-09-05 John D. Ramsdell <ramsdell@mitre.org>

* src/Algebra/AbelianGroup/UnificationMatching.hs: Added

reference to Andrew Kennedy's Ph.D. thesis as it contains a proof

of correctness of the implemented matching algorithm.

* agum.cabal (Version): Released as version 2.1.

2009-08-29 John D. Ramsdell <ramsdell@mitre.org>

* src/Algebra/AbelianGroup/UnificationMatching.hs (Substitution,

apply): Hid the representation of a substitution and supplied a

function for applying a substitution to a term.

* agum.cabal (Version): Released as version 2.0.

* src/Algebra/AbelianGroup/Main.hs (readM): Adapted the code to

work when Monad no longer has a fail method.

2015-04-27 John D. Ramsdell <ramsdell@mitre.org>

* src/Algebra/AbelianGroup/Main.hs (AnsErr): Added Functor and

Applicative instance so that the code compiles in GHC 7.10.

Thanks go to Douglas McClean.

* agum.cabal (Version): Released as version 2.6

2013-02-21 John D. Ramsdell <ramsdell@mitre.org>

* agum.cabal (Location): Added repository location.

* agum.cabal (Version): Released as version 2.5

2012-02-29 John D. Ramsdell <ramsdell@mitre.org>

* agum.cabal (Version): Released as version 2.4. Also,

constrained the containers package to be 0.3 or greater.

* src/Algebra/AbelianGroup/UnificationMatching.hs: Replaced

occurrences of Data.Map.foldWithKey by Data.Map.foldrWithKey as

the former has been deprecated.

2010-06-21 John D. Ramsdell <ramsdell@mitre.org>

* agum.cabal (Version): Released as version 2.3.

* agum.cabal (Build-Depends): changes dependency to

base >= 3 && <5, containers

2009-09-17 John D. Ramsdell <ramsdell@mitre.org>

* agum.cabal (Version): Released as version 2.2.

2009-09-14 John D. Ramsdell <ramsdell@.mitre.org>

* src/Algebra/AbelianGroup/IntLinEq.hs: Integer solutions to

linear equation solver was placed in its own module.

2009-09-13 John D. Ramsdell <ramsdell@mitre.org>

* src/Algebra/AbelianGroup/UnificationMatching.hs (unify): Changed

the result to be a substitution since unification always succeeds.

2009-09-05 John D. Ramsdell <ramsdell@mitre.org>

* src/Algebra/AbelianGroup/UnificationMatching.hs: Added

reference to Andrew Kennedy's Ph.D. thesis as it contains a proof

of correctness of the implemented matching algorithm.

* agum.cabal (Version): Released as version 2.1.

2009-08-29 John D. Ramsdell <ramsdell@mitre.org>

* src/Algebra/AbelianGroup/UnificationMatching.hs (Substitution,

apply): Hid the representation of a substitution and supplied a

function for applying a substitution to a term.

* agum.cabal (Version): Released as version 2.0.

Depends on 2 packages:

Used by 1 package:

comments powered byDisqus

A service provided by
FP Complete