3-D global model doesn't converge with GMG and AMG on aspect3.0
Hi, I recently install aspect3.0 and running my 3-D global model with it, but i am facing the issue about model doesnt converge or stuck which it never happened with aspect2.6.0-pre.
I use the same parameter file (edit it very few based on changes for aspect3.0) with AMG solver, solver parameter and viscosity part is as follow:
set Nonlinear solver scheme = single Advection, iterated Stokes # iterated Advection and Stokes # single Advection, iterated Stokes
set Nonlinear solver tolerance = 1.0e-3
set Max nonlinear iterations = 500
subsection Solver parameters
subsection Stokes solver parameters
set Stokes solver type = block AMG
set Linear solver A block tolerance = 1e-1
set Linear solver tolerance = 1e-3
set Maximum number of expensive Stokes solver steps = 4000
set Number of cheap Stokes solver steps = 300
set GMRES solver restart length = 200
end
set Temperature solver tolerance = 1e-7
set Composition solver tolerance = 1e-7
end
set Minimum viscosity = background: 1.0e19|1.0e20, plbd: 0.999e19|0.999e19
set Maximum viscosity = background: 1.0e24|1.0e24, plbd: 1.001e19|1.001e19
it got stuck on 'rebuilding stokes preconditioner'.. for 12 hours
Number of active cells: 178,204 (on 5 levels)
Number of degrees of freedom: 7,611,464 (4,452,546+190,554+1,484,182+1,484,182)
Number of active cells: 781,835 (on 6 levels)
Number of degrees of freedom: 33,333,604 (19,501,236+831,544+6,500,412+6,500,412)
Number of active cells: 1,680,698 (on 7 levels)
Number of degrees of freedom: 75,115,113 (43,921,071+1,913,328+14,640,357+14,640,357)
Number of active cells: 8,034,248 (on 8 levels)
Number of degrees of freedom: 355,010,466 (207,613,245+8,988,391+69,204,415+69,204,415)
Number of active cells: 12,338,366 (on 9 levels)
Number of degrees of freedom: 552,282,324 (322,967,559+14,003,059+107,655,853+107,655,853)
*** Timestep 0: t=0 years, dt=0 years
Solving temperature system... 0 iterations.
Solving plbd system ... 0 iterations.
Rebuilding Stokes preconditioner...
i tried to use GMG solver to run same setting, but it doesnt converge, even i reduce the viscosity contrast from 10to19-10to24. to 1020to1023
parameter file as follow:
set Nonlinear solver scheme = single Advection, iterated Stokes # iterated Advection and Stokes # single Advection, iterated Stokes
set Nonlinear solver tolerance = 1.0e-3
set Max nonlinear iterations = 500
subsection Solver parameters
subsection Stokes solver parameters
set Stokes solver type = block GMG
set Linear solver A block tolerance = 1e-1
set Linear solver tolerance = 1e-3
set Maximum number of expensive Stokes solver steps = 4000
set Number of cheap Stokes solver steps = 300
set GMRES solver restart length = 200
end
set Temperature solver tolerance = 1e-7
set Composition solver tolerance = 1e-7
end
set Minimum viscosity = background: 1.0e19|1.0e20, plbd: 0.999e20|0.999e20
set Maximum viscosity = background: 1.0e23|1.0e24, plbd: 1.001e20|1.001e20
the error file as follow:
----------------------------------------------------
Exception 'ExcMessage (exception_message.str())' on rank 0 on processing:
--------------------------------------------------------
An error occurred in line <3034> of file </work2/09569/tzhao2/stampede3/software/aspect/source/utilities.cc> in function
void aspect::Utilities::throw_linear_solver_failure_exception(const std::string &, const std::string &, const std::vector<SolverControl> &, const std::exception &, const MPI_Comm, const std::string &)
The violated condition was:
false
Additional information:
The iterative Stokes solver in
StokesMatrixFreeHandlerImplementation::solve did not converge.
The initial residual was: 4.928433e+19
The final residual is: 1.454681e+19
The required residual for convergence is: 4.928433e+16
See
outputs/GMG_SAVANI_plbdonly_30km_1e20_Slab2Deep_1e23/solver_history.txt
for the full convergence history.
The solver reported the following error:
--------------------------------------------------------
An error occurred in line <3034> of file
</work2/09569/tzhao2/stampede3/software/aspect/source/utilities.cc> in
function
void aspect::Utilities::throw_linear_solver_failure_exception(const
std::string &, const std::string &, const std::vector<SolverControl>
&, const std::exception &, const MPI_Comm, const std::string &)
The violated condition was:
false
Additional information:
The iterative (bottom right) solver in
BlockSchurGMGPreconditioner::vmult did not converge.
The initial residual was: 9.888465e-01
The final residual is: 1.333543e-01
The required residual for convergence is: 9.888465e-07
The solver reported the following error:
--------------------------------------------------------
An error occurred in line <1338> of file
</work2/09569/tzhao2/stampede3/software/deal.II-v9.5.2/deal.II-v9.5.2/include/deal.II/lac/solver_cg.h>
in function
void
dealii::SolverCG<dealii::LinearAlgebra::distributed::Vector<double,
dealii::MemorySpace::Host>>::solve(const MatrixType &, VectorType &,
const VectorType &, const PreconditionerType &) [VectorType =
dealii::LinearAlgebra::distributed::Vector<double,
dealii::MemorySpace::Host>, MatrixType =
aspect::MatrixFreeStokesOperators::MassMatrixOperator<3, 1, double>,
PreconditionerType = dealii::PreconditionMG<3,
dealii::LinearAlgebra::distributed::Vector<double,
dealii::MemorySpace::Host>, MatrixType =
aspect::MatrixFreeStokesOperators::MassMatrixOperator<3, 1, double>,
PreconditionerType = dealii::PreconditionMG<3,
dealii::LinearAlgebra::distributed::Vector<double,
dealii::MemorySpace::Host>, dealii::MGTransferMatrixFree<3, double>>]
The violated condition was:
solver_state == SolverControl::success
Additional information:
Iterative method reported convergence failure in step 100. The
residual in the last step was 0.133354.
This error message can indicate that you have simply not allowed a
sufficiently large number of iterations for your iterative solver to
converge. This often happens when you increase the size of your
problem. In such cases, the last residual will likely still be very
small, and you can make the error go away by increasing the allowed
number of iterations when setting up the SolverControl object that
determines the maximal number of iterations you allow.
The other situation where this error may occur is when your matrix is
not invertible (e.g., your matrix has a null-space), or if you try to
apply the wrong solver to a matrix (e.g., using CG for a matrix that
is not symmetric or not positive definite). In these cases, the
residual in the last iteration is likely going to be large.
Stacktrace:
-----------
Does my viscosity contrast setting or solver setting need to be improved? I ran several viscosity contrast test before with aspect2.6.0-pre on frontera (using AMG) , it always worked, now it doesnt work anymore,
I would appreciate any help or advise, thanks for your time!
Hi,
I also tried this model using GMG several weeks ago. Here are some suggestions which might be helpful:
- set Linear solver S block tolerance = 1e-5
- set Number of cheap Stokes solver steps = 30000
- set GMRES restart length = 2000
I think the above adjustments can ensure the convergence of GMG solver.
Bests, Xinyu Li
Hi,
I also tried this model using GMG several weeks ago. Here are some suggestions which might be helpful:
1. set Linear solver S block tolerance = 1e-5 2. set Number of cheap Stokes solver steps = 30000 3. set GMRES restart length = 2000I think the above adjustments can ensure the convergence of GMG solver.
Bests, Xinyu Li
Thank you Xinyu, it does converge now!