EMxtalExtract - EMsoft-org/EMsoft GitHub Wiki

Program: EMxtalExtract

Sometimes a user may want to share a crystal structure file, which is stored in HDF5 format, with another user via email. Since some email servers may not allow for such a binary file to be attached to a message, the EMxtalExtract program can be used to convert the HDF5 file entries into a simple text file that can either be attached or simply pasted into an email message.

The original HDF5 file can then be reconstructed by feeding the text file into the EMmkxtal program using a standard redirect. As an example, consider the SrTiO3.xtal structure file. The EMxtalExtract program produces the following text file, say STO.txt:

1
   0.39070
221
38
   0.00000,   0.00000,   0.00000,   1.00000,   0.00500
y
22
   0.50000,   0.50000,   0.50000,   1.00000,   0.00500
y
 8
   0.50000,   0.50000,   0.00000,   1.00000,   0.00500
n
SrTiO3.xtal
''

Using EMmkxtal <STO.txt on a UNIX platform, one can regenerate the original HDF5 file.