CN115374689A - Air quality index prediction method based on improved sparrow search algorithm optimization - Google Patents

Air quality index prediction method based on improved sparrow search algorithm optimization Download PDF

Info

Publication number
CN115374689A
CN115374689A CN202210052206.3A CN202210052206A CN115374689A CN 115374689 A CN115374689 A CN 115374689A CN 202210052206 A CN202210052206 A CN 202210052206A CN 115374689 A CN115374689 A CN 115374689A
Authority
CN
China
Prior art keywords
air quality
search algorithm
value
quality index
sparrow
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Withdrawn
Application number
CN202210052206.3A
Other languages
Chinese (zh)
Inventor
胡青
胡珍
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhejiang Lover Health Science and Technology Development Co Ltd
Original Assignee
Zhejiang Lover Health Science and Technology Development Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhejiang Lover Health Science and Technology Development Co Ltd filed Critical Zhejiang Lover Health Science and Technology Development Co Ltd
Priority to CN202210052206.3A priority Critical patent/CN115374689A/en
Publication of CN115374689A publication Critical patent/CN115374689A/en
Withdrawn legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F30/00Computer-aided design [CAD]
    • G06F30/20Design optimisation, verification or simulation
    • G06F30/27Design optimisation, verification or simulation using machine learning, e.g. artificial intelligence, neural networks, support vector machines [SVM] or training a model
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/004Artificial life, i.e. computing arrangements simulating life
    • G06N3/006Artificial life, i.e. computing arrangements simulating life based on simulated virtual individual or collective life forms, e.g. social simulations or particle swarm optimisation [PSO]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • G06N3/084Backpropagation, e.g. using gradient descent
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/04Forecasting or optimisation specially adapted for administrative or management purposes, e.g. linear programming or "cutting stock problem"
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/06Resources, workflows, human or project management; Enterprise or organisation planning; Enterprise or organisation modelling
    • G06Q10/063Operations research, analysis or management
    • G06Q10/0639Performance analysis of employees; Performance analysis of enterprise or organisation operations
    • G06Q10/06395Quality analysis or management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q50/00Information and communication technology [ICT] specially adapted for implementation of business processes of specific business sectors, e.g. utilities or tourism
    • G06Q50/10Services
    • G06Q50/26Government or public services
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2111/00Details relating to CAD techniques
    • G06F2111/08Probabilistic or stochastic CAD

Landscapes

  • Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Human Resources & Organizations (AREA)
  • General Physics & Mathematics (AREA)
  • Strategic Management (AREA)
  • Economics (AREA)
  • Tourism & Hospitality (AREA)
  • Evolutionary Computation (AREA)
  • Development Economics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Health & Medical Sciences (AREA)
  • Software Systems (AREA)
  • General Business, Economics & Management (AREA)
  • Marketing (AREA)
  • Entrepreneurship & Innovation (AREA)
  • Educational Administration (AREA)
  • Health & Medical Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Biophysics (AREA)
  • Computational Linguistics (AREA)
  • Data Mining & Analysis (AREA)
  • Biomedical Technology (AREA)
  • Quality & Reliability (AREA)
  • Molecular Biology (AREA)
  • Computing Systems (AREA)
  • Operations Research (AREA)
  • Mathematical Physics (AREA)
  • Game Theory and Decision Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Medical Informatics (AREA)
  • Computer Hardware Design (AREA)
  • Geometry (AREA)
  • Primary Health Care (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)

Abstract

The invention discloses an air quality index prediction method based on improved sparrow search algorithm optimization, which comprises the following steps of: s1: acquiring historical data of air quality, constructing a training set and a testing set, and S2: establishing a BP neural network structure; s3: optimizing the weight and the threshold of the BP neural network by using the improved sparrow search algorithm; s4: establishing an air quality index prediction model based on improved sparrow search algorithm optimization; s5: and performing air quality index prediction by using the model. The prediction method provided by the invention not only solves the defects that the sparrow search algorithm is low in convergence speed and easy to fall into a local optimal solution in the later iteration stage, improves the global search capability of the BP neural network, further improves the prediction precision of the air quality prediction model, but also provides a scientific and effective method for related departments to accurately predict the air quality.

Description

Air quality index prediction method based on improved sparrow search algorithm optimization
Technical Field
The invention belongs to the field of air quality index prediction. More specifically, the invention relates to an air quality index prediction method based on improved sparrow search algorithm optimization.
Background
In recent years, with the increasingly rapid industrialization process, the rapid development of economy and the increasing of population in China, the problem of air pollution has attracted social attention. The harm of the atmospheric pollutants to human health is continuously intensified, and a plurality of problems are brought to the life of people. Air quality prediction based on air pollution parameters has become an important subject in environmental science, and many mature prediction models are used for predicting different pollutants in the aspect of air quality prediction. The prediction of air pollutants can timely determine preventive measures to avoid harm caused by air pollution, so that real-time monitoring of air quality is achieved, and a model with high prediction accuracy is designed by means of the monitored air quality data and methods such as artificial intelligence and machine learning, so that the change condition of the air quality in a period of time in the future can be predicted. The method is not only beneficial to timely acquiring the information of the air quality, but also beneficial to helping residents reasonably plan outdoor travel according to the information, and is also beneficial to the urban managers to take appropriate measures to control air pollution so as to improve the air quality.
Sparrow search optimization (SSA) is an intelligent optimization algorithm derived from the natural activities of sparrows to forage and evade predation. Sparrows divide the population into discoverers and followers to forage according to a proportion, and a danger early warning mechanism is also superposed to prevent the populations from being predated. By calculating the fitness value of each individual and sequencing, the positions of the finder, the joiner and the alerter are continuously updated along with the increase of the iteration times, and the whole population is continuously close to the optimal solution, namely the position of the optimal food. The sparrow search algorithm is applied to many actual engineering fields due to strong optimizing capability, high convergence speed and good stability, and the problems of low convergence speed and low precision of the traditional BP neural network can be solved by utilizing the sparrow search algorithm to optimize the BP neural network.
Although the sparrow search algorithm can optimize the BP neural network to a certain extent, the same as other intelligent optimization algorithms, the problems that the population diversity is reduced and the local optimum is easy to fall into exist when the global optimum is approached are also existed.
Disclosure of Invention
The invention aims to provide an air quality index prediction method based on improved sparrow search algorithm optimization, aiming at the problems that a BP neural network is easy to fall into local optimization, low in precision and the like during prediction, and the weight and the threshold of the BP neural network are optimized by utilizing the advantages that sparrows have high convergence speed and high optimization precision compared with the traditional optimization algorithm. Meanwhile, considering the defects of reduced population diversity, low convergence speed and weak global search capability of sparrow search in the later iteration stage, the quality of an initial solution is improved by introducing cubic mapping, and the diversity of the initialized sparrow population is increased. And the capability of jumping out the local optimal solution by combining the butterfly optimization strategy is enhanced. And finally, establishing a corresponding model and applying the model to the field of air quality prediction so as to improve the prediction precision and efficiency.
To achieve these objects and other advantages in accordance with the purpose of the invention, there is provided an air quality index prediction method optimized based on an improved sparrow search algorithm, comprising the steps of:
s1: acquiring historical air quality data, and constructing a training set and a testing set;
s2: establishing a BP neural network structure;
s3: optimizing the weight and the threshold of the BP neural network by using the improved sparrow search algorithm;
s4: establishing an air quality index prediction model based on improved sparrow search algorithm optimization;
s5: and performing air quality index prediction by using the model.
Preferably, the training data comprises PM 2.5 、PM 10 、SO 2 、CO、NO 2 、O 3 And the like.
Preferably, the parameters of the BP neural network include weight values and threshold values of the BP neural network.
Preferably, the objective function of the improved sparrow search algorithm is the error rate E of the training set of the BP neural network train Error rate E with test set test The sum, expressed as:
fitness=argmin(E train +E test )
preferably, the step S3 specifically includes the steps of:
s31: initializing parameters of a sparrow search algorithm, including the sparrow population number n, the follower number P, the joiner number S and the population maximum iteration number t max A population warning value R;
s32: carrying out population initialization by utilizing cubic mapping;
s33: establishing a fitness function and sequencing;
s34: the positions of discoverers are updated by fusing butterfly optimization strategies, so that the global search performance of the algorithm is enhanced
S35: updating the follower position;
s36: randomly selecting an alertor and updating the position of the alertor;
s37: calculating and sequencing the updated fitness value;
s38: and (4) judging whether the iteration stop condition is met, if so, exiting and outputting a result, otherwise, repeatedly executing the steps S32-S36.
Preferably, in step S32, the cubic mapping formula is:
y(n+1)=4y(n) 3 -3y(n) (2)
wherein n is the mapping degree, y (n) is epsilon (-1, 0) U (0, 1), and y (n) is the nth mapping value.
In order to prevent the value generated by chaotic mapping from exceeding the weight and threshold value optimization range of the BP neural network, the mapping value is adjusted to a uniform interval by using the formula (2).
X i =X lb +0.5(X lb -X ub )(y i +1) (3)
Wherein, X lb 、X ub The upper and lower boundaries of the dimensionality of the individuals in the sparrow population; x i The actual position value of the sparrow individual is obtained.
Preferably, in step S34, the location update formula of the finder is:
Figure BDA0003474154670000041
wherein the content of the first and second substances,
Figure BDA0003474154670000042
indicating that the ith sparrow is in the d-dimensional position at the t-th iteration. X gbest Is the current global optimum position, f i The smell of the ith butterfly is expressed, the value of the smell depends on the fitness, and r is a random number of 0-1. Q is a random number following a standard normal distribution. L is a single row of all 1 matrices in d dimensions. R is an early warning value and the value range is [0,1 ]]. ST is an alert value with a value range of [0.5,1']。
When R < ST, which means that there are no predators around the foraging environment at this time, the finder can perform an extensive search operation. When R is more than or equal to ST, the method indicates that some sparrows in the population have found predators and gives an alarm to other sparrows in the population, and all sparrows need to quickly fly to other safe places to forage.
Preferably, in step S35, the location update formula of the follower is:
Figure BDA0003474154670000061
wherein the content of the first and second substances,
Figure BDA0003474154670000062
for the t +1 th iteration the optimal position of the finder is found,
Figure BDA0003474154670000063
the global worst position for the t-th iteration. A is a single row of d-dimensional matrices in which each element is randomly assigned a value of 1 or-1, and A + =A T (AA T ) -1 And n is the total number of sparrows. When i is>n/2, this indicates that the ith participant with lower fitness value does not obtain food, is in a state of full hunger, and needs to fly to other places to find food to obtain moreEnergy; when i is less than or equal to n/2, a part of the participants can forage around the best discoverer, and the participants and the discoverer can compete for food, so that the participants change into discoverers.
Preferably, in step S36, the position update formula of the alert person is:
Figure BDA0003474154670000064
wherein, the first and the second end of the pipe are connected with each other,
Figure BDA0003474154670000065
for the t-th iteration global optimum position, beta is a step size control parameter, and K is [ -1,1]A random number in between. Xi is a very small constant to avoid when f i =f w When the denominator is 0. f. of i 、f g 、f w Representing the current, best and worst fitness, respectively. When f is i >f g This indicates that the sparrow is now at the border of the population and is extremely vulnerable to predators. f. of i =f g This indicates that sparrows in the middle of the population are aware of the danger and need to be close to other sparrows to minimise their risk of being prey.
The invention at least comprises the following beneficial effects:
firstly, the weight and the threshold of the BP neural network are optimized by utilizing the advantages of high search precision and strong stability of a sparrow search algorithm, and the prediction efficiency and precision are improved.
Secondly, the invention adopts cubic mapping to realize population initialization, thereby increasing the diversity of the population and avoiding the premature convergence.
Thirdly, the invention integrates the butterfly optimization strategy to enhance the global search performance of the algorithm and reduce the risk of the algorithm falling into the local optimum.
And fourthly, the model established after the algorithm is improved is used for predicting the air quality index, and compared with other models, the model is remarkably improved in the aspects of prediction accuracy, convergence rate and global search performance, and can be well applied to the actual AQI prediction.
Additional advantages, objects, and features of the invention will be set forth in part in the description which follows and in part will become apparent to those having ordinary skill in the art upon examination of the following or may be learned from practice of the invention.
Drawings
FIG. 1 is a flow chart of an air quality index prediction method based on improved sparrow search algorithm optimization according to the invention;
FIG. 2 is a flow chart of an improved sparrow search algorithm according to the present invention;
FIG. 3 is a diagram of a BP neural network according to the present invention;
Detailed Description
As shown in fig. 1, an air quality index prediction method based on improved sparrow search algorithm optimization includes the following steps:
s1: acquiring historical air quality data, and constructing a training set and a testing set;
s2: establishing a BP neural network structure;
s3: optimizing the weight and the threshold of the BP neural network by using the improved sparrow search algorithm;
s4: establishing an air quality index prediction model optimized based on an improved sparrow search algorithm;
s5: and performing air quality index prediction by using the model.
Further, the training data includes influence factors such as PM2.5, PM10, SO2, CO, NO2, O3, and the like.
Further, the parameters of the BP neural network include a weight value and a threshold value of the BP neural network.
Further, the objective function of the improved sparrow search algorithm is the error rate E of the neural network training set train Error rate E with test set test The expression is as follows:
fitness=argmin(E train +E test )
further, in step S3, the method specifically includes the following steps:
s31: parameter initialization for sparrow search algorithmIncluding the sparrow population number n, the follower number P, the joiner number S, the population maximum iteration number t max A population warning value R;
s32: carrying out population initialization by utilizing cubic mapping;
s33: establishing a fitness function and sequencing;
s34: the positions of discoverers are updated by fusing butterfly optimization strategies, so that the global search performance of the algorithm is enhanced
S35: updating the follower position;
s36: randomly selecting an alertor and updating the position of the alertor;
s37: calculating and sequencing the updated fitness value;
s38: and (4) judging whether the iteration stop condition is met, if so, exiting and outputting a result, otherwise, repeatedly executing the steps S32-S36.
Compared with the traditional optimization algorithm, the sparrow search algorithm has the advantages of high convergence rate and high optimization precision, and the prediction precision and the convergence rate of the BP neural network are improved by optimizing the weight and the threshold of the BP neural network. However, the sparrow search algorithm has the defects of reduced population diversity, low convergence rate and weak global search capability in the later iteration stage, so that the sparrow search algorithm is easy to fall into a local optimal solution. The invention improves the algorithm, mainly comprising the following two points:
1. and the cubic mapping is adopted to complete population initialization, so that the population diversity is increased, and the premature convergence phenomenon is avoided.
2. And the positions of the discoverers are updated by fusing the butterfly optimization strategy, so that the global search performance of the algorithm is enhanced, and the risk of trapping the algorithm into a local optimal solution is reduced.
The algorithm flow chart is shown in fig. 2.
When the sparrow search algorithm initializes the population, a random generation mode is adopted, and the sparrow population is unevenly distributed in the mode, so that later iterative optimization is influenced. In order to improve the global search capability of the algorithm and avoid the reduction of population diversity in the later iteration stage, the chaotic sequence is utilized to initialize the positions of sparrow individuals in consideration of the characteristics of randomness, ergodicity, regularity and the like of chaotic mapping. The uniformity and the ergodicity of the cubic mapping are superior to those of the classical Logistic mapping, so that the initialization of the population is completed by adopting the cubic mapping in the invention. The cubic mapping formula is as follows:
y(n+1)=4y(n) 3 -3y(n) (2)
wherein n is the mapping number, y (n) ∈ (-1, 0) U (0, 1), and y (n) is the nth mapping value.
In order to prevent the value generated by chaotic mapping from exceeding the weight and threshold value optimization range of the BP neural network, the mapping value is adjusted to a uniform interval by using the formula (2).
X i =X lb +0.5(X lb -X ub )(y i +1) (3)
Wherein X lb 、X ub The upper and lower boundaries of the dimensionality of the individuals in the sparrow population; x i The actual position value of the sparrow individual is obtained.
Specifically, in step S34, the location update formula of the finder is:
Figure BDA0003474154670000111
wherein the content of the first and second substances,
Figure BDA0003474154670000112
indicating that the ith sparrow is in the d-dimensional position at the t-th iteration. X gbest Is the current global optimum position, f i The smell of the ith butterfly is expressed, the value of the smell depends on the fitness, and r is a random number of 0-1. Q is a random number following a standard normal distribution. L is a single row of all 1 matrices in d dimensions. R is an early warning value and the value range is [0,1 ]]. ST is an alert value with a value range of [0.5,1]. When R is<ST, which means that there are no predators around the foraging environment at this time, the finder may perform an extensive search operation. When R ≧ ST, this indicates that some sparrows in the population have found predators and raised an alarm to other sparrows in the population, at which time all sparrows need to fly quickly to other safe locations for foraging.
Specifically, in step S35, the location update formula of the follower is:
Figure BDA0003474154670000131
wherein, the first and the second end of the pipe are connected with each other,
Figure BDA0003474154670000132
for the t +1 th iteration the optimal position of the finder is found,
Figure BDA0003474154670000133
the global worst position for the t-th iteration. A is a single row of d-dimensional matrices in which each element is randomly assigned a value of 1 or-1, and A + =A T (AA T ) -1 And n is the total number of sparrows. When i is>n/2, this shows that the ith subscriber with lower fitness value does not obtain food, is in a state of full hunger, and needs to fly to other places to find food at this time to obtain more energy; when i is less than or equal to n/2, a part of the participants can forage around the best discoverer, and the participants and the discoverer can compete for food, so that the participants change into discoverers.
Specifically, in step S36, the position update formula of the guardian is:
Figure BDA0003474154670000134
wherein the content of the first and second substances,
Figure BDA0003474154670000135
for the t-th iteration global optimum position, beta is a step size control parameter, and K is [ -1,1]A random number in between. Xi is a very small constant to avoid when f i =f w When the denominator is 0. f. of i 、f g 、f w Representing the current, best and worst fitness respectively. When f is i >f g This indicates that the sparrow is now at the border of the population and is extremely vulnerable to predators. f. of i =f g This indicates that sparrows in the middle of the population are aware of the danger and need to be close to other sparrows to minimise their risk of being prey.
The BP neural network is a multi-layer feedforward network comprising an input layer, a hidden layer and an output layer, and the BP neural network topology comprises the input layer, the hidden layer and the output layer. The main characteristics are that the input signal is transmitted in the forward direction and the error is propagated in the reverse direction. The error of the neural network is a function of the internal link weights. The training process of the network is to iteratively improve the weight and the threshold value through the gradient reduction of the error function so as to make the actual output value of the network continuously approach the expected output value. The network neural structure is shown in fig. 3.
The weights and thresholds of the output layer and the hidden layer are trained and corrected in a gradient descending manner, and the correction formula is as follows:
Figure BDA0003474154670000141
wherein the content of the first and second substances,
Figure BDA0003474154670000142
eta is learning rate, x i (i =1,L, n) is an input value of the neural network, d j (j =1,l, p) is the output value of the hidden layer, i.e. the input value of the output layer. y is k (k =1,L, q) is the actual predicted value of the network, o k (k =1,L, q) is the actual output value of the network, θ j For hidden layer neuron thresholds, β k Is the output layer neuron threshold. w is a ij As a weight between the input layer and the hidden layer, w jk The weights from the hidden layer to the output layer.
The weight and the threshold value of the BP neural network training are randomly generated, and the stability and the precision of the search result are influenced, so the parameters of the neural network are optimized through the improved sparrow search algorithm, and the convergence speed and the precision of the model are improved.
The above embodiments are only for illustrating the technical idea of the present invention, and the protection scope of the present invention is not limited thereby, and any modifications made on the basis of the technical scheme according to the technical idea of the present invention fall within the protection scope of the present invention.

Claims (9)

1. The air quality index prediction method based on the optimization of the improved sparrow search algorithm is characterized by comprising the following steps of:
s1: acquiring historical air quality data, and constructing a training set and a testing set;
s2: establishing a BP neural network structure;
s3: optimizing the weight and the threshold of the BP neural network by using the improved sparrow search algorithm;
s4: establishing an air quality index prediction model based on improved sparrow search algorithm optimization;
s5: and (5) performing air quality index prediction by using the model.
2. The improved sparrow search algorithm optimized air quality index prediction method according to claim 1, wherein the training data comprises influence factors of PM2.5, PM10, SO2, CO, NO2, O3, and the like.
3. The improved sparrow search algorithm optimization-based air quality index prediction method according to claim 1, wherein the parameters of the BP neural network comprise weight values and threshold values of the BP neural network.
4. The improved sparrow search algorithm optimization-based air quality index prediction method according to claim 1, wherein the objective function of the improved sparrow search algorithm is an error rate E of a BP neural network training set train Error rate with test set E test The sum, expressed as:
fitness=argmin(E train +E test ) (1) 。
5. the improved sparrow search algorithm optimization-based air quality index prediction method according to claim 1, wherein in the step S3, the method specifically comprises the following steps:
s31: initializing parameters of a sparrow search algorithm, including the sparrow population number n, the follower number P, the joiner number S and the population maximum iteration number t max A population warning value R;
s32: carrying out population initialization by utilizing cubic mapping;
s33: establishing a fitness function and sequencing;
s34: the positions of discoverers are updated by fusing butterfly optimization strategies, so that the global search performance of the algorithm is enhanced
S35: updating the follower position;
s36: randomly selecting an alertor and updating the position of the alertor;
s37: calculating and sequencing the updated fitness value;
s38: and (4) judging whether the iteration stopping condition is met, if so, exiting and outputting a result, otherwise, repeatedly executing the steps S32-S36.
6. The improved sparrow search algorithm optimization-based air quality index prediction method according to claim 5, wherein in step S32, the cubic mapping formula is as follows:
y(n+1)=4y(n) 3 -3y(n) (2)
wherein n is the mapping degree, y (n) is epsilon (-1, 0) U (0, 1), and y (n) is the nth mapping value.
In order to prevent the value generated by chaotic mapping from exceeding the weight and threshold value optimization range of the BP neural network, the mapping value is adjusted to a uniform interval by using the formula (2).
X i =X lb +0.5(X lb -X ub )(y i +1) (3)
Wherein, X lb 、X ub The upper and lower boundaries of the dimensionality of the individuals in the sparrow population; x i The actual position value of the sparrow individual is obtained.
7. The improved sparrow search algorithm optimization-based air quality index prediction method according to claim 5, wherein in step S34, the discoverer location update formula is as follows:
Figure FDA0003474154660000021
wherein the content of the first and second substances,
Figure FDA0003474154660000022
indicating that the ith sparrow is in the d-dimensional position at the t-th iteration. X gbest Is the current global optimum position, f i The smell of the ith butterfly is expressed, the value of the smell depends on the fitness, and r is a random number of 0-1. Q is a random number following a standard normal distribution. L is a single row of all 1 matrices in d dimensions. R is an early warning value and has a value range of [0,1')]. ST is an alert value with a value range of [0.5,1']. When R is<ST, which means that there are no predators around the foraging environment at this time, the finder can perform extensive search operations. When R ≧ ST, this indicates that some sparrows in the population have found predators and raised an alarm to other sparrows in the population, at which time all sparrows need to fly quickly to other safe locations for foraging.
8. The improved sparrow search algorithm optimization-based air quality index prediction method according to claim 5, wherein in step S35, the position update formula of the follower is as follows:
Figure FDA0003474154660000041
wherein the content of the first and second substances,
Figure FDA0003474154660000042
for the t +1 th iteration the optimal position of the finder is found,
Figure FDA0003474154660000043
the global worst position for the t-th iteration. A is a single row d-dimensional matrix in which each element followsA machine value of 1 or-1, and A + =A T (AA T ) -1 And n is the total number of sparrows. When i is>n/2, this shows that the ith participant with lower fitness value does not obtain food, is in a state of full hunger, and needs to fly to other places to forage to obtain more energy; when i is less than or equal to n/2, a part of the participants can forage around the best discoverer, and the participants and the discoverer can compete for food, so that the participants change into discoverers.
9. The optimized air quality index prediction method based on the improved sparrow search algorithm as claimed in claim 5, wherein in step S36, the position update formula of the alerter is as follows:
Figure FDA0003474154660000044
wherein the content of the first and second substances,
Figure FDA0003474154660000045
for the t-th iteration global optimum position, beta is a step size control parameter, and K is [ -1,1]A random number in between. Xi is a very small constant to avoid when f i =f w When the denominator is 0. f. of i 、f g 、f w Representing the current, best and worst fitness, respectively. When f is i >f g This indicates that the sparrow is now at the border of the population and is extremely vulnerable to predators. f. of i =f g This indicates that sparrows in the middle of the population are perceived as dangerous and need to be close to other sparrows to minimize their risk of being prey.
CN202210052206.3A 2022-01-17 2022-01-17 Air quality index prediction method based on improved sparrow search algorithm optimization Withdrawn CN115374689A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210052206.3A CN115374689A (en) 2022-01-17 2022-01-17 Air quality index prediction method based on improved sparrow search algorithm optimization

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210052206.3A CN115374689A (en) 2022-01-17 2022-01-17 Air quality index prediction method based on improved sparrow search algorithm optimization

Publications (1)

Publication Number Publication Date
CN115374689A true CN115374689A (en) 2022-11-22

Family

ID=84060930

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210052206.3A Withdrawn CN115374689A (en) 2022-01-17 2022-01-17 Air quality index prediction method based on improved sparrow search algorithm optimization

Country Status (1)

Country Link
CN (1) CN115374689A (en)

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115659764A (en) * 2022-12-09 2023-01-31 苏州绿控传动科技股份有限公司 Permanent magnet synchronous motor optimization method and system based on improved sparrow search algorithm
CN116151478A (en) * 2023-04-03 2023-05-23 江西锦路科技开发有限公司 Short-time traffic flow prediction method, device and medium for improving sparrow search algorithm
CN116449686A (en) * 2023-06-15 2023-07-18 斯润天朗(北京)科技有限公司 PID control method and device for optimizing RBF neural network by improving sparrow population algorithm
CN116502772A (en) * 2023-06-25 2023-07-28 成都英沃信科技有限公司 Gas well daily gas production prediction method, determination device, electronic equipment and storage medium
CN117787105A (en) * 2024-01-08 2024-03-29 西南交通大学 Tunnel surrounding rock grading method, device, equipment and readable storage medium
CN117807356A (en) * 2024-02-29 2024-04-02 齐鲁工业大学(山东省科学院) Double-vector hydrophone positioning method based on improved sparrow algorithm optimized particle filtering
CN118039022A (en) * 2024-04-11 2024-05-14 国能龙源环保有限公司 Sulfur dioxide concentration prediction method and device and computer equipment
CN117787105B (en) * 2024-01-08 2024-06-07 西南交通大学 Tunnel surrounding rock grading method, device, equipment and readable storage medium

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115659764A (en) * 2022-12-09 2023-01-31 苏州绿控传动科技股份有限公司 Permanent magnet synchronous motor optimization method and system based on improved sparrow search algorithm
CN116151478A (en) * 2023-04-03 2023-05-23 江西锦路科技开发有限公司 Short-time traffic flow prediction method, device and medium for improving sparrow search algorithm
CN116449686A (en) * 2023-06-15 2023-07-18 斯润天朗(北京)科技有限公司 PID control method and device for optimizing RBF neural network by improving sparrow population algorithm
CN116502772A (en) * 2023-06-25 2023-07-28 成都英沃信科技有限公司 Gas well daily gas production prediction method, determination device, electronic equipment and storage medium
CN117787105A (en) * 2024-01-08 2024-03-29 西南交通大学 Tunnel surrounding rock grading method, device, equipment and readable storage medium
CN117787105B (en) * 2024-01-08 2024-06-07 西南交通大学 Tunnel surrounding rock grading method, device, equipment and readable storage medium
CN117807356A (en) * 2024-02-29 2024-04-02 齐鲁工业大学(山东省科学院) Double-vector hydrophone positioning method based on improved sparrow algorithm optimized particle filtering
CN117807356B (en) * 2024-02-29 2024-05-10 齐鲁工业大学(山东省科学院) Double-vector hydrophone positioning method based on improved sparrow algorithm optimized particle filtering
CN118039022A (en) * 2024-04-11 2024-05-14 国能龙源环保有限公司 Sulfur dioxide concentration prediction method and device and computer equipment

Similar Documents

Publication Publication Date Title
CN115374689A (en) Air quality index prediction method based on improved sparrow search algorithm optimization
CN105159216B (en) Environment of chicken house ammonia concentration intelligent monitor system
CN109547431A (en) A kind of network security situation evaluating method based on CS and improved BP
CN107253195B (en) A kind of carrying machine human arm manipulation ADAPTIVE MIXED study mapping intelligent control method and system
CN113762603B (en) Photovoltaic base station short-term photovoltaic power prediction method based on improved sparrow algorithm optimization
CN111988329B (en) Network intrusion detection method based on deep learning
CN108507700A (en) A kind of pig house multi-point temperature prediction technique and system
CN111191559A (en) Overhead line early warning system obstacle identification method based on time convolution neural network
CN114021689A (en) Chaotic search optimization method for self-adaptive neural network traffic flow prediction
CN109214579A (en) Salt-soda soil stability prediction method and system based on BP neural network
CN108093085A (en) A kind of big data system real time service parameter adaptive adjusting method
Song et al. Optimized XGBoost based sparrow search algorithm for short-term load forecasting
CN111105077B (en) DG-containing power distribution network reconstruction method based on firefly mutation algorithm
CN110197278A (en) Based on the Air Quality Forecast method for improving chicken group&#39;s algorithm optimization BP neural network
CN114117787A (en) Short-term wind power prediction method based on SSA (simple sequence analysis) optimization BP (back propagation) neural network
Jia et al. Water quality prediction method based on LSTM-BP
CN113221447A (en) Soil humidity prediction method for optimizing BP neural network based on improved genetic algorithm
CN117114915A (en) Aquaculture PH value prediction method based on improved particle swarm optimization
CN116632834A (en) Short-term power load prediction method based on SSA-BiGRU-Attention
CN110910263A (en) Grain condition monitoring method based on GA-BP neural network
CN115860044A (en) Short-term power load prediction method based on improved squirrel search algorithm
Lu et al. Dynamic evolution analysis of desertification images based on BP neural network
Wu et al. Echo state network prediction based on backtracking search optimization algorithm
CN114357877A (en) Fishpond water quality evaluation prediction system and method based on fuzzy evaluation and improved support vector machine
Han et al. Short-term wind speed forecasting model based on spiking neural network

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
WW01 Invention patent application withdrawn after publication
WW01 Invention patent application withdrawn after publication

Application publication date: 20221122