title: Parallel execution of COM instances in Matlab
body: <p>I'm trying to accelerate our test environment by using the ParralelToolbox of Mathworks. However I am unable to start several Matlab instances in parallel (up to now we run our tests sequentially and each one is starting a new Matlab instance via an ActX server).
  So when I run the following code below</p>
  
  <pre><code>ML=ver('Matlab');
  ML_Path=matlabroot;
  ML_Ver=ML.Version;
  parfor i = 1:3
      NewMatlab = actxserver(['matlab.application.single.',ML_Ver])
      Answer = NewMatlab.Feval('test',1);
      NewMatlab.Quit;
      NewMatlab.release;
  end
  </code></pre>
  
  <p>the Matlab instances are called sequentially (test is just a very simple script that sums up a few numbers).</p>
  
  <p>However if I start a new Matlab via command line</p>
  
  <pre><code>ML=ver('Matlab');
  ML_Path=matlabroot;
  ML_Ver=ML.Version;
  parfor i = 1:3
      dos('matlab -nodesktop -minimize -wait -batch "test"');
  end
  </code></pre>
  
  <p>it works. I see that these two methods are quite different in the handling of starting Matlab, but the first approach would be  </p>