Just several notes and thoughts on the topic...

First of all, it was me, who write to Serge about DoCon (so, indirectly
facilitate this discussion).

"Language and Library are intermixed in the Axiom book".

In my opinion they are mixed not only in the book. When you tell about what
is the feature of library and what is the feature of language, what is the
criteria to separate? IMHO library features are implemented in "pure" SPAD
(i.e. without direct usage of lisp). Moreover, if you have "pure spad"
package (say, PkgA), but some derived package (PkgB) uses this package and
Lisp together, then PkgB is not the library - it is the feature of the
language (as it uses lisp directly). But in this case PkgA cannot be
extracted (excluded) from language as other part of language depends on it.
So even "pure" SPAD package become feature of the language, but not feature
of the library. (Such situation presents e.g. with Expression or Symbol or
both - I do not remember exactly at this moment). Consequently IMHO
separation of SPAD language and AXIOM library is not as straightforward as
it is desired (although in many places in the book this separation can be
done, of course).

"Haskell and SPAD language constructs"

In las month I've looked at FriCAS code and DoCon code. And read about both
and about Haskell. And thought about how to implement Axiom functionality
(some of it) in Haskell. Can it be mapped directly? And what issues would
airse if some one try.

Haskell98 (without extensions) - although it has parametrized types and
classes - has very poor support for types and classes parametrization (in
comparison with SPAD). Actually, when I read about related haskell
extensions, I found, that many of things required are implemented (such as
multiple type variables etc.), but even though they are present, there are
big discussion around those. Documentation tells, that those extensions
must be used with greate care as it can lead to many troubles. I wonder if
SPAD (and even more, Aldor - as in my opinion it is better - more
accurately - designed). May be Aldor and SPAD has the same problems, but
those are not disscussed as widely, as those languages has fewer useres...
is it right? or if Aldor and SPAD was able to overcome those troubles, the
the question is how?

Any way "pro" for SPAD is that it can join(...) domains and categories
reusing the implementation. In Haskell I did not find such an ability, so
you have to explicitly rewrite even obvious implementations (instances) of
type classes (or may be I do not know something about haskell in this
regard).

Haskell is "pure functional", so it do not allow for destructive updates
(monads are used instead). As so some FriCAS implementations cannot be
translated to Haskell directly. I do not thing, that it is the problem of
haskell... it is just it's feature, which make it different from SPAD.

Those two things (more flexible type parametrization in SPAD and
impossibility of destructive updates in Haskell) make it quite non trivial
task to map FriCAS implementation to Haskell one (and I even do not want to
thing about cases, when Lisp is used directly).

One more thing which is not so trivial in haskell is to make objects, which
both: contain some data and which are "callable" at the same time. I.g.
polynomials, which you can apply to argument (call) as P(x) and from which
you can take their coefficients from (as coeffs(P)). Of course it is
possible to combine function and data in one object in Haskell, but the
sintax will not be so nice and intuitive.

It should be mentioned though, that Haskell has it's own goodies (which are
not presented in SPAD), e.g. Algebraic constructors with ability to pattern
match them. Although it is always possible to manage without this feature,
but it makes the code more clean and clear.

But finally, for me Haskell is better then SPAD just for one reason. It
(and its general pupose libraries) are much more better supported and
maintained.

Recently, I was unable to compile working version of none: FriCAS,
Open-Axiom nor Axiom - running on fresh Ubuntu 11.10. Ok, now I think, that
the problem is GCC 4.6, which is default there. Either, I was unable to
compile FriCAS of version greater than 1.2 on cygwin (ok, I've compiled
1.3, but it did not operate normally). I understand, that there are no
people, who would support all those platforms. But from the point of view
of everage user it is unacceptable to spent several nights just to make the
system start (and possibly without success). Even aldor (in my opinion)
would not solve this problem as it is not maintained at this moment (as I
understand).

Finally, I would prefer to has Axiom library on Haskell (or some other
strongly-typed  mainstream language, e.g. F# or OCaml), but it seems to be
impossible... and this makes me upset :(         (yes, I know, that F# is
not open source, but in contrast with Aldor it is actively maintained and
promoted by Microsoft at this moment and its binaries are freely available
for commercial use, which gives hope, that it will be around for some time).

Dmitry.

-- 
You received this message because you are subscribed to the Google Groups 
"FriCAS - computer algebra system" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/fricas-devel?hl=en.

Reply via email to