<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Hi,<br>
<br>
I changed from "0" to PETSC_NULL_OBJECT. In linux, I managed to get
the output now:<br>
<br>
Vector Object:Vec_0x24c7f10_0 1 MPI processes<br>
type: mpi<br>
Process [0]<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0833333<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
0.0416667<br>
<br>
Doing the same in VS2008 in windows 64bit, both "0" and
"PETSC_NULL_OBJECT" give the results as:<br>
<br>
Vector Object:Vec_0000000084000000_0 1 MPI<br>
type: mpi<br>
Process [0]<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
0<br>
<br>
Why are the results different? The changes I made (as mentioned
earlier) are the same in both.<br>
<pre class="moz-signature" cols="72">Yours sincerely,
TAY wee-beng</pre>
<br>
On 22/4/2012 9:41 PM, Matthew Knepley wrote:
<blockquote
cite="mid:CAMYG4G=WD6sdE7D-b7S6piB1G1f6ajVU597cKms2LMxFGnJw3w@mail.gmail.com"
type="cite">
<div class="gmail_extra">On Sun, Apr 22, 2012 at 3:36 PM, Jed
Brown <span dir="ltr"><<a moz-do-not-send="true"
href="mailto:jedbrown@mcs.anl.gov" target="_blank">jedbrown@mcs.anl.gov</a>></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">
<div class="gmail_quote">On Sun, Apr 22, 2012 at 14:28,
Matthew Knepley <span dir="ltr"><<a
moz-do-not-send="true" href="mailto:knepley@gmail.com"
target="_blank">knepley@gmail.com</a>></span>
wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0
.8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im">
<div>On Sun, Apr 22, 2012 at 3:20 PM, Jed Brown <span
dir="ltr"><<a moz-do-not-send="true"
href="mailto:jedbrown@mcs.anl.gov"
target="_blank">jedbrown@mcs.anl.gov</a>></span>
wrote:<br>
</div>
</div>
<div class="gmail_quote">
<div class="im">
<div>
<blockquote class="gmail_quote" style="margin:0 0
0 .8ex;border-left:1px #ccc
solid;padding-left:1ex">
<p>Look at the man page for VecView, it needs a
PetscViewer argument.</p>
</blockquote>
</div>
</div>
<div>Works for me with VecView(x, PETSC_NULL_OBJECT,
ierr), although it is 0</div>
</div>
</blockquote>
</div>
<br>
<div>Matt, are you trying to cause confusion? The posted
code called VecView with the wrong number of arguments.
Also, telling any Fortran user that "0" is even related to
PETSC_NULL_OBJECT is a terrible idea because they are
totally different things on the Fortran side.</div>
</blockquote>
</div>
<br>
This is perfectly sensible:</div>
<div class="gmail_extra"><br>
</div>
<div class="gmail_extra"> 1) If you use PETSC_NULL_OBJECT, you get
the default viewer</div>
<div class="gmail_extra"><br>
</div>
<div class="gmail_extra">
2) I was talking about the solution, which is the 0 vector in
my output</div>
<div class="gmail_extra"><br>
</div>
<div class="gmail_extra"> Matt<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>
</div>
</blockquote>
</body>
</html>