当前位置:网站首页>基于PSO优化的多目标最优值求解matlab仿真
基于PSO优化的多目标最优值求解matlab仿真
2022-07-23 09:46:00 【我爱C编程】
目录
1.算法描述
在PSO中,群中的每个粒子表示为向量。在投资组合优化的背景下,这是一个权重向量,表示每个资产的分配资本。矢量转换为多维搜索空间中的位置。每个粒子也会记住它最好的历史位置。对于PSO的每次迭代,找到全局最优位置。这是群体中最好的最优位置。一旦找到全局最优位置,每个粒子都会更接近其局部最优位置和全局最优位置。当在多次迭代中执行时,该过程产生一个解决该问题的良好解决方案,因为粒子会聚在近似最优解上。
Ray等人通过将PSO算法和Pareto排序机制想结合起来。采用Pareto排序法来选择一组精英解,全局最优粒子的选择则是采用轮盘赌方式从中选择。实际运行时,只有少量的个体选择概率大,种群多样性保持不好。Coello等在PSO算法中选择群体最佳位置则是通过引入Pareto竞争机制和微粒知识库。该知识库用于存储微粒在每次飞行循环后的飞行经验,知识库的更新是通过考虑一个基于地理学的系统,该系统是就每个微粒的目标函数值而言来定义的。这个知识库被微粒用来确定一个指导搜索的领导者。同时非劣解的确定是通过将候选个体与从种群中随机选出的比较集进行比较,因此比较集的参数对算法成功与否有着至关重要的影响。若参数过大,则容易发生早熟收敛的现象,而参数过小,则种群中选出的非劣解的数量可能过少。
2.部分程序
for it=1:MaxIt
for i=1:nPop
rep_h=SelectLeader(rep,beta);
particle(i).Velocity=w*particle(i).Velocity ...
+c1*rand*(particle(i).Best.Position - particle(i).Position) ...
+c2*rand*(rep_h.Position - particle(i).Position);
particle(i).Velocity=min(max(particle(i).Velocity,-VelMax),+VelMax);
particle(i).Position=particle(i).Position + particle(i).Velocity;
flag=(particle(i).Position<VarMin | particle(i).Position>VarMax);
particle(i).Velocity(flag)=-particle(i).Velocity(flag);
particle(i).Position=min(max(particle(i).Position,VarMin),VarMax);
particle(i).Cost=CostFunction(particle(i).Position);
if Dominates(particle(i),particle(i).Best)
particle(i).Best.Position=particle(i).Position;
particle(i).Best.Cost=particle(i).Cost;
elseif ~Dominates(particle(i).Best,particle(i))
if rand<0.5
particle(i).Best.Position=particle(i).Position;
particle(i).Best.Cost=particle(i).Cost;
end
end
end
particle=DetermineDomination(particle);
nd_particle=GetNonDominatedParticles(particle);
rep=[rep
nd_particle];
rep=DetermineDomination(rep);
rep=GetNonDominatedParticles(rep);
for i=1:numel(rep)
[rep(i).GridIndex rep(i).GridSubIndex]=GetGridIndex(rep(i),G);
end
if numel(rep)>nRep
EXTRA=numel(rep)-nRep;
rep=DeleteFromRep(rep,EXTRA,gamma);
rep_costs=GetCosts(rep);
G=CreateHypercubes(rep_costs,nGrid,alpha);
end
disp(['Iteration ' num2str(it) ': Number of Repository Particles = ' num2str(numel(rep))]);
w=w*wdamp;
end3.部分仿真图预览



4.源码获取方式
点击下载链接:
基于PSO优化的多目标最优值求解matlab仿真+程序操作视频
获取方式2:
博客资源项,搜索和博文同名资源。
获取方式3:
如果下载链接失效,加博主微信联系。
A_055
边栏推荐
- Using shell script to block IP with high scanning frequency
- Introduction and mechanism of Aptos
- linux定时备份数据库脚本
- MySQL的大心脏 — 索引
- AVX指令集加速矩阵乘法
- After using vscode to format the code, save and find that the code is messy again. What should I do? Vs remove formatting
- Is online handling of fund account opening safe? Who can answer it
- Live classroom system 03 model class and entity
- 【测试平台开发】十七、接口编辑页面实现下拉级联选择,绑定接口所属模块...
- CAN总线快速了解
猜你喜欢

Fastapi application joins Nacos

leetcode: 17. 电话号码的字母组合

Supervisor installation and use

Postgresql快照优化Globalvis新体系分析(性能大幅增强)
![[array & String & Macro exercise]](/img/44/26debc1ee958277935e73a75d894d4.png)
[array & String & Macro exercise]

运维高级作业03

Kettle实现共享数据库连接及插入更新组件实例

Qu'est - ce que le codage par titre?

Which is a good fixed asset management system? What are the fixed asset management platforms?

C语言项目实战:24点游戏计算器(基于结构体、指针、函数、数组、循环等知识点)
随机推荐
Getting started with Prometheus (III)
Introduction and mechanism of Aptos
【解决异常】Flink上传jar包至集群环境运行报未序列化异常
【小程序自动化Minium】一、框架介绍和环境搭建
[software test] redis abnormal test encountered in disk-to-disk work
C# 线程锁和单多线程简单使用
[untitled] test [untitled] test
[test platform development] 21. complete sending interface request and display response header information
Building personal network disk based on nextcloud
Advanced operation and maintenance 02
Live classroom system 02 build project environment
易基因|靶基因DNA甲基化测序(Target-BS)
[array & String & Macro exercise]
什么是Promise?Promise有什么好处
中望CAD专业版 2022软件安装包下载及安装教程
leetcode-设置交集大小至少为2
初识C语言函数
Cmake notes
OpenHarmony南向学习笔记——Hi3861+HC-SR04超声波检测
Kettle implémente une connexion de base de données partagée et insère une instance de composant de mise à jour