<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1253">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
See <a href="https://doc.comsol.com/5.5/doc/com.comsol.help.comsol/comsol_ref_solver.27.123.html" id="LPlnk">https://doc.comsol.com/5.5/doc/com.comsol.help.comsol/comsol_ref_solver.27.123.html</a></div>
<div class="_Entity _EType_OWALinkPreview _EId_OWALinkPreview_1 _EReadonly_1">
<div id="LPBorder_GTaHR0cHM6Ly9kb2MuY29tc29sLmNvbS81LjUvZG9jL2NvbS5jb21zb2wuaGVscC5jb21zb2wvY29tc29sX3JlZl9zb2x2ZXIuMjcuMTIzLmh0bWw." class="LPBorder321641" style="width: 100%; margin-top: 16px; margin-bottom: 16px; position: relative; max-width: 800px; min-width: 424px;">
<table id="LPContainer321641" role="presentation" style="padding: 12px 36px 12px 12px; width: 100%; border-width: 1px; border-style: solid; border-color: rgb(200, 200, 200); border-radius: 2px;">
<tbody>
<tr valign="top" style="border-spacing: 0px;">
<td style="width: 100%;">
<div id="LPTitle321641" style="font-size: 21px; font-weight: 300; margin-right: 8px; font-family: wf_segoe-ui_light, "Segoe UI Light", "Segoe WP Light", "Segoe UI", "Segoe WP", Tahoma, Arial, sans-serif; margin-bottom: 12px;">
<a target="_blank" id="LPUrlAnchor321641" href="https://doc.comsol.com/5.5/doc/com.comsol.help.comsol/comsol_ref_solver.27.123.html" style="text-decoration: none; color: var(--themePrimary);">The Iterative Solvers - COMSOL Multiphysics</a></div>
<div id="LPDescription321641" style="font-size: 14px; max-height: 100px; color: rgb(102, 102, 102); font-family: wf_segoe-ui_normal, "Segoe UI", "Segoe WP", Tahoma, Arial, sans-serif; margin-bottom: 12px; margin-right: 8px; overflow: hidden;">
The relaxation factor ù to some extent controls the stability and convergence properties of a numerical solver by shifting its eigenvalue spectrum. The optimal value for the relaxation factor can improve convergence significantly — for example, for SOR when
used as a solver. However, the optimal choice is typically a subtle task with arbitrary complexity.</div>
<div id="LPMetadata321641" style="font-size: 14px; font-weight: 400; color: rgb(166, 166, 166); font-family: wf_segoe-ui_normal, "Segoe UI", "Segoe WP", Tahoma, Arial, sans-serif;">
doc.comsol.com</div>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
We use BCGS for constant memory while gmres without restart requires increased memory but has predictable convergence than BCGS.</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Hong</div>
<div class="_Entity _EType_OWALinkPreview _EId_OWALinkPreview _EReadonly_1"></div>
<br>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> petsc-users <petsc-users-bounces@mcs.anl.gov> on behalf of Jed Brown <jed@jedbrown.org><br>
<b>Sent:</b> Wednesday, September 29, 2021 5:28 PM<br>
<b>To:</b> Marco Cisternino <marco.cisternino@optimad.it>; petsc-users@mcs.anl.gov <petsc-users@mcs.anl.gov><br>
<b>Subject:</b> Re: [petsc-users] FGMRES and BCGS</font>
<div> </div>
</div>
<div class="BodyFragment"><font size="2"><span style="font-size:11pt;">
<div class="PlainText">It is not surprising. BCGS uses less memory for the Krylov vectors, but that might be a small fraction of the total memory used (considering your matrix and GAMG). FGMRES(30) needs 60 work vectors (2 per iteration). If you're using a
linear (non-iterative) preconditioner, then you don't need a flexible method -- plain GMRES should be fine. FGMRES uses the unpreconditioned norm, which you can also get via -ksp_type gmres -ksp_norm_type unpreconditioned.<br>
<br>
This classic paper shows that for any class of nonsymmetric Krylov method, there are matrices in which that method outperforms every other method by at least sqrt(N).<br>
<br>
<a href="https://epubs.siam.org/doi/10.1137/0613049">https://epubs.siam.org/doi/10.1137/0613049</a><br>
<br>
Marco Cisternino <marco.cisternino@optimad.it> writes:<br>
<br>
> Good Morning,<br>
> I usually solve a non-symmetric discretization of the Poisson equation using GAMG+FGMRES.<br>
> In the last days I tried to use BCGS in place of FGMRES, still using GAMG as preconditioner.<br>
> No problem in finding the solution but I'm experiencing something I didn't expect.<br>
> The test case is a 25 millions cells domain with Dirichlet and Neumann boundary conditions.<br>
> Both the solvers are able to solve the problem with an increasing number of MPI processes, but:<br>
><br>
> * FGMRES is about 25% faster than BCGS for all the processes number<br>
> * Both solvers have the same scalability from 48 to 384 processes<br>
> * Both solvers almost use the same amount of memory (FGMRES use a restart=30)<br>
> Am I wrong expecting less memory consumption and more performance from BCGS with respect to FGMRES?<br>
> Thank you in advance for any help.<br>
><br>
> Best regards,<br>
> Marco Cisternino<br>
</div>
</span></font></div>
</body>
</html>