Putting the 'I' in 'PID'

Or it may happen once within a minute, and cause the end of the vehicle's lifetime...

-- snip --

Reply to
Tim Wescott
Loading thread data ...

When you're doing it 'right', at some point early in the modeling process you check to see whether an LTI assumption will be valid and over what sorts of operating ranges. Then you decide whether you can blithely treat the system as linear, if you can decorate the controller with a few easy nonlinearities (like anti-windup in the integrator) and _otherwise_ treat the system as linear, or if you _really_ have to delve into the nonlinear control bag-o-tricks to make things work.

Sometimes (often, when you're dealing with an unfamiliar system or really trying to wring performance out of it) you have to do some design, remeasure, redesign cycles before you get it right*. This can take the form of tweaking if you're close to your goal, but too much undirected tweaking can lead you off into the pucker brush of control design land, where the only path to success lies in getting airlifted back to your starting place and redoing the process _correctly_.

My day job often involves coming in at the point where people realize that they're off in the pucker brush and don't _know_ how to do the design right. Often I can't get their system whipped entirely into shape, because often the problem is that the plant or processor is somehow deficient to the task at hand**, but I have _always_ been able to get significantly improved performance.

  • It's like peeling an onion -- you peel off a layer of the problem and cry as you do it. Then you notice that the problem is still too big, so you peel off another layer and cry. You repeat as necessary until you have enough money saved up to start a basket-weaving supply house, or until the problem is solved, whichever comes first.
** This is another benefit of good system modeling -- if you can identify all of the issues that need to be dealt with, sometimes you'll find that you just won't get to your goal without changes to more than just the control algorithm. With proper up-front modeling you can discover this while there's still time for a mechanical design cycle.
Reply to
Tim Wescott

That's a funny (and apt) description of some of my tasks at my day job!

Rick

P.S. Thanks for the insights.

Reply to
Rick Armstrong

%First, thanks for citing my webpage in your discussion. %It's true that the PDF structure results in identical closed loop poles for equivalent gains in a PID structure %and that the difference is that the PID introduces closed loop zeros, but the PDF does not. The book "Modern Control Systems" by Dorf provides %an excellent graph of how closed loop zeros affect overshoot with respect to the damped natural frequency. Since the PDF eliminates zeros introduced %by the controller you eliminate any risk that the controller will be the source of overshoot but other system aspects can also lead to overshoot 1) zeros in the %original system itself 2) insufficient damping caused by improperly tuned closed loop dynamics (poles) of the system and 3) nonlinear things like saturation and %not providing mechanisms in the integrator to prevent windup. Dorf can address the first two, but you may have to look to other references for anti-windup controls - it's not too difficult.

% Getting back to your original question regarding the integrator in PID controls. You only need integration only if you are trying to achieve an accurate attitude of your hovercraft at steady state. An unbalanced %structure will require a steady non-zero torque by your thruster logic. This steady value can only be achieved by either knowing what the imbalance is, and adding it to the control or by using the integrator. % The non-zero error (from the difference of level and what the attitude sensor measures) will integrate up until this constant component is met and level attitude is achieved at which time the error is reduced very near %zero. The integrator will continue to correct to trim this error back to zero. But if your gain in the integrator component is too aggressive, the attitude will overshoot as it tries to achieve the equilibrium of level %and the control may hunt. Nonlinearity can result in a steady state oscillation or limit cycle as the integrator dithers the attitude back and forth. Reducing the integrator gain or increasing the P or D gains may %dampen out the oscillation.

%One last comment. Although you picked a very interesting model to learn controls, you also picked a very interesting and challenging problem. The rigid body inertia of the hovercraft with regards to attitude controls is %known as the double integrator problem. A single rotor, as in a helicopter adds some intrinsic damping by its gyroscopic restoring moments, but multiple thrusters don't provide this advantage. I would recommend %using nested loops. I believe your attitude sensor also has gyro (rate outputs). Design yourself an inner rate loop using these gyros, then an outer loop using attitude. the inner loop will give you an adjustment of %damping and greater stability. There's also the question of coupling. If your mechanical system is not decoupled with respect to the roll and pitch axes, angular rates can couple from one axis into another and result %in instability. Alignment and decoupling are important. So I've said enough other than good luck with your controls project.

% Mike Borrello

Reply to
maborrello

PolyTech Forum website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.