matlab mxgetpr函数语法

发表matlab mxgetpr函数相关文章
一句话说明: Real data elements in array of type DOUBLE

mxGetPr (C and Fortran)

Real data elements in array of type DOUBLE

C Syntax

#include "matrix.h"
double *mxGetPr(const mxArray *pm);

Fortran Syntax

mwPointer mxGetPr(pm)
mwPointer pm

Arguments

pm

Pointer to an mxArray of type double

Returns

Pointer to the first element of the real data. Returns NULL in C (0 in Fortran) if there is no real data.

Description

Use mxGetPr on arrays of type double only. Use mxIsDouble to validate the mxArray type. For other mxArray types, use mxGetData.

Call mxGetPr to access the real data in the mxArray that pm points to. Once you have the starting address, you can access any other element in the mxArray.

Examples

See the following examples in matlabroot/extern/examples/refbook.

For Fortran examples, see:

See Also

mxGetPi, mxSetPi, mxSetPr, mxGetData, mxIsDouble

欢迎转载,转载请注明来自一手册:http://yishouce.com/matlab/func/mxgetpr

与matlab mxgetpr用法相关的文章

友情链接It题库(ittiku.com)| 版权归yishouce.com所有| 友链等可联系 admin#yishouce.com|粤ICP备16001685号-1