产生不规则结果的遗传算法,发现多变量功能的最大值
我正在尝试实现一种遗传算法,以找到此功能的最大值,
f(x,y,z) = x^2 + y^3 + z^4 + xyz on [0,10] [0,20] [0,30] for x,y,z respectively
我的目标函数与上面的函数相同。人口的每个x,y,z
均由一个随机初始化的二进制字符串表示。
我已经实施了这样的实施:
- 轮盘赌轮的选择
- 单点跨界(无交叉率)
- 突变:如果选择了染色体(x,y,z)进行突变,则i将随机位的随机位,一个随机的y和随机位z。
。
我注意到给出较大的Z指数,它是第一个收敛的变量。随着世代的流逝,其余的人都难以融合。这是可以接受的行为吗?
I'm trying to implement a genetic algorithm in order to find the maxima of this function
f(x,y,z) = x^2 + y^3 + z^4 + xyz on [0,10] [0,20] [0,30] for x,y,z respectively
my objective function is the same as the function above. Each x,y,z
of the population is represented by a binary string which is initialized randomly.
I've implemented it like this:
- Roulette wheel selection
- Single point crossover (no crossover rate)
- Mutation: If the chromosome (x,y,z) is selected for mutation I flip a random bit of x, a random bit of y and a random bit of z.
I've noticed that giving the bigger z exponent, it is the first variable to converge. The rest of them have trouble converging as generations go by. Is this an acceptable behavior?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论