Take a quick look at the Simulink user interface.
- [Narrator] Another really powerful tool the MATLAB offers is Simulink. Simulink is a block diagram tool that we can use to build systems, feedback loops, we can even use it to generate code for hardware like FPGAs. If you're using the home edition of MATLAB, Simulink won't be installed by default, and you'll have to purchase it and install it. If you do have it, it will be located here on your toolbar. So let's open it up and check it out. When we click on it, we're given some options here for different types of projects we can start. Let's go ahead and open up a blank model.
I'll double click that. And the large blank space in front of us here is where we can drag the blocks for our block diagrams. We get the blocks in the library browser here. Let's go ahead and click on this. And you can see on the left hand of the library, there's a list of all the different categories that we have. And on the right, there are the blocks. Up here we can search for things. Let's look for sum, just for kicks. And we can see all the blocks that have to do with summations. Summing blocks for control systems, addition blocks, dot products, etcetera.
We could search for something else like filter. And this will bring up all the various blocks associated with filtering. You can also feel free to look through the various categories here on the left. If we look in math operations, we have all kinds of fun things we can check out. Two important ones I want to bring your attention to are sources and sinks. Sources are what we use to generate data or bring in data from the MATLAB workspace. You can see there's thing here like pulse generators, sine waves, random numbers, and the like.
Similarly, we can use sinks to visualize data or bring it back out into the MATLAB workspace. Blocks like scope or XY graph can be used to plot data. And the two workspace block can grab a signal and bring it back out into the MATLAB workspace. So let's put these to use.
- Creating MATLAB variables
- Working with matrix and scalar operations
- Using if statements and loops
- Creating functions
- Importing data
- Building basic plots and 3D plots
- Working with images
- Creating Simulink models