[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: question about VecLoad (pls disregard previous one)



2008/5/15 tsjb00 <tsjb00@xxxxxxxxxxx>:
>
> Many thanks to all for the reply!
>
> I use the code:
>  PetscViewerBinaryOpen(PETSC_COMM_WORLD,"out.dat",FILE_MODE_READ,viewer);
>  VecLoad(viewer,VECMPI,&v1);
> to get the vector storing values of var.
>
> My problem is, it seems that the vector global is evenly distributed over processors; while in my program, a DA is defined and according to DA global vectors are not distributed the same way. Would anybody please tell me how to deal with that?

The output vector, using VecView(), is in natural order. It has no
idea about distribution over processes. When it is read in,
using VecLoad(), it is redistributed according to the current partition.

  Matt

> Thanks in advance!
>
> JB
>
> _________________________________________________________________
> MSN 中文网,最新时尚生活资讯,白领聚集门户。
> http://cn.msn.com
>
>



-- 
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