converting a matlab array (MAT-file) to C++ array

1.1k Views Asked by At

I have a 2-D double-precision array in MATLAB that contains specific data. I want to use this array in c++, so I save the array in a mat-file. I know that MATLAB has some c functions that provide reading mat-file in c++ (matdsgn , matOpen , ...), but I don't know how to use them in a c++ program. Actually, I don't know how to use a C library in C++. Any help would be appreciated.

1

There are 1 best solutions below

0
On

If you have MATLAB 2017a, there is a built-in function. See this MATHWORKS link: Math Works