[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Getting Remote Distributed Vector Elements?
- To: petsc-users@xxxxxxxxxxx
- Subject: Re: Getting Remote Distributed Vector Elements?
- From: "Matthew Knepley" <knepley@xxxxxxxxx>
- Date: Mon, 23 Jul 2007 09:39:29 -0500
- Dkim-signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=XVQdXcIqjwNNzhUkp0L8k+VOPh8mL4SveKrp/N7PqzLc1NBtSPaRrem7igX1MYd9m4P14nMoaW1SqwXhh0kGfbHoG84HB1BHtaVFuXnZF0JwvD98eRjYiGQOiGN3BGAyXxpYz0nTlICig3oBNnUneOLjR3u57HxCA0NgD8kej3w=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=TktJaaGXmR3mwOE2BNwP2uLkESbWim56IXXGFNSRZmswv1ois8tHr9bCWT+zvEmdsWY2Qz4RyDO3R5grkfnQkJ3e1TU6LJkrokts7WrywFGjVzPc7tglbwRxMR6xt6Af3TDVJ/1rYDgETIqy7My/IP98e/DnZn1bQaJ2XgHgjRg=
- In-reply-to: <200707231524.07705.timothy.stitt@ichec.ie>
- References: <200707231524.07705.timothy.stitt@ichec.ie>
- Reply-to: petsc-users@xxxxxxxxxxx
- Sender: owner-petsc-users@xxxxxxxxxxx
On 7/23/07, Tim Stitt <timothy.stitt@xxxxxxxx> wrote:
Hi all,
I was just wondering if anyone can suggest the most efficient method for
obtaining any given element in a distributed vector? If I understand
correctly VecGetValues() only returns local elements? I need to access
non-local elements also. What is the best approach?
You create a VecScatter with these indices into a local vector, and then get
the array from that.
Matt
Thanks in advance,
Tim.
--
Dr. Timothy Stitt <timothy_dot_stitt_at_ichec.ie>
HPC Application Consultant - ICHEC (www.ichec.ie)
Dublin Institute for Advanced Studies
5 Merrion Square - Dublin 2 - Ireland
+353-1-6621333 (tel) / +353-1-6621477 (fax) / +353-874195427 (mobile)
--
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