On Jun 14, 2011, at 8:45 PM, Matthew Knepley wrote: > On Wed, Jun 15, 2011 at 1:42 AM, Barry Smith <bsmith at mcs.anl.gov> wrote: > > On Jun 14, 2011, at 8:36 PM, Matthew Knepley wrote: > > > On Wed, Jun 15, 2011 at 1:20 AM, Barry Smith <bsmith at mcs.anl.gov> wrote: > > > > On Jun 14, 2011, at 7:59 PM, Jed Brown wrote: > > > > > On Wed, Jun 15, 2011 at 02:53, Barry Smith <bsmith at mcs.anl.gov> wrote: > > > It seems we should provide a DMSDA that is built specifically for > > > staggered grids, with the correct number of "slots" in the correct > > > "locations", it would have appropriate grid hierarchies and > > > interpolation/restriction. Not terribly hard but a bit of basic plumbing > > > code. I would rather have this then try to "tack on" the current DA a > > > bunch more stuff. > > > > > > Yeah, though there are many different staggered discretizations so this > > > could end up being a big project. Not conceptually hard, just a lot of > > > code. DMDA is already not especially small. > > > > DMDA started out small. DMSDA will start out small :-) > > > > Actually before we do DMSDA we probably should do a code review of DM, > > then of DMDA and slim down DMDA a good amount. > > > > My vote would be to layer PetscSection on top of DMDA. That would allow > > arbitrarily complex data layout over a dead simple > > topology. Its halfway to DMMesh, and it should be the easy half. > > It won't give the proper layout of degree's of freedom relative to their > neighbors of the stagger mesh nor communicate the right ghost points. > > Why not? I have done it before. The trial implementation (in C++) is in > src/dm/impls/cartesian. I will just reimplement that completely > in C.
If so, why not dump DMDA also and replace it with a dead simple implementation based on PetscSections? Barry > > Matt > > > Barry > > > > > Matt > > > > > > Barry > > > > > > > > > > > > -- > > 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
