[petsc-users] high order interpolation

Matthew Knepley knepley at gmail.com
Tue Aug 27 05:42:24 CDT 2019


On Tue, Aug 27, 2019 at 4:44 AM Ruth Schöbel via petsc-users <
petsc-users at mcs.anl.gov> wrote:

> Hi,
> I am on the way to write a program in python where I need parallel high
> order interpolation.
> I saw there exists “createInterpolation(self, DM dm)”, but this seems to
> be accurate only for constant functions.


Linear functions.


> Is there a way to get a higher
> order interpolation matrix? If it does not exist maybe someone has
> already written a code himself which I may use?
>

All the pieces are in PETSc, just not hooked up in the way you need. Here
we are dispatching to
local interpolation:


https://gitlab.com/petsc/petsc/blob/master/src/snes/utils/dmplexsnes.c#L886

It is currently hard coded to linear interpolation, as you point out.
However, PETSc has high order
interpolation. You would want something like this loop


https://gitlab.com/petsc/petsc/blob/master/include/petsc/private/petscfeimpl.h#L216

but with a tabulation for your points, which you can get from


https://gitlab.com/petsc/petsc/blob/master/src/dm/dt/fe/interface/fe.c#L862

I know this is more complicated than it should be, but we have not quite
worked out what should be
exposed to the user. I would just replace that short, linear
DMPlexInterpolationEvalute() routine with
a higher order one which assumes a PetscFE or PetscDS that comes in with it.

  Thanks,

    Matt


> Thanks Ruth
>
>
>
>
> ------------------------------------------------------------------------------------------------
>
> ------------------------------------------------------------------------------------------------
> Forschungszentrum Juelich GmbH
> 52425 Juelich
> Sitz der Gesellschaft: Juelich
> Eingetragen im Handelsregister des Amtsgerichts Dueren Nr. HR B 3498
> Vorsitzender des Aufsichtsrats: MinDir Volker Rieke
> Geschaeftsfuehrung: Prof. Dr.-Ing. Wolfgang Marquardt (Vorsitzender),
> Karsten Beneke (stellv. Vorsitzender), Prof. Dr.-Ing. Harald Bolt,
> Prof. Dr. Sebastian M. Schmidt
>
> ------------------------------------------------------------------------------------------------
>
> ------------------------------------------------------------------------------------------------
>
>

-- 
What most experimenters take for granted before they begin their
experiments is infinitely more interesting than any results to which their
experiments lead.
-- Norbert Wiener

https://www.cse.buffalo.edu/~knepley/ <http://www.cse.buffalo.edu/~knepley/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20190827/ad34840c/attachment.html>


More information about the petsc-users mailing list