[petsc-users] DMCreateXXXVector vs VecDuplicate
Matthew Knepley
knepley at gmail.com
Mon Sep 24 08:20:59 CDT 2018
On Mon, Sep 24, 2018 at 8:57 AM Phil Tooley <phil.tooley at sheffield.ac.uk>
wrote:
> Hi all,
>
> Can I get come clarification regarding DMCreateXXXVector
Vectors created from a DM have additional information, such as the DM itself
and special View routines.
> vs
> VecDuplicate.
VecDuplicate will retain this special information if present
> The manual says that I can obtain additional vectors with
> the latter, does this mean that I *must* only call DMCreateXXXVector
> once each for global and local?
>
No, you can call it as much as you want.
Thanks,
Matt
> I ask because I want multiple instances of an image class all with the
> same distributed layout. It makes life much tidier if I can just pass
> the DMDA rather than also having to pass vectors to be copied.
>
> Cheers
>
>
> Phil
>
> --
> Phil Tooley
> Research Software Engineering
> University of Sheffield
>
>
--
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
https://www.cse.buffalo.edu/~knepley/ <http://www.cse.buffalo.edu/~knepley/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20180924/57a20b2f/attachment.html>
More information about the petsc-users
mailing list