Front page | perl.perl6.internals |
Postings from June 2002
Re: matrix design
Thread Previous
|
Thread Next
From:
Dan Sugalski
Date:
June 19, 2002 07:39
Subject:
Re: matrix design
Message ID:
a05111b04b9364631b26f@[63.120.19.221]
At 10:03 AM +0200 6/19/02, =?latin1?Q?Josef_H=F6=F6k?= wrote:
>Ok now what do you think of representing matrices as below:
Yech! :)
On the other hand, since the matrix is an atomic data type, it's
perfectly fine to have any sort of internals you want, since it'll
all be hidden. Which means that even if the implementation is
abysmal, we can replace it later.
It might be best to start with a dense matrix (where you allocate
enough memory to hold all the potential elements of the matrix in one
big chunk, hung off a Buffer) and later on implement a sparse matrix,
as those are more complex.
If you're going to do this, I'd *also* strongly recommend you get in
touch with the perl PDL folks first, and tap their experience.
Whatever you do, *start small*! Seriously. Get a plain
multidimensional array working first, then go up from there.
--
Dan
--------------------------------------"it's like this"-------------------
Dan Sugalski even samurai
dan@sidhe.org have teddy bears and even
teddy bears get drunk
Thread Previous
|
Thread Next