CMR  1.3.0
Loading...
Searching...
No Matches
Classes | Enumerations | Functions
matroid.h File Reference

Functionality for matroids. More...

#include <cmr/env.h>
#include <cmr/matrix.h>
#include <cmr/graph.h>
#include <stdio.h>

Go to the source code of this file.

Classes

struct  CMR_MINOR
 A minor of a matroid. More...
 

Enumerations

enum  CMR_MINOR_TYPE {
  CMR_MINOR_TYPE_DETERMINANT = -2 , CMR_MINOR_TYPE_ENTRY = -1 , CMR_MINOR_TYPE_CUSTOM = 0 , CMR_MINOR_TYPE_U24 = 1 ,
  CMR_MINOR_TYPE_FANO = 2 , CMR_MINOR_TYPE_FANO_DUAL = 3 , CMR_MINOR_TYPE_K5 = 4 , CMR_MINOR_TYPE_K5_DUAL = 5 ,
  CMR_MINOR_TYPE_K33 = 6 , CMR_MINOR_TYPE_K33_DUAL = 7
}
 

Functions

CMR_EXPORT CMR_ERROR CMRchrmatBinaryPivot (CMR *cmr, CMR_CHRMAT *matrix, size_t pivotRow, size_t pivotColumn, CMR_CHRMAT **presult)
 Apply a pivot to matrix and returns the resulting matrix in *presult.
 
CMR_EXPORT CMR_ERROR CMRchrmatTernaryPivot (CMR *cmr, CMR_CHRMAT *matrix, size_t pivotRow, size_t pivotColumn, CMR_CHRMAT **presult)
 Applies a pivot to matrix and returns the resulting matrix in *presult.
 
CMR_EXPORT CMR_ERROR CMRchrmatRegularPivot (CMR *cmr, CMR_CHRMAT *matrix, size_t pivotRow, size_t pivotColumn, CMR_SUBMAT **pviolator, CMR_CHRMAT **presult)
 Applies a pivot to matrix and returns the resulting matrix in *presult.
 
CMR_EXPORT CMR_ERROR CMRchrmatBinaryPivots (CMR *cmr, CMR_CHRMAT *matrix, size_t numPivots, size_t *pivotRows, size_t *pivotColumns, CMR_CHRMAT **presult)
 Applies a sequence of pivots to matrix and returns the resulting matrix in *presult.
 
CMR_EXPORT CMR_ERROR CMRchrmatTernaryPivots (CMR *cmr, CMR_CHRMAT *matrix, size_t numPivots, size_t *pivotRows, size_t *pivotColumns, CMR_CHRMAT **presult)
 Applies a sequence of pivots to matrix and returns the resulting matrix in *presult.
 
CMR_EXPORT CMR_ERROR CMRchrmatRegularPivots (CMR *cmr, CMR_CHRMAT *matrix, size_t numPivots, size_t *pivotRows, size_t *pivotColumns, CMR_SUBMAT **pviolator, CMR_CHRMAT **presult)
 Applies a sequence of pivots to matrix and returns the resulting matrix in *presult.
 
CMR_EXPORT CMR_ERROR CMRminorCreate (CMR *cmr, CMR_MINOR **pminor, size_t numPivots, CMR_SUBMAT *submatrix, CMR_MINOR_TYPE type)
 Creates a minor, allocating space for numPivots pivots and a remaining submatrix.
 
CMR_EXPORT CMR_ERROR CMRminorFree (CMR *cmr, CMR_MINOR **pminor)
 Frees the minor *pminor (if pminor is not NULL).
 
CMR_EXPORT CMR_MINOR_TYPE CMRminorType (CMR_MINOR *minor)
 Returns the type of minor.
 
CMR_EXPORT size_t CMRminorNumPivots (CMR_MINOR *minor)
 Returns the number of pivots needed to make a minor visible.
 
CMR_EXPORT size_t * CMRminorPivotRows (CMR_MINOR *minor)
 Returns the array with pivot rows to make a minor visible.
 
CMR_EXPORT size_t * CMRminorPivotColumns (CMR_MINOR *minor)
 Returns the array with pivot columns to make a minor visible.
 
CMR_EXPORT CMR_SUBMATCMRminorSubmatrix (CMR_MINOR *minor)
 Returns the submatrix to take (after applying pivots) to make a minor visible.
 
CMR_EXPORT CMR_ERROR CMRminorPrint (CMR *cmr, CMR_MINOR *minor, size_t numRows, size_t numColumns, FILE *stream)
 Writes the minor minor to stream by means of lists of row and column indices as well as pivot entries.
 
CMR_EXPORT CMR_ERROR CMRminorWriteToFile (CMR *cmr, CMR_MINOR *minor, size_t numRows, size_t numColumns, const char *fileName)
 Writes the minor minor to the file fileName by means of lists of row and column indices as well as pivot entries.
 

Detailed Description

Functionality for matroids.

Author
Matthias Walter