> On Jun 4, 2025, at 1:06 PM, Mark Adams <mfad...@lbl.gov> wrote: > > It looks like it pivots in blocks and is a point-wise ILU: > https://urldefense.us/v3/__https://petsc.org/release/manualpages/PC/PCILU/__;!!G_uCfscf7eWS!bLJjV_o5EdHrYFCvaAx1cH4gN3bYp79B0t10NWDhrlPZQWdn7KcKBX_pOyjuYD5pyZO4oNCt22EC7u-7hUelMUc$ > > <https://urldefense.us/v3/__https://petsc.org/release/manualpages/PC/PCILU/__;!!G_uCfscf7eWS!d82xhlyQ6-cWmSO0PBI3pnGPDROVlCOPZn87hYtI4Pi9Kkbf4wgpQjnYsrJVy0pwHGtZYvPKXDxQCoq9BTvE6Ao$> > > Mark > > On Wed, Jun 4, 2025 at 9:36 AM Frank Bramkamp <bramk...@nsc.liu.se > <mailto:bramk...@nsc.liu.se>> wrote: >> Dear PETSc team, >> >> I have a general question regarding the implementation of the inverse >> For the ILU factorization. >> >> I am looking e.g. on the implementation for block size 6 for the BAIJ matrix >> format in serial: >> src/mat/impls/baij/seq/dgefa6.c >> >> I wonder: >> You are using pivoting in the inverse computation. >> >> But if one changes the position of elements or rows, do we not have to apply >> an inverse permutation at the end >> to get the inverse of the original matrix to some column ?! Otherwise it is >> the inverse of the permutated matrix ?!
To compute the explicit inverse it does 6 triangular solves with columns of the identity. During the triangular solves it does the needed permutations so the inverse is the inverse of the original matrix, not a permuted version. >> >> I am not quite sure if one has to do this in principle or if my >> understanding is not quite correct. >> Maybe I miss something in your code. >> >> >> Thanks, Frank >> >> >>