Inputs/Outputs with GranOO (tutorial)

Tutorials

basic
your first simulation
advanced

This page describes the different file formats for importing/exporting data with granoo

The internal file formats : *dd files

GranOO uses several file formats. The list below details their respective interests.

  • *.gdd format is a complete backup of a domain. It contains the whole data of a simulation. If you want to monitor a simulation this kind of file is perfect. However, this format is not well adapted to exchange between different computers or different granoo versions. In addition, because all data are present, these files can be very large.

  • *.agdd is a simple ascii file format. Note that this format is only adapted to spherical discrete element domains. *.agdd is a very good portable format to exchange between different computers or different granoo versions… but it contains only a geometrical description of the domain ! Note that *.agdd can easily be self written. The listing below shows the composition of a *.agdd file. Please remove the comments if you want to use this file, *.agdd does not support any comment.

4 # number of discrete element
0.0	 0.	0.	0.1 # x,y,z position and radius
0.1	 0.	0.	0.1 # ...
0.2	 0.	0.	0.1 # ...
0.3	 0.	0.	0.1 # ...
3 # number of element pair 
0 1 # gives the index (start from 0) of both discrete elements
1 2 # ...
2 3 # ...
2 # number of discrete element set
left # id of the first discrete element set
1    # number of item indexed by the first discrete element set
0    # index of discrete element indexed by the first discrete element set
right # id of the second discrete element set
1     # number of item indexed by the second discrete element set
3     # index of discrete element indexed by the second discrete element set
  • *.lgdd is a simple ascii file format that may be used for any cases. *.lgdd format is a portable format well adapted to exchange between different computers or different granoo versions. Note that *.lgdd contains only a geometrical description of domains. The main difference with the *.agdd is that *.lgdd supports any discrete element shapes.

These three file formats may be used to read or write domains.

Exporting data to paraview

The standard plugin _ExportPVD can be used to export data for the well known data visualization tool paraview. Just insert the following line in your .inp file.

<EXPORT-TO-PVD Field="All"/> 

This plugin creates an output.pvd file in the output directory of your simulation. This file can be opened by paraview. To show correctly this file, you must first load and execute the paraview plugin ExtractData.py located in the Tool/Paraview/Macro directory of your granoo repository.

Exporting raw data for specific post-treatment

You probably want to monitor the evolution of specific parameters during a simulation. GranOO embeds the concepts of numerical sensors that helps you for this task. The numerical sensors will be treated in detail later in this tutorial.