Hector E Barrios Molano <[email protected]> writes: > Dear PETSc Experts! > > Do you know if there is an efficient way to move a matrix from a single > processor (MatCreateSeqBAIJ) to a matrix contained in all processors?
How did you create the original SeqBAIJ? Could you just call MatSetValues on a parallel matrix instead (even if only setting values from rank 0)? Many of our tutorials suggest this mode if you can't parallelize your assembly. > As a little bit of context, I have a code in which only one processor > creates a matrix and a vector for a linear system of equations. Then we > want to use a parallel solver to get the solution and give it back to a > single processor > > I tried MatView to create a binary file and MatLoad to load the matrix > in parallel. This seems to work but performance is significantly > decreased independent of the number of processors used. > > I have some questions: > > Can I share the matrix without having to write it to a file, for > example, through a buffer? > Is there a way to efficiently avoid the overhead of writing, reading > loading matrices to and from processors? > > Thanks for your comments, > > Hector > -- > *Hector Barrios* > PhD Student, Graduate Research Assistant > Hildebrand Department of Petroleum and Geosystems Engineering > The University of Texas at Austin > [email protected] <mailto:[email protected]>
