[petsc-dev] errors for /petsc/src/ts/examples/tutorials/ex29.c

Jed Brown jed at jedbrown.org
Thu Sep 15 23:35:00 CDT 2016


Barry Smith <bsmith at mcs.anl.gov> writes:
>   A perhaps better fix is to finally remove this from the DMDCreateNd() calls 
>
>   /* This violates the behavior for other classes, but right now users expect negative dimensions to be handled this way */
>   ierr = DMSetFromOptions(*da);CHKERRQ(ierr);
>   ierr = DMSetUp(*da);CHKERRQ(ierr);
>
>   Perhaps we could remove both of these lines from those calls and require every use of DMDCreateNd() to add the 
> DMSetUp() call. Then the user is free to insert a DMSetFromOptions() in between or not. We remove the negative value business which is hokey anyway?
>
>   So in the use of DMDAGetReducedDMDA() it could call DMDACreate2d() then the DMSetUp() but skip the DMSetFromOptions() line.

I won't stop you, but I'm not sure that's worth it.  We don't use
MatCreateAIJ type "convenience" functions in library code, so why should
we use the DMDACreate*d convenience functions?  Presumably doing so
would remove the conditionals (over dimension) that we have now.  Or
perhaps we should do both?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 800 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-dev/attachments/20160915/d291b0ba/attachment.sig>


More information about the petsc-dev mailing list