English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
Simulink is an integrated simulation and model-based design environment for dynamic and embedded systems. Simulink, also developed by MathWorks, is a dataflow graphical programming language tool used for modeling, simulating, and analyzing multi-domain dynamic systems. It is essentially a graphical block diagram drawing tool with a customizable block library set.
It allows you to integrate MATLAB algorithms into models and export simulation results to MATLAB for further analysis.
Simulink support-
System-level design
Simulation
Automatic code generation
Testing and verification of embedded systems
MathWorks provides several other additional products as well as third-party hardware and software products that can be used with Simulink.
The following list briefly describes some of them-
Stateflow Allows the development of state machines and flowcharts.
Simulink Coder Allows the generation of C source code for automatic real-time implementation of systems.
xPC Targetandx86-based real-time systemsProvides an environment where Simulink and Stateflow models can be simulated and tested in real-time on physical systems.
Embedded Coder Supports specific embedded targets.
HDL Coder Allows the automatic generation of synthesizable VHDL and Verilog.
SimEvents A graphical component library is provided for modeling queuing systems.
Simulink can perform systematic verification and confirmation of models through build pattern checking, requirements traceability, and model coverage analysis.
Simulink Design Verifier allows you to identify design errors and generate test case scenarios for model verification.
To open Simulink, please enter in the MATLAB workspace-
simulink
Simulink opens immediatelyLibrary Browser. The Library Browser is used to build simulation models.
In the left pane, you will find several libraries categorized by different systems. Clicking each library will display design blocks in the right pane.
To create a new model, clickNewButtons on the “Library Browser” toolbar. This will open a new untitled model window.
A Simulink model is a block diagram.
Model elements can be added by selecting appropriate elements from the “Library Browser” and dragging them into the “Model” window.
Or, you can copy model elements and paste them into the model window.
Drag and drop items from the Simulink library to create projects.
For the purpose of this example, we will use two blocks for simulation-A Source(Signal) and a Sink(Oscilloscope). The signal generator (source) produces analog signals, which are then displayed graphically by the scope (the sink).
First, drag the required blocks from the library to the project window. Then, connect the blocks together, which can be done by dragging a connector from a connection point on one block to a connection point on another block.
Let's drag the “Sine Wave” block into the model.
Select “Receiver” from the library and then drag the “Range” block into the model.
Drag the signal line from the output of the sine wave module to the input of the oscilloscope module.
Press the “ RunRun the simulation by clicking the ”button, and keep all parameters default (you can change them from the “Simulation” menu)
You should get the following figure from the merged range.