mxCreateLogicalMatrix (C) - Create 2-D, logical mxArray initialized to false

C Syntax

#include "matrix.h"
mxArray *mxCreateLogicalMatrix(mwSize m, mwSize n);

Arguments

m

The desired number of rows

n

The desired number of columns

Returns

A pointer to the created mxArray, if successful. If unsuccessful in a stand alone (non-MEX-file) application, mxCreateLogicalMatrix returns NULL. If unsuccessful in a MEX-file, the MEX-file terminates and control returns to the MATLAB prompt. mxCreateLogicalMatrix is unsuccessful when there is not enough free heap space to create the mxArray.

Description

Use mxCreateLogicalMatrix to create an m-by-n mxArray of mxLogical elements. mxCreateLogicalMatrix initializes each element in the array to logical 0.

Call mxDestroyArray when you finish using the mxArray. mxDestroyArray deallocates the mxArray.

See Also

mxCreateLogicalArray, mxCreateSparseLogicalMatrix, mxCreateLogicalScalar

  


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