PSO in simulink

44 次查看(过去 30 天)
Recep
Recep 2011-2-8
移动Walter Roberson 2024-8-29
Hi. I want to run PSO algorithm in Simulink with s-functions.I will do optimization of control system with PSO. Could you help me? You can suggest anathor way for this. Thank you very much.
  12 个评论
ATHIRAH AYOB
ATHIRAH AYOB 2022-6-8
移动:Walter Roberson 2024-8-29
Hi zeeshan, did you get anything?
idris
idris 2024-8-28
Particle Swarm Optimization

请先登录,再进行评论。

回答(3 个)

Seth Popinchalk
Seth Popinchalk 2011-2-10
编辑:John Kelly 2014-5-27
In general, optimization is applied to a Simulink model using MATLAB commands to adjust variables that define the parameters of the simulation. Using Particle Swarm Optimization (PSO) to optimize a system modeled in Simulink can use the same approach. Define the system you would like to optimize in Simulink and some measurement of quality of the solution based on the outputs of the simulation. Use MATLAB workspace variables to define the parameters of the system that are changing, including initial conditions or input signals to the model. The simulation can be run using the sim command to generate the outputs of the model.
Using a PSO Algorithm initialize the particles using random positions in your solution space. Run a simulation for each particle so you can calculate the quality measure. Update the particles best known position if you have improved this measure of quality.
Each particle solution can be run in parallel by running the sim command within a parfor loop.
  5 个评论
Sriniwas@AT
Sriniwas@AT 2013-6-13
Seth Popinchalk - Is it really possible to implement Partcile Swarm Optimization algorithm for online optimization rather than offline optimization?
My idea was to perform this PSO algorithm using an Embedded Matlab Function block inside a simulink model.
Bahaa Abdulkhaliq
Bahaa Abdulkhaliq 2018-12-3
hello, please how can i perform pso code inside an embedded function . lhave some problems

请先登录,再进行评论。


mohamed elbesealy
mohamed elbesealy 2016-10-8
  4 个评论
Quan Zhou
Quan Zhou 2017-1-31
this is an offline optimisation, the connection among m-file and Simulink is in the tracklsq.m file. hope this would help. In addition, have you find any online demo using PSO controller in the loop.
syukron jamil
syukron jamil 2017-9-13
I don't understand. can you help me to make simulink pid pso? send to syukronjamils@gmail.com

请先登录,再进行评论。


Kiprono
Kiprono 2013-2-12
Have a look at this paper. It explains pso implementation as an s-function: http://www.sciencedirect.com/science/article/pii/S0038092X12001247

类别

Help CenterFile Exchange 中查找有关 Particle Swarm 的更多信息

产品

Community Treasure Hunt

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

Start Hunting!

Translated by