Hi,

 

I need to compute the solution of least square regression for many times (> 
10^6) for large matrix A (>10^9x10^3). I use a hypercube basis, so each row of 
the matrix A has exactly one non-zero entry with value 1. On different runs, 
the positions of the 1 are different. I would like to reuse the sparse 
structure of A, what is the best way to do in this scenario?

 

I have heard of MatCreateMPIAIJWithSplitArrays, but it is kind of difficult to 
use. I try it a bit and seems like after creation if I need to change the 
column index, I need to skip the diagonal block. Also, I am not 100% sure, how 
to find which columns belong to the diagonal block for each process. But as 
mentioned, I need to run the regression million times, even it is difficult to 
use, I will try if it is fastest method.

 

Best,

Baron

 

Reply via email to