On Fri, Dec 2, 2011 at 8:04 AM, Feng-Chao Wang <span dir="ltr">&lt;<a href="mailto:wolfshow@gmail.com">wolfshow@gmail.com</a>&gt;</span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<u></u>



<div style="FONT-SIZE:10pt;MARGIN:10px;FONT-FAMILY:verdana">
<div><font face="Verdana" size="2">Dear all,</font></div>
<div> </div>
<div>I intend to postprocess the solution of a PDE (stored in a 
parallel PETSc vector ) using tecplot. Thus I want to 
 output the values of the parallel vector as well as other data 
(such as the grid information) to a ASCII file.</div>
<div> </div>
<div>When I deal this with </div>
<div> </div>
<div> </div>
<div>VecGetArray(U, &amp;u);</div>
<div> </div>
<div>for (i=0; i&lt;Mx*My; i++)</div>
<div>{</div>
<div>PetscViewerASCIIPrintf(viewer,&quot;%F %F %F&quot;, x, y, u[i]);</div>
<div>}</div>
<div><font face="Verdana" size="2"></font> </div>
<div>If more than 1 processor are used, I found that only part of the value of u 
was output correctly (that stored on the first processor).</div>
<div>I found in the manual page of &quot;PetscViewerASCIIPrintf&quot; that &quot;<span style="DISPLAY:inline!important;FLOAT:none;WORD-SPACING:0px;FONT:medium Simsun;TEXT-TRANSFORM:none;COLOR:rgb(0,0,0);TEXT-INDENT:0px;WHITE-SPACE:normal;LETTER-SPACING:normal;BACKGROUND-COLOR:rgb(255,255,255)">Not 
Collective, but only first processor in set has any effect</span>&quot;</div>
<div> </div>
<div>Could anyone give me some suggestions on this issue?</div></div></blockquote><div><br></div><div><a href="http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Vec/VecView.html">http://www.mcs.anl.gov/petsc/petsc-current/docs/manualpages/Vec/VecView.html</a></div>
<div><br></div><div>  Matt</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div style="FONT-SIZE:10pt;MARGIN:10px;FONT-FAMILY:verdana">
<div>Thank you very much in advance!</div>
<div> </div>
<div>Best Regards</div>
<div> </div>
<div> </div>
<div> </div>
<div> </div>
<div> </div>
<div align="left"><font face="Verdana" color="#c0c0c0" size="2">2011-12-02 
</font></div><font face="Verdana" size="2">
<hr style="WIDTH:122px;min-height:2px" align="left" size="2">

<div><font face="Verdana" color="#c0c0c0" size="2"><span>Feng-Chao Wang</span> 
</font></div></font></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br>What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>
-- Norbert Wiener<br>