mxGetJc (C and Fortran) - Get jc array of sparse matrix

C Syntax

#include "matrix.h"
mwIndex *mxGetJc(const mxArray *pm);

Fortran Syntax

mwPointer mxGetJc(pm)
mwPointer pm

Arguments

pm

Pointer to a sparse mxArray

Returns

A pointer to the first element in the jc array, if successful, and NULL in C (0 in Fortran) otherwise. Possible causes of failure include

Description

Use mxGetJc to obtain the starting address of the jc array. The jc array is an integer array having n+1 elements, where n is the number of columns in the sparse mxArray. The values in the jc array indirectly indicate columns containing nonzero elements. For a detailed explanation of the jc array, see mxSetJc.

C Examples

See fulltosparse.c in the refbook subdirectory of the examples directory.

Additional examples:

See Also

mxGetIr, mxGetNzmax, mxSetIr, mxSetJc, mxSetNzmax

  


 © 1984-2008- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS