Hi Toby, The first thing I did was to run my code to check for correctness on a matrix of size 202x200. It gave me, what looked to be, the singular values i was expecting on that matrix. The code ran extremely quickly on this size of matrix. I suppose could keep generating larger and larger fake matrices until I get stuck but not too stuck. But at some point I think I will have to solve this specific problem.
Theoretically I might be able to work around this problem by creating the transpose of my matrix when I read in my original matrix from several files. (I could just create another matrix and do another call to MatSetValue w/ the row and column values switched.) This would just require hacking some code in SLEPc but it seems possible. And my very very naive way of loading the data into the matrix only takes about an hour or so which is substantially better than the times that I'm seeing. However, I am wondering if there is something I'm doing that is really wrong in some way. I am trying to dig through the transpose code to understand but any input anyone can give me would be great. Sarah On Jul 14, 2008, at 2:21 PM, Toby D. Young wrote: > > >> I'll start out by saying I'm a new user to PETSc. I'm actually using >> SLEPc > > Me too. :-) > >> I have a very large, very sparse matrix with dimensions on the order >> of 3 million by 1 million. I created my matrix using MatCreateMPIAIJ >> and it seems to be evenly distributed across my machines. I've hit a >> bottleneck when running some code to compute the SVD of the matrix >> and the bottleneck seems to be using the MatTranspose operation on my >> matrix. > > I can not directly help you with your questions Sarah, sorry. Out of > sheer academic interest in your problem (I had a similar problem > once and > found a work-around): Have you tried to run your code for very small > matrices (say, 300x100)? Just to check that the bottleneck problem > is in > fact not something else! > > Transposing a HUGE matrix such as the one you have is an expensive > operation in anyone's book. As far as I know, PETSc does not store > zero-components of a matrix but uses a sparsity pattern to "remember" > them... (Someone please correct me if I am wrong). > > Hope that is somehow helpful for you. > > Best, > Toby > > > ----- > > Toby D. Young - Adiunkt (Assistant Professor) > Department of Computational Science > Institute of Fundamental Technological Research > Polish Academy of Sciences > Room 206, ul. Swietokrzyska 21 > 00-049 Warszawa, Polska > > +48 22 826 12 81 ext. 184 > http://rav.ippt.gov.pl/~tyoung
