[petsc-users] Product of nonsymmetric matrices is symmetric
Jed Brown
jed at jedbrown.org
Thu Mar 5 08:04:42 CST 2020
The place for this to go would be MatPtAP() for matrix D of SBAIJ matrix
type (thus producing A of type SBAIJ), but we don't have an
implementation of that. You can do the product with an AIJ matrix and
then MatConvert to SBAIJ.
flw at rzg.mpg.de writes:
> Dear PETSc team,
> I have a linear system of the form
> A*x=b,
> where
> A=(D-G^T D G).
> Here, G and D are real NxN matrices, D is diagonal and G is not
> symmetric. So far, we are using the matmpiaij format for all of the
> given matrices and create A with the help of matmatmult.
>
> However, as is easy to show, the matrix A itself is symmetric, due
> to the sandwich G^T D G. Therefore, we would like to make use of this
> fact and use the mpisbaij format fir A instead of mpiaij. Can you tell
> me how to set up the matrix A in this fashion? Unfortunately, I
> haven't found anything on that in the archive yet.
>
>
> Best regards,
> Felix
More information about the petsc-users
mailing list