Click here to Skip to main content
15,912,977 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have generated a C++ library using the following command
" mcc -B 'cpplib:SVD,SingularValueDecomposition,1.0' svd.m "

it generated all the libraries and dll s. I dont know how to make use of it in C++ as these libraries make use of datatypes such as "mwArray" which are not recognized by c++. I there any way to use the in C++
Posted

1 solution

are any headers generated? if so, the headers should have the definitions you need, just need to include the headers (usually one main header that includes anything else required) and tell your linker to use the lib.

Found these resources for you:
http://tomopt.com/docs/standalone/tomlab_sal008.php[^]
http://tomopt.com/docs/standalone/tomlab_sal011.php#source_appendix[^]

Found this explanation of mwArray in Matlab's help:
http://www.mathworks.com/help/toolbox/compiler/mwarrayconstmwarrayarr.html[^]

As you can see, they seem to require an additional include that may not be part of your generated header.
 
Share this answer
 
v3
Comments
Ravi-original 18-Apr-11 13:45pm    
Yes there is one header generated. Lets say I have generated c++ libraries for svd.m the there is a header called svd.h which is generated in addition to svd.lib and svd.dll. but the library svd.h doesnot have the definition for the datatype I am talking about
Albert Holguin 18-Apr-11 14:00pm    
found some examples in the web... see if it makes sense to you. according to their examples, the functions necessary to create mwArray types are included.
Albert Holguin 19-Apr-11 22:20pm    
posted an update with a new link...

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900