Marcin 'Qrczak' Kowalczyk wrote:
> Haskell's type system is powerful, but cannot express anything at
> compile time. Very dynamic domains must be represented as runtime
> objects, i.e. values. These values and elements of those domains have
> carefully designed types, because Haskell is statically typed and
> requires certain discipline in this respect, but types themselves
> are not sufficient to determine domains.
>
> This is an opposite approach than I presented in the previous mail.
> Classes are not the appropriate tool for modelling domains of a
> sufficiently advanced algebra system.
>
If I understand correctly, you propose a system where Domains are
record types, whose fields are functions corresponding to
operations in the Domain.
Maple uses this technique. There is a package called "Gauss"
which sets up domains in this manner. The documentation
indicates that it was inspired by Axiom (originally Scratchpad), so
that probably uses the same technique.
To be honest, I have always felt that this was a bit clumsy, and I
was hoping that Haskell would provide a more elegant solution,
though I am less sure of this now! However, I am only a naive user
both of CA packages and Haskell, so I cant offer any other
constructive criticisms.
Rob MacAulay
Rob MacAulay Vulcan Asic ___________
email : [EMAIL PROTECTED] \ |####/
http : www.vulcanasic.com \ |###/
Tel +[44] 1763 247624 (direct) \ |##/
Tel +[44] 1763 248163 (office) \ |#/
Fax +[44] 1763 241291 \|/