octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: sparse matrices


From: Andy Adler
Subject: Re: sparse matrices
Date: Tue, 13 Apr 2004 11:50:10 -0400 (EDT)

On Tue, 13 Apr 2004, Paul Thomas wrote:

> You are correct about the awkwardness of compressed column and
> compressed row formats.  It is not apparent to me that the extra
> compression over the coordinate ordered ( that doesn't sound like the
> right name) format;  ie
>
>                   a( i1 , j1 )        i1           j1
>                   a(i2  ,j2  )        i2           j2

This format doesn't solve the difficulties. If you wish to
extract an element a(3,5); you can't directly index the matrix,
but you will need to search to find if the element exists.
To make searching efficient, the elements should be stored sorted,
but that is an additional complexity every time the matrix is changed.

> I used SPARSEKIT2 by Yousef Saad, which has loads of conversion routines
> between different formats in it and all the basic arithmetic operations.
>  It is, however, written in F77.

SPARSEKIT2 info can be found here:
http://www-users.cs.umn.edu/~saad/software/SPARSKIT/sparskit.html

It contains many, but not all, of the needed utility functions.
It is licenced under the GPL, and contains a sparse math implementation
( http://www-users.cs.umn.edu/~saad/spmath/ ) which provides
a "Matlab-like" interface.

I haven't used this tool; but it does look useful.

andy



reply via email to

[Prev in Thread] Current Thread [Next in Thread]