From: Gunter Winkler (guwi17_at_[hidden])
Date: 2007-10-01 03:02:04
Am Montag, 1. Oktober 2007 05:07 schrieb choon:
> Actually, I will use sparse matrix M in both left and right hand
> mat-vec multiplication, so, storing M as column major will affect the
> performance of the other one. My application is a cutting-plane
> method, so it need to store some vectors (I am happy to describe this
> in more details, if necessary).
Ok, I see. So you get an additional vector on each iteration, right?
Maybe you should have a look at operation_sparse.hpp which contains
sparse_prod(). This is an optimized version of prod for multiplication
of two sparse matrices. In order to speed up the left and right
multiplication we have to specialize axpy_prod() for compressed_matrix
and compressed_vector. Unfortunately my time is quite limited, so I can
only help with comments.
> Could you please tell what do you mean by compressing dense vector
> into archive? Also, I am thinking of doing the operation with dense
> vector but keep the same vector in sparse format. Do you have any
> efficient way of doing that of it is just a sparse vector
> construction with dense vector as argument?
I just added my scatter/gather example on
Maybe this helps. The code is still experimental and ugly. Maybe you
find the time to optimize it. If it is really useful we should consider
to include it into uBLAS.