[petsc-users] Krylov Method Takes Too Long to Solve
Jie Cheng
chengj5 at rpi.edu
Fri Apr 22 16:09:47 CDT 2016
Hi
I’m implementing finite element method on nonlinear solid mechanics. The main portion of my code that involves PETSc is that in each step, the tangent stiffness matrix A is formed and the increment of the nodal degrees of freedom is solved. Standard Newton’s iteration. The problem is: when I use Krylov methods to solve the linear system, the KSPsolve process takes too long, although only 2 or 3 iterations are needed.
The finite element formulation is the displacement/pressure mixed formulation, which I believe is symmetric and positive-definite. However if I pick conjugate gradient method with ICC preconditioned, PETSc gives me a -8 converged reason, which indicates a non-positive-definite matrix. After a couple of trials and errors, the only pair that works is GMRES plus PCKSP. But as I said, the KSPsolve function takes too much time.
A typical problem I’m trying has 16906 rows and 16906 cols. The message printed out by ksp_view is as following:
KSP Object: 1 MPI processes
type: gmres
GMRES: restart=30, using Classical (unmodified) Gram-Schmidt Orthogonalization with no iterative refinement
GMRES: happy breakdown tolerance 1e-30
maximum iterations=10000, initial guess is zero
tolerances: relative=1e-05, absolute=1e-50, divergence=10000
left preconditioning
using PRECONDITIONED norm type for convergence test
PC Object: 1 MPI processes
type: ksp
KSP and PC on KSP preconditioner follow
---------------------------------
KSP Object: (ksp_) 1 MPI processes
type: gmres
GMRES: restart=30, using Classical (unmodified) Gram-Schmidt Orthogonalization with no iterative refinement
GMRES: happy breakdown tolerance 1e-30
maximum iterations=10000, initial guess is zero
tolerances: relative=1e-05, absolute=1e-50, divergence=10000
left preconditioning
using PRECONDITIONED norm type for convergence test
PC Object: (ksp_) 1 MPI processes
type: ilu
ILU: out-of-place factorization
0 levels of fill
tolerance for zero pivot 2.22045e-14
matrix ordering: natural
factor fill ratio given 1, needed 1
Factored matrix follows:
Mat Object: 1 MPI processes
type: seqaij
rows=16906, cols=16906
package used to perform factorization: petsc
total: nonzeros=988540, allocated nonzeros=988540
total number of mallocs used during MatSetValues calls =0
using I-node routines: found 7582 nodes, limit used is 5
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=16906, cols=16906
total: nonzeros=988540, allocated nonzeros=988540
total number of mallocs used during MatSetValues calls =0
using I-node routines: found 7582 nodes, limit used is 5
---------------------------------
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=16906, cols=16906
total: nonzeros=988540, allocated nonzeros=988540
total number of mallocs used during MatSetValues calls =0
using I-node routines: found 7582 nodes, limit used is 5
Could anyone give me any suggestion please?
Thanks
Jie Cheng
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20160422/31c660fd/attachment.html>
More information about the petsc-users
mailing list