| /petsc/src/sys/utils/ |
| H A D | mathclose.c | 17 PetscBool PetscIsCloseAtTol(PetscReal a, PetscReal b, PetscReal rtol, PetscReal atol) in PetscIsCloseAtTol() argument 27 rtol = PetscAbsReal(rtol); in PetscIsCloseAtTol() 31 …return ((diff <= PetscAbsReal(rtol * b)) || (diff <= PetscAbsReal(rtol * a)) || (diff <= atol)) ? … in PetscIsCloseAtTol()
|
| /petsc/src/snes/impls/gs/ |
| H A D | snesgs.c | 33 PetscErrorCode SNESNGSSetTolerances(SNES snes, PetscReal abstol, PetscReal rtol, PetscReal stol, Pe… in SNESNGSSetTolerances() argument 44 if (rtol != (PetscReal)PETSC_CURRENT) { in SNESNGSSetTolerances() 45 …rtol >= 0.0 && rtol < 1.0, PetscObjectComm((PetscObject)snes), PETSC_ERR_ARG_OUTOFRANGE, "Relative… in SNESNGSSetTolerances() 46 gs->rtol = rtol; in SNESNGSSetTolerances() 79 PetscErrorCode SNESNGSGetTolerances(SNES snes, PetscReal *atol, PetscReal *rtol, PetscReal *stol, P… in SNESNGSGetTolerances() argument 86 if (rtol) *rtol = gs->rtol; in SNESNGSGetTolerances() 172 PetscReal rtol = PETSC_CURRENT, atol = PETSC_CURRENT, stol = PETSC_CURRENT; in SNESSetFromOptions_NGS() local 181 …s_rtol", "Relative residual tolerance for GS iteration", "SNESComputeGS", gs->rtol, &rtol, &flg1)); in SNESSetFromOptions_NGS() 184 if (flg || flg1 || flg2 || flg3) PetscCall(SNESNGSSetTolerances(snes, atol, rtol, stol, max_its)); in SNESSetFromOptions_NGS() 339 gs->rtol = 1e-5; in SNESCreate_NGS()
|
| /petsc/src/ksp/ksp/impls/gmres/fgmres/ |
| H A D | modpcf.c | 76 PetscReal rtol, abstol, dtol; in KSPFlexibleModifyPCKSP() local 91 PetscCall(KSPGetTolerances(sub_ksp, &rtol, &abstol, &dtol, &maxits)); in KSPFlexibleModifyPCKSP() 92 if (!loc_its) rtol = .1; in KSPFlexibleModifyPCKSP() 93 else rtol *= .9; in KSPFlexibleModifyPCKSP() 94 PetscCall(KSPSetTolerances(sub_ksp, rtol, abstol, dtol, maxits)); in KSPFlexibleModifyPCKSP()
|
| /petsc/src/dm/dt/fe/tests/ |
| H A D | ex4.c | 45 #define CheckVals(a, b, rtol, atol, msg) \ argument 47 …if (!PetscIsCloseAtTolScalar(a, b, rtol, atol)) PetscCall(PetscPrintf(PETSC_COMM_WORLD, "%s: %g (%… 55 PetscReal rtol = PETSC_SMALL, atol = 0.0; in main() local 94 CheckVals(vals[0], vals[1], rtol, atol, "Error volume"); in main() 95 CheckVals((3 + dim) * vals[0], vals[3], rtol, atol, "Error mass"); in main() 96 CheckVals((3 + dim) * vals[0], vals[4], rtol, atol, "Error local lumped mass"); in main() 97 CheckVals((3 + dim) * vals[0], vals[5], rtol, atol, "Error lumped mass"); in main()
|
| /petsc/src/vec/vec/tests/ |
| H A D | ex63.c | 7 const PetscReal rtol = 1e-10, atol = PETSC_SMALL; in CheckExp() local 22 if (!PetscIsCloseAtTolScalar(lhs, rhs, rtol, atol)) { in CheckExp() 28 …PetscCheck(PetscIsCloseAtTol(lhs_r, rhs_r, rtol, atol), PETSC_COMM_SELF, PETSC_ERR_PLIB, "Real com… in CheckExp() 29 …PetscCheck(PetscIsCloseAtTol(lhs_i, rhs_i, rtol, atol), PETSC_COMM_SELF, PETSC_ERR_PLIB, "Imaginar… in CheckExp()
|
| H A D | ex64.c | 7 const PetscReal rtol = 1e-10, atol = PETSC_SMALL; in CheckLog() local 22 if (!PetscIsCloseAtTolScalar(lhs, rhs, rtol, atol)) { in CheckLog() 28 …PetscCheck(PetscIsCloseAtTol(lhs_r, rhs_r, rtol, atol), PETSC_COMM_SELF, PETSC_ERR_PLIB, "Real com… in CheckLog() 29 …PetscCheck(PetscIsCloseAtTol(lhs_i, rhs_i, rtol, atol), PETSC_COMM_SELF, PETSC_ERR_PLIB, "Imaginar… in CheckLog()
|
| /petsc/src/vec/vec/utils/tagger/impls/ |
| H A D | cdf.c | 18 PetscReal rtol; member 161 PetscReal rtol, atol; in VecTaggerComputeBox_CDF_SortedArray_Iterative() local 167 rtol = cdf->rtol; in VecTaggerComputeBox_CDF_SortedArray_Iterative() 265 …if ((atol || rtol) && ((!atol) || (maxDiff <= atol)) && ((!rtol) || (maxDiff <= rtol * intervalLen… in VecTaggerComputeBox_CDF_SortedArray_Iterative() 394 … PetscInt_FMT ", abs tol: %g, rel tol %g\n", cuml->maxit, (double)cuml->atol, (double)cuml->rtol)); in VecTaggerView_CDF() 413 …ute boxes from CDF boxes", "VecTaggerCDFIterativeSetTolerances()", cuml->rtol, &cuml->rtol, NULL)); in VecTaggerSetFromOptions_CDF() 485 PetscErrorCode VecTaggerCDFIterativeSetTolerances(VecTagger tagger, PetscInt maxit, PetscReal rtol,… in VecTaggerCDFIterativeSetTolerances() argument 492 PetscValidLogicalCollectiveReal(tagger, rtol, 3); in VecTaggerCDFIterativeSetTolerances() 495 cuml->rtol = rtol; in VecTaggerCDFIterativeSetTolerances() 518 …aggerCDFIterativeGetTolerances(VecTagger tagger, PetscInt *maxit, PetscReal *rtol, PetscReal *atol) in VecTaggerCDFIterativeGetTolerances() argument [all …]
|
| /petsc/src/binding/petsc4py/demo/legacy/petsc-examples/ksp/ |
| H A D | ex2.py | 169 rtol=1.e-2/((m+1)*(n+1)) variable 170 ksp.setTolerances(rtol=rtol,atol=1.e-50) 199 if norm > rtol*10:
|
| /petsc/src/mat/tests/ |
| H A D | ex261.c | 8 const PetscReal rtol = 1e-10, atol = PETSC_SMALL; in CheckDiagonal() local 36 if (!PetscIsCloseAtTolScalar(lhs, dval, rtol, atol)) { in CheckDiagonal() 42 …PetscCheck(PetscIsCloseAtTol(lhs_r, dval_r, rtol, atol), PETSC_COMM_SELF, PETSC_ERR_PLIB, "Real co… in CheckDiagonal() 43 …PetscCheck(PetscIsCloseAtTol(lhs_i, dval_i, rtol, atol), PETSC_COMM_SELF, PETSC_ERR_PLIB, "Imagina… in CheckDiagonal()
|
| /petsc/src/snes/linesearch/interface/ |
| H A D | linesearch.c | 196 linesearch->rtol = 1e-8; in SNESLineSearchCreate() 845 …iterative line search", "SNESLineSearchSetTolerances", linesearch->rtol, &linesearch->rtol, NULL)); in SNESLineSearchSetFromOptions() 910 … tolerances: relative=%e, absolute=%e, lambda=%e\n", (double)linesearch->rtol, (double)linesearch… in SNESLineSearchView() 1124 …Search linesearch, PetscReal *minlambda, PetscReal *maxlambda, PetscReal *rtol, PetscReal *atol, P… in SNESLineSearchGetTolerances() argument 1136 if (rtol) { in SNESLineSearchGetTolerances() 1137 PetscAssertPointer(rtol, 4); in SNESLineSearchGetTolerances() 1138 *rtol = linesearch->rtol; in SNESLineSearchGetTolerances() 1184 …ineSearch linesearch, PetscReal minlambda, PetscReal maxlambda, PetscReal rtol, PetscReal atol, Pe… in SNESLineSearchSetTolerances() argument 1190 PetscValidLogicalCollectiveReal(linesearch, rtol, 4); in SNESLineSearchSetTolerances() 1206 if (rtol != (PetscReal)PETSC_DEFAULT) { in SNESLineSearchSetTolerances() [all …]
|
| /petsc/src/snes/linesearch/impls/bisection/ |
| H A D | linesearchbisection.c | 13 PetscReal rtol, atol, ltol; in SNESLineSearchApply_Bisection() local 20 PetscCall(SNESLineSearchGetTolerances(linesearch, NULL, NULL, &rtol, &atol, <ol, &max_it)); in SNESLineSearchApply_Bisection() 98 if (PetscAbsScalar(fty) / PetscAbsScalar(fty_initial) <= rtol) { in SNESLineSearchApply_Bisection() 101 …= %g <= rtol = %g\n", (double)(PetscAbsScalar(fty) / PetscAbsScalar(fty_initial)), (double)rtol)); in SNESLineSearchApply_Bisection() 222 linesearch->rtol = 1e-8; in SNESLineSearchCreate_Bisection()
|
| /petsc/src/tao/leastsquares/impls/pounders/ |
| H A D | gqt.c | 214 …t n, PetscReal *a, PetscInt lda, PetscReal *b, PetscReal delta, PetscReal rtol, PetscReal atol, Pe… in gqt() argument 273 paru = PetscMax(paru, (1.0 + rtol) * parl); in gqt() 311 …if (PetscAbs(xnorm - delta) <= rtol * delta || (par == 0 && xnorm <= (1.0 + rtol) * delta)) info =… in gqt() 333 …if (p5 * rznorm * rznorm / delta2 <= rtol * (1.0 - p5 * rtol) * (par + rxnorm * rxnorm / delta2)) { in gqt() 392 paru = PetscMax(paru, (1.0 + rtol) * pars); in gqt() 401 if (paru <= (1.0 + p5 * rtol) * pars) info = 3; in gqt()
|
| /petsc/src/ts/tutorials/output/ |
| H A D | ex20opt_ic_3.out | 22 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9 38 rtol: 2 47 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9
|
| H A D | ex20opt_ic_2.out | 22 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9 38 rtol: 2 47 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9
|
| /petsc/src/ts/tutorials/optimal_control/output/ |
| H A D | ex1_3.out | 24 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9 41 rtol: 3 50 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9
|
| H A D | ex1_2.out | 24 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9 41 rtol: 4 50 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9
|
| /petsc/src/ksp/ksp/tests/ |
| H A D | ex13.c | 31 PetscReal rtol = PETSC_DEFAULT; in main() local 42 rtol = 1.e-10; in main() 49 rtol = 1.e-5; in main() 173 PetscCall(KSPSetTolerances(ksp, rtol, PETSC_CURRENT, PETSC_CURRENT, PETSC_CURRENT)); in main()
|
| /petsc/src/tao/bound/tutorials/output/ |
| H A D | plate2_20_alt.out | 24 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9 43 rtol: 3 52 tolerances: ftol=0.0001, rtol=1e-05, gtol=0.9
|
| H A D | plate2_20.out | 24 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9 43 rtol: 3 52 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9
|
| H A D | plate2_10.out | 23 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9 42 rtol: 4 51 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9
|
| H A D | plate2_12.out | 24 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9 43 rtol: 3 52 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9
|
| H A D | plate2_11.out | 24 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9 43 rtol: 3 52 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9
|
| H A D | plate2_18.out | 23 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9 42 rtol: 4 51 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9
|
| /petsc/src/tao/leastsquares/tutorials/output/ |
| H A D | cs1_view_l1dict.out | 20 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9 38 rtol: 5 47 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9
|
| H A D | cs1_view_l1dict_alt.out | 20 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9 38 rtol: 6 47 tolerances: ftol=0.0001, rtol=1e-10, gtol=0.9
|