File Exchange

image thumbnail


version (138 KB) by Jerome Lacaille
Compile mex-functions with C++ Math Library and the mwArray matrix.

1 Download

Updated 21 Oct 2002

No License

Mex-functions can be compiled using the C structure mxArray. But it's also possible to use the C++ mwArrays and all the C++ math library. Use "cppmex -setup" to initialise the compiler for your installation and then type cppmex instead of mex. Now the entry point become void cppMexFunction(int nlhs, mwArray mlhs[], int nrhs, mwArray mrhs[]).

Cite As

Jerome Lacaille (2021). cppmex (, MATLAB Central File Exchange. Retrieved .

Comments and Ratings (3)

Nguyen Thang

I found error when run:
>> cppmex -setup
??? Error using ==> cppmex_setup at 8
Can't find <C:\Program Files\MATLAB\R2008a\extern\include\libmmfile.mlib>.

Error in ==> cppmex at 60
cppmex_setup ;

Plz help me! many thanks.

Jian Wang


Matthias Frank

It's a really helpfull extension to the compiler. It make it very easy to write and to translate mex files.
Thanks to Jerome

MATLAB Release Compatibility
Created with R13
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!