From Matlab to Java To Matlab

· Interoperability, JAVA, Matlab

Lately, most of my testers are either Java or Matlab.

You can’t do (not in linear time 🙂 ) your Matlab magics with Java, and you can only dream on your Java OOD capabilities when working with Matlab…

A nice workaround is to combine your testers; work on your main programming language of interest, and call back and forth to the other one:

From Java to Matlab:

The idea is create a “Matlab Control” and then run (=evaluate) Matlab code:

  1. MatlabControl.eval(String your_matlab_command)
  2. MatlabControl.feval(String your_matlab_function_name, Object[] args)

The complete solution from: Kamin Whitehouse


From Matlab to Java (a little more built-in):

  • For using Java objects:


  • For using static Java methods:


The complete official Matlab link

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: