RNGT(5) | File Formats Manual | RNGT(5) |
NAME
rngt
— Rad-Net Gas
Temperatures
DESCRIPTION
rngt
is a binary file format for storing
gas temperatures. The temperatures are discretized according to the mesh of
the gas. The mesh to which the temperatures are attached is
not
described there but must be defined in a separate file, for example in an
smsh(5) file. The number of
temperatures and their order must therefore correspond to the data of the
mesh to which they are attached, i.e. to the nodes or cells listed in the
corresponding mesh.
A rngt
file is actually a Star-Buffer file
(see sbuf(5)). It starts with a
header of 4 integers. The first integer is a power of two (usually 4096)
that defines the size of the memory page in bytes
(pagesize) on which the list of temperatures are
aligned. By aligning data to pagesize, and depending on system requirements,
memory mapping can be used to automatically load/unload pages on demand (see
mmap(2)). The second integer is
the size of the array, i.e. the number of temperatures
stored in the list. The two remaining integers store the memory size (4
bytes) and the memory alignment (4 bytes) of a temperature.
Padding bytes follow the file header to align the listed temperatures to pagesize.
Padding bytes are finally added at the end of the file to align its overall size with the size of a page.
Data are encoded with respect to the little endian bytes ordering, i.e. least significant bytes are stored first.
The file format is as follows:
⟨rngt⟩ | ::= | ⟨pagesize⟩
⟨size⟩ 4
4 |
⟨padding⟩ | ||
⟨temperatures⟩ | ||
⟨padding⟩ | ||
⟨pagesize⟩ | ::= | uint64_t |
⟨size⟩ | ::= | uint64_t # Number of temperatures stored |
⟨temperatures⟩ | ::= | float ... # In K |
⟨padding⟩ | ::= | [int8_t ...] |
SEE ALSO
HISTORY
The rngt
format was first developed for
the htrdr-planeto(1)
program.
September 26, 2023 | UNIX |