what algorithms are applied in the auto tuning of PID block in simulink?

Illustration
Stanley_Cheng - 2021-08-24T10:38:23+00:00
Question: what algorithms are applied in the auto tuning of PID block in simulink?

Hi everyone,   as the title, could anyone tell me about that?   The auto tuning really offers a really good control performance.   Thanks very much!

Expert Answer

Profile picture of John Williams John Williams answered . 2025-11-20

Typical PID tuning objectives include:
Closed-loop stability — The closed-loop system output remains bounded for bounded input.
 
Adequate performance — The closed-loop system tracks reference changes and suppresses disturbances as rapidly as possible. The larger the loop bandwidth (the first frequency at which the open-loop gain is unity), the faster the controller responds to changes in the reference or disturbances in the loop.
 
Adequate robustness — The loop design has enough phase margin and gain margin to allow for modeling errors or variations in system dynamics.
 
The MathWorks algorithm for tuning PID controllers helps you meet these objectives by automatically tuning the PID gains to balance performance (response time) and robustness (stability margins).
 
By default, the algorithm chooses a crossover frequency (loop bandwidth) based upon the plant dynamics, and designs for a target phase margin of 60°. If you specify the crossover frequency using wc or the phase margin using pidtuneOptions, the algorithm computes PID gains that best meet those targets.
 
 

Workflow for Autotuning in Simulink

The following steps provide a general overview of the workflow for PID autotuning in Simulink using the Closed-Loop PID Autotuner or Open-Loop PID Autotuner blocks.

  1. Incorporate a PID autotuner block into your model between the PID controller and the plant.

  2. Configure the start/stop signal that controls when the tuning experiment begins and ends.

  3. Specify controller parameters such as controller type and the target bandwidth for tuning.

  4. Configure experiment parameters such as the amplitudes of the perturbations injected during the frequency-response experiment.

  5. Run the model and initiate tuning. Use the start/stop signal to initiate the PID autotuning process. When you start the process, the autotuner block injects test signals and measures the response of the plant.

  6. Stop the experiment with the start/stop signal. When the experiment stops, the autotuner block computes and returns tuned PID gains. You can examine the tuned gains for reasonableness.

  7. Transfer the tuned gains from the autotuner block to your PID controller. You can then validate the performance of the tuned controller in Simulink.


Not satisfied with the answer ?? ASK NOW

Get a Free Consultation or a Sample Assignment Review!