[petsc-users] reuse Mumps factorization for multiple RHS

Barry Smith bsmith at petsc.dev
Tue Aug 4 19:27:47 CDT 2020


  Yes, it automatically uses the same factorization.


> On Aug 4, 2020, at 6:55 PM, Anthony Paul Haas <aph at email.arizona.edu> wrote:
> 
> Hello,
> 
> When using Mumps to solve a linear system of equations (see below), can I reuse the factorization to solve for multiple RHS, ie, can I use KSPSolve multiple times while only building a different RHS in between the calls to KSPSolve?
> 
> Thanks,
> 
> Anthony
> 
> call KSPSetType(self%ksp,KSPPREONLY,self%ierr_ps)
> call KSPGetPC(self%ksp,pc,self%ierr_ps)
>                                                                                                                                                                                      
> call PCSetType(pc,PCLU,self%ierr_ps)
>                                                                                                                                                                                                
> call PCFactorSetMatSolverPackage(pc,MATSOLVERMUMPS,self%ierr_ps)
> call PCFactorSetUpMatSolverPackage(pc,self%ierr_ps)

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20200804/3f5ca41c/attachment.html>


More information about the petsc-users mailing list