<div dir="auto">Great, thanks! </div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Sun, 25 Sep 2022, 17:55 Barry Smith, <<a href="mailto:bsmith@petsc.dev">bsmith@petsc.dev</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word;line-break:after-white-space"><div><br></div><div>  Thanks for the bug report; your fix is correct. I have corrected it in PETSc and also added support for multiple block per MPI rank in  <a href="https://gitlab.com/petsc/petsc/-/merge_requests/5678" target="_blank" rel="noreferrer">https://gitlab.com/petsc/petsc/-/merge_requests/5678</a></div><div><br></div><div>  Barry</div><div><br></div><div><br><blockquote type="cite"><div><div><br><br>---------- Forwarded message ----------<br>Date: Thu, 22 Sep 2022 02:31:37 +0300<br>From: Abylay Zhumekenov <<a href="mailto:ablay94z@gmail.com" target="_blank" rel="noreferrer">ablay94z@gmail.com</a>><br>To: <a href="mailto:petsc-users@mcs.anl.gov" target="_blank" rel="noreferrer">petsc-users@mcs.anl.gov</a><br>Subject: [petsc-users] PCApplySymmetricRight for PCBJACOBI<br><br>Hello,<br><br>I have been playing around with a block Jacobi preconditioner (PCJACOBI)<br>with an incomplete Cholesky (PCICC) sub-preconditioner. Although you cannot<br>set KSPSetPCSide to PC_SYMMETRIC for PCBJACOBI, you still can do it for<br>PCICC. I was surprised to find that PCApplySymmetricLeft is properly<br>applied to a vector. However, PCApplySymmetricRight throws an error:<br>...<br>    [0]PETSC ERROR: Object is in wrong state<br>    [0]PETSC ERROR: VecPlaceArray() was already called on this vector,<br>without a call to VecResetArray()<br>    ...<br>    [0]PETSC ERROR: #3 PCApplySymmetricLeft_BJacobi_Singleblock() at<br>/home/abylay/KAUST/Libraries/C/petsc/src/ksp/pc/impls/bjacobi/bjacobi.c:660<br>    [0]PETSC ERROR: #4 PCApplySymmetricLeft() at<br>/home/abylay/KAUST/Libraries/C/petsc/src/ksp/pc/interface/precon.c:532<br>...<br>The problem goes away if I add:<br>...<br>    PetscCall(VecResetArray(bjac->x));<br>    PetscCall(VecResetArray(bjac->y));<br>...<br>at line 698 in source file bjacobi.c. I don't know if it is a bug, and how<br>I should report it, just wanted let someone know if it is.<br>Thanks.<br><br>Abylay Zhumekenov<br></div></div></blockquote></div><br></div></blockquote></div>