\(\text{SaveComplexMatrix}\)

You can use the \(\text{SaveComplexMatrix}\) to save a boolean matrix to a file.

You can use the \savecomplexmatrix backslash command to insert this function.

The following variants of this function are available:

  • \(\text{boolean } \text{SaveComplexMatrix} \left ( \text{<matrix>}, \text{<filename>} \right )\)

  • \(\text{boolean } \text{SaveComplexMatrix} \left ( \text{<matrix>}, \text{<filename>}, \text{<binary>} \right )\)

The \(\text{<matrix>}\) is the complex matrix to be saved and \(\text{<filename>}\) is the filename of the file to save the complex matrix to. The file will be overwritten if it exists.

The \(\text{<binary>}\) flag indicates if the file should be saved in a binary format or in CSV format. If excluded or false, the complex matrix will be saved as a tab separated CSV file suitable for import into software packages such as Microsoft Excel. If true, the complex matrix will be saved in a packed binary format.

Both formats can be read by Aion using the function \(\text{LoadComplexMatrix}\).

Note that the binary format is designed to be relatively simple for external applications to implement. For details on the binary format, see File Formats.

The Figure 167 shows how you can use the \(\text{SaveComplexMatrix}\) function.