[petsc-users] MatPtAP

David Knezevic david.knezevic at akselos.com
Tue Feb 23 22:08:41 CST 2016


On Tue, Feb 23, 2016 at 10:40 PM, Barry Smith <bsmith at mcs.anl.gov> wrote:

>
>   A custom MatPtAP would almost surely pay off, but it is only an
> optimization so you need to ask if this computation is your main "blocker"
> to getting more "science" done.  Can you send a picture of the exact
> structure of P?
>

I've attached a picture of the sparsity pattern of P. There are 0s and 1s
on the diagonal, and some dense columns in the first few columns.

David







>
> > On Feb 23, 2016, at 9:35 PM, David Knezevic <david.knezevic at akselos.com>
> wrote:
> >
> > I'm using MatPtAP, which works well for me, but in some examples I've
> tested the PtAP calculation dominates the overall solve time (e.g. see
> attached -log_summary output).
> >
> > In my case, A is a stiffness matrix, and P is the identity matrix except
> for a small number of columns (e.g. about 10 or so) which are dense.
> >
> > In this situation, I was wondering if there is a more efficient way to
> proceed than using MatPtAP? For example, would it be noticeably faster to
> calculate P^T A P directly using MatMults for the dense columns, rather
> than using MatPtAP?
> >
> > Thanks!
> > David
> >
> >
> > <PtAP_log_summary.txt>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20160223/b79aa5c9/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: P_sparsity.png
Type: image/png
Size: 22116 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20160223/b79aa5c9/attachment-0001.png>


More information about the petsc-users mailing list