%%MatrixMarket matrix coordinate real general
%=================================================================================
%
% This ASCII file represents a sparse MxN matrix with L
% nonzeros in the following Matrix Market format:
%
% +----------------------------------------------+
% |%%MatrixMarket matrix coordinate real general | <--- header line
% |% | <--+
% |% comments | |-- 0 Or more comment lines
% |% | <--+
% | M N L | <--- rows, columns, entries
% | I1 J1 A(I1, J1) | <--+
% | I2 J2 A(I2, J2) | |
% | I3 J3 A(I3, J3) | |-- L lines
% | . . . | |
% | IL JL A(IL, JL) | <--+
% +----------------------------------------------+
%
% Indices are 1-based, i.e. A(1,1) Is the first element.
%
%=================================================================================
5 5 8
1 1 1.000e+00
2 2 1.050e+01
3 3 1.500e-02
1 4 6.000e+00
4 2 2.505e+02
4 4 -2.800e+02
4 5 3.332e+01
5 5 1.200e+01
MTXFormat
01 Syntax
Microsoft.VisualBasic.Math.Matrix.MatrixMarket.MTXFormat
02 Methods
| Name | Overloads | Summary |
|---|---|---|
| WriteMatrix | 2 | Writes a SparseMatrix as a Matrix Market coordinate stream. |
03 Members
WriteMatrix(
SparseMatrix, String)Saves a SparseMatrix into a Matrix Market coordinate text file (%%MatrixMarket matrix coordinate real general).
WriteMatrix(
SparseMatrix, StreamWriter)Writes a SparseMatrix as a Matrix Market coordinate stream. The indices are emitted 1-based to match MTXFormat.ReadMatrix().