
A2.5 Ox exported mathematics functions 65
MatCopy.. .
MATRIX MatCopy(MATRIX mDest, MATRIX mSrc, int cM,int cN);
MATRIX MatCopyTranspose(MATRIX mDestT, MATRIX mSrc,
int cM, int cN);
void MatCopyVecr(MATRIX mDest, VECTOR vSrc_r, int cM, int cN);
void MatCopyVecc(MATRIX mDest, VECTOR vSrc_c, int cM, int cN);
mSrc[cM][cN] in: m × n matrix A to copy
vSrc
r[cM*cN] in: vectorized m × n matrix (stored by row)
vSrc
c[cM*cN] in: vectorized m × n matrix (stored by column)
mDest[cM][cN] in: allocated matrix
out: copy of source matrix
mDestT[cN][cM] in: allocated matrix
out: copy of transpose of mSrc
Return value
MatCopy and MatCopyTranspose return a pointer to the destination matrix
which holds a copy of the source matrix.
MatDup
MATRIX MatDup(MATRIX mSrc, int cM, int cN);
mSrc[cM][cN] in: m × n matrix A to duplicate
Return value
Returns a pointer to a newly allocated matrix, which must be deallocated with
MatFree. A return value of NULL indicates allocation failure.
MatFree, MatFreeBlock
void MatFree(MATRIX mA, int cM, int cN);
void MatFreeBlock(MATRIX m);
mA[cM][cN] in: matrix to free, previously allocated using
MatAlloc or MatDup
No return value.
Description
MatFree(m,a,b) is the macro version which maps to MatFreeBlock(m).
MatGenInvert
MATRIX MatGenInvert(MATRIX mA, int cM, int cN, MATRIX mRes,
VECTOR vSval);
mA[cM][cN] in: m × n matrix A to invert
mRes[cN][cM] in: allocated matrix (may be equal to mA)
out: generalized inverse of A using SVD
vSval[ min(cM,cN)] in: NULL or allocated vector
out: sing.vals of A (if m ≥ n)orA
0
(if m<n);
Kommentare zu diesen Handbüchern