[petsc-users] Refinement, interpolation, and auxiliary data

Matthew Knepley knepley at gmail.com
Wed Jan 21 06:49:42 CST 2015


On Tue, Jan 20, 2015 at 5:06 PM, Justin Chang <jychang48 at gmail.com> wrote:

> Matt,
>
> 1) I am not sure if I fully understand the difference between those two
> types of refinement you just described. If I understand this correctly, in
> the first method, Triangle and TetGen will refine the mesh based on the
> refinement limit (largest allowable cell size) but doesn't necessarily
> have  to uniformly refine the mesh, meaning the box/cube mesh could end up
> looking very distorted and unstructured with various element sizes. And in
> the second method, it ensures that all elements/cells are refined the same
> number of times no matter how what method was used to create the DMPlex
> mesh. Or am I missing something?
>

Yes, that is right.


> 2) Okay that makes sense.
>
> 3) Generally speaking the data would be cell-wise, but hypothetically what
> if I had to work with data that's defined at the cell vertices? Data like
> the Marmousi set (btw the link I proved was sort of broken, here is another
> link
> <http://www.reproducibility.org/RSF/book/data/marmousi/paper_html/node2.html>
> to it) is pointwise, but i am sure it could be preprocessed and
> interpolated to cell-centered data. When I see your run examples in
> builder.py for SNES ex12, you have the flag "-mat_petscspace_order 1" even
> when -petscspace_order is 2. So I guess my question is does the order of
> the material/auxiliary FE necessarily have to match that of the trial
> function FE?
>

No, its does not. As you noted, there are tests for ex12 that have
different orders for the coefficient and the solution.

This month is completely busy for me, but I think I will have time to meet
in Feb.

  Thanks,

     Matt


> Thanks,
> Justin
>
> On Tue, Jan 20, 2015 at 5:45 AM, Matthew Knepley <knepley at gmail.com>
> wrote:
>
>> On Tue, Jan 20, 2015 at 3:06 AM, Justin Chang <jychang48 at gmail.com>
>> wrote:
>>
>>> Hi all,
>>>
>>> I have a few simple questions regarding DMPlex mesh refinement,
>>> interpolation, and auxiliary data:
>>>
>>> 1) What exactly does DMPlexSetRefinementUniform do? Is it relevant only
>>> for the DMPlexCreateBoxMesh() function?
>>>
>>
>> Plex supports two types of refinement now. First, you can call a mesh
>> generator for refinement, like Triangle or TetGen. Second,
>> you can uniformly refine cells, although I have only coded this for
>> simplices and tensor products. The uniform refinement works
>> on any mesh, not just the builtin ones.
>>
>>
>>> 2) When I interpolate a given DMPlex mesh, what becomes of the
>>> "boundary" edge/face labels and/or IDs? That is, say if I had a 2D simplex
>>> element on the boundary domain and two of its vertices are assigned
>>> different marker ID's and/or labels, what will become of those intermediate
>>> mesh point(s) become?
>>>
>>
>> I do not mark them. That is up to the application, since there is no way
>> to do it generically. What I do in my simple code is to use
>> MarkBoundaryFaces() and LabelComplete(). For complex things, I use the
>> ExodusII format for marking faces.
>>
>>
>>> 3) If I have highly heterogeneous diffusivity or permeability (e.g.,
>>> random permeability or a marmousi
>>> <http://www.caam.rice.edu/~benamou/OLD/marmousi.html>data set) that
>>> need to be read in as auxiliary coefficients, would I need to manually
>>> interpolate the data for the intermediate mesh points before I project the
>>> field into the FE space, or does PETSc have an ability somewhere to
>>> automatically interpolate these values for you?
>>>
>>
>> You have to explain more about what this data means. Is it cell-wise
>> data? If so, why do you need to interpolate?
>> Shouldn't it just be in P0? If not, you can project the P0 data into any
>> other space using either ProjectFunction()
>> or a slightly modified version of DMPlexComputeInterpolatorFEM().
>>
>>   Thanks,
>>
>>      Matt
>>
>>
>>> Thanks,
>>> Justin
>>>
>>
>>
>>
>> --
>> 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
>>
>
>


-- 
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
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20150121/e1f9f35d/attachment.html>


More information about the petsc-users mailing list