遗传算法matlab代码下载,遗传算法优化问题

Simple example of genetic algorithm for optimization problems

It is used to generate useful solutions to optimization and search problems. Genetic algorithms belong to the larger class of evolutionary algorithms, which generate solutions to optimization problems using techniques inspired by natural evolution, such as inheritance, mutation, selection, and crossover.

function [p_min, iter, f]=genetic_algorithm (func, numMaxInd, numF, numMaxGen, pRepr, pRecom, pMut, pImm, numVariabili, limLow, limUp, tolerance)

% Output variables:

% - p_min: it's the minimum point of the objective function;

% - iter: it's the final iteration number;

% - f: it's the objective function value in the minimum point.

%

% Input variables:

% - func: it's the handle of the objective function to minimize (example: f_obj=@(x) function(x) where x is the variables vector);

% - numMaxInd: Number of individuals (number of initial points);

% - numF: Number of sons for each generation;

% - numMaxGen: Max number of generations (number of max iterations);

% - pRepr: Reproduction probability;

% - pRecom: Ricombination probability;

% - pMut: Mutation probability;

% - pImm: Immigration probability;

% - numVariabili: it's the number of the function variables.

% - limLow: it's the low bound for the initial points;

% - limUp: it's the high bound for the initial points;

% - tolerance: it's the tolerance error for the stop criterion.

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值