[petsc-users] Nodes Communication - Petsc Vec
Matthew Knepley
knepley at gmail.com
Wed Feb 16 08:48:51 CST 2022
On Wed, Feb 16, 2022 at 9:47 AM Medane TCHAKOROM <
medane.tchakorom at univ-fcomte.fr> wrote:
> Re:
>
>
> It does not apply, because "their communicator must be on the same set of
> processes" .
>
> In my case, I have two disjoint subcomm from PETSC_COMM_WORD with same
> number of processes.
>
> I want to send information (Petsc Vec) from one subcomm to another subcomm.
>
The way I do this is to go to the supercommunicator, incorporating these
two groups and use VecScatter.
The alternative is just to use custom MPI calls as you say.
Thanks,
Matt
> Thanks
> On 16/02/2022 15:43, Junchao Zhang wrote:
>
> See Notes at
> https://petsc.org/main/docs/manualpages/PetscSF/VecScatterCreate.html
>
> Does it apply to your case?
>
> --Junchao Zhang
>
>
> On Wed, Feb 16, 2022 at 8:12 AM Medane TCHAKOROM <
> medane.tchakorom at univ-fcomte.fr> wrote:
>
>> Re:
>>
>> I forgot to mention that the nodes are in differents communicators. Does
>> VecScatter functionnality still applies ?
>>
>> Thanks.
>> On 16/02/2022 15:03, Matthew Knepley wrote:
>>
>> On Wed, Feb 16, 2022 at 8:55 AM Medane TCHAKOROM <
>> medane.tchakorom at univ-fcomte.fr> wrote:
>>
>>> Hello,
>>>
>>> I want to pass a Petsc Vec from one node to another one. Is there any
>>> Petsc method for doing this
>>>
>>
>> You likely want the VecScatter functionality. There is a discussion of
>> this in the manual:
>> https://petsc.org/main/docs/manual/vec/?highlight=vecscatter#sec-unstruct
>>
>> Thanks,
>>
>> Matt
>>
>>
>>> or should I use MPI_Irecv and MPI_Isend for non-blocking communication ?
>>>
>>> When using MPI_Isend, can i send a Petsc Vec, or should I get the array
>>> from it, and then send it ?
>>>
>>> Thanks
>>>
>>>
>>
>> --
>> 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/>
>>
>>
--
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/20220216/c7080271/attachment.html>
More information about the petsc-users
mailing list