Online Teaching and Virtual Labs with MATLAB and Simulink
From the series: Online Teaching with MATLAB and Simulink
To continue to meet the ever-increasing demand for graduates with strong technical and problem-solving skills, universities have adopted more online, hybrid, and flipped courses. These teaching modalities require educators to redesign their courses and adopt new tools that will support student learning. MathWorks continues to provide resources to educate the next generation of engineers and scientists by developing tools to support instructors as they adapt to the changing landscape of education. In this webinar, you will learn about tools that encourage self-driven learning and cloud-based tools that afford instructors and students anytime, anywhere access to their course content.
We will discuss several resources, including:
- Challenging students using real-world problems with hardware, IoT, MATLAB Online™, and Simulink®
- Empowering students to take ownership of their own learning with self-paced courses, MATLAB® apps, and interactive programming using Live Scripts
- Mentoring students at scale with automated assessment and feedback in MATLAB Grader™
- Connecting MATLAB users through the Distance Learning Community
Published: 17 Nov 2020
Slide 1
Welcome to this MathWorks technical webinar. Today we’ll discuss various MathWorks resources for your virtual course and how to integrate these tools quickly. My name is Dr. Elvira Osuna-Highley and I am a Senior Customer Success Engineer at MathWorks.
Slide 2
The landscape of education is changing. Universities are adopting more online, hybrid and flipped courses. The changing landscape requires us to be adaptable and robust with our teaching approaches.
We need tools that can easily transition through all these modalities. From the first lecture to the last, tools need to enhance the student experience both in the classroom and online. In this session, we’ll discuss various MathWorks resources that can help you achieve your learning outcomes no matter the class format.
Slide 3
I’d like to start by showing an example of what an adaptable, student-focused course looks like. This online Differential Equations course is offered by MIT through EdX and has consistently high enrollment by users worldwide. Now, I know not everyone is not thinking of creating a Massive open online course, but the concepts and tools used here can be used for any format and any class size. Creating this online course had 3 key hurdles:
First, students needed access to MATLAB. To overcome this, the course need an online solution. They used MATLAB Online as this requires no downloads or installation- you use MATLAB right in your browser. Second, learning Differential Equations online is a tall order. The course materials need to allow for students to learn at their own pace. Students needed to interact with the material and have a narrative around the code to help guide them through the material. To accomplish this, they used Live Scripts. Live Scripts are interactive documents that allow you to create a story around your code. Finally, assessment. They needed to efficiently grade assignments while offering feedback. With such a large course, running each student’s code and writing feedback is an impossible task. With MATLAB Grader, they were able to create online assignments, automatically grade them and offer feedback to each student. In addition, the instructors themselves gain insights on student understanding of the material.
So, what did the users think of this course? They found the concepts were easier to grasp because of the computational tools used. The students could interact with the material and spend as much time as they needed in order to understand the concepts. Exercises were organized well and feedback helped the students better understand the material. And because the exercises were autograded, this freed up the instructors and teaching assistants and they could use that time to help students one-on-one. In fact, the instructors found that the tools had so greatly enhanced student understanding of the material, that they have adopted these tools in their in-person version of this course.
Slide 4
If we take the example I just spoke about, we can sort course design into 4 categories. First, we need to make sure everyone has access to the tools they need. In this case, we’ll discuss access to MATLAB, Simulink and toolboxes. Secondly, we need to successfully communicate and share information with our students whether it be online or in-person. We need to assess and deliver feedback to the students in a consistent and timely manner. Lastly, where do you and your students go if you need help or ideas? We’ll discuss all these categories one at a time…
But before we do, I’d like to give a quick overview of MathWorks products.
Slide 5
MATLAB, our first core product, is the leading environment for technical computing. It is a programming environment for algorithm development, data analysis, visualization, and numeric computation. It is also the foundation of MathWorks products.
People apply MATLAB to a broad range of applications, including signal processing, control system analysis, image processing, data science, and general data analysis. That’s one reason why MATLAB is widely used throughout industry and academia.
Simulink is the leading environment for modeling, simulating, and implementing dynamic and embedded systems. With Simulink, you can design and simulate systems before moving to hardware, and you can explore and implement new designs without having to write C, C++, or HDL code.
Add-on toolboxes provided additional functions for specific areas, such as signal and image processing, control system design, statistics, symbolic math, deep learning and other areas.
Slide 6
Now, let’s talk about how we ensure everyone gets access to the MathWorks tools they need.
Slide 7
If your university offers campus-wide access, everyone can download MATLAB onto their university or personal computers. With an installed version of MATLAB, you can work from anywhere and no internet connection is needed.
Search for your university’s portal page and download MATLAB and Simulink from anywhere. This portal page also includes resources for getting started with MATLAB and Simulink, as well as online tools for instructors.
I speak to many faculty that are concerned that, students may only have access to old laptops or tablets. They need a solution that still allows students to use MATLAB, but doesn’t involve downloads and installations. Through a campus-wide license, faculty, staff and students have access to various online tools including…
Slide 8
MATLAB Online. This is a convenient way to use MATLAB without having to download or install any software and we provide the compute power, maintenance, and support. The interface is very similar to locally installed MATLAB. One of my favorite features of MATLAB Online is that it always runs the latest version of MATLAB. Faculty tell me that students work on different versions and everything from class examples to grading can be challenging. And I’ll admit, this is a problem I ran into while I was teaching as well. MATLAB Online eliminates this problem since everyone will be working on the same version.
In addition to MATLAB Online, we have recently released Simulink Online. Just like MATLAB Online, there is no download required and you will have access to the latest version of Simulink. Also supported with Simulink Online is Stateflow, Simscape, Simscape Multibody, Simscape Electrical, Simulink Control Design, and DSP System Toolbox.
In terms of storage, every user gets 5 GB of space on MATLAB Drive. Your data, MATLAB and Simulink code are available to you on all your devices including your tablet or mobile phone. A nice feature of MATLAB Drive is being able to share code and other documents with others. You can create examples or assignments and share them with students through MATLAB Drive. Additionally, they can share assignments with you and you can run their code in MATLAB Online. Thus eliminating the need to download each individual student’s code, organizing the all the code properly and running each one.
Slide 9
If your university’s license does not allow for downloads, don’t worry, you still have access solutions.
If you can access MATLAB through your university but only while on campus, you can establish a secure connection to the university network and continue to use MATLAB. Your IT department website should have instructions on how to do this.
For immediate needs, downloading a 30 day trial from our website may be a good option. You can download trials of MATLAB, Simulink as well as toolboxes.
If 30 days isn’t sufficient, and you can’t access MATLAB through a secure connection please contact your MathWorks representative to discuss access solutions.
Slide 10
Now that everyone has access to the tools they need, let’s discuss designing and teaching your course and lab. In a distance learning format, students do more independent learning. We need tools that help guide the students through their learning.
Slide 11
Using interactive documents allows you to create a narrative around the code, giving students context and guidance. MATLAB Live Editor gives you tools to tell a story with your code making it easier for you and your students to understand your work. Let’s take a look at Live Editor in action.
DEMO in MATLAB Online using Live Scripts
Live Editor lets you create a notebook that allows you to combine code with formatted text, images and equations. You can choose to display your results next to your code or view them inline. There is an option to hide your code. This is useful if you prefer your students to gain understanding of the material before getting into the details of the code.
You can separate your code into sections to introduce new concepts within the workflow and each section can be run independently. Students can explore how important parameters affect the overall result by using live controls. They can interact with the code to gain intuition of the material. In fact, students can interact with the results directly. And with this interactive tool, students can generate code to reproduce their adjustments.
Live tasks streamline common workflows like thresholding and identifying outliers. You can tweek parameters and auto-generate the code that reproduces your results.
This interactive document can be shared as is for MATLAB users, or converted to word, html, pdf or latex document.
Live Editor is a great way to guide your students through a workflow programmatically. But you can also use interactive apps.
They are a great way for students to interact with the material and gain intuition before “looking under the hood” and being overwhelmed by equations. Apps correspond to the toolboxes you have installed. So your configuration may look a little different than mine. You can rearrange the order of the sections so the apps you use most are close to the top. Today, I’ll be showing the color thresholding app. Each app progresses you through the workflow. Let’s say I’m a student that’s trying to learn how to threshold an image so as to remove the background. I may start with a common color space like RGB. I can interact with the interface and see how each component affects the overall system. As I work to understand what happens when I threshold in this space, I may learn that this color space may not be the best choice. All apps give you flexibility to explore various parameters within the app to get the best results. Students can learn how each parameter affects the overall result by interacting with the concepts. Once students gain intuition with the material, they can generate code right from the app and understand how the work they did in a graphical user interface, translates to a programmatic workflow.
What if you want to teach a concept that would work well in an app format, but there isn’t one available?
Slide 12 is hidden (additional slide on MATLAB Apps for future use if a demo isn’t used)
Slide 13
You can create your own. App Designer is an interactive development environment for designing an app and programming its behavior. You can drag and drop the visual components of your graphical user interface into the workspace and has an integrated editor to quickly program the components behavior. It also offers a grid layout manager to organize your user interface, and automatic reflow options to make your app detect and respond to changes in screen size. In addition, you can create and share standalone applications. An interesting project idea would be for students to create an app to test their understanding of concepts.
Slide 14
In addition to apps and interactive programming, using self-paced tutorials are a good way to guide students through their learning. Concepts that you teach in your courses may already be developed as a part of our self-paced tutorials. You can assign the entire course or sections of it. Each of the courses provides a certificate and you can verify which sections were completed. Many of these courses are offered in multiple languages.
The first 7 offerings are free courses that help the learner understand the basics of the particular topic. They typically take about 2-3 hours to complete. Many instructors assign the onramps as homework or a suggested refresher at the beginning of the course. This allows students to get the foundation they need to be successful in your course without taking valuable class time to review MATLAB.
If your university has the suite available, you have free access to the focused courses as well. These are more in-depth courses and you may find you can supplement or replace lectures with sections of these courses. The Computational Math courses tackle a specific area and are great as refreshers for students or to offer a hands-on way to learn a topic.
In fact, many faculty have used these courses to flip their course. At Carnegie Mellon, Dr. Wang has flipped his course by using these self-paced courses to teach concepts, freeing up classtime to work on domain specific projects that reinforce the concepts students learned in these self-paced courses.
Slide 15
All of the tools that we spoke about have one thing in common- they allow the students to learn by doing rather than memorizing.
Clearly, humans learn best this way. But one major aspect of interactive learning is <click>
making mistakes. Often times we forget that mistakes can be valuable teachers. When students are given the space to make mistakes, they learn and retain the material better than if they were to memorize. And, there’s the added bonus that they stay more engaged with the material.
This approach forces learners to be active participants rather than a passive observers. We’re going to discuss how we can increase student engagement by challenging students with hands-on, real-world experiential learning. This will increase retention of concepts and keep students engaged in the material.
Slide 16
Educators have been looking to virtual lab solutions to offer a hands-on experience to students. Students are engaged and have a deeper understanding of the material than if they had just read it in the textbook.
We’ll discuss 3 lab types today. First, Virtual Labs exist in the virtual space to simulate a process, test, apparatus, or other activity.
Hardware Labs incorporates kits, mobile devices, or other components that exist at home or off campus.
And finally, Remote Labs use equipment that exists on campus but is viewed, accessed, or even controlled by students remotely.
These all have their plusses and minuses and you can decide what is best for your course and your desired learning outcomes. We’ll discuss solutions for each one of these types of lab models starting with Virtual Labs.
Slide 17
The first thing that comes to my mind when discussing virtual labs is Simulink. With Simulink students can model entire systems and learn how each piece affects the overall design. It provides an environment for graphical design and realistic simulation.
Simulink gives students space to explore. It allows students to examine the behavior of the system without worrying about making mistakes. When we give students this space, they learn and retain the material better.
Before moving to the hardware, students can explore and implement more sophisticated designs without having to write code. Additionally, MATLAB and Simulink work together to create a total design environment.
Slide 18
Recently, we launched SL Online. So, let’s take a look! You can launch Simulink from the toolbar in MATLAB Online. On the Simulink start page, you’ll find templates and resources. The Simulink Library Browser contains hundreds of components to choose from. The pane displays a tree view of the libraries available through your license. When you select a library, it’s contents appear in the blocks pane. You simply choose the right block and drag and drop it into your workspace. Today, we’ll create a simple system with a source, gain and scope. This is our signal, and now we’ll need to add a gain. You could go back to the Library Browser or you can type the component you’d like to use into the workspace and add it from there. We need a way to view our output signal, so I’ll add a scope. By simply clicking on the component, you can modify its parameters to get the exact system you want. If you are a Simulink user, you’ll notice that it has the same look and feel as your Simulink installation, but we provide the maintenance, compute power and support. Let’s take a look at the output of the system we just created.
We’ve been discussing how with Simulink, students can model entire systems and learn the effects of each part of the system to the overall design. Let’s take a look at a more complex system, a fault tolerant fuel control system. Students can click into each part of the system and gain a deep understanding of the contribution of that component. They can see what is inside of their models and how they are built, which really helps with understanding the theory.
In this example, we have a dashboard that controls some of the parameters of the system. This allows students to graphically interact with the system before they dig deeper into the model.
This is how we teach students about simulation, but what about using real, physical hardware?
Slide 19
If your university can support it, hardware is a great way for students to gain hands-on experience with the concepts you teach. It challenges students to learn by doing and thereby improving student engagement. Due to the breadth of hardware support from MathWorks, students can learn concepts and tools that are used in the real world on real data. Being able to use hardware has become such an important skill, that industry has developed low cost hardware for use in the classroom. MathWorks hardware support packages have built-in examples to get users started. You could leverage those examples in class thus reducing the need to develop simple, “Hello World” type examples.
Slide 20
Sending all your students an Arduino or Raspberry Pi may not be feasible for all educators. However, students typically have hardware right in their pocket. You can leverage their smartphones to offer them hands-on experience with acquiring data from hardware. You can use MATLAB Mobile to access to raw data from your smartphone sensors such as the camera, accelerometer and others. You can find project ideas on our website, but some of my favorites are designing a step counter or a household object classifier.
Slide 21
Another way to do projects at home is to use internet of things. IoT is how our devices speak to one another. For example, I can control my home’s thermostat from my mobile phone. ThingSpeak is MathWorks’s IoT analytics platform. Students can use the data from one of our thousands of public channels to analyze the particular system. If there is a particular hardware you typically use in your course, you can set-up a channel on ThingSpeak and your students can access the raw data for analysis. So, what does one of these projects look like? Let me show you one of my favorites…
Slide 22
We used a Raspberry Pi, a web cam and ThingSpeak to analyze traffic on a busy highway near our offices in Natick Mass. This is a public channel that you can access and use in class. You can have the students access the last 12 months of data and analyze the effects of Covid-19 on traffic. If you’re interested in incorporating ThingSpeak, our website is a great repository for such code examples. In addition, I encourage you to look at the many public channels available. There may be a few that you can leverage in your course.
ThingSpeaks allows you to do labs where the student anazlyze real-world sensor data. If you’re interested in virtually controlling hardware, consider a remote lab. Remote labs provide virtual access to hardware.
Slide 23
One such remote lab is the Robotarium at Georgia Tech. The Robotarium seeks to democratize robotics by providing remote access to a state-of-the art, multi-robot research facility. <click>
Working through the Robotarium, your students can develop and test robotics algorithms in a simulator. Once your students are satisfied with their algorithm, they can deploy their work onto remotely accessible hardware. The Robotarium provides access to real hardware. Since you’re not acquiring and maintaining hardware, you save time, effort and money.
If you are interested in providing a lab experience in an online manner, look for our webinar on Virtual Labs.
Slide 24
So far, our students have access to the tools they need, we have successfully given instruction, now how do we virtually assess our students and offer them feedback?
Slide 25
Traditionally, students would hand in an assignment, you’d grade it and hand it back 1-2 weeks later. But how many students go over the graded assignment and try to improve on their solutions? By the time they receive their graded assignment, the class has moved on to another topic. If you were to continue this workflow as course go online, you would have to send the students the assignment, they would have to print it out, complete it and scan it before submitting the assignment. So, we need a way to provide and assess homework in a digital way.
As we discussed earlier, students will have to do more self-driven learning and offering assignments through an autograding system is another way to encourage this type of learning. Autograding provides instant feedback encouraging students to improve on their solutions.
Slide 26
MATLAB grader is our browser-based autograding system. It allows you to create interactive course assignments with automatic grading. You can tailor your feedback for each assessment and help guide the students to the correct answer. MATLAB Grader also integrates with your learning management system. Available through MATLAB Grader are Templates of common assessment types for both script and function-based problems. And you can randomized input parameters to create custom assessments.
So let’s take a look at a student workflow…
Slide 27
Let’s say I’m a student in your course. I’d navigate to the assigned problem and I’d code my solution right in the problem. <click>
When I submit my solution, I’d receive real-time, contextual feedback on my solution. <click>
I can revisit the problem and use your feedback to better my solution. The instant feedback motivates students to continue to improve their solution. WE often talk about introducing more gamification into courses. That is, applying game-design elements to courses to keep students engaged and wanting to learn more. This provides a way to gamify your assignments and keeps the students immersed and motivated.
Slide 28
As students complete assignments, the grades go right into your grade book. And you not only get the grades, you also get metrics on how each student- and the class as a whole- did on the assignment.
Slide 29
To get an overall idea on how the class did on an assignment, you can take a look at this metric. The green bar is the number of students that correctly answered the question. You’ll be able to get a quick overview of class performance.
If you dig deeper, you can get analytics on which problems and assessments were the hardest. The top graphs are metrics on correct solutions. Conversely, the bottom graphs give us insight into the incorrect solutions. As a former educator, I find the top middle graph to be incredibly informative. It tells me how many times a student tried a problem before getting it correct. Normally, you’d manually grade a problem and have no idea how many times a student tried the problem before getting it correct. A student that correctly answers the problem in one attempt has a different understanding of the material than a student that takes 15 attempts. These metrics allow you to better support your students and know which ones may be silently struggling.
Solution maps show size, time of arrival, and distance from the reference solution. You can click on any data point to see who submitted it and their code. It Includes a complete history of students’ attempts to find the correct solution. You can also search for a student and view their submissions. This is particularly useful for office hours and recitations.
Slide 30
Where do you go for help integrating these tools? And how do you get ideas for the coming semester?
Slide 31
Well, When I was teaching, I always liked to hear how my peers taught similar concepts. I think there’s value in learning from each other. On our courseware page you’ll find course materials created by your peers. There’s material like course outlines, downloadable assignments, videos, lectures, and more. These course materials are hosted on the creator’s end – who you could partner with directly if you like.
There’s material on different topics like intro to programming, and of course various domains in engineering and science.
Slide 32
We’ve spent much of this session discussing how students learn best by doing, and but it turns out, we all learn best this way. That’s why we offer a free hands-on training for educators. You can get guided experience with the resources we discuss in this session. It typically takes about 2-3 hours to complete. As with the other trainings, you can work at your own pace and you can skip around the training so you can learn the tools that are most urgent to you now. This is a great training and I encourage you to try it out.
Slide 33
In addition to the educator training, you can use MOOCs to get ideas on how to teach various topics. MOOCs created with the support of MathWorks typically use many of the tools we discussed here. Attending a MOOC can be a good way to gain hands-on experience with the tools on a topic you teach. You can then apply those resources to your course.
Here, I call out 2 examples of MOOCs we’ve worked with. In the first one, MathWorks partnered with Coursera to create a series of online courses on data science. Vanderbilt’s free online course, Introduction to Programming with MATLAB, is a top MOOC (massive open online course) and remains one of the Top 50 MOOCs of All Time, {rated by Class Central, a search engine and review site for MOOCs}.
If you are interested in creating a MOOC, I encourage you to reach out to our MOOC support team whose contact is shown at the bottom right.
Slide 34
The online teaching page has all the tools and resources we spoke about and more. It’s a great go-to page when you want to learn about new tools or get help with existing ones.
And the distance learning community page is a space where the community can have discussions and share ideas regarding distance learning. I encourage you to engage in this community- look at the discussions, -start your own. Educators around the world are in this together and this is a great space to help each other.
Slide 35
We discussed many tools, and you may be a bit overwhelmed with where to start.
First, complete the free Educator Training. This will give you hands on experience with the tools we discussed. You can skip around and complete the training in the order that is most useful to you.
An easy addition to your course- that will have a big impact, is adding MATLAB and Simulink Onramp to your course. This will help students ramp-up and save you valuable class time. If you have access to the suite, try a few of the focused courses as well.
Converting your examples to Live Scripts allows you to create a narrative around your examples. Students can interact with the code and better understand the material. You can provide guidance and the student do more self-driven learning.
Speak to your LMS administrator to add MATLAB Grader. Autograding not only saves you and your TAs time, it motivates the students to get the right answer and give you analytics to understand learner comprehension.
Lastly, give students space to make mistakes. Use MATLAB Mobile and ThingSpeak to virtualize your labs and give students hands-on experience with hardware.
Slide 36
Finally, the customer Success group is available to answer any questions you have and to help you integrate these tools into your course. If you have any questions after this session, you should reach out to your customer success team at MathWorks by emailing education@mathworks.com.