-
Notifications
You must be signed in to change notification settings - Fork 0
4. HDF5 output format
The framework provided a mini wrapper for outputting the grid variables (snapshots) in HDF5 format. You can output any grid variables at any time. Before using the HDF5 output function, the HDF5 library must be installed correctly. Then you can use the compile option -D HDF5 to compile HDF5 support into the framework.
At current, the format of output is very simple, only two datasets: one is for coordinates called 'coords', the other is for the data itself called 'solution'.
- coordinate dataset is a two dimensional array : coords[size][3]
- 1st : the size of the grid
- 2nd : a constant value : 3. These unused coordinates in 1D/2D can be ignored safely when reading it.
- solution dataset is a one dimensional array recording values of the variable according the order of their coordinates.
There is no rigorous order in coordinates. The coordinates within the same sub-grid is ordered by x-y-z from small to big, but there is no global ordering when using space parallel. So if you want to plot a cross section of a 3D result, it is better to run the program using one single process. Some example scripts for reading and plotting the result data are located in the 'test' directory.