[Users] Problem with CarpetRegrid2/AMR

Hal Finkel hfinkel at anl.gov
Tue Aug 30 16:28:10 CDT 2011


On Tue, 2011-08-30 at 16:21 -0400, Erik Schnetter wrote:
> Hal
> 
> Thanks for taking the discussion to the list.

You're quite welcome.

> 
> Looking at your pictures again, I see one large problem I didn't
> realise before: your domain is periodic, but the grid structure is
> not. It would be the task of CarpetRegrid2 to ensure that the grid
> structure is also periodic, but this is not implemented yet; hence the
> periodicity thorn cannot fill in the boundary points of the fine grid.
> 
> I suggest to switch to reflecting boundary conditions to test this,
> and/or to use a larger domain so that there is no refinement near the
> domain boundary.

Could I also decrease the block size? I currently have
CarpetRegrid2::adaptive_block_size = 4, could it be smaller than that?
Is there a restriction based on the number of ghost points?

Thanks again,
Hal

> 
> It is straightforward to implement periodicity in the grid structure
> -- one needs to take the current grid structure, shift it in the 26
> directions, and take the logical union of all 27 grid structures. This
> will then be automatically clipped. The most complex part is
> calculating by how much to shift.
> 
> -erik
> 
> PS: You say "first picture" etc., but I think my email client shows
> the attachment in a different order. I would rather specify
> attachments via file names, and rename files accordingly. For my, chi
> on level 1 is the 5th image, visit0007.png.
> 
> On Tue, Aug 30, 2011 at 3:37 PM, Hal Finkel <hfinkel at anl.gov> wrote:
> > I am trying to setup a simple simulation using CarpetRegrid2's AMR
> > capability. As Erik has already pointed out to me (off list), the
> > adaptive-refinement triggering code is still under development.
> > Nevertheless, I would really like to get it working.
> >
> > In my current test case, I am using Kranc to solve a Klein-Gordon
> > equation (with a non-linear potential). With the provided initial
> > conditions, the system has an expanding bubble. This works well when
> > refinement is turned off. To be clear, the evolution equation is:
> >
> > evolCalc =
> > {
> >        Name -> "SFBubble_Evolve",
> >        Schedule -> {"in MoL_CalcRHS"},
> >        Where -> Interior,
> >        Shorthands -> {},
> >        Equations -> {
> >                dot[chi]        -> chiM,
> >                dot[chiM]       -> PD[chi,li,lj] Euc[ui,uj] - Vchi[chi]
> >        }
> > };
> >
> > where Vchi[chi_] := V'[chi] (V is the potential). The AMR level_mask is
> > set by:
> >
> > lvlmskSet =
> > {
> >        Name -> "SFBubble_SetLevelMask",
> >        Schedule -> {"AT preregrid"},
> >        Where -> Interior,
> >        Shorthands -> { adchix, adchiy, adchiz },
> >        Equations ->
> >        {
> >                adchix -> fabs[dx PD[chi,1]],
> >                adchiy -> fabs[dy PD[chi,2]],
> >                adchiz -> fabs[dz PD[chi,3]],
> >
> >                "level_mask" -> (
> >                        Max[
> >                                adchix, adchiy, adchiz
> >                        ]/dchimax
> >                ) /. Max[a_, b_, c_] -> fmax[a, fmax[b, c]]
> >        }
> > };
> >
> > (in words: the value of chi should not change by more than dchimax over
> > the length of one grid cell)
> >
> > I am using the Periodic thorn to provide periodic boundary conditions.
> >
> > I've attached six pictures. They are at t = 0, the first level 1
> > intermediate time step, and the first coarse time step. The first three
> > pictures are the value of chi on a slice through the middle of the box.
> > The second three pictures are the value of level_mask. As can be seen in
> > the second chi image, the interpolation into the refined region seems to
> > be incorrect. The "boundary" seems to have appeared in the middle of the
> > block. I have also attached the block descriptions. Is there something I
> > could be doing incorrectly which would cause this? Otherwise, does
> > anyone have any ideas on where to look for the problem?
> >
> > I am using the trunk version as of this morning.
> >
> > Thank you in advance,
> > Hal
> >
> > --
> > Hal Finkel
> > Postdoctoral Appointee
> > Leadership Computing Facility
> > Argonne National Laboratory
> >
> > _______________________________________________
> > Users mailing list
> > Users at einsteintoolkit.org
> > http://lists.einsteintoolkit.org/mailman/listinfo/users
> >
> >
> 
> 
> 
> -- 
> Erik Schnetter <schnetter at cct.lsu.edu>   http://www.cct.lsu.edu/~eschnett/

-- 
Hal Finkel
Postdoctoral Appointee
Leadership Computing Facility
Argonne National Laboratory
1-630-252-0023
hfinkel at anl.gov



More information about the Users mailing list