|  | CMR
    1.3.0
    | 
A matrix \( A \in \{-1,0,+1\}^{m \times n} \) is called series-parallel if it can be obtained from a \( 0 \)-by- \( 0 \) matrix by successively adjoining
The removal of such a row/column is called an SP-reduction. A matroid is called series-parallel if it is represented by a series-parallel matrix. This is equivalent to being the graphic matroid of a series-parallel graph.
Theorem. A matrix \( A \in \{-1,0,1\}^{m \times n} \) is either series-parallel or it contains, up to scaling of rows/columns with \( -1 \),
The latter two matrices are called wheel matrices since their represented matroids are the graphic matroids of wheel graphs.
The command
cmr-series-parallel IN-MAT [OPTION...]
 determines whether the matrix given in file IN-MAT is series-parallel. If this is not the case, then a maximal number of SP-reductions is carried out, leading to the reduced matrix. Moreover, one can ask for one of the minimal non-series-parallel submatrices above.
Options:
-i FORMAT Format of file IN-MAT; default: dense.-S OUT-SP Write the list of series-parallel reductions to file OUT-SP; default: skip computation.-R OUT-REDUCED Write the reduced submatrix to file OUT-REDUCED; default: skip computation.-N NON-SUB Write a minimal non-series-parallel submatrix to file NON-SUB; default: skip computation.-b Test for being binary series-parallel; default: ternary.Advanced options:
--stats Print statistics about the computation to stderr.--time-limit LIMIT Allow at most LIMIT seconds for the computation.Formats for matrices: dense, sparse
If IN-MAT is - then the matrix is read from stdin.
If OUT-SP, OUT-REDUCED or NON-SUB is - then the list of reductions (resp. the submatrix) is written to stdout.
The implemented algorithm is not yet published. For a matrix \( A \in \{0,1\}^{m \times n}\) with \( k \) (sorted) nonzeros it runs in \( \mathcal{O}( m + n + k ) \) time assuming no hashtable collisions.
The corresponding functions in the library are
and are defined in series_parallel.h.