MfixReader User Guide

1. Introduction

This library of subroutines, written in the C language, can read MFIX data sets. It uses the MFIX format version, embedded in the restart file, so that it can correctly read many versions of MFIX files.

Data is not read into memory when a dataset is first opened. Instead, only basic metadata (data about the data) is gathered at that time. Later, the application may make any number of "requests" where each request returns one or more variables at a single time step. Other requests return the coordinates and lists of available variables.

A modest number of integrity checks are made to detect corrupt datasets. For example, if the final array of data for a variable is incomplete, the library quietly ignores that array; all previous arrays (i.e., previous time steps) are available.

See www.psc.edu/general/software/packages/mfix/tools to download the library.

Most of the code for the library is in the file MfixReader.c. Additional code for the conversion of binary data is in the file libbio.c. The file kLib.c contains general support for C routines including a special debugging system. Each of these files has an associated header file that defines variables, enumerated types and data structures. All are included in the download.