[petsc-users] What exactly goes into DMPlexSetRefinementLimit

Justin Chang jychang48 at gmail.com
Wed Aug 17 15:04:12 CDT 2016


Ah I didn't realize that in DMPlexCreateBoxMesh(...) one of the fields was
to define number of faces in each spatial direction. Right now it is set to
1 for 3D, so i guess I will just have to change this

Thanks!

On Wed, Aug 17, 2016 at 2:46 PM, Matthew Knepley <knepley at gmail.com> wrote:

> On Wed, Aug 17, 2016 at 2:35 PM, Justin Chang <jychang48 at gmail.com> wrote:
>
>> Because the base mesh starts off with 6 elements and 8 vertices. This is
>> enough data for one cell per MPI process. Refinement is done after
>> DMPlexDistribute(...). If I use anymore than 6 cores, some of the MPI ranks
>> will have an empty DM Object. For example:
>>
>
> You could
>
> 1) Just stick an explicit call to uniform refinement in for the serial mesh
>
> 2) Use a cell volume that is 1/N, where N is the number of cells you want
>
>    Matt
>
>
>> $ mpirun -n 8 --bind-to-core --bysocket ./ex12 -dim 3 -run_type full
>> -interpolate 1 -petscspace_order 1 -bc_type dirichlet -ksp_rtol 1.0e-7
>> -pc_type ml -refinement_limit 1 -dm_refine 1 -dm_view
>>
>> DM Object: Parallel Mesh 8 MPI processes
>>
>>   type: plex
>>
>> Parallel Mesh in 3 dimensions:
>>
>>   0-cells: 10 0 10 10 10 0 10 10
>>
>>   1-cells: 25 0 25 25 25 0 25 25
>>
>>   2-cells: 24 0 24 24 24 0 24 24
>>
>>   3-cells: 8 0 8 8 8 0 8 8
>>
>> Labels:
>>
>>   marker: 1 strata of sizes (18)
>>
>>   depth: 4 strata of sizes (10, 25, 24, 8)
>>
>> Number of SNES iterations = 1
>>
>> L_2 Error: 0.118178
>>
>> On Wed, Aug 17, 2016 at 2:28 PM, Matthew Knepley <knepley at gmail.com>
>> wrote:
>>
>>> On Wed, Aug 17, 2016 at 2:04 PM, Justin Chang <jychang48 at gmail.com>
>>> wrote:
>>>
>>>> When I enter values  like 1/16, 1/12, 1/24, and so on, I was expecting
>>>> to get roughly the same dm object as if I simply did -dm_refine <0/1/2/3>.
>>>> Instead it seems I get highly unstructured grids, and the smaller the
>>>> number gets, the fewer additional cells I get. Is there a way to make the
>>>> refinement limit uniform?
>>>>
>>>
>>> Why not just use -dm_refine ?
>>>
>>>    Matt
>>>
>>>
>>>> On Wed, Aug 17, 2016 at 9:38 AM, Matthew Knepley <knepley at gmail.com>
>>>> wrote:
>>>>
>>>>> On Wed, Aug 17, 2016 at 5:23 AM, Justin Chang <jychang48 at gmail.com>
>>>>> wrote:
>>>>>
>>>>>> Hi all,
>>>>>>
>>>>>> Playing around with SNES ex12.c and I am attempting to tinker around
>>>>>> with 3D options. I am trying to understand what kind of values go into
>>>>>> -refinement_limit for 3D simplices.
>>>>>>
>>>>>
>>>>> The cell volume limits for any cells created out of the existing
>>>>> cells. This is how TetGen understands refinement. I think a
>>>>> better way is to use a metric tensor field, and we now have an
>>>>> interface to pragmatic for this (I think currently I only hooked it up
>>>>> to DMCoarsen() but it does both). Clearly the interface is immature,
>>>>> but this is the way we are headed.
>>>>>
>>>>>   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
>>>
>>
>>
>
>
> --
> 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/20160817/58d69fe7/attachment-0001.html>


More information about the petsc-users mailing list