[petsc-dev] printing the matrix name via -mat_view_info

Jed Brown jed at 59A2.org
Thu Sep 30 10:46:06 CDT 2010


On Thu, Sep 30, 2010 at 17:30, Barry Smith <bsmith at mcs.anl.gov> wrote:
> On Sep 30, 2010, at 12:35 AM, Jed Brown wrote:
>> how should the Matlab user find out what the name of the loaded vector is?
>
>   Whose

Some PETSc program outputs an ASCII file with a name like
mat_0x8af3c10_4, they source the file and now this variable is in
scope in their environment, but it's not predictable like Mat_0.

>> It won't be the same on consecutive identical runs.
>
>   True, though likely it will be the same.

With Open MPI, MPI_Comm is a pointer into the heap (like the opaque
handle for PETSc objects).  Most kernels randomize addresses so it is
not at all reproducible.

>> Or should it practically become mandatory to name objects that will go to Matlab?
>
>   I hate that, someone's been running some computation and then it stops suddenly because they forgot to name an output variable.

I only meant as a practical matter because it is cumbersome to work
with from Matlab unless they are named, not a rule to be enforced.

Jed



More information about the petsc-dev mailing list