Effacer les filtres
Effacer les filtres

How can I tune my PID controller using Ziegler Nichols?

37 vues (au cours des 30 derniers jours)
Patricia Strutz
Patricia Strutz le 24 Sep 2020
I am modeling a linearized inverted pendulum using a transfer function, and using a PID controller to control it. I am adding a pulse disturbance after 1 second. As I am new to control theory, I am struggling with how to choose PID gains (I am trying to find good gains myself, rather than using the auto tune functionality).
I read that the Ziegler-Nichols method suggests keeping integral and derivative action at 0, and increasing the proportional gain until constant oscillations occur. For me, that is at a gain of 5. However, the scope shows a pendulum angle of above 60 (radians?) - which is not possible because it no longer works with the small angle approximation. And, if I use P = 5, I = 0, D = 0 on a simscape model that I created, the pendulum goes wild. For the simscape, a P-gain of 23 first results in stable oscillations. Using the autotune gives gains of approx. P = 105, I = 472, D = 5.7. How am I supposed to find the right gains?

Réponses (1)

Delprat Sebastien
Delprat Sebastien le 24 Sep 2020
Modifié(e) : Delprat Sebastien le 22 Avr 2022
Please stop using ziegler nichols. This method has been created a whole ago when computers were not available. It is only intended for process that are integrator with a delay. IT WILL NOT WORK ON OTHER SYSTEMS, except if your lucky. Generally, the closed loop will have overshoots, etc. So how to tune pid. Either by hand, purely by trial and errors. Alternatively if you have a linear model, use linear control system theory for the controler synthesis (compute gain to have a given phase margin for instance or to get the closed loop poles at a specified location).
  4 commentaires
Sam Chak
Sam Chak le 19 Fév 2024
Considering that the mathematical model or transfer function of the system is currently unavailable, I would like to inquire whether the system is open-loop stable or unstable. Additionally, I would like to know if you have modeled the system in Simulink to gain further insights.
Delprat Sebastien
Delprat Sebastien le 12 Avr 2024
Automatic control is in the middle of maths and physics... I really advise you against designing a controler for a completely unknown system. Any unstable system in practice requires some safety measures to recorvers problems..
Inverted pendulum are unstable. You can easily make a nonlinear model of the system based on the physics of equations. Then identifying the nonlinear system when in the down position is easy and can be done with very few experiments (like droping the arm with no control an measuring oscillations allows to identify the arm inertia, damping). Then having the coefficient, you can easily compute a linearized system around the unstable equilibrium

Connectez-vous pour commenter.

Produits


Version

R2020a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by