How can I pass a C++ Function into MATLAB function when doing mixed programming?
조회 수: 10 (최근 30일)
이전 댓글 표시
Hi friends: Because I need to do some secondary development using NX OPEN/C API, and I would like to take adantage of the math functions in MATLAB,I'm trying to do mixed programming. You know, it's not difficult to pass a number, vector or matrix into a compiled MATLAB function when programming in Visual C++. However, some functions, for example, optimization functions,need another function as their input. That's what the question is. When the MATLAB code was compiled, I found the input of function hundle became MwArray,and it seemed it was not prepared to receive a function. I found a paper saying that we can #include"matlab.hpp" and use MATLAB C++ Math Library. But in fact matlab.hpp is out of date. Is there another way to solve this problem? My software versions are MATLAB 2014a and Visual Studio 2015. Thanks!
댓글 수: 0
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Call C++ from MATLAB에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!