Week 1 · Getting Started with Control Systems and MATLAB
English translation
Before practice
01 The controlled system and goal
Example scenario To maintain a room at a desired temperature, what must you be able to measure and adjust?
Description
Specify the measured output, such as temperature, and its target range
Identify adjustable inputs, such as heating output
02 Why use computational tools?
How can examining responses on a computer help before changing a physical device?
Description
Comparing responses to different control actions using a model can narrow down candidates to test on the actual device.
MATLAB supports calculation and visualization. Judge whether results are appropriate using the objective and model assumptions.
Practice
1. Check the environment
Change to a=0:0.5:3, then display numel(a) and a.^2. Record the number of elements and the square of each element.
2. First plot
Calculate cos(t) using the same t as the “2. First plot” code in the practice Live Script, and plot it with sin(t) in the same figure.
Use the legend to distinguish the sine and cosine curves. Retain a figure showing both curves.
Submission and saving
Include code, actual outputs and plots, and your own interpretation. Submit through KLAS; check the semester schedule and latest announcements for the deadline.
Filename: Name_StudentID_Week1.mlx.
Restart the runtime, run all code from the top, then save.
Optional practice
Example: Omitting the dot operator in an array operation
In a=1:5, run only the line with a.^2 changed to a^2 separately, and retain the error message.
State whether you intend matrix exponentiation or element-wise squaring. Restore that line to a.^2 and record all five results.