<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html;
      charset=windows-1252">
  </head>
  <body>
    <p>Thanks Pierre for the clarification, perhaps it would be useful
      to print ||r(i)||/||b|| according to ksp_norm_type?<br>
      <br>
      <br>
    </p>
    <p><br>
    </p>
    <div class="moz-cite-prefix">On 11/25/20 5:29 PM, Pierre Jolivet
      wrote:<br>
    </div>
    <blockquote type="cite"
      cite="mid:197C066B-B5E9-477C-BA99-E9C0A9D2114D@joliv.et">
      <meta http-equiv="Content-Type" content="text/html;
        charset=windows-1252">
      Dear Nicola,
      <div class="">rtol is relative tolerance: everything is computed
        with respect to r_0.</div>
      <div class="">So, for the preconditioned case:
        3.759000903215e-04/5.033493299009e+03 < 1e-07</div>
      <div class="">For the unpreconditioned
        case: 8.902026754193e-06/3.204525251924e+02 < 1e-07<br
          class="">
        <div class="">
          <div>Is it clearer that way?</div>
          <div><br class="">
          </div>
          <div>Thanks,</div>
          <div>Pierre</div>
          <div><br class="">
            <blockquote type="cite" class="">
              <div class="">On 25 Nov 2020, at 4:14 PM, Nicola Varini
                <<a href="mailto:nicola.varini@epfl.ch" class=""
                  moz-do-not-send="true">nicola.varini@epfl.ch</a>>
                wrote:</div>
              <br class="Apple-interchange-newline">
              <div class="">
                <div class="">
                  <p class="">Dear all, forgive me if the following
                    question is trivial, but I am trying to figure out<br
                      class="">
                    how the convergence criteria works in case of
                    -ksp_norm_type preconditioned.<br class="">
                    Below you can find the logs for preconditioned vs
                    unpreconditioned. The solver converge with reason
                    converged_rtol.<br class="">
                    -ksp_rtol=1e-7<br class="">
                    In the case of unpreconditioned norm it is clear
                    that ||r||/||b||<1e-7 at iteration 12.<br
                      class="">
                    In the case of preconditioned norm it should be
                    ||r||/||b|| = 1.17e-06.<br class="">
                    What am I missing?<br class="">
                    <br class="">
                    <b class="">PRECONDITIONED NORM</b><br class="">
                      0 KSP preconditioned resid norm 5.033493299009e+03
                    true resid norm 3.204525251924e+02 ||r(i)||/||b||
                    1.000000000000e+00<br class="">
                      1 KSP preconditioned resid norm 3.425803632572e+02
                    true resid norm 1.937892001317e+02 ||r(i)||/||b||
                    6.047360682066e-01<br class="">
                      2 KSP preconditioned resid norm 4.382931341126e+01
                    true resid norm 5.154130142755e+01 ||r(i)||/||b||
                    1.608391177339e-01<br class="">
                      3 KSP preconditioned resid norm 4.272202338001e+00
                    true resid norm 9.790042315960e+00 ||r(i)||/||b||
                    3.055067926234e-02<br class="">
                      4 KSP preconditioned resid norm 2.728350554402e-01
                    true resid norm 1.065721671294e+00 ||r(i)||/||b||
                    3.325677245496e-03<br class="">
                      5 KSP preconditioned resid norm 2.269929645857e-02
                    true resid norm 1.475155830456e-01 ||r(i)||/||b||
                    4.603352180079e-04<br class="">
                      6 KSP preconditioned resid norm 7.380512306491e-03
                    true resid norm 4.703550871658e-02 ||r(i)||/||b||
                    1.467783993536e-04<br class="">
                      7 KSP preconditioned resid norm 1.413199151428e-03
                    true resid norm 1.452742106199e-02 ||r(i)||/||b||
                    4.533408202436e-05<br class="">
                      8 KSP preconditioned resid norm 3.759000903215e-04
                    true resid norm 4.907814057015e-03 ||r(i)||/||b||
                    1.531526098622e-05<br class="">
                  </p>
                  <p class=""><b class="">UNPRECONDITIONED NORM</b><br
                      class="">
                  </p>
                  <p class="">  0 KSP unpreconditioned resid norm
                    3.204525251924e+02 true resid norm
                    3.204525251924e+02 ||r(i)||/||b|| 1.000000000000e+00<br
                      class="">
                      1 KSP unpreconditioned resid norm
                    1.310814475877e+02 true resid norm
                    1.310814475877e+02 ||r(i)||/||b|| 4.090510677331e-01<br
                      class="">
                      2 KSP unpreconditioned resid norm
                    2.319724277605e+01 true resid norm
                    2.319724277605e+01 ||r(i)||/||b|| 7.238901538416e-02<br
                      class="">
                      3 KSP unpreconditioned resid norm
                    2.060554152717e+00 true resid norm
                    2.060554152717e+00 ||r(i)||/||b|| 6.430138603150e-03<br
                      class="">
                      4 KSP unpreconditioned resid norm
                    2.471285360225e-01 true resid norm
                    2.471285360226e-01 ||r(i)||/||b|| 7.711861090006e-04<br
                      class="">
                      5 KSP unpreconditioned resid norm
                    6.698832182690e-02 true resid norm
                    6.698832182689e-02 ||r(i)||/||b|| 2.090428895409e-04<br
                      class="">
                      6 KSP unpreconditioned resid norm
                    1.941260318181e-02 true resid norm
                    1.941260318179e-02 ||r(i)||/||b|| 6.057871808041e-05<br
                      class="">
                      7 KSP unpreconditioned resid norm
                    5.610469571259e-03 true resid norm
                    5.610469571233e-03 ||r(i)||/||b|| 1.750795868394e-05<br
                      class="">
                      8 KSP unpreconditioned resid norm
                    1.357950031961e-03 true resid norm
                    1.357950031957e-03 ||r(i)||/||b|| 4.237601283190e-06<br
                      class="">
                      9 KSP unpreconditioned resid norm
                    4.277774357590e-04 true resid norm
                    4.277774357315e-04 ||r(i)||/||b|| 1.334916725885e-06<br
                      class="">
                     10 KSP unpreconditioned resid norm
                    1.171326258320e-04 true resid norm
                    1.171326258188e-04 ||r(i)||/||b|| 3.655225551692e-07<br
                      class="">
                     11 KSP unpreconditioned resid norm
                    3.381696730013e-05 true resid norm
                    3.381696731034e-05 ||r(i)||/||b|| 1.055287902320e-07<br
                      class="">
                     12 KSP unpreconditioned resid norm
                    8.902026754193e-06 true resid norm
                    8.902026767788e-06 ||r(i)||/||b|| 2.777954944322e-08<br
                      class="">
                    <br class="">
                    <br class="">
                    Thanks,<br class="">
                    <br class="">
                    Nicola<br class="">
                  </p>
                </div>
              </div>
            </blockquote>
          </div>
          <br class="">
        </div>
      </div>
    </blockquote>
  </body>
</html>