How to use PSA algorithm
This article mainly introduces the relevant knowledge of "how to use the PSA algorithm". The editor shows you the operation process through the actual case. The operation method is simple, fast and practical. I hope this article "how to use the PSA algorithm" can help you solve the problem.
In order to solve optimization problems, there are many biological heuristic algorithms. Through some biological characteristics to avoid local minimization and speed up optimization. What I want to introduce here is the Porcellio scaber algorithm (PSA) proposed by Yinyan Zhang and Shuai Li of the Hong Kong Polytechnic University (The Hong Kong Polytechnic University). What I should learn is the survival rule of the rat woman in the biology book of middle school.
Function PS_simple (number_of_PS,MaxStep)
Number of% porcellio scaber
N=number_of_PS
% initalize a matrix to store position data
X=zeros (MaxStep,2,N)
% Generate the initial positions of all the porcellio scaber
X (1) 4*rand (2)
% Set weighted paramter\ lambda for decion based on aggregation and the
% propensity to explore novel enviroments
Lambda=0.8
% generate a series of\ tau and make each elment of\ tau a zero mean
% random real number
Sigma=0.001; standard deviation
Tau_data=zeros (MaxStep,2,N)
For iTunes 1 purl 2
For jungle 1V N
Tau_data (:, iMagnej) = sigma* (2*rand (MaxStep,1)-1)
End
End
Iter=1
While iter