[petsc-users] Slepc SVDCyclicSetExplicitMatrix does not prealloc memory?

Gong Ding gdiso at ustc.edu
Fri Apr 1 03:45:00 CDT 2011


> On 01/04/2011, Gong Ding wrote:
> 
> 
> 
> > Hi,
> 
> > I am stiall dealing with the ill conditioned problem. :-(
> 
> > Yesderday, I installed slepc-3.1-p6 for SVD calculation of my matrix.
> 
> > 
> 
> > The SVD solver works well for the largest singualr value calculation.
> 
> > But for the smallest singualr value, all most all the methods fail.
> 
> > 
> 
> > Finally, I chosen the most inefficient way. 
> 
> > That build the cyclic matrix explicitly with 
> 
> > shift-and-invert spectral transformation.
> 
> > And solve the eigen value problem by LU preconditioned GMRES.
> 
> > The preconditioner should be superlu rather than others.
> 
> > I guess the reason is superlu use static pivot. 
> 
> > Because solver with partial pivot such as mumps can not work.
> 
> > Anyway, slepc solved my problem. 
> 
> > 
> 
> > However, the explicit building cyclic matrix takes too long to finish.
> 
> > The log info says 
> 
> > 
> 
> > [0] MatSetUpPreallocation(): Warning not preallocating matrix storage
> 
> > [0] MatAssemblyEnd_SeqAIJ(): Matrix size: 35038 X 35038; storage space: 325302 unneeded,482948 used
> 
> > [0] MatAssemblyEnd_SeqAIJ(): Number of mallocs during MatSetValues() is 42204
> 
> > [0] MatAssemblyEnd_SeqAIJ(): Maximum nonzeros in any row is 33
> 
> > [0] Mat_CheckInode(): Found 26800 nodes of 35038. Limit used: 5. Using Inode routines
> 
> > 
> 
> > It seems no preallocation for cyclic matrix. Is it a bug or I forgot something?
> 
> > 
> 
> 
> 
> Yes, you are right. No preallocation is done in this case within SLEPc. This is a problem also in SLEPc's QEPLINEAR. This is pending, my intention is to get it fixed for the next release.
> 

Hope the problem can be solved soon.
And do you have some comment on how to solve the smallest singular value?
I guess i am not on the right way since matlab (with arpack) can calculate smallest singular value.
But I never make arpack work. 
Even for smallest eigen value problem, arpack report no eigen value are found.    





More information about the petsc-users mailing list