DSPRelated.com
Forums

How to call MATLAB in C#

Started by chuxeei September 6, 2006
Heello guys!!

I am currently developing a software using c#. But the thing is, i
have to do some image processing, and matlab is just the way to do it.
I was wondering if it is possible to embed matlab to c# and how?

I wasnt so lucky in finding resources on the net....

any help would be greatly appreciated...

thanks!!!!!!

-chuxeei
Hi Chuxeei,
if by calling Matlab in C# you mean using some functions or .m files in C#, you can do it in Matlab 7.2 version only. It has a toolbox called "Matlab Builder for .NET" which you can build some library, or COM objects which are implementable in your C# application. you can find the documents on online matlab help.
and if by calling you mean run matlab engine or part of program from a running C# application and pass some variables to it, you can do it in different ways. one of the ways is using Dynamic Data Exchange or COM objects. Also you can find how to make server and client examples in matlab help. search for C# COM client in matlab help and you'll find a good example for it.
Cheers,
Koorosh

chuxeei wrote:
Heello guys!!

I am currently developing a software using c#. But the thing is, i
have to do some image processing, and matlab is just the way to do it.
I was wondering if it is possible to embed matlab to c# and how?

I wasnt so lucky in finding resources on the net....

any help would be greatly appreciated...

thanks!!!!!!

-chuxeei