mxSetPi (Fortran)
(Not recommended) Set imaginary data elements in
mxDOUBLE_CLASS
array
mxSetPi
is not available in the interleaved complex API. Use
mxSetComplexDoubles
instead. For more information, see Version History.
Fortran Syntax
#include "fintrf.h" subroutine mxSetPi(pm, pi) mwPointer pm, pi
Description
Use mxSetPi
to set the imaginary data of the specified
mxArray
.
Most mxCreate
* functions optionally allocate heap space to hold
imaginary data. If you allocate heap space when calling an mxCreate
*
function, then do not use mxSetPi
to initialize the imaginary
elements of the array. Rather, call this function to replace existing values with new
values. Examples of allocating heap space include setting the
ComplexFlag
to mxCOMPLEX
or setting
pi
to a non-0
value.
The mxSetPi
function does not free any memory allocated for
existing data that it displaces. To free existing memory, call
mxFree
on the pointer returned by
mxGetPi
.