Reputation: 11
I am trying to output my numerical simulation data in vtk format. My grid is structured and I need to use the VTK's XML format. My greatest confusion is about the WholeExtent and the Piece Extent attributes. E.g., the VTK pdf manual says
StructuredGrid WholeExtent = "x1 x2 y1 y2 z1 z2".
What exactly are these x1
, x2
's, etc? A similar question is about the x1
, x2
's in the Piece Extent attribute.
Thank you!
Upvotes: 0
Views: 248
Reputation: 11
I got the answer on the VTK forum, courtesy of Dan Lipsa.
It is easier to explain it using a minimum working example. Suppose we have a 10x6x1 (2D) grid, 2 CPUs in the x-direction, 1 CPU in the remaining directions. That is, Proc 1 has 6x6x1 and Proc 2 has 5x6x1 grid points, respectively. Then I've these lines of code in my vts files:
Processor 1: StructuredGrid WholeExtent=" 1 6 1 6 1 1 " Piece Extent=" 1 6 1 6 1 1 "
Processor 2: StructuredGrid WholeExtent=" 6 10 1 6 1 1 " Piece Extent=" 6 10 1 6 1 1 "
A sample data file can be found at the following link: VTK forum
Upvotes: 1