I want to tune PID controller by using Genetic algorithm in simulink, if anybody knows pls help me.....

12 Ansichten (letzte 30 Tage)
I have modelled longitudinal autopilot in simulink.
i used pid controller.
i want to tune pid gain values by using genetic algorithm
i dont know how to take fitness function and give input in simulink

Antworten (2)

Sebastian Castro
Sebastian Castro am 11 Feb. 2016
If you have Simulink Design Optimization, you can assign the gains of the PID controller as variables and use them in a Response Optimization task.
One of the algorithms in this tool, available with Global Optimization Toolbox, is Pattern Search. One of the Pattern Search methods is genetic algorithm.
If you don't have Simulink Design Optimization (but you do have Global Optimization Toolbox) you can always write your own script in MATLAB that runs the models, collects data, and uses that as a cost function with the patternsearch function.
- Sebastian
  2 Kommentare
SURESH PANDIYAN
SURESH PANDIYAN am 13 Feb. 2016
thank u sir for ur answer..... but i need the method of how to implement Genetic algorithm into simulink for tuning PID controller also how the fitness function should created
ashwani kumar
ashwani kumar am 2 Jul. 2019
if you found any code kindly send on uktechashwani@gmail.com.i have same task.

Melden Sie sich an, um zu kommentieren.


Ahmed chihi
Ahmed chihi am 16 Jul. 2017
i need help about how to implement Genetic algorithm into simulink for tuning PID controller, did you solve the problem plz ?

Community Treasure Hunt

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

Start Hunting!

Translated by