[Trilinos-Users] Replicate Serial Vectors

Ammar T. Al-Sayegh alsayegh at purdue.edu
Mon Aug 1 15:06:11 MDT 2005


Mike,

Thank you for following up on my question. The application
that I'm working on involved nonlinear analysis of structures.
So far, I did a small cantilever beam analysis serial program
using Epetra that segments the beam into many elements and
perform state determination sequentially on them. What I would
like to do is to parallelize this process. This requires
information to be shared and dynamically assigned and updated
between the main processor P0 that performs the overall
analysis and other processors P1..PN that will only do state
determination.

As you pointed out, the documentation indicates that LocalMap
can be used to exchange full vector/matrix information between
processors, but I could not find a procedure or an example to
illustrate that. The simplest example I can think of is to have
a single vector x shared between two processors P0, and P1.
We change x on P0 and print the new value on P1, then we update
it again on P1 and print the updated value on P0. In other words,
I would like to get the final result of Mpi_Send() and
Mpi_Revceive() without having to resort to MPI. Once I can
exchange vectors and matrices to parallelize my program directly
from Epetra, then I can investigate further with other Trilinos
functions to see how I can make it more efficient.


-ammar



----- Original Message ----- 
From: "Michael A Heroux" <maherou at sandia.gov>
To: "'Ammar T. Al-Sayegh'" <alsayegh at purdue.edu>
Cc: <trilinos-users at software.sandia.gov>
Sent: Monday, August 01, 2005 9:59 AM
Subject: RE: [Trilinos-Users] Replicate Serial Vectors


> Ammar,
> 
> There are several ways to manage replicated data in Trilinos.  However,
> there is no way to have a replicated vector be synchronized "automatically"
> for every operation.  We have avoided this type of mechanism because it
> would typically require a lot of communication and promote poor parallel
> programming approaches.  In general we have avoided implicit communication
> because of these problems.
> 
> Having said this, there is a concept in Epetra of a LocalMap, such that
> Vectors (and MultiVectors) built using such a map will be synchronized
> during Epetra operations.  Epetra also supports replicated data through
> Import and Export operations.  Imports and Exports can be used to automate
> synchronization for user-defined operations.
> 
> If you give me a few more details about your situation, I will try to
> provide you with some examples.
> 
> Mike
> 
>> -----Original Message-----
>> From: trilinos-users-bounces at software.sandia.gov 
>> [mailto:trilinos-users-bounces at software.sandia.gov] On Behalf 
>> Of Ammar T. Al-Sayegh
>> Sent: Sunday, July 31, 2005 10:59 PM
>> To: trilinos-users at software.sandia.gov
>> Subject: [Trilinos-Users] Replicate Serial Vectors
>> 
>> Hi All,
>> 
>> I would like to replicate short serial vectors over multiple 
>> processors. For example, if I have a short serial vector x, 
>> and two processors P0 and P1, then I would like to have 
>> identical copies of x on P0 and P1. If I change x on P0, then 
>> the change will be automatically replicated on P1, and vise 
>> versa. Is there a simple example on how to do that?
>> 
>> Thanks.
>> 
>> 
>> -ammar
>> 
>> _______________________________________________
>> Trilinos-Users mailing list
>> Trilinos-Users at software.sandia.gov
>> http://software.sandia.gov/mailman/listinfo/trilinos-users
>> 
> 
>



More information about the Trilinos-Users mailing list