[petsc-users] lsqr usage

Barry Smith bsmith at mcs.anl.gov
Wed May 23 16:29:33 CDT 2012


  You cut and threw away the most important part of the error message. Where is the stack trace? Are we to guess where the error message was triggered? Please send the entire error message.

   Barry

On May 23, 2012, at 4:15 PM, Ildar Rakhmanov wrote:

> Hi, 
> I seems I am missing something. I want to use KSPLSQR.
> I set up lsqr.c (see attachment)
> it uses 3x2 matrix.
> 
> The results is
> 
> ildar at ildar:~/lsqr> ./lsqr 
> Matrix A after construction
> row 0: (0, 1)  (1, 0) 
> row 1: (0, 0)  (1, 1) 
> row 2: (0, 1)  (1, 1) 
> u 
> 1
> 1
> b 
> 0
> 0
> 0
> b 
> 1
> 1
> 2
> [0]PETSC ERROR: --------------------- Error Message ------------------------------------
> [0]PETSC ERROR: Invalid argument!
> [0]PETSC ERROR: Must be square matrix, rows 3 columns 2!
> [0]PETSC ERROR: ------------------------------------------------------------------------
> 
> 
> 
> Could any one point out how to correctly use LSQR solver?
> 
> <lsqr.c>



More information about the petsc-users mailing list