PID Control Simulation
Simulate a PID closed loop system in MATLAB given setpoint, plant transfer function, and time vector. Plot system output and error.
Constraints
- Function: [y,e]=pid_sim(set,plant,t).
- Use feedback and pidstd.
- Compute error = set - y.
- Plot response.
1function [y,e] = pid_sim(set,plant,t)2% TODO3end