CMR  1.3.0
Typedefs | Functions
element.h File Reference

Functionality for the row and column elements of a matrix. More...

#include <cmr/env.h>
#include <assert.h>

Go to the source code of this file.

Typedefs

typedef int CMR_ELEMENT
 

Functions

CMR_EXPORT const char * CMRelementString (CMR_ELEMENT element, char *buffer)
 
static bool CMRelementIsValid (CMR_ELEMENT element)
 Returns true if element is a row or a column element. More...
 
static CMR_ELEMENT CMRrowToElement (size_t row)
 
static CMR_ELEMENT CMRcolumnToElement (size_t column)
 
static bool CMRelementIsRow (CMR_ELEMENT element)
 
static size_t CMRelementToRowIndex (CMR_ELEMENT element)
 
static bool CMRelementIsColumn (CMR_ELEMENT element)
 
static size_t CMRelementToColumnIndex (CMR_ELEMENT element)
 
static CMR_ELEMENT CMRelementTranspose (CMR_ELEMENT element)
 Transposes element, i.e., turns rows into columns and vice versa. More...
 

Detailed Description

Functionality for the row and column elements of a matrix.

Author
Matthias Walter

Typedef Documentation

◆ CMR_ELEMENT

typedef int CMR_ELEMENT

Function Documentation

◆ CMRcolumnToElement()

static CMR_ELEMENT CMRcolumnToElement ( size_t  column)
inlinestatic
Parameters
columnColumn index.

◆ CMRelementIsColumn()

static bool CMRelementIsColumn ( CMR_ELEMENT  element)
inlinestatic
Parameters
elementElement to check.

◆ CMRelementIsRow()

static bool CMRelementIsRow ( CMR_ELEMENT  element)
inlinestatic
Parameters
elementElement to check.

◆ CMRelementIsValid()

static bool CMRelementIsValid ( CMR_ELEMENT  element)
inlinestatic

Returns true if element is a row or a column element.

Parameters
elementElement to check for validity.

◆ CMRelementString()

CMR_EXPORT const char* CMRelementString ( CMR_ELEMENT  element,
char *  buffer 
)
Parameters
elementElement to print.
bufferBuffer of size at least 32. May be NULL, in which case a static buffer is used.

◆ CMRelementToColumnIndex()

static size_t CMRelementToColumnIndex ( CMR_ELEMENT  element)
inlinestatic
Parameters
elementElement to convert.

◆ CMRelementToRowIndex()

static size_t CMRelementToRowIndex ( CMR_ELEMENT  element)
inlinestatic
Parameters
elementElement to convert.

◆ CMRelementTranspose()

static CMR_ELEMENT CMRelementTranspose ( CMR_ELEMENT  element)
inlinestatic

Transposes element, i.e., turns rows into columns and vice versa.

Parameters
elementElement to transpose.

◆ CMRrowToElement()

static CMR_ELEMENT CMRrowToElement ( size_t  row)
inlinestatic
Parameters
rowRow index.