Sunday, March 3, 2013

A Blend of Theory and Practice: A Control Systems Example


My last article states the importance of having a blend of theory and practical exposure in your engineering education. I would like to give you an example of how actually you can go about developing it.

We all have control systems as one of the compulsory courses that we need to pass before we get an engineering degree.  It’s a very important course.  Be it any system in any field, you will, at some point, have to control it to achieve certain objectives. The course that we study during our undergrad spans the following aspects of control systems
  1. What is a system and representing a system in a block diagram.
  2. Mathematical representations of any system by transfer functions and state space (If your professor does not teach state space, go ahead and learn it by yourself. It’s super important in industry). You lean about deriving transfer functions on paper. 
  3. Time and frequency response of that system. Comparison of such responses with higher order systems (You learn big mathematical formulae and derivations to represent different parameters like settling time, overshoot, gain frequency, phase margin etc etc). 
  4. Root Locus, Bode plots, Nyquist plots. You learn all the rules and learn how to sketch these on a graph paper by following the rules.
  5. PID Controller design: You learn about the structure of PID controller and if there is sufficient time in the semester you will learn how to implement it on paper.

So, after giving your final exam, you are proficient in drawing block diagrams, root loci, bode plots on paper, deriving settling time, overshoot numbers given a particular system, changing a system from transfer function form to state space form etc.

This is important to understand the math behind controls. Is it sufficient for the industry?  What else should you do??

  1. Software Implementation: You can do each and every thing mentioned above in MATLAB. When you learn a certain concept, say root locus, in the class, try to plot the same locus using MATLAB. Try to plot a step response and see if it matches to what you sketched in the class. Analyze the system properties (settling time, overshoot etc) by interactively moving the poles and zeros and see the effect. You will have derived relations between the system properties and pole positions in the class. Try to replicate them in MATLAB. 
  2. Take a transfer function change it into state space and vice versa using MATLAB. Design a PID controller and see how the system properties are affected when you change the proportional, integral and derivative gains. 
  3. Get comfortable in plotting and analyzing root loci and bode plots using SISOTOOL in MATLAB.

This skill set with develop an understanding of quickly analyzing the system and coming up with a set of controllers that will satisfy your requirements on settling time, overshoot, steady state errors etc.

Hardware Implementation: If more interested you can also use micro controllers to actually see your controller in action on say a DC motor. Implement DC motor speed control. It’s a classic example to try out and is explained in every single control’s book.

Why I am telling this?
In industry no one will ask you to derive expressions, or ask you a proof of how you did what you did. They will want to see results, see your controllers in action. And 99% of the time it’s about designing a PID controller and tweaking the three gains to achieve the system performance.
All you will do ità Model the system in MATLAB, design a PID controller, tweak the gains and check for a) stability, b) system properties (settling time, overshot etc) and c) tracking (steady state error) and d) robustness. So be sure before you call it a day for control systems, you are comfortable in the above mentioned aspects of the system and controller.

To sum up: Be sure to go one step ahead than a textbook oriented course and get familiar with MATLAB tools (tf(), ss(), pid(), rlocus(), sisotool(), bode() etc commands) to be able to use MATLAB to do what you would otherwise spend time on doing by hand. This one subject will then open arenas like controls, mechatronics, robotics, instrumentation, modeling & development and much more which you can focus if you go for higher studies.

Good Books you can refer for the basics:
Feedback Control Systems by Franklin Powell


Hope these links help you.

(If you are interested in controls/ mechatronics I have designed few projects that I can share with you. Let me know via email at bits2world@gmail.com and I will email them to you)

No comments:

Post a Comment