Manually setting DA min and max indexes
Jed Brown
jed at 59A2.org
Thu Oct 22 12:40:46 CDT 2009
Milad Fatenejad wrote:
> Hello:
>
> Is it possible to set the min/max m,n,p indexes when creating a 3D
> distributed array? I'm writing a 3D code on a structured mesh, and the
> mesh is partitioned among the processes elsewhere. Assuming that each
> process already knows what chunk of the mesh it owns, is it possible
> to give Petsc this information
> when you create a DA so that the partitioning is consistent between
> PETSc and the rest of the code?
For a simple decomposition, you just set the local sizes (m,n,p instead
of M,N,P in DACreate3d). For irregular cases, use the lx,ly,lz inputs
(or DASetVertexDivision). If you want to number the subdomains
differently than PETSc, you should be able to make a communicator with
your preferred numbering (see MPI_Group_incl) and create the DA on this
communicator.
Jed
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 261 bytes
Desc: OpenPGP digital signature
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20091022/31960152/attachment.pgp>
More information about the petsc-users
mailing list