java design differential evolution (DE) algorithm to solve the optimization problem of multivariate function

How to use differential evolution algorithm to solve the problem of optimal value of multivariate function? The fundamental lies in finding the optimal solution of the optimal n-dimensional individual, and bringing it into the established fitness function value to solve the optimal value of the multivariate function. The key issue is the preservation of the optimal value. During the design process.
The following provides DE to solve the hyper-ellipsoid function f(x)=sum(x(i)*2^i), where i is equal to 0-Np; where Np is the number of population individuals. Take the java program as an example!

import java.util.Random;
/***************************
 改进差分算法
 	初始化
 	变异
 	交叉
 	选择
 需求1:利用差分演化算法求解超椭球体函数y=sum(x(i)*2^i)在区间[-1,2]的最小值/最大值
 	时间:2020.11.27
 	
 	思考:怎样的迭代次数最好,存不存在最好的迭代次数;
 	            种群的选取到底怎样才是最好的
 	    F/Cr的选取是怎样影响我们的最优结果,从理论和实验上去做
 需求2:利用差分求解函数z=x.^2+y.^2在区间[-1,2]上的最大值/最小值
 	思考:怎样解决多为的函数最优化问题,已就是多目标函数的最优值并且带有约束性,matlab已经给出解决办法;
 	通过采用优化工具箱linprog(c,A,b,Aeq,beq,vlb,vub,x0)解决。亦即采用DE算法解决此些问题是否
 	有必要,

Guess you like

Origin blog.csdn.net/weixin_51631044/article/details/112991955