Why function 'sparse' is not supported by Matlab compiler?

2 ビュー (過去 30 日間)
Simona787
Simona787 2018 年 5 月 17 日
コメント済み: Simona787 2018 年 5 月 18 日
I want to compile some my matlab codes to generate a c++ dll, so that I can integrate it into my c++ project. But after all these thing done I run the program, some errors occurred, saying Undefined function 'sparse' corresponding to input parameters of 'int32' type.I check the source codes and found the 'sparse' was a matlab built-in function which is responsible for create a sparse matrix. so I wonder if there are other alternative for the 'sparse'? Why function 'sparse' is not supported by Matlab compiler? ps: matlab 2015b +vs2015

回答 (1 件)

Steven Lord
Steven Lord 2018 年 5 月 17 日
According to the Release Notes for MATLAB Coder (which I believe is what you're using, not MATLAB Compiler) support for generating code using sparse matrices was introduced in release R2018a.
  3 件のコメント
Walter Roberson
Walter Roberson 2018 年 5 月 18 日
Generating C++ DLL is MATLAB Compiler SDK if the DLL relies upon MCR being present, and is MATLAB Coder if the DLL is to be stand-alone (that is, not require MCR to be present.)
Simona787
Simona787 2018 年 5 月 18 日
Yes,I have already installed mcr.

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeC Shared Library Integration についてさらに検索

製品


リリース

R2015b

Community Treasure Hunt

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

Start Hunting!

Translated by