[petsc-users] VTK format?

Blaise A Bourdin bourdin at lsu.edu
Thu Sep 3 10:14:36 CDT 2020


Hi,

There is also support for the exodus format, with parallel IO. Have a look at src/dm/impls/plex/tests/ex26.c for an example. Exodus is a bit complicated and needs formatting before you can start dumping data in a file. It is supported by pretty much all post-processing software on the market.

Blaise
> On Sep 3, 2020, at 9:53 AM, Jed Brown <jed at jedbrown.org> wrote:
> 
> Use the xml format (not the legacy format) by naming your file.vtu instead of file.vtk
> 
> On Thu, Sep 3, 2020, at 8:17 AM, Berend van Wachem wrote:
>> Dear PETSc,
>> 
>> What is the best way to write data from a DMPLEX vector to file, so it 
>> can be viewed with paraview?
>> I've found that the standard VTK format works for a serial job, but if 
>> there is more than 1 processor, the geometry data gets messed up.
>> I've attached a small working example for a cylinder and the visualised 
>> geometry with paraview for 1 processors and 4 processors.
>> Any pointers or "best practice" very much appreciated.
>> 
>> Best regards,
>> 
>> Berend.
>> 
>> 
>> 
>> 
>> Attachments:
>> 	• visualisemesh-1proc.png
>> 	• visualisemesh-4proc.png
>> 	• visualizemesh.c

-- 
A.K. & Shirley Barton Professor of  Mathematics
Adjunct Professor of Mechanical Engineering
Adjunct of the Center for Computation & Technology
Louisiana State University, Lockett Hall Room 344, Baton Rouge, LA 70803, USA
Tel. +1 (225) 578 1612, Fax  +1 (225) 578 4276 Web http://www.math.lsu.edu/~bourdin



More information about the petsc-users mailing list