Showing results for 
Search instead for 
Did you mean: 

Connect Matlab and PlantSim


Hello everyone, 


I have the following problem:

I'm running a production simulation with Plant Sim 13. Every time the production stops (e.g. due to an error) I want to check whether it is beneficial to use the down time to change my material (stored on bobbins) or not. In order to solve this problem, I'm using Matlab's MILP solver. 

Is there a possibility to call the Matlab script from within PlantSim? I also need the current stock of material from PlantSim to run my optimization with Matlab. Afterwards the results of the optimization should be used by PlantSim to initiate a change of corresponding bobbins.


What is the best way to solve the described problem? Is there an easier way to solve it? 


Thanks in advance, 



Re: Connect Matlab and PlantSim

Solution Partner Phenom Solution Partner Phenom
Solution Partner Phenom

For sure this is possible, you can call the API from within Plant Simulation.


The way you describe it, you would have the following steps in your logic:

  1. Detect production stop event
  2. Export data of current stocks to a Matlab format (e.g. text file)
  3. Trigger Matlab optimization logic
  4. Import optimization result into Plant Simulation
  5. Continue simulation run


Gert Nomden
Senior Consultant | Tecnomatix Product Manager

Re: Connect Matlab and PlantSim


Many thanks for your quick response!


I will try to implement the logic the way you suggested