This course teaches Simulink, from the basics (beginning with installation) through advanced topics (Simulink for embedded systems). Here is a sampling of topics that I cover in this course:
By the time you complete this course, you will be well-prepared to effectively use Simulink for a range of tasks, including the following:
You will also have the skills to understand and resolve some common challenges with Simulink and to build systems that scale well for use in commercially viable systems. Some years ago while I was in graduate school, I switched from running my simulations in Matlab scripts to using Simulink - and became far more productive! I found that I was able to focus on what I wanted to simulate instead of getting bogged down in the implementation. Prior to switching to Simulink, I spent a lot of time debugging my simulation scripts. After switching to Simulink, I spent far less time debugging and was free to focus on getting results. For the past several years in industry, I've continued to use Simulink for both simulation and embedded hardware, and it has hugely enhanced my productivity. I hope that you too experience huge gains in productivity as you use Simulink, and I intend for this course to help you achieve those gains!
*Disclaimer: after publishing this course, I learned that a book entitled "Mastering Simulink" was published a number of years ago. This course is not associated with that book.
Welcome to Simulink! This lecture introduces the course and summarizes some of the key topics in Simulink that you'll master as you progress through the course.
This optional lecture will walk you through installing and activating Matlab and Simulink, in case you don't have them installed already. If you don't have a license, don't worry! I'll work through the course using the trial version of Matlab/Simulink with a trial license so that your results with a trial installation will be identical to mine. Also, it's fine if you have an older version of Simulink - I'll occasionally mention points on which the latest version of Simulink differs from older versions so that you can easily keep up with the course and replicate my results as you learn to master Simulink!
This lecture will help you get started with Simulink by creating and simulating a very simple model. If you already have some experience with Simulink, never fear! Later lectures will soon delve into more advanced material for you.
This lecture introduces some really common logic blocks that nearly everyone will end up using on a regular basis when creating Simulink models.
In this lecture, I will introduce you to input blocks in Simulink. I will also create a slightly more sophisticated model using a couple of kinds of inputs to demonstrate how certain input blocks (and a few common blocks) can be put to good use. The example model will demonstrate, among other things, how to use switches, clocks, and conditional logic, how to create a simple memory element, and how to graphically viewing simulation outputs.
This lecture will give you a brief introduction to Simulink's output blocks, with a simple simulation to highlight a few features of one of my favorite output blocks, the scope. I'll also talk through use cases for some other common outputs.
In this lecture, you'll be introduced to using datatypes in Simulink, the basics of datatype inheritance, sample rates and times and how to transition between them, and triggered and enabled subsystems.
After this session, you'll know how to select and configure a solver that will give you a good balance between simulation speed and fidelity.
In this lecture, I'll show you how to deal with some common Simulink modeling challenges by walking you through a set of example models with extended explanations. Specifically, this lecture will help you work with memory and signal management.
This lecture will help you use if-statements, boolean logic, and switches to execute logic based on different circumstances or strategies of your choosing.
In this session, you'll learn about Simulink libraries - why they exist, how to use them, how to modify them, and how they can make your logic more modular, more maintainable, and more scalable.
This lecture introduces masks, which you can use to make your logic more aesthetically appealing, user-friendly, and re-usable. Masks help make your models look more professional, and create a level of abstraction between the user and the underlying logic, so that users can easily treat some (or all) of your model as a black box.
This lesson will introduce you to Matlab scripting for Simulink, using m-files for model callbacks and mask callbacks, and using Matlab scripting in Matlab function blocks. Integrating m-file scripting with Simulink can help you make your models more scalable, and Matlab function blocks are often helpful for quick, proof-of-concept work in simulation.
In this session, you'll learn some tips and tricks for signal routing to make your model more human-readable. You'll also learn how to name signals, how to log signals during simulation for plotting afterward, and how to add testpoints for embedded software.
This lesson will help give you an understanding of what to do when things go wrong. It is frustrating, when learning to use new software, to encounter errors and warnings. This lesson introduces you to some common error, warning, and diagnostic messages, shows you how to control those messages, and explains what causes (and how to prevent) some of the more common error and warning messages, so that you can effectively accomplish your work without issues.
Ready to learn to use Stateflow? You'll learn how to use Stateflow in this session, with a simple Stateflow example compared against if-else logic and switching logic from a previous session. Stateflow is a fantastic tool for state-based logic, and once you've completed this lesson, you'll be well equipped to be productive with Stateflow.
In this lesson, you'll learn to use Simulink to create code that you can then run on hardware, such as a Raspberry Pi, Lego Mindstorms robot, and more. Forget hand-coding! Simulink's visual approach to algorithm development will allow you to create high-quality code for your hardware while focusing on your software strategies, rather than on coding syntax.
Hi, I'm David. I earned my bachelor's and master's degrees in electrical engineering and enjoy applying my engineering knowledge to real-world problems.
I used Matlab in my bachelor's degree program and then encountered Simulink when I began my graduate studies. I've been using Simulink almost daily ever since, both throughout my time in graduate school and over the course of the last several years that I've spent working in industry.
Working with Simulink has been very rewarding and I've enjoyed having the opportunity to apply this amazing tool to the daily challenges that I encounter as an engineer. I hope that you find Simulink as helpful and as practical as I have found it.
I've used Simulink for system identification, control systems design, general software algorithms, artificial intelligence, physical system (plant) modeling and simulation, signal processing and more. Once you start with Simulink, you will be amazed by how many problems it can help you solve!