Haskell Matrix Library...

Frederik Eaton frederik at a5.repetae.net
Fri Jun 24 22:49:47 EDT 2005

I haven't read this whole thread in detail, but the matlab/octave
thing has also been something of a concern of mine since I will
probably be doing a master's in machine learning next year.

However, I was just planning to spend a few weeks writing a embedded
domain specific language wrapper in Haskell for matlab/octave. Maybe
that's harder than I'd imagined it would be - but the problem with
writing a Haskell matrix library from scratch is that not only do you
lose a lot of the functionality which has already been implemented in
these programs, but you also lose all the work which has gone into
tuning them for speed. They support a wide variety of optimized
internal matrix representations which are transparent to the user,
special fast linear algebra operations on those matrices, etc. And for
the kind of applications that people use matlab and octave for, speed
and scalability tend to be important. So an arrangement where you keep
the optimized matlab kernel as a backend and just send it commands
would seem to be preferable.

Plus, with an EDSL you could improve the type system, index matrices
over arbitrary Enum-like types (which are translated to and from
integers), graft rudimentary tensor support into Octave, etc.

Maybe there would also be uses for a native Haskell matrix library but
my intuition is that something like what I described above would be
more useful to more people. Am I wrong?



More information about the Libraries mailing list