edit: Prolog is the answer.
A:
I believe the type system of the Fortress Programming Language works in some way similar to what you describe. It uses an Object-Oriented Type System with Generic Traits to describe e.g. Algebraic Properties of Operators (like Associativity, Commutativity, Distributivity, Identity, Symmetry, One-Element, Zero-Element and so on). It needs to know all these in order to automatically distribute computations across nodes in a cluster.
Jörg W Mittag
2009-07-29 15:47:57
Ok this looks pretty good. It is obviously quite young though. I'll check it out.
Alex
2009-07-29 17:00:13
A:
Prolog is good for handling axioms. There is a open source object-oriented extension of prolog at sourceforge.net:
Larry Watanabe
2009-07-29 17:08:57