[petsc-dev] DACreate3d should work for 1 node in Z

Ethan Coon ecoon at lanl.gov
Tue Apr 19 15:44:08 CDT 2011


On Tue, 2011-04-19 at 22:25 +0200, Jed Brown wrote:
> On Tue, Apr 19, 2011 at 22:19, Ethan Coon <ecoon at lanl.gov> wrote:
>         At any rate, I'll fix the error message in 2D and add it to 3D
>         to only
>         error in the cases that actually currently break.  Doing
>         DMDA_BOUNDARY_PERIODIC with P=1 and s > zl (the multiple-wraps
>         around
>         the domain case) will take more thought...
> 
> The special case of 1 is probably the most important since it is the
> minimal size for a 3D method running a 2D problem. 

Agreed -- I was surprised this didn't work because we've been doing a
problem where we use stencil_size > 1, and we run z-dimension size = 1
problems all the time for this case.  Apparently we only do stencil_size
> 1 in the 2D case (but intended to generalize to 3D soon).  The
periodic case is the one you need to collapse 3D into 2D with no extra
work... an infinite domain in the 3rd dimension.

The short answer -- make the z-size = s.  It's not that huge of a hit --
the local arrays are 6*NX*NY*ndofs instead of 5*NX*NY*ndofs.

Otherwise, I'll try to implement the special-special case of
DMDA_BOUNDARY_PERIODIC, P=1, zl=1, and s > 1 soon.

Ethan

> Multiple wraps gets hairy pretty quickly and it doesn't seem important
> to support in the short term. It's certainly less important than
> general 3D domains with some bits empty (since this comes up
> frequently for coarse levels of multigrid).

-- 
------------------------------------
Ethan Coon
Post-Doctoral Researcher
Applied Mathematics - T-5
Los Alamos National Laboratory
505-665-8289

http://www.ldeo.columbia.edu/~ecoon/
------------------------------------




More information about the petsc-dev mailing list