<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hi Dave,<div><span class="Apple-tab-span" style="white-space:pre">        </span>Thanks for your help.&nbsp;</div><div><br></div><div>Max<br><div><div><br></div><blockquote type="cite"><span class="Apple-style-span" style="border-collapse: separate; font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; font-size: medium; ">Hey Max,<br><br>Without knowing anything about the specific application related to<br>your Stokes problem, or information about the mesh you are using, I<br>have a couple of questions and suggestions which might help.<br></span></blockquote><div><br></div><div>The test case that I am working with is isoviscous convection, benchmark case 1a from Blankenbach 1989.</div><br><blockquote type="cite"><span class="Apple-style-span" style="border-collapse: separate; font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; font-size: medium; ">1) If &nbsp;A, is your stokes operator A = ( K,B ; B^T, 0 ), what is your<br>precondition operator?<br>Specifically, what is in the (2,2) slot in the precondioner? - i.e.<br>what matrix are you you applying -stokes_fieldsplit_1_pc_type jacobi<br>-stokes_fieldsplit_1_ksp_type preonly to?<br>Is it the identity as in the SpeedUp notes?<br></span></blockquote><div><br></div><div>I think that this is the problem. The (2,2) slot in the LHS matrix is all zero (pressure does not appear in the continuity equation), so I think that the preconditioner is meaningless. I am still confused as to why this choice of preconditioner was suggested in the tutorial, and what is a better choice of preconditioner for this block? Should I be using one of the Schur complement methods instead of the additive or multiplicative field split?</div><div><br></div><blockquote type="cite"><span class="Apple-style-span" style="border-collapse: separate; font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; font-size: medium; ">2) This choice<br>-stokes_fieldsplit_0_pc_type ml -stokes_fieldsplit_0_ksp_type preonly<br>may simply not be a very effective and degrade the performance of the<br>outer solver.<br>I'd make the solver for the operator in the (1,1) slot much stronger,<br>for example<br>&nbsp;-stokes_fieldsplit_0_ksp_type gmres<br>&nbsp;-stokes_fieldsplit_0_ksp_rtol 1.0e-4<br>&nbsp;-stokes_fieldsplit_0_mg_levels_ksp_type gmres<br>&nbsp;-stokes_fieldsplit_0_mg_levels_pc_type bjacobi<br>&nbsp;-stokes_fieldsplit_0_mg_levels_ksp_max_it 4<br><br>Add a monitor on this solver (-stokes_fieldsplit_0_ksp_XXX) to see how<br>ML is doing.<br><br>3) Using -stokes_pc_fieldsplit_type MULTIPLICATIVE should reduce the<br>number of outer iterations by a factor of two, but it will use more<br>memory.</span></blockquote><blockquote type="cite"><span class="Apple-style-span" style="border-collapse: separate; font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; font-size: medium; ">4) You should use a flexible Krylov method on the outer most solve<br>(-stokes_ksp_XXX) as the preconditioner is varying between each outer<br>iteration. Use -stokes_ksp_type fgmres or -stokes_ksp_type gcr<br></span></blockquote><div><br></div><div>Thanks for pointing this out. I made that change.</div><br><blockquote type="cite"><span class="Apple-style-span" style="border-collapse: separate; font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; font-size: medium; ">5) Depending on how the physical problem is scaled<br>(non-dimensionalised), the size of the residuals associated with the<br>momentum and continuity equation make be quite different. You are<br>currently use the entire residual from (u,p) to determine when to stop<br>iterating. You might want to consider writing a monitor which examines<br>the these residuals independently.<br></span></blockquote><div><br></div><div>I think that I have scaled the problem correctly. I (slowly) obtain a sufficiently accurate solution using as options only:</div><div>-stokes_ksp_atol 1e-5 -stokes_ksp_rtol 1e-5 -stokes_ksp_monitor_true_residual -stokes_ksp_norm_type UNPRECONDITIONED</div><br><blockquote type="cite"><br><br>Cheers,<br>&nbsp;Dave</blockquote></div><br></div></body></html>