unique-logic: Solve simple simultaneous equations
This is a package candidate release! Here you can preview how this package release will appear once published to the main package index (which can be accomplished via the 'maintain' link below). Please note that once a package has been published to the main package index it cannot be undone! Please consult the package uploading documentation for more information.
Solve a number of equations simultaneously. This is not Computer Algebra, better think of a kind of type inference algorithm or logic programming with only one allowed solution.
Only one solution is computed. Simultaneous equations with multiple solutions are not allowed. However, variables may remain undefined. We do not even check for consistency, since with floating point numbers even simple rules may not be consistent.
The modules ordered with respect to abstraction level are:
UniqueLogic.ST.System: Construct and solve sets of functional dependencies. Example:
assignment3 (+) a b c
meaning dependencya+b -> c
.UniqueLogic.ST.Rule: Combine functional dependencies to rules that can apply in multiple directions. Example:
add a b c
means relationa+b = c
which resolves to dependenciesa+b -> c, c-a -> b, c-b -> a
. For an executable example see UniqueLogic.ST.Example.Rule.UniqueLogic.ST.Expression: Allows to write rules using arithmetic operators. It creates temporary variables automatically. Example:
(a+b)*c =:= d
resolves toa+b = x, x*c = d
. For an executable example see UniqueLogic.ST.Example.Expression.UniqueLogic.ST.SystemLabel: Provides a new type for named variables. When creating a variable you decide whether and how an assignment to this variable shall be logged. There is an example that shows how to solve a logic system using symbolic expressions. The naming and logging allows us to observe shared intermediate results. For an executable example see UniqueLogic.ST.Example.Label.
UniqueLogic.ST.SystemLog, UniqueLogic.ST.RuleLog: These modules allow to log an assignment depending on the arguments to an assignment. This is more general than UniqueLogic.ST.SystemLabel which allows only dependencies on the result of an assignment.
The package is purely Haskell 98.
Properties
Versions | 0.2, 0.3, 0.3, 0.4, 0.4.0.1 |
---|---|
Change log | None available |
Dependencies | base (>=4 && <5), transformers (>=0.2 && <0.6), utility-ht (>=0.0.1 && <0.1) [details] |
License | BSD-3-Clause |
Author | Henning Thielemann |
Maintainer | Henning Thielemann <haskell@henning-thielemann.de> |
Category | Logic programming |
Home page | http://hub.darcs.net/thielema/unique-logic/ |
Source repo | this: darcs get http://hub.darcs.net/thielema/unique-logic/ --tag 0.3 head: darcs get http://hub.darcs.net/thielema/unique-logic/ |
Uploaded | by HenningThielemann at 2018-02-17T22:19:54Z |
Modules
[Index]
Downloads
- unique-logic-0.3.tar.gz [browse] (Cabal source package)
- Package description (as included in the package)
Maintainer's Corner
Package maintainers
For package maintainers and hackage trustees