[Haskell-cafe] matrix computations based on the GSL

Henning Thielemann lemming at henning-thielemann.de
Fri Jul 8 09:54:20 EDT 2005


On Fri, 8 Jul 2005, Keean Schupke wrote:

> Henning Thielemann wrote:
>
> >My objections to making everything a matrix were the objections I sketched
> >for MatLab.
> >
> >The example, again: If you write some common expression like
> >
> >transpose x * a * x
>
> Which just goes to show why haskell limits the '*' operator to
> multiplying the same types. Keep this to Matrix-times-Matrix operators.

Btw. the interface file by Alberto gives you uniform usage of an operator
symbol (<>) while retaining full type safety by functional dependencies.

http://dis.um.es/~alberto/hmatrix/doc/LinearAlgebra.Interface.html

This is a good solution, I think.

> I feel using separate types for vectors and scalars just overcomplicates
> things...

I'm excited if your code gets swamped by conversions between Double and
Matrix then. I really plead for representing everything with strings, this
is the most simple and most flexible solution! :-]



More information about the Haskell-Cafe mailing list