how to export simulink data to matlab workspace | applied electronics engineering

Latest

how to export simulink data to matlab workspace

By Applied Electronics - Monday, March 6, 2017 No Comments
In this 4th part tutorial of Modeling Digital Communication systems using Simulink we will show how to export simulink data to matlab workspace. Saving simulink simulation produced data as variable in Matlab workspace can be used for further manipulation or analysis using matlab programming language.

To illustrate we will use the simulink model created in the earlier tutorial How to create sampled based signal in simulink. This is shown below.



Now to export the simulation data, we connect the To Workspace block which you can find in the Simulink/ Sink library to the output of the block whose data we want to collect. In this example we want to collect/save/export the output of the Sine Wave block. So we connect the To Workspace to the output of the Sine Wave block. Thats shown below.


Now running the simulation will save the sine wave sampled output to the Matlab workspace as shown below. The variable name that will store those sampled data from simulink is the simout. simout is variable name because the To Workspace block name is simout. You can change it to other name by simply double clicking on the To Workspace and changing the name there.


So in this simulink tutorial we showed you how to export simulink data to matlab workspace. For matlab programming language and matlab code based tutorial see matlab code for qpsk modulation and demodulation or the matlab tutorial page. For learning simulink see Electrotechnical Systems: Simulation with Simulink® and SimPowerSystems PDF free download.

No Comment to " how to export simulink data to matlab workspace "