Re: [petsc-users] Preconditioner for LSQR

2022-03-01 Thread Jose E. Roman
To: Pierre Jolivet > Cc: Lucas Banting ; petsc-users@mcs.anl.gov > > Subject: Re: [petsc-users] Preconditioner for LSQR > > Caution: This message was sent from outside the University of Manitoba. > > > To use SLEPc's TSQR one would do something like this: > > i

Re: [petsc-users] Preconditioner for LSQR

2022-03-01 Thread Lucas Banting
the resulting solution to produce the next right hand side vector. Thanks again, Lucas From: Jose E. Roman Sent: Tuesday, March 1, 2022 4:49 AM To: Pierre Jolivet Cc: Lucas Banting ; petsc-users@mcs.anl.gov Subject: Re: [petsc-users] Preconditioner for LSQR

Re: [petsc-users] Preconditioner for LSQR

2022-03-01 Thread Jose E. Roman
To use SLEPc's TSQR one would do something like this: ierr = BVCreateFromMat(A,);CHKERRQ(ierr); ierr = BVSetFromOptions(X);CHKERRQ(ierr); ierr = BVSetOrthogonalization(X,BV_ORTHOG_CGS,BV_ORTHOG_REFINE_IFNEEDED,PETSC_DEFAULT,BV_ORTHOG_BLOCK_TSQR);CHKERRQ(ierr); ierr =

Re: [petsc-users] Preconditioner for LSQR

2022-02-28 Thread Pierre Jolivet
Hello Lucas, In your sequence of systems, is A changing? Are all right-hand sides available from the get-go? In that case, you can solve everything in a block fashion and that’s how you could get real improvements. Also, instead of PCCHOLESKY on A^T * A + KSPCG, you could use PCQR on A +

Re: [petsc-users] Preconditioner for LSQR

2022-02-28 Thread Jed Brown
This is a small problem for which direct Householder QR may be fast enough (depending on the rest of your application). For multi-node, you can use TSQR (backward stable like Householder) or Cholesky (unstable). julia> A = rand(20, 200); julia> @time Q, R = qr(A); 0.866989 seconds (14

Re: [petsc-users] Preconditioner for LSQR

2022-02-28 Thread Matthew Knepley
On Mon, Feb 28, 2022 at 6:54 PM Lucas Banting wrote: > Hello, > > I have an MPIDENSE matrix of size about 200,000 x 200, using KSPLSQR on my > machine a solution takes about 15 s. I typically run with six to eight > processors. > I have to solve the system several times, typically 4-30, and was

[petsc-users] Preconditioner for LSQR

2022-02-28 Thread Lucas Banting
Hello, I have an MPIDENSE matrix of size about 200,000 x 200, using KSPLSQR on my machine a solution takes about 15 s. I typically run with six to eight processors. I have to solve the system several times, typically 4-30, and was looking for recommendations on reusable preconditioners to use