[petsc-users] Condition number of a matrix
    Jose E. Roman 
    jroman at dsic.upv.es
       
    Tue Mar  8 05:35:22 CST 2011
    
    
  
On 08/03/2011, Tim Kroeger wrote:
> Dear PETSc team,
> 
> Is there some possibility in PETSc to compute (an approximation to) the condition number of a matrix?  The matrix is a rank-1 modification of a sparse matrix, and I am anyway using SuperLU_Dist to compute a factorization of the matrix.  The matrix is about 70000 times 70000.
> 
> Best Regards,
> 
> Tim
> 
> -- 
> Dr. Tim Kroeger
> CeVis -- Center of Complex Systems and Visualization
> University of Bremen              tim.kroeger at cevis.uni-bremen.de
> Universitaetsallee 29             tim.kroeger at mevis.fraunhofer.de
> D-28359 Bremen                            Phone +49-421-218-59246
> Germany                                   Fax   +49-421-218-59277
You can compute the condition number as the ratio of the largest to the smallest singular value (or eigenvalue in case of symmetric matrices). With SLEPc you can compute either eigenvalues or singular values. Here is an example that computes the condition number: http://www.grycap.upv.es/slepc/documentation/current/src/examples/ex8.c.html
PETSc itself provides some tools for approximating the extreme singular values of the preconditioned operator, see KSPComputeExtremeSingularValues.
Jose
    
    
More information about the petsc-users
mailing list