Hi,

    I am trying to plot the solution of a 3-D Poisson equation.  The solution 
vector, Vec sol, is output to a file in binary format and then will be 
processed with a stand-alone program in which Vecload() is called.  The number 
of  processes required in the stand-alone post-processing 
program can be different from that in the solver program. That is, I can
 ask one process to created the data file for plotting. This way is much
 easier to combine the distributed vector in several processes into one 
process.

The coordinates of nodes are needed to plot the 3-D distributions of the 
solution. The matrix and the vector are managed with DMDA, so the array for the 
coordinates can be obtained by DMDAGetCoordinateDA(da,&cda) and 
DMDAVecGetArray(cda,gc,&coors).  Here, coors is defined as DMDACoor3d   
***coors.   Since the function VecVeiw can only output one vector, Vec sol, to 
a binary file , the array of coordinates must be output to another file and 
thus must be read separately. The problem is that the array of coordinates is 
local array and the number of processes in the post-processing program must be 
same as that in the solver. This means the Vec sol cannot be combined into one 
by only calling Vecload.

   Is there any efficient way to output the coordinates and combine them from 
several processes into one process like the way of writing and reading Vec sol?


                                          

Reply via email to