![]() |
FrontISTR
5.9.0
Large-scale structural analysis program with finit element method
|
This module provides a unified convergence check for Newton iteration. More...
Functions/Subroutines | |
| subroutine, public | fstr_check_convergence (hecMESH, hecMAT, fstrSOLID, fstrPR, ndof, iter, sub_step, cstep, residual_vec, nresid, resb, res_prev, n_node_global, iterStatus, maxDLag, converg_dlag) |
| Wrapper that calls fstr_check_convergence_main and applies the common divergence/NaN handling (status classification, failure logging, fstrSOLID stats update). More... | |
| subroutine, public | fstr_check_convergence_main (hecMESH, hecMAT, fstrSOLID, fstrPR, ndof, iter, cstep, residual_vec, nresid, resb, res_prev, n_node_global, iterStatus, do_failure_check, res_for_check, maxDLag, converg_dlag) |
| Core convergence check: computes residual norm, applies the per-path convergence criterion, and (when not converged) returns the residual value used to decide divergence in the caller. More... | |
This module provides a unified convergence check for Newton iteration.
The subroutine fstr_check_convergence computes residual norms from the assembled residual vector and checks convergence/divergence criteria. It replaces the former fstr_check_iteration_converged and various inline convergence checks in contact and dynamic analysis routines.
| subroutine, public m_fstr_iterationcontrol::fstr_check_convergence | ( | type(hecmwst_local_mesh), intent(in) | hecMESH, |
| type(hecmwst_matrix), intent(in) | hecMAT, | ||
| type(fstr_solid), intent(inout) | fstrSOLID, | ||
| type(fstr_param), intent(in) | fstrPR, | ||
| integer(kind=kint), intent(in) | ndof, | ||
| integer(kind=kint), intent(in) | iter, | ||
| integer(kind=kint), intent(in) | sub_step, | ||
| integer(kind=kint), intent(in) | cstep, | ||
| real(kind=kreal), dimension(:), intent(in) | residual_vec, | ||
| integer(kind=kint), intent(in) | nresid, | ||
| real(kind=kreal), intent(inout) | resb, | ||
| real(kind=kreal), intent(inout) | res_prev, | ||
| integer(kind=kint), intent(in) | n_node_global, | ||
| integer(kind=kint), intent(out) | iterStatus, | ||
| real(kind=kreal), intent(in), optional | maxDLag, | ||
| real(kind=kreal), intent(in), optional | converg_dlag | ||
| ) |
Wrapper that calls fstr_check_convergence_main and applies the common divergence/NaN handling (status classification, failure logging, fstrSOLID stats update).
The body fstr_check_convergence_main is kept separate so that customized convergence criteria can be implemented by swapping/extending it without touching the failure-handling boilerplate here.
Definition at line 29 of file fstr_CheckConvergence.f90.
| subroutine, public m_fstr_iterationcontrol::fstr_check_convergence_main | ( | type(hecmwst_local_mesh), intent(in) | hecMESH, |
| type(hecmwst_matrix), intent(in) | hecMAT, | ||
| type(fstr_solid), intent(inout) | fstrSOLID, | ||
| type(fstr_param), intent(in) | fstrPR, | ||
| integer(kind=kint), intent(in) | ndof, | ||
| integer(kind=kint), intent(in) | iter, | ||
| integer(kind=kint), intent(in) | cstep, | ||
| real(kind=kreal), dimension(:), intent(in) | residual_vec, | ||
| integer(kind=kint), intent(in) | nresid, | ||
| real(kind=kreal), intent(inout) | resb, | ||
| real(kind=kreal), intent(inout) | res_prev, | ||
| integer(kind=kint), intent(in) | n_node_global, | ||
| integer(kind=kint), intent(out) | iterStatus, | ||
| logical, intent(out) | do_failure_check, | ||
| real(kind=kreal), intent(out) | res_for_check, | ||
| real(kind=kreal), intent(in), optional | maxDLag, | ||
| real(kind=kreal), intent(in), optional | converg_dlag | ||
| ) |
Core convergence check: computes residual norm, applies the per-path convergence criterion, and (when not converged) returns the residual value used to decide divergence in the caller.
Branching is by fstrPRsolution_type (static/dynamic) and n_node_global (>0 = contact path). Currently used paths:
| [in] | hecMESH | mesh |
| [in] | hecMAT | matrix (B=residual, X=solution increment) |
| [in,out] | fstrSOLID | solid data (QFORCE, dunode) |
| [in] | fstrPR | global parameters (solution_type, nlgeom) |
| [in] | ndof | degrees of freedom per node |
| [in] | iter | current Newton iteration number |
| [in] | cstep | current loading step number |
| [in] | residual_vec | assembled residual vector (used by contact paths) |
| [in] | nresid | size of residual_vec |
| [in,out] | resb | reference residual for self-normalization (set at iter=1) |
| [in,out] | res_prev | previous normalized residual (for relres computation) |
| [in] | n_node_global | total internal node count (>0 for contact path, 0 for non-contact) |
| [out] | iterStatus | kitrConverged or kitrContinue (failure paths handled by caller) |
| [out] | do_failure_check | true if caller should run divergence/NaN check |
| [out] | res_for_check | residual value the caller should use for divergence check |
| [in] | maxDLag | (optional) max change of Lagrange multiplier |
| [in] | converg_dlag | (optional) threshold for maxDLag |
Definition at line 137 of file fstr_CheckConvergence.f90.