Hi all,
We develop a CFD code using the PETSc library that solves the Navier-Stokes
equations using the fractional-step method from Perot (1993).
At each time-step, we solve two systems: one for the velocity field, the
other, a Poisson system, for the pressure field.
One of our test-cases is a 2D lid-driven cavity flow (Re=100) on a 20x20
grid using 1 or 2 procs.
For the Poisson system, we usually use CG preconditioned with GAMG.
So far, we have been using PETSc-3.5.4, and we would like to update the
code with the latest release: 3.7.4.
As suggested in the changelog of 3.6, we replaced the routine
`KSPSetNullSpace()` with `MatSetNullSpace()`.
Here is the list of options we use to configure the two solvers:
* Velocity solver: prefix `-velocity_`
-velocity_ksp_type bcgs
-velocity_ksp_rtol 1.0E-08
-velocity_ksp_atol 0.0
-velocity_ksp_max_it 10000
-velocity_pc_type jacobi
-velocity_ksp_view
-velocity_ksp_monitor_true_residual
-velocity_ksp_converged_reason
* Poisson solver: prefix `-poisson_`
-poisson_ksp_type cg
-poisson_ksp_rtol 1.0E-08
-poisson_ksp_atol 0.0
-poisson_ksp_max_it 20000
-poisson_pc_type gamg
-poisson_pc_gamg_type agg
-poisson_pc_gamg_agg_nsmooths 1
-poissonksp_view
-poisson_ksp_monitor_true_residual
-poisson_ksp_converged_reason
With 3.5.4, the case runs normally on 1 or 2 procs.
With 3.7.4, the case runs normally on 1 proc but not on 2.
Why? The Poisson solver diverges because of an indefinite preconditioner
(only with 2 procs).
We also saw that the routine `MatSetNullSpace()` was already available in
3.5.4.
With 3.5.4, replacing `KSPSetNullSpace()` with `MatSetNullSpace()` led to
the Poisson solver diverging because of an indefinite matrix (on 1 and 2
procs).
Thus, we were wondering if we needed to update something else for the KSP,
and not just modifying the name of the routine?
I have attached the output files from the different cases:
* `run-petsc-3.5.4-n1.log` (3.5.4, `KSPSetNullSpace()`, n=1)
* `run-petsc-3.5.4-n2.log`
* `run-petsc-3.5.4-nsp-n1.log` (3.5.4, `MatSetNullSpace()`, n=1)
* `run-petsc-3.5.4-nsp-n2.log`
* `run-petsc-3.7.4-n1.log` (3.7.4, `MatSetNullSpace()`, n=1)
* `run-petsc-3.7.4-n2.log`
Thank you for your help,
Olivier
======================
*** PetIBM - Start ***
======================
directory: ./
Parsing file .//cartesianMesh.yaml... done.
Parsing file .//flowDescription.yaml... done.
Parsing file .//simulationParameters.yaml... done.
---------------------------------------
Cartesian grid
---------------------------------------
number of cells: 20 x 20
---------------------------------------
---------------------------------------
Flow
---------------------------------------
dimensions: 2
viscosity: 0.01
initial velocity field:
0
0
boundary conditions (component, type, value):
->location: xMinus (left)
0 DIRICHLET 0
1 DIRICHLET 0
->location: xPlus (right)
0 DIRICHLET 0
1 DIRICHLET 0
->location: yMinus (bottom)
0 DIRICHLET 0
1 DIRICHLET 0
->location: yPlus (top)
0 DIRICHLET 1
1 DIRICHLET 0
---------------------------------------
---------------------------------------
Time-stepping
---------------------------------------
formulation: Navier-Stokes solver (Perot, 1993)
convection: Euler-explicit
diffusion: Euler-implicit
time-increment: 0.0005
starting time-step: 0
number of time-steps: 1
saving-interval: 1
---------------------------------------
----------------------------------------
KSP info: Velocity system
----------------------------------------
KSP Object:(velocity_) 1 MPI processes
type: bcgs
maximum iterations=10000
tolerances: relative=1e-08, absolute=0, divergence=10000
left preconditioning
using nonzero initial guess
using DEFAULT norm type for convergence test
PC Object:(velocity_) 1 MPI processes
type: jacobi
PC has not been set up so information may be incomplete
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=760, cols=760
total: nonzeros=3644, allocated nonzeros=3644
total number of mallocs used during MatSetValues calls =0
not using I-node routines
----------------------------------------
KSP info: Poisson system
----------------------------------------
KSP Object:(poisson_) 1 MPI processes
type: cg
maximum iterations=20000
tolerances: relative=1e-08, absolute=0, divergence=10000
left preconditioning
using nonzero initial guess
using DEFAULT norm type for convergence test
PC Object:(poisson_) 1 MPI processes
type: gamg
PC has not been set up so information may be incomplete
MG: type is MULTIPLICATIVE, levels=0 cycles=unknown
Cycles per PCApply=0
Using Galerkin computed coarse grid matrices
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
not using I-node routines
[time-step 0] Writing grid into file... done.
Residual norms for velocity_ solve.
0 KSP preconditioned resid norm 1.148589971947e-03 true resid norm 2.324746103222e+00 ||r(i)||/||b|| 1.000000000000e+00
1 KSP preconditioned resid norm 8.875846864181e-09 true resid norm 1.793849713607e-05 ||r(i)||/||b|| 7.716325284387e-06
2 KSP preconditioned resid norm 1.418061760018e-13 true resid norm 2.860743141913e-10 ||r(i)||/||b|| 1.230561538720e-10
Linear solve converged due to CONVERGED_RTOL iterations 2
KSP Object:(velocity_) 1 MPI processes
type: bcgs
maximum iterations=10000
tolerances: relative=1e-08, absolute=0, divergence=10000
left preconditioning
using nonzero initial guess
using PRECONDITIONED norm type for convergence test
PC Object:(velocity_) 1 MPI processes
type: jacobi
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=760, cols=760
total: nonzeros=3644, allocated nonzeros=3644
total number of mallocs used during MatSetValues calls =0
not using I-node routines
Residual norms for poisson_ solve.
0 KSP preconditioned resid norm 3.484842547039e+00 true resid norm 3.733946078026e-04 ||r(i)||/||b|| 1.000000000000e+00
1 KSP preconditioned resid norm 1.811253169494e-01 true resid norm 7.228442792139e-05 ||r(i)||/||b|| 1.935872302677e-01
2 KSP preconditioned resid norm 1.542623996402e-02 true resid norm 6.271495204198e-06 ||r(i)||/||b|| 1.679589119164e-02
3 KSP preconditioned resid norm 1.141587944457e-03 true resid norm 5.550316489102e-07 ||r(i)||/||b|| 1.486447948931e-03
4 KSP preconditioned resid norm 8.344808297999e-05 true resid norm 4.646241002647e-08 ||r(i)||/||b|| 1.244324611432e-04
5 KSP preconditioned resid norm 3.385646578103e-06 true resid norm 3.291969709661e-09 ||r(i)||/||b|| 8.816329001197e-06
6 KSP preconditioned resid norm 2.094925660940e-07 true resid norm 2.180458891396e-10 ||r(i)||/||b|| 5.839556452698e-07
7 KSP preconditioned resid norm 1.337344815377e-08 true resid norm 1.309021292118e-11 ||r(i)||/||b|| 3.505731643586e-08
Linear solve converged due to CONVERGED_RTOL iterations 7
KSP Object:(poisson_) 1 MPI processes
type: cg
maximum iterations=20000
tolerances: relative=1e-08, absolute=0, divergence=10000
left preconditioning
has attached null space
using nonzero initial guess
using PRECONDITIONED norm type for convergence test
PC Object:(poisson_) 1 MPI processes
type: gamg
MG: type is MULTIPLICATIVE, levels=2 cycles=v
Cycles per PCApply=1
Using Galerkin computed coarse grid matrices
Coarse grid solver -- level -------------------------------
KSP Object: (poisson_mg_coarse_) 1 MPI processes
type: preonly
maximum iterations=1, initial guess is zero
tolerances: relative=1e-05, absolute=1e-50, divergence=10000
left preconditioning
using NONE norm type for convergence test
PC Object: (poisson_mg_coarse_) 1 MPI processes
type: bjacobi
block Jacobi: number of blocks = 1
Local solve is same for all blocks, in the following KSP and PC objects:
KSP Object: (poisson_mg_coarse_sub_) 1 MPI processes
type: preonly
maximum iterations=1, initial guess is zero
tolerances: relative=1e-05, absolute=1e-50, divergence=10000
left preconditioning
using NONE norm type for convergence test
PC Object: (poisson_mg_coarse_sub_) 1 MPI processes
type: lu
LU: out-of-place factorization
tolerance for zero pivot 2.22045e-14
using diagonal shift on blocks to prevent zero pivot [INBLOCKS]
matrix ordering: nd
factor fill ratio given 5, needed 2.36496
Factored matrix follows:
Mat Object: 1 MPI processes
type: seqaij
rows=60, cols=60
package used to perform factorization: petsc
total: nonzeros=1296, allocated nonzeros=1296
total number of mallocs used during MatSetValues calls =0
not using I-node routines
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=60, cols=60
total: nonzeros=548, allocated nonzeros=548
total number of mallocs used during MatSetValues calls =0
not using I-node routines
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=60, cols=60
total: nonzeros=548, allocated nonzeros=548
total number of mallocs used during MatSetValues calls =0
not using I-node routines
Down solver (pre-smoother) on level 1 -------------------------------
KSP Object: (poisson_mg_levels_1_) 1 MPI processes
type: chebyshev
Chebyshev: eigenvalue estimates: min = 0.0993375, max = 2.08609
maximum iterations=2
tolerances: relative=1e-05, absolute=1e-50, divergence=10000
left preconditioning
using nonzero initial guess
using NONE norm type for convergence test
PC Object: (poisson_mg_levels_1_) 1 MPI processes
type: sor
SOR: type = local_symmetric, iterations = 1, local iterations = 1, omega = 1
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
not using I-node routines
Up solver (post-smoother) same as down solver (pre-smoother)
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
not using I-node routines
[time-step 1] Writing fluxes into file... done.
[time-step 1] Writing pressure into file... done.
=====================
*** PetIBM - Done ***
=====================
#PETSc Option Table entries:
-options_left
-poisson_ksp_atol 0.0
-poisson_ksp_converged_reason
-poisson_ksp_max_it 20000
-poisson_ksp_monitor_true_residual
-poisson_ksp_rtol 1.0E-08
-poisson_ksp_type cg
-poisson_ksp_view
-poisson_pc_gamg_agg_nsmooths 1
-poisson_pc_gamg_type agg
-poisson_pc_type gamg
-velocity_ksp_atol 0.0
-velocity_ksp_converged_reason
-velocity_ksp_max_it 10000
-velocity_ksp_monitor_true_residual
-velocity_ksp_rtol 1.0E-08
-velocity_ksp_type bcgs
-velocity_ksp_view
-velocity_pc_type jacobi
#End of PETSc Option Table entries
There are no unused options.
======================
*** PetIBM - Start ***
======================
directory: ./
Parsing file .//cartesianMesh.yaml... done.
Parsing file .//flowDescription.yaml... done.
Parsing file .//simulationParameters.yaml... done.
---------------------------------------
Cartesian grid
---------------------------------------
number of cells: 20 x 20
---------------------------------------
---------------------------------------
Flow
---------------------------------------
dimensions: 2
viscosity: 0.01
initial velocity field:
0
0
boundary conditions (component, type, value):
->location: xMinus (left)
0 DIRICHLET 0
1 DIRICHLET 0
->location: xPlus (right)
0 DIRICHLET 0
1 DIRICHLET 0
->location: yMinus (bottom)
0 DIRICHLET 0
1 DIRICHLET 0
->location: yPlus (top)
0 DIRICHLET 1
1 DIRICHLET 0
---------------------------------------
---------------------------------------
Time-stepping
---------------------------------------
formulation: Navier-Stokes solver (Perot, 1993)
convection: Euler-explicit
diffusion: Euler-implicit
time-increment: 0.0005
starting time-step: 0
number of time-steps: 1
saving-interval: 1
---------------------------------------
----------------------------------------
KSP info: Velocity system
----------------------------------------
KSP Object:(velocity_) 2 MPI processes
type: bcgs
maximum iterations=10000
tolerances: relative=1e-08, absolute=0, divergence=10000
left preconditioning
using nonzero initial guess
using DEFAULT norm type for convergence test
PC Object:(velocity_) 2 MPI processes
type: jacobi
PC has not been set up so information may be incomplete
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=760, cols=760
total: nonzeros=3644, allocated nonzeros=3800
total number of mallocs used during MatSetValues calls =0
not using I-node (on process 0) routines
----------------------------------------
KSP info: Poisson system
----------------------------------------
KSP Object:(poisson_) 2 MPI processes
type: cg
maximum iterations=20000
tolerances: relative=1e-08, absolute=0, divergence=10000
left preconditioning
using nonzero initial guess
using DEFAULT norm type for convergence test
PC Object:(poisson_) 2 MPI processes
type: gamg
PC has not been set up so information may be incomplete
MG: type is MULTIPLICATIVE, levels=0 cycles=unknown
Cycles per PCApply=0
Using Galerkin computed coarse grid matrices
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
not using I-node (on process 0) routines
[time-step 0] Writing grid into file... done.
Residual norms for velocity_ solve.
0 KSP preconditioned resid norm 1.148589971947e-03 true resid norm 2.324746103222e+00 ||r(i)||/||b|| 1.000000000000e+00
1 KSP preconditioned resid norm 8.875846864181e-09 true resid norm 1.793849713607e-05 ||r(i)||/||b|| 7.716325284387e-06
2 KSP preconditioned resid norm 1.418061760018e-13 true resid norm 2.860743141913e-10 ||r(i)||/||b|| 1.230561538720e-10
Linear solve converged due to CONVERGED_RTOL iterations 2
KSP Object:(velocity_) 2 MPI processes
type: bcgs
maximum iterations=10000
tolerances: relative=1e-08, absolute=0, divergence=10000
left preconditioning
using nonzero initial guess
using PRECONDITIONED norm type for convergence test
PC Object:(velocity_) 2 MPI processes
type: jacobi
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=760, cols=760
total: nonzeros=3644, allocated nonzeros=3800
total number of mallocs used during MatSetValues calls =0
not using I-node (on process 0) routines
Residual norms for poisson_ solve.
0 KSP preconditioned resid norm 3.540871046457e+00 true resid norm 3.733946078026e-04 ||r(i)||/||b|| 1.000000000000e+00
1 KSP preconditioned resid norm 1.257128124270e-01 true resid norm 7.334555515521e-05 ||r(i)||/||b|| 1.964290689329e-01
2 KSP preconditioned resid norm 1.250635679151e-02 true resid norm 5.229463758195e-06 ||r(i)||/||b|| 1.400519356445e-02
3 KSP preconditioned resid norm 7.044787396120e-04 true resid norm 4.496085949179e-07 ||r(i)||/||b|| 1.204111107988e-03
4 KSP preconditioned resid norm 5.752276071869e-05 true resid norm 3.304114740417e-08 ||r(i)||/||b|| 8.848854995153e-05
5 KSP preconditioned resid norm 4.501641492631e-06 true resid norm 2.475433259121e-09 ||r(i)||/||b|| 6.629536708334e-06
6 KSP preconditioned resid norm 2.447627881266e-07 true resid norm 1.929318717776e-10 ||r(i)||/||b|| 5.166969949379e-07
7 KSP preconditioned resid norm 1.594610003820e-08 true resid norm 1.215791508998e-11 ||r(i)||/||b|| 3.256049989990e-08
Linear solve converged due to CONVERGED_RTOL iterations 7
KSP Object:(poisson_) 2 MPI processes
type: cg
maximum iterations=20000
tolerances: relative=1e-08, absolute=0, divergence=10000
left preconditioning
has attached null space
using nonzero initial guess
using PRECONDITIONED norm type for convergence test
PC Object:(poisson_) 2 MPI processes
type: gamg
MG: type is MULTIPLICATIVE, levels=2 cycles=v
Cycles per PCApply=1
Using Galerkin computed coarse grid matrices
Coarse grid solver -- level -------------------------------
KSP Object: (poisson_mg_coarse_) 2 MPI processes
type: preonly
maximum iterations=1, initial guess is zero
tolerances: relative=1e-05, absolute=1e-50, divergence=10000
left preconditioning
using NONE norm type for convergence test
PC Object: (poisson_mg_coarse_) 2 MPI processes
type: bjacobi
block Jacobi: number of blocks = 2
Local solve is same for all blocks, in the following KSP and PC objects:
KSP Object: (poisson_mg_coarse_sub_) 1 MPI processes
type: preonly
maximum iterations=1, initial guess is zero
tolerances: relative=1e-05, absolute=1e-50, divergence=10000
left preconditioning
using NONE norm type for convergence test
PC Object: (poisson_mg_coarse_sub_) 1 MPI processes
type: lu
LU: out-of-place factorization
tolerance for zero pivot 2.22045e-14
using diagonal shift on blocks to prevent zero pivot [INBLOCKS]
matrix ordering: nd
factor fill ratio given 5, needed 2.45338
Factored matrix follows:
Mat Object: 1 MPI processes
type: seqaij
rows=66, cols=66
package used to perform factorization: petsc
total: nonzeros=1526, allocated nonzeros=1526
total number of mallocs used during MatSetValues calls =0
not using I-node routines
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=66, cols=66
total: nonzeros=622, allocated nonzeros=622
total number of mallocs used during MatSetValues calls =0
not using I-node routines
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=66, cols=66
total: nonzeros=622, allocated nonzeros=622
total number of mallocs used during MatSetValues calls =0
not using I-node (on process 0) routines
Down solver (pre-smoother) on level 1 -------------------------------
KSP Object: (poisson_mg_levels_1_) 2 MPI processes
type: chebyshev
Chebyshev: eigenvalue estimates: min = 0.0990463, max = 2.07997
maximum iterations=2
tolerances: relative=1e-05, absolute=1e-50, divergence=10000
left preconditioning
using nonzero initial guess
using NONE norm type for convergence test
PC Object: (poisson_mg_levels_1_) 2 MPI processes
type: sor
SOR: type = local_symmetric, iterations = 1, local iterations = 1, omega = 1
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
not using I-node (on process 0) routines
Up solver (post-smoother) same as down solver (pre-smoother)
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
not using I-node (on process 0) routines
[time-step 1] Writing fluxes into file... done.
[time-step 1] Writing pressure into file... done.
=====================
*** PetIBM - Done ***
=====================
#PETSc Option Table entries:
-options_left
-poisson_ksp_atol 0.0
-poisson_ksp_converged_reason
-poisson_ksp_max_it 20000
-poisson_ksp_monitor_true_residual
-poisson_ksp_rtol 1.0E-08
-poisson_ksp_type cg
-poisson_ksp_view
-poisson_pc_gamg_agg_nsmooths 1
-poisson_pc_gamg_type agg
-poisson_pc_type gamg
-velocity_ksp_atol 0.0
-velocity_ksp_converged_reason
-velocity_ksp_max_it 10000
-velocity_ksp_monitor_true_residual
-velocity_ksp_rtol 1.0E-08
-velocity_ksp_type bcgs
-velocity_ksp_view
-velocity_pc_type jacobi
#End of PETSc Option Table entries
There are no unused options.
======================
*** PetIBM - Start ***
======================
directory: ./
Parsing file .//cartesianMesh.yaml... done.
Parsing file .//flowDescription.yaml... done.
Parsing file .//simulationParameters.yaml... done.
---------------------------------------
Cartesian grid
---------------------------------------
number of cells: 20 x 20
---------------------------------------
---------------------------------------
Flow
---------------------------------------
dimensions: 2
viscosity: 0.01
initial velocity field:
0
0
boundary conditions (component, type, value):
->location: xMinus (left)
0 DIRICHLET 0
1 DIRICHLET 0
->location: xPlus (right)
0 DIRICHLET 0
1 DIRICHLET 0
->location: yMinus (bottom)
0 DIRICHLET 0
1 DIRICHLET 0
->location: yPlus (top)
0 DIRICHLET 1
1 DIRICHLET 0
---------------------------------------
---------------------------------------
Time-stepping
---------------------------------------
formulation: Navier-Stokes solver (Perot, 1993)
convection: Euler-explicit
diffusion: Euler-implicit
time-increment: 0.0005
starting time-step: 0
number of time-steps: 1
saving-interval: 1
---------------------------------------
----------------------------------------
KSP info: Velocity system
----------------------------------------
KSP Object:(velocity_) 1 MPI processes
type: bcgs
maximum iterations=10000
tolerances: relative=1e-08, absolute=0, divergence=10000
left preconditioning
using nonzero initial guess
using DEFAULT norm type for convergence test
PC Object:(velocity_) 1 MPI processes
type: jacobi
PC has not been set up so information may be incomplete
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=760, cols=760
total: nonzeros=3644, allocated nonzeros=3644
total number of mallocs used during MatSetValues calls =0
not using I-node routines
----------------------------------------
KSP info: Poisson system
----------------------------------------
KSP Object:(poisson_) 1 MPI processes
type: cg
maximum iterations=20000
tolerances: relative=1e-08, absolute=0, divergence=10000
left preconditioning
using nonzero initial guess
using DEFAULT norm type for convergence test
PC Object:(poisson_) 1 MPI processes
type: gamg
PC has not been set up so information may be incomplete
MG: type is MULTIPLICATIVE, levels=0 cycles=unknown
Cycles per PCApply=0
Using Galerkin computed coarse grid matrices
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
not using I-node routines
[time-step 0] Writing grid into file... done.
Residual norms for velocity_ solve.
0 KSP preconditioned resid norm 1.148589971947e-03 true resid norm 2.324746103222e+00 ||r(i)||/||b|| 1.000000000000e+00
1 KSP preconditioned resid norm 8.875846864181e-09 true resid norm 1.793849713607e-05 ||r(i)||/||b|| 7.716325284387e-06
2 KSP preconditioned resid norm 1.418061760018e-13 true resid norm 2.860743141913e-10 ||r(i)||/||b|| 1.230561538720e-10
Linear solve converged due to CONVERGED_RTOL iterations 2
KSP Object:(velocity_) 1 MPI processes
type: bcgs
maximum iterations=10000
tolerances: relative=1e-08, absolute=0, divergence=10000
left preconditioning
using nonzero initial guess
using PRECONDITIONED norm type for convergence test
PC Object:(velocity_) 1 MPI processes
type: jacobi
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=760, cols=760
total: nonzeros=3644, allocated nonzeros=3644
total number of mallocs used during MatSetValues calls =0
not using I-node routines
Residual norms for poisson_ solve.
0 KSP preconditioned resid norm 3.538121181419e+00 true resid norm 3.733946078026e-04 ||r(i)||/||b|| 1.000000000000e+00
1 KSP preconditioned resid norm 1.958186883778e-01 true resid norm 7.230832340944e-05 ||r(i)||/||b|| 1.936512255358e-01
2 KSP preconditioned resid norm 2.107489727621e-02 true resid norm 6.273706549672e-06 ||r(i)||/||b|| 1.680181346644e-02
3 KSP preconditioned resid norm 1.615041289898e-03 true resid norm 5.554457935242e-07 ||r(i)||/||b|| 1.487557082822e-03
4 KSP preconditioned resid norm 1.639528881280e-04 true resid norm 4.649693287881e-08 ||r(i)||/||b|| 1.245249178944e-04
5 KSP preconditioned resid norm 4.829636187510e-05 true resid norm 3.293449837694e-09 ||r(i)||/||b|| 8.820292979258e-06
6 KSP preconditioned resid norm 4.571090134338e-05 true resid norm 2.181651322264e-10 ||r(i)||/||b|| 5.842749939811e-07
7 KSP preconditioned resid norm 4.570272612928e-05 true resid norm 1.309391347419e-11 ||r(i)||/||b|| 3.506722700484e-08
8 KSP preconditioned resid norm 4.569573599829e-05 true resid norm 8.051968034041e-13 ||r(i)||/||b|| 2.156423222453e-09
9 KSP preconditioned resid norm 4.569506796599e-05 true resid norm 4.924555008194e-14 ||r(i)||/||b|| 1.318860772301e-10
10 KSP preconditioned resid norm 4.569657790838e-05 true resid norm 2.592815923625e-14 ||r(i)||/||b|| 6.943902963365e-11
11 KSP preconditioned resid norm 4.563836061413e-05 true resid norm 3.949524292753e-13 ||r(i)||/||b|| 1.057734688778e-09
12 KSP preconditioned resid norm 2.726688428420e-05 true resid norm 3.469316354874e-12 ||r(i)||/||b|| 9.291286704141e-09
13 KSP preconditioned resid norm 9.144247241683e-05 true resid norm 1.817886753969e-11 ||r(i)||/||b|| 4.868540455545e-08
14 KSP preconditioned resid norm 9.145592805030e-05 true resid norm 3.497901531175e-11 ||r(i)||/||b|| 9.367841575859e-08
Linear solve did not converge due to DIVERGED_INDEFINITE_MAT iterations 15
KSP Object:(poisson_) 1 MPI processes
type: cg
maximum iterations=20000
tolerances: relative=1e-08, absolute=0, divergence=10000
left preconditioning
using nonzero initial guess
using PRECONDITIONED norm type for convergence test
PC Object:(poisson_) 1 MPI processes
type: gamg
MG: type is MULTIPLICATIVE, levels=2 cycles=v
Cycles per PCApply=1
Using Galerkin computed coarse grid matrices
Coarse grid solver -- level -------------------------------
KSP Object: (poisson_mg_coarse_) 1 MPI processes
type: preonly
maximum iterations=1, initial guess is zero
tolerances: relative=1e-05, absolute=1e-50, divergence=10000
left preconditioning
using NONE norm type for convergence test
PC Object: (poisson_mg_coarse_) 1 MPI processes
type: bjacobi
block Jacobi: number of blocks = 1
Local solve is same for all blocks, in the following KSP and PC objects:
KSP Object: (poisson_mg_coarse_sub_) 1 MPI processes
type: preonly
maximum iterations=1, initial guess is zero
tolerances: relative=1e-05, absolute=1e-50, divergence=10000
left preconditioning
using NONE norm type for convergence test
PC Object: (poisson_mg_coarse_sub_) 1 MPI processes
type: lu
LU: out-of-place factorization
tolerance for zero pivot 2.22045e-14
using diagonal shift on blocks to prevent zero pivot [INBLOCKS]
matrix ordering: nd
factor fill ratio given 5, needed 2.36496
Factored matrix follows:
Mat Object: 1 MPI processes
type: seqaij
rows=60, cols=60
package used to perform factorization: petsc
total: nonzeros=1296, allocated nonzeros=1296
total number of mallocs used during MatSetValues calls =0
not using I-node routines
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=60, cols=60
total: nonzeros=548, allocated nonzeros=548
total number of mallocs used during MatSetValues calls =0
not using I-node routines
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=60, cols=60
total: nonzeros=548, allocated nonzeros=548
total number of mallocs used during MatSetValues calls =0
not using I-node routines
Down solver (pre-smoother) on level 1 -------------------------------
KSP Object: (poisson_mg_levels_1_) 1 MPI processes
type: chebyshev
Chebyshev: eigenvalue estimates: min = 0.09935, max = 2.08635
maximum iterations=2
tolerances: relative=1e-05, absolute=1e-50, divergence=10000
left preconditioning
has attached null space
using nonzero initial guess
using NONE norm type for convergence test
PC Object: (poisson_mg_levels_1_) 1 MPI processes
type: sor
SOR: type = local_symmetric, iterations = 1, local iterations = 1, omega = 1
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
has attached null space
not using I-node routines
Up solver (post-smoother) same as down solver (pre-smoother)
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
has attached null space
not using I-node routines
[time-step 0] ERROR: Poisson solver diverged due to reason: -10
#PETSc Option Table entries:
-options_left
-poisson_ksp_atol 0.0
-poisson_ksp_converged_reason
-poisson_ksp_max_it 20000
-poisson_ksp_monitor_true_residual
-poisson_ksp_rtol 1.0E-08
-poisson_ksp_type cg
-poisson_ksp_view
-poisson_pc_gamg_agg_nsmooths 1
-poisson_pc_gamg_type agg
-poisson_pc_type gamg
-velocity_ksp_atol 0.0
-velocity_ksp_converged_reason
-velocity_ksp_max_it 10000
-velocity_ksp_monitor_true_residual
-velocity_ksp_rtol 1.0E-08
-velocity_ksp_type bcgs
-velocity_ksp_view
-velocity_pc_type jacobi
#End of PETSc Option Table entries
There are no unused options.
======================
*** PetIBM - Start ***
======================
directory: ./
Parsing file .//cartesianMesh.yaml... done.
Parsing file .//flowDescription.yaml... done.
Parsing file .//simulationParameters.yaml... done.
---------------------------------------
Cartesian grid
---------------------------------------
number of cells: 20 x 20
---------------------------------------
---------------------------------------
Flow
---------------------------------------
dimensions: 2
viscosity: 0.01
initial velocity field:
0
0
boundary conditions (component, type, value):
->location: xMinus (left)
0 DIRICHLET 0
1 DIRICHLET 0
->location: xPlus (right)
0 DIRICHLET 0
1 DIRICHLET 0
->location: yMinus (bottom)
0 DIRICHLET 0
1 DIRICHLET 0
->location: yPlus (top)
0 DIRICHLET 1
1 DIRICHLET 0
---------------------------------------
---------------------------------------
Time-stepping
---------------------------------------
formulation: Navier-Stokes solver (Perot, 1993)
convection: Euler-explicit
diffusion: Euler-implicit
time-increment: 0.0005
starting time-step: 0
number of time-steps: 1
saving-interval: 1
---------------------------------------
----------------------------------------
KSP info: Velocity system
----------------------------------------
KSP Object:(velocity_) 2 MPI processes
type: bcgs
maximum iterations=10000
tolerances: relative=1e-08, absolute=0, divergence=10000
left preconditioning
using nonzero initial guess
using DEFAULT norm type for convergence test
PC Object:(velocity_) 2 MPI processes
type: jacobi
PC has not been set up so information may be incomplete
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=760, cols=760
total: nonzeros=3644, allocated nonzeros=3800
total number of mallocs used during MatSetValues calls =0
not using I-node (on process 0) routines
----------------------------------------
KSP info: Poisson system
----------------------------------------
KSP Object:(poisson_) 2 MPI processes
type: cg
maximum iterations=20000
tolerances: relative=1e-08, absolute=0, divergence=10000
left preconditioning
using nonzero initial guess
using DEFAULT norm type for convergence test
PC Object:(poisson_) 2 MPI processes
type: gamg
PC has not been set up so information may be incomplete
MG: type is MULTIPLICATIVE, levels=0 cycles=unknown
Cycles per PCApply=0
Using Galerkin computed coarse grid matrices
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
not using I-node (on process 0) routines
[time-step 0] Writing grid into file... done.
Residual norms for velocity_ solve.
0 KSP preconditioned resid norm 1.148589971947e-03 true resid norm 2.324746103222e+00 ||r(i)||/||b|| 1.000000000000e+00
1 KSP preconditioned resid norm 8.875846864181e-09 true resid norm 1.793849713607e-05 ||r(i)||/||b|| 7.716325284387e-06
2 KSP preconditioned resid norm 1.418061760018e-13 true resid norm 2.860743141913e-10 ||r(i)||/||b|| 1.230561538720e-10
Linear solve converged due to CONVERGED_RTOL iterations 2
KSP Object:(velocity_) 2 MPI processes
type: bcgs
maximum iterations=10000
tolerances: relative=1e-08, absolute=0, divergence=10000
left preconditioning
using nonzero initial guess
using PRECONDITIONED norm type for convergence test
PC Object:(velocity_) 2 MPI processes
type: jacobi
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=760, cols=760
total: nonzeros=3644, allocated nonzeros=3800
total number of mallocs used during MatSetValues calls =0
not using I-node (on process 0) routines
Residual norms for poisson_ solve.
0 KSP preconditioned resid norm 3.675561452464e+00 true resid norm 3.733946078026e-04 ||r(i)||/||b|| 1.000000000000e+00
1 KSP preconditioned resid norm 1.382927944793e-01 true resid norm 7.337110823414e-05 ||r(i)||/||b|| 1.964975034480e-01
2 KSP preconditioned resid norm 1.332736590420e-02 true resid norm 5.231408329311e-06 ||r(i)||/||b|| 1.401040138233e-02
3 KSP preconditioned resid norm 7.068423912044e-04 true resid norm 4.498808989698e-07 ||r(i)||/||b|| 1.204840374148e-03
4 KSP preconditioned resid norm 5.780387430517e-05 true resid norm 3.306714792465e-08 ||r(i)||/||b|| 8.855818277411e-05
5 KSP preconditioned resid norm 9.232365586631e-06 true resid norm 2.477096469374e-09 ||r(i)||/||b|| 6.633991004722e-06
6 KSP preconditioned resid norm 9.406830883053e-06 true resid norm 1.931060675770e-10 ||r(i)||/||b|| 5.171635142602e-07
7 KSP preconditioned resid norm 9.497484331186e-06 true resid norm 1.216972156000e-11 ||r(i)||/||b|| 3.259211918355e-08
8 KSP preconditioned resid norm 9.506436199946e-06 true resid norm 8.518483280015e-13 ||r(i)||/||b|| 2.281362157356e-09
9 KSP preconditioned resid norm 9.506879296911e-06 true resid norm 5.497903868197e-14 ||r(i)||/||b|| 1.472411157877e-10
10 KSP preconditioned resid norm 9.507208806186e-06 true resid norm 3.717630270466e-15 ||r(i)||/||b|| 9.956304115755e-12
11 KSP preconditioned resid norm 9.506187392238e-06 true resid norm 8.887919148873e-15 ||r(i)||/||b|| 2.380301954862e-11
12 KSP preconditioned resid norm 9.361666552978e-06 true resid norm 1.188906975551e-13 ||r(i)||/||b|| 3.184049664100e-10
13 KSP preconditioned resid norm 1.398897696828e-06 true resid norm 2.581418907230e-13 ||r(i)||/||b|| 6.913380250511e-10
14 KSP preconditioned resid norm 1.347868474581e-06 true resid norm 5.212878458961e-14 ||r(i)||/||b|| 1.396077594596e-10
15 KSP preconditioned resid norm 1.373086792820e-06 true resid norm 1.232461869862e-14 ||r(i)||/||b|| 3.300695414739e-11
16 KSP preconditioned resid norm 1.371833240683e-06 true resid norm 2.410622562975e-15 ||r(i)||/||b|| 6.455965117337e-12
17 KSP preconditioned resid norm 1.371626478785e-06 true resid norm 8.718241249556e-16 ||r(i)||/||b|| 2.334859975848e-12
18 KSP preconditioned resid norm 1.371832823880e-06 true resid norm 1.974183346731e-15 ||r(i)||/||b|| 5.287123342111e-12
19 KSP preconditioned resid norm 1.369858098414e-06 true resid norm 8.549423128555e-15 ||r(i)||/||b|| 2.289648256805e-11
20 KSP preconditioned resid norm 1.326759616124e-06 true resid norm 3.978696226795e-14 ||r(i)||/||b|| 1.065547317410e-10
21 KSP preconditioned resid norm 6.756901714642e-07 true resid norm 8.190685621828e-14 ||r(i)||/||b|| 2.193573621759e-10
22 KSP preconditioned resid norm 1.137069552371e-06 true resid norm 1.024555307390e-13 ||r(i)||/||b|| 2.743894223377e-10
Linear solve did not converge due to DIVERGED_INDEFINITE_MAT iterations 23
KSP Object:(poisson_) 2 MPI processes
type: cg
maximum iterations=20000
tolerances: relative=1e-08, absolute=0, divergence=10000
left preconditioning
using nonzero initial guess
using PRECONDITIONED norm type for convergence test
PC Object:(poisson_) 2 MPI processes
type: gamg
MG: type is MULTIPLICATIVE, levels=2 cycles=v
Cycles per PCApply=1
Using Galerkin computed coarse grid matrices
Coarse grid solver -- level -------------------------------
KSP Object: (poisson_mg_coarse_) 2 MPI processes
type: preonly
maximum iterations=1, initial guess is zero
tolerances: relative=1e-05, absolute=1e-50, divergence=10000
left preconditioning
using NONE norm type for convergence test
PC Object: (poisson_mg_coarse_) 2 MPI processes
type: bjacobi
block Jacobi: number of blocks = 2
Local solve is same for all blocks, in the following KSP and PC objects:
KSP Object: (poisson_mg_coarse_sub_) 1 MPI processes
type: preonly
maximum iterations=1, initial guess is zero
tolerances: relative=1e-05, absolute=1e-50, divergence=10000
left preconditioning
using NONE norm type for convergence test
PC Object: (poisson_mg_coarse_sub_) 1 MPI processes
type: lu
LU: out-of-place factorization
tolerance for zero pivot 2.22045e-14
using diagonal shift on blocks to prevent zero pivot [INBLOCKS]
matrix ordering: nd
factor fill ratio given 5, needed 2.45338
Factored matrix follows:
Mat Object: 1 MPI processes
type: seqaij
rows=66, cols=66
package used to perform factorization: petsc
total: nonzeros=1526, allocated nonzeros=1526
total number of mallocs used during MatSetValues calls =0
not using I-node routines
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=66, cols=66
total: nonzeros=622, allocated nonzeros=622
total number of mallocs used during MatSetValues calls =0
not using I-node routines
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=66, cols=66
total: nonzeros=622, allocated nonzeros=622
total number of mallocs used during MatSetValues calls =0
not using I-node (on process 0) routines
Down solver (pre-smoother) on level 1 -------------------------------
KSP Object: (poisson_mg_levels_1_) 2 MPI processes
type: chebyshev
Chebyshev: eigenvalue estimates: min = 0.0990585, max = 2.08023
maximum iterations=2
tolerances: relative=1e-05, absolute=1e-50, divergence=10000
left preconditioning
has attached null space
using nonzero initial guess
using NONE norm type for convergence test
PC Object: (poisson_mg_levels_1_) 2 MPI processes
type: sor
SOR: type = local_symmetric, iterations = 1, local iterations = 1, omega = 1
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
has attached null space
not using I-node (on process 0) routines
Up solver (post-smoother) same as down solver (pre-smoother)
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
has attached null space
not using I-node (on process 0) routines
[time-step 0] ERROR: Poisson solver diverged due to reason: -10
#PETSc Option Table entries:
-options_left
-poisson_ksp_atol 0.0
-poisson_ksp_converged_reason
-poisson_ksp_max_it 20000
-poisson_ksp_monitor_true_residual
-poisson_ksp_rtol 1.0E-08
-poisson_ksp_type cg
-poisson_ksp_view
-poisson_pc_gamg_agg_nsmooths 1
-poisson_pc_gamg_type agg
-poisson_pc_type gamg
-velocity_ksp_atol 0.0
-velocity_ksp_converged_reason
-velocity_ksp_max_it 10000
-velocity_ksp_monitor_true_residual
-velocity_ksp_rtol 1.0E-08
-velocity_ksp_type bcgs
-velocity_ksp_view
-velocity_pc_type jacobi
#End of PETSc Option Table entries
There are no unused options.
======================
*** PetIBM - Start ***
======================
directory: ./
Parsing file .//cartesianMesh.yaml... done.
Parsing file .//flowDescription.yaml... done.
Parsing file .//simulationParameters.yaml... done.
---------------------------------------
Cartesian grid
---------------------------------------
number of cells: 20 x 20
---------------------------------------
---------------------------------------
Flow
---------------------------------------
dimensions: 2
viscosity: 0.01
initial velocity field:
0.
0.
boundary conditions (component, type, value):
->location: xMinus (left)
0 DIRICHLET 0.
1 DIRICHLET 0.
->location: xPlus (right)
0 DIRICHLET 0.
1 DIRICHLET 0.
->location: yMinus (bottom)
0 DIRICHLET 0.
1 DIRICHLET 0.
->location: yPlus (top)
0 DIRICHLET 1.
1 DIRICHLET 0.
---------------------------------------
---------------------------------------
Time-stepping
---------------------------------------
formulation: Navier-Stokes solver (Perot, 1993)
convection: Euler-explicit
diffusion: Euler-implicit
time-increment: 0.0005
starting time-step: 0
number of time-steps: 1
saving-interval: 1
---------------------------------------
----------------------------------------
KSP info: Velocity system
----------------------------------------
KSP Object:(velocity_) 1 MPI processes
type: bcgs
maximum iterations=10000
tolerances: relative=1e-08, absolute=0., divergence=10000.
left preconditioning
using nonzero initial guess
using DEFAULT norm type for convergence test
PC Object:(velocity_) 1 MPI processes
type: jacobi
PC has not been set up so information may be incomplete
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=760, cols=760
total: nonzeros=3644, allocated nonzeros=3644
total number of mallocs used during MatSetValues calls =0
not using I-node routines
----------------------------------------
KSP info: Poisson system
----------------------------------------
KSP Object:(poisson_) 1 MPI processes
type: cg
maximum iterations=20000
tolerances: relative=1e-08, absolute=0., divergence=10000.
left preconditioning
using nonzero initial guess
using DEFAULT norm type for convergence test
PC Object:(poisson_) 1 MPI processes
type: gamg
PC has not been set up so information may be incomplete
MG: type is MULTIPLICATIVE, levels=0 cycles=unknown
Cycles per PCApply=0
Using Galerkin computed coarse grid matrices
GAMG specific options
Threshold for dropping small values from graph 0.
AGG specific options
Symmetric graph false
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
not using I-node routines
[time-step 0] Writing grid into file... done.
Residual norms for velocity_ solve.
0 KSP preconditioned resid norm 1.148589971947e-03 true resid norm 2.324746103222e+00 ||r(i)||/||b|| 1.000000000000e+00
1 KSP preconditioned resid norm 8.875846864181e-09 true resid norm 1.793849713607e-05 ||r(i)||/||b|| 7.716325284387e-06
2 KSP preconditioned resid norm 1.418061760018e-13 true resid norm 2.860743141913e-10 ||r(i)||/||b|| 1.230561538720e-10
Linear velocity_ solve converged due to CONVERGED_RTOL iterations 2
KSP Object:(velocity_) 1 MPI processes
type: bcgs
maximum iterations=10000
tolerances: relative=1e-08, absolute=0., divergence=10000.
left preconditioning
using nonzero initial guess
using PRECONDITIONED norm type for convergence test
PC Object:(velocity_) 1 MPI processes
type: jacobi
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=760, cols=760
total: nonzeros=3644, allocated nonzeros=3644
total number of mallocs used during MatSetValues calls =0
not using I-node routines
Residual norms for poisson_ solve.
0 KSP preconditioned resid norm 3.561941359575e+00 true resid norm 3.733946078026e-04 ||r(i)||/||b|| 1.000000000000e+00
1 KSP preconditioned resid norm 1.946406555499e-01 true resid norm 4.949185566569e-05 ||r(i)||/||b|| 1.325457160642e-01
2 KSP preconditioned resid norm 1.068754275594e-02 true resid norm 2.544125614119e-06 ||r(i)||/||b|| 6.813503893617e-03
3 KSP preconditioned resid norm 4.814477551625e-04 true resid norm 1.469330228153e-07 ||r(i)||/||b|| 3.935060114554e-04
4 KSP preconditioned resid norm 1.974337770997e-05 true resid norm 7.016234541043e-09 ||r(i)||/||b|| 1.879040134600e-05
5 KSP preconditioned resid norm 1.473724790065e-06 true resid norm 3.095939240025e-10 ||r(i)||/||b|| 8.291333552577e-07
6 KSP preconditioned resid norm 4.989952288177e-08 true resid norm 1.985550182405e-11 ||r(i)||/||b|| 5.317565227013e-08
7 KSP preconditioned resid norm 7.284241186542e-10 true resid norm 6.288840976516e-13 ||r(i)||/||b|| 1.684234545733e-09
Linear poisson_ solve converged due to CONVERGED_RTOL iterations 7
KSP Object:(poisson_) 1 MPI processes
type: cg
maximum iterations=20000
tolerances: relative=1e-08, absolute=0., divergence=10000.
left preconditioning
using nonzero initial guess
using PRECONDITIONED norm type for convergence test
PC Object:(poisson_) 1 MPI processes
type: gamg
MG: type is MULTIPLICATIVE, levels=3 cycles=v
Cycles per PCApply=1
Using Galerkin computed coarse grid matrices
GAMG specific options
Threshold for dropping small values from graph 0.
AGG specific options
Symmetric graph false
Coarse grid solver -- level -------------------------------
KSP Object: (poisson_mg_coarse_) 1 MPI processes
type: preonly
maximum iterations=10000, initial guess is zero
tolerances: relative=1e-05, absolute=1e-50, divergence=10000.
left preconditioning
using NONE norm type for convergence test
PC Object: (poisson_mg_coarse_) 1 MPI processes
type: bjacobi
block Jacobi: number of blocks = 1
Local solve is same for all blocks, in the following KSP and PC objects:
KSP Object: (poisson_mg_coarse_sub_) 1 MPI processes
type: preonly
maximum iterations=1, initial guess is zero
tolerances: relative=1e-05, absolute=1e-50, divergence=10000.
left preconditioning
using NONE norm type for convergence test
PC Object: (poisson_mg_coarse_sub_) 1 MPI processes
type: lu
LU: out-of-place factorization
tolerance for zero pivot 2.22045e-14
using diagonal shift on blocks to prevent zero pivot [INBLOCKS]
matrix ordering: nd
factor fill ratio given 5., needed 1.05825
Factored matrix follows:
Mat Object: 1 MPI processes
type: seqaij
rows=11, cols=11
package used to perform factorization: petsc
total: nonzeros=109, allocated nonzeros=109
total number of mallocs used during MatSetValues calls =0
using I-node routines: found 4 nodes, limit used is 5
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=11, cols=11
total: nonzeros=103, allocated nonzeros=103
total number of mallocs used during MatSetValues calls =0
using I-node routines: found 8 nodes, limit used is 5
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=11, cols=11
total: nonzeros=103, allocated nonzeros=103
total number of mallocs used during MatSetValues calls =0
using I-node routines: found 8 nodes, limit used is 5
Down solver (pre-smoother) on level 1 -------------------------------
KSP Object: (poisson_mg_levels_1_) 1 MPI processes
type: chebyshev
Chebyshev: eigenvalue estimates: min = 0.099075, max = 1.08983
Chebyshev: eigenvalues estimated using gmres with translations [0. 0.1; 0. 1.1]
KSP Object: (poisson_mg_levels_1_esteig_) 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=10, initial guess is zero
tolerances: relative=1e-12, absolute=1e-50, divergence=10000.
left preconditioning
using PRECONDITIONED norm type for convergence test
maximum iterations=2
tolerances: relative=1e-05, absolute=1e-50, divergence=10000.
left preconditioning
using nonzero initial guess
using NONE norm type for convergence test
PC Object: (poisson_mg_levels_1_) 1 MPI processes
type: sor
SOR: type = local_symmetric, iterations = 1, local iterations = 1, omega = 1.
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=61, cols=61
total: nonzeros=549, allocated nonzeros=549
total number of mallocs used during MatSetValues calls =0
not using I-node routines
Up solver (post-smoother) same as down solver (pre-smoother)
Down solver (pre-smoother) on level 2 -------------------------------
KSP Object: (poisson_mg_levels_2_) 1 MPI processes
type: chebyshev
Chebyshev: eigenvalue estimates: min = 0.0993751, max = 1.09313
Chebyshev: eigenvalues estimated using gmres with translations [0. 0.1; 0. 1.1]
KSP Object: (poisson_mg_levels_2_esteig_) 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=10, initial guess is zero
tolerances: relative=1e-12, absolute=1e-50, divergence=10000.
left preconditioning
using PRECONDITIONED norm type for convergence test
maximum iterations=2
tolerances: relative=1e-05, absolute=1e-50, divergence=10000.
left preconditioning
using nonzero initial guess
using NONE norm type for convergence test
PC Object: (poisson_mg_levels_2_) 1 MPI processes
type: sor
SOR: type = local_symmetric, iterations = 1, local iterations = 1, omega = 1.
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
has attached null space
not using I-node routines
Up solver (post-smoother) same as down solver (pre-smoother)
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
has attached null space
not using I-node routines
[time-step 1] Writing fluxes into file... done.
[time-step 1] Writing pressure into file... done.
=====================
*** PetIBM - Done ***
=====================
#PETSc Option Table entries:
-options_left
-poisson_ksp_atol 0.0
-poisson_ksp_converged_reason
-poisson_ksp_max_it 20000
-poisson_ksp_monitor_true_residual
-poisson_ksp_rtol 1.0E-08
-poisson_ksp_type cg
-poisson_ksp_view
-poisson_pc_gamg_agg_nsmooths 1
-poisson_pc_gamg_type agg
-poisson_pc_type gamg
-velocity_ksp_atol 0.0
-velocity_ksp_converged_reason
-velocity_ksp_max_it 10000
-velocity_ksp_monitor_true_residual
-velocity_ksp_rtol 1.0E-08
-velocity_ksp_type bcgs
-velocity_ksp_view
-velocity_pc_type jacobi
#End of PETSc Option Table entries
There are no unused options.
======================
*** PetIBM - Start ***
======================
directory: ./
Parsing file .//cartesianMesh.yaml... done.
Parsing file .//flowDescription.yaml... done.
Parsing file .//simulationParameters.yaml... done.
---------------------------------------
Cartesian grid
---------------------------------------
number of cells: 20 x 20
---------------------------------------
---------------------------------------
Flow
---------------------------------------
dimensions: 2
viscosity: 0.01
initial velocity field:
0.
0.
boundary conditions (component, type, value):
->location: xMinus (left)
0 DIRICHLET 0.
1 DIRICHLET 0.
->location: xPlus (right)
0 DIRICHLET 0.
1 DIRICHLET 0.
->location: yMinus (bottom)
0 DIRICHLET 0.
1 DIRICHLET 0.
->location: yPlus (top)
0 DIRICHLET 1.
1 DIRICHLET 0.
---------------------------------------
---------------------------------------
Time-stepping
---------------------------------------
formulation: Navier-Stokes solver (Perot, 1993)
convection: Euler-explicit
diffusion: Euler-implicit
time-increment: 0.0005
starting time-step: 0
number of time-steps: 1
saving-interval: 1
---------------------------------------
----------------------------------------
KSP info: Velocity system
----------------------------------------
KSP Object:(velocity_) 2 MPI processes
type: bcgs
maximum iterations=10000
tolerances: relative=1e-08, absolute=0., divergence=10000.
left preconditioning
using nonzero initial guess
using DEFAULT norm type for convergence test
PC Object:(velocity_) 2 MPI processes
type: jacobi
PC has not been set up so information may be incomplete
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=760, cols=760
total: nonzeros=3644, allocated nonzeros=3800
total number of mallocs used during MatSetValues calls =0
not using I-node (on process 0) routines
----------------------------------------
KSP info: Poisson system
----------------------------------------
KSP Object:(poisson_) 2 MPI processes
type: cg
maximum iterations=20000
tolerances: relative=1e-08, absolute=0., divergence=10000.
left preconditioning
using nonzero initial guess
using DEFAULT norm type for convergence test
PC Object:(poisson_) 2 MPI processes
type: gamg
PC has not been set up so information may be incomplete
MG: type is MULTIPLICATIVE, levels=0 cycles=unknown
Cycles per PCApply=0
Using Galerkin computed coarse grid matrices
GAMG specific options
Threshold for dropping small values from graph 0.
AGG specific options
Symmetric graph false
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
not using I-node (on process 0) routines
[time-step 0] Writing grid into file... done.
Residual norms for velocity_ solve.
0 KSP preconditioned resid norm 1.148589971947e-03 true resid norm 2.324746103222e+00 ||r(i)||/||b|| 1.000000000000e+00
1 KSP preconditioned resid norm 8.875846864181e-09 true resid norm 1.793849713607e-05 ||r(i)||/||b|| 7.716325284387e-06
2 KSP preconditioned resid norm 1.418061760018e-13 true resid norm 2.860743141913e-10 ||r(i)||/||b|| 1.230561538720e-10
Linear velocity_ solve converged due to CONVERGED_RTOL iterations 2
KSP Object:(velocity_) 2 MPI processes
type: bcgs
maximum iterations=10000
tolerances: relative=1e-08, absolute=0., divergence=10000.
left preconditioning
using nonzero initial guess
using PRECONDITIONED norm type for convergence test
PC Object:(velocity_) 2 MPI processes
type: jacobi
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=760, cols=760
total: nonzeros=3644, allocated nonzeros=3800
total number of mallocs used during MatSetValues calls =0
not using I-node (on process 0) routines
Residual norms for poisson_ solve.
0 KSP preconditioned resid norm 3.590651691469e+00 true resid norm 3.733946078026e-04 ||r(i)||/||b|| 1.000000000000e+00
1 KSP preconditioned resid norm 1.866726089922e-01 true resid norm 5.166385838639e-05 ||r(i)||/||b|| 1.383626257766e-01
2 KSP preconditioned resid norm 1.900939193435e-01 true resid norm 5.256577682445e-05 ||r(i)||/||b|| 1.407780822915e-01
Linear poisson_ solve did not converge due to DIVERGED_INDEFINITE_PC iterations 3
KSP Object:(poisson_) 2 MPI processes
type: cg
maximum iterations=20000
tolerances: relative=1e-08, absolute=0., divergence=10000.
left preconditioning
using nonzero initial guess
using PRECONDITIONED norm type for convergence test
PC Object:(poisson_) 2 MPI processes
type: gamg
MG: type is MULTIPLICATIVE, levels=3 cycles=v
Cycles per PCApply=1
Using Galerkin computed coarse grid matrices
GAMG specific options
Threshold for dropping small values from graph 0.
AGG specific options
Symmetric graph false
Coarse grid solver -- level -------------------------------
KSP Object: (poisson_mg_coarse_) 2 MPI processes
type: preonly
maximum iterations=10000, initial guess is zero
tolerances: relative=1e-05, absolute=1e-50, divergence=10000.
left preconditioning
using NONE norm type for convergence test
PC Object: (poisson_mg_coarse_) 2 MPI processes
type: bjacobi
block Jacobi: number of blocks = 2
Local solve is same for all blocks, in the following KSP and PC objects:
KSP Object: (poisson_mg_coarse_sub_) 1 MPI processes
type: preonly
maximum iterations=1, initial guess is zero
tolerances: relative=1e-05, absolute=1e-50, divergence=10000.
left preconditioning
using NONE norm type for convergence test
PC Object: (poisson_mg_coarse_sub_) 1 MPI processes
type: lu
LU: out-of-place factorization
tolerance for zero pivot 2.22045e-14
using diagonal shift on blocks to prevent zero pivot [INBLOCKS]
matrix ordering: nd
factor fill ratio given 5., needed 1.09231
Factored matrix follows:
Mat Object: 1 MPI processes
type: seqaij
rows=12, cols=12
package used to perform factorization: petsc
total: nonzeros=142, allocated nonzeros=142
total number of mallocs used during MatSetValues calls =0
using I-node routines: found 4 nodes, limit used is 5
linear system matrix = precond matrix:
Mat Object: 1 MPI processes
type: seqaij
rows=12, cols=12
total: nonzeros=130, allocated nonzeros=130
total number of mallocs used during MatSetValues calls =0
using I-node routines: found 7 nodes, limit used is 5
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=12, cols=12
total: nonzeros=130, allocated nonzeros=130
total number of mallocs used during MatSetValues calls =0
using I-node (on process 0) routines: found 7 nodes, limit used is 5
Down solver (pre-smoother) on level 1 -------------------------------
KSP Object: (poisson_mg_levels_1_) 2 MPI processes
type: chebyshev
Chebyshev: eigenvalue estimates: min = 0.0991605, max = 1.09077
Chebyshev: eigenvalues estimated using gmres with translations [0. 0.1; 0. 1.1]
KSP Object: (poisson_mg_levels_1_esteig_) 2 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=10, initial guess is zero
tolerances: relative=1e-12, absolute=1e-50, divergence=10000.
left preconditioning
using PRECONDITIONED norm type for convergence test
maximum iterations=2
tolerances: relative=1e-05, absolute=1e-50, divergence=10000.
left preconditioning
using nonzero initial guess
using NONE norm type for convergence test
PC Object: (poisson_mg_levels_1_) 2 MPI processes
type: sor
SOR: type = local_symmetric, iterations = 1, local iterations = 1, omega = 1.
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=62, cols=62
total: nonzeros=556, allocated nonzeros=556
total number of mallocs used during MatSetValues calls =0
not using I-node (on process 0) routines
Up solver (post-smoother) same as down solver (pre-smoother)
Down solver (pre-smoother) on level 2 -------------------------------
KSP Object: (poisson_mg_levels_2_) 2 MPI processes
type: chebyshev
Chebyshev: eigenvalue estimates: min = 0.0993731, max = 1.0931
Chebyshev: eigenvalues estimated using gmres with translations [0. 0.1; 0. 1.1]
KSP Object: (poisson_mg_levels_2_esteig_) 2 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=10, initial guess is zero
tolerances: relative=1e-12, absolute=1e-50, divergence=10000.
left preconditioning
using PRECONDITIONED norm type for convergence test
maximum iterations=2
tolerances: relative=1e-05, absolute=1e-50, divergence=10000.
left preconditioning
using nonzero initial guess
using NONE norm type for convergence test
PC Object: (poisson_mg_levels_2_) 2 MPI processes
type: sor
SOR: type = local_symmetric, iterations = 1, local iterations = 1, omega = 1.
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
has attached null space
not using I-node (on process 0) routines
Up solver (post-smoother) same as down solver (pre-smoother)
linear system matrix = precond matrix:
Mat Object: 2 MPI processes
type: mpiaij
rows=400, cols=400
total: nonzeros=1920, allocated nonzeros=1920
total number of mallocs used during MatSetValues calls =0
has attached null space
not using I-node (on process 0) routines
[time-step 0] ERROR: Poisson solver diverged due to reason: -8
#PETSc Option Table entries:
-options_left
-poisson_ksp_atol 0.0
-poisson_ksp_converged_reason
-poisson_ksp_max_it 20000
-poisson_ksp_monitor_true_residual
-poisson_ksp_rtol 1.0E-08
-poisson_ksp_type cg
-poisson_ksp_view
-poisson_pc_gamg_agg_nsmooths 1
-poisson_pc_gamg_type agg
-poisson_pc_type gamg
-velocity_ksp_atol 0.0
-velocity_ksp_converged_reason
-velocity_ksp_max_it 10000
-velocity_ksp_monitor_true_residual
-velocity_ksp_rtol 1.0E-08
-velocity_ksp_type bcgs
-velocity_ksp_view
-velocity_pc_type jacobi
#End of PETSc Option Table entries
There are no unused options.