[petsc-users] [petsc-maint] Performing a coordinate system rotation for the stiffness matrix

Stefano Zampini stefano.zampini at gmail.com
Mon May 31 10:12:13 CDT 2021


Mike

as long as P is a sparse matrix with compatible rows and cols (i.e.
rows(P)= cols(A) = rows (A)) , MatPtAP will compute the result.

Il giorno lun 31 mag 2021 alle ore 16:52 Mark Adams <mfadams at lbl.gov> ha
scritto:

>
>
> On Mon, May 31, 2021 at 9:20 AM Michael Wick <michael.wick.1980 at gmail.com>
> wrote:
>
>> Hi PETSc team:
>>
>> I am considering implementing a skew roller boundary condition for my
>> elasticity problem. The method is based on this journal paper:
>> http://inside.mines.edu/~vgriffit/pubs/All_J_Pubs/18.pdf
>>
>> Or you may find the method in the attached Bathe's slides, pages 9 -10.
>>
>> Roughly speaking, a (very) sparse matrix T will be created which takes
>> the shape [ I, O; O, R], where R is a 3x3 rotation matrix. And the original
>> linear problem K U = F will be modified into (T^t K T) (T^t U) = T^t F. In
>> doing so, one can enforce a roller boundary condition on a slanted surface.
>>
>> I think it can be an easy option if I can generate the T matrix and do
>> two matrix multiplications to get T^t K T. I noticed that there is a
>> MatPtAP function. Yet, after reading a previous discussion, it seems that
>> this function is not designed for this purposes (
>> https://lists.mcs.anl.gov/pipermail/petsc-users/2018-June/035477.html).
>>
>
> Yes, and no. It is motivated and optimized for a Galerkin coarse grid
> operator for AMG solvers, but it is a projection and it should be fine. If
> not, we will fix it.
>
> We try to test our methods of "empty" operators , but I don't know
> if MatPtAP has ever been tested for super sparse P. Give it a shot and see
> what happens.
>
> Mark
>
>
>>
>> I assume I can only call MatMatMult & MatTransposeMatMult to do this job,
>> correct? Is there any existingly PETSc function to do T^t K T in one call?
>>
>> Thanks,
>>
>> Mike
>>
>>

-- 
Stefano
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20210531/dd56c112/attachment.html>


More information about the petsc-users mailing list