mxGetJc (C and Fortran)
Sparse matrix JC array
C Syntax
#include "matrix.h" mwIndex *mxGetJc(const mxArray *pm);
Fortran Syntax
#include "fintrf.h" mwPointer mxGetJc(pm) mwPointer pm
Arguments
pm
Pointer to a sparse
mxArray
Returns
Pointer to the first element in the jc
array, if successful, and
NULL
in C (0
in Fortran) otherwise. Possible
causes of failure include
Specifying a full (nonsparse)
mxArray
.Specifying a value for
pm
that isNULL
in C (0
in Fortran). This failure usually means that an earlier call tomxCreateSparse
failed.
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
.
Examples
To open an example, type:
edit([fullfile(matlabroot,"extern","examples","refbook","filename")]);
where filename
is:
To open an example, type:
edit([fullfile(matlabroot,"extern","examples","mx","filename")]);
where filename
is:
To open an example, type:
edit([fullfile(matlabroot,"extern","examples","mex","filename")]);
where filename
is:
See Also
Version History
Introduced before R2006a