2013年5月20日

粒子群算法 PSO

摘要: 中规中矩, 没有ABC快 1 -- 粒子群算法 PSO(全局,变权重) 2 3 -- lua 相关简易操作 4 sin = math.sin 5 cos = math.cos 6 sqrt = math.sqrt 7 pi = math.pi 8 random = math.random 9 exp = math.exp 10 int = math.floor 11 12 13 -- 获得不同的随机序列 14 math.randomseed(os.time()) 15 16 17 -- ==============================求解函数======... 阅读全文

posted @ 2013-05-20 20:19 郁郁思扬 阅读(682) 评论(0) 推荐(0) 编辑

人工蜂群算法 ABC

摘要: 刚用LUA写了AGSO算法,效果奇差无比. 可能写错了..下面这个蜂群算法.效果很好.跳出局部最优的能力比较强! 1 -- 人工蜂群算法 ABC 2 3 4 -- lua 相关简易操作 5 sin = math.sin 6 cos = math.cos 7 sqrt = math.sqrt 8 pi = math.pi 9 random = math.random 10 exp = math.exp 11 int = math.floor 12 13 14 -- 获得不同的随机序列 15 math.randomseed(os.time()) 16 17 18 --... 阅读全文

posted @ 2013-05-20 02:19 郁郁思扬 阅读(6900) 评论(0) 推荐(1) 编辑

导航