# Short-Term Power Load Prediction of VMD-LSTM Based on ISSA Optimization
## 2 Fundamentals of the Model
### Sparrow Search Algorithm  
The Sparrow Search Algorithm (SSA), a bio-inspired intelligent optimization algorithm, is developed by mimicking sparrows' foraging behavior and their natural evasion behavior against predators. Characterized by a stable performance, robust global exploration ability, and a minimal number of parameters, this algorithm offers a novel approach for addressing complex global optimization problems [30]. Consequently, it has gained extensive applications in various optimization tasks in recent years. The specific principles of the Sparrow Search Algorithm are elaborated as follows:  
(1) Assuming that matrix \(X\) represents the sparrow population, then  
\[X= \begin{bmatrix}x_{11}&x_{12}&\cdots&x_{1d}\\ x_{21}&x_{22}&\cdots&x_{2d}\\ \vdots&\vdots&\vdots&\vdots\\ x_{n1}&x_{n2}&\cdots&x_{md}\\ \end{bmatrix}  \tag{18}\]  
where \(n\) means the number of sparrows in the population; \(d\) means the dimension of the LSTM hyperparameters to be optimized; and \(x\) means individual sparrows within the sparrow population. (2) Thus, the fitness values of each sparrow are determined as follows:  
\[F_{x}= \begin{bmatrix}f(x_{11},x_{12},\cdots,x_{1d})\\ f(x_{21},x_{22},\cdots,x_{2d})\\ \vdots\\ f(x_{n1},x_{n2},\cdots,x_{md})\\ \end{bmatrix}  \tag{19}\]  
where \(f\) means the fitness value. In the Sparrow Search Algorithm, the discoverer assumes the responsibility of food searching for the entire population and provides foraging directions to the joiners. As a result, a discoverer with superior fitness gains priority in acquiring food, and its search range is more extensive than that of the joiners. At each iteration, the position of the discoverer is updated as follows:  
\[X^{t+1}_{i,j}= \begin{cases}X^{t}_{i,j}\cdot\exp(\frac{-1}{\alpha\cdot t_{max}} ),&R_{2}<ST\\ X^{t}_{i,j}+Q\cdot L,&R_{2}\geq ST\\ \end{cases}  \tag{20}\]  
where \(t\) means the current iteration number, \(j=1,2,3,\cdots,d\); \(i_{termax}\) means the maximum iteration number set in the Sparrow Search Algorithm; \(X^{t}_{i,j}\) means the position information of the \(i\)th sparrow in the \(j\)th dimension; \(\alpha\in(0,1]\) is a random number; \(R_{2}\in[0,1]\) means the warning value; \(ST\in[0.5,1]\) means the safety value; and \(Q\) is a random number following the normal distribution. \(L\) represents a \(1\times d\) matrix with all elements set to 1. When \(R_{2}<ST\), which indicates the absence of predators during the foraging process, the discoverer is enabled to execute extensive searches. Conversely, when \(R_{2}>ST\), implying the presence of predators in the surrounding area, sparrows need to migrate to a secure position. (3) The joiner positions are updated as follows:  
\[X^{t+1}_{i,j}= \begin{cases}Q\cdot\exp(\frac{X_{sqrt}-X^{t}_{i,j}}{\rho}),&i> \frac{n}{2}\\ X^{t+1}_{p}+\left|X^{t}_{i,j}-X^{t+1}_{p}\right|\cdot A^{+}\cdot L,&\text{ other}\\ \end{cases}  \tag{21}\]where \(X_{p}\) denotes the optimal position currently occupied by the discoverer, and \(X_{worst}\) means the current global worst position. \(A\) is a \(1\times d\) matrix with each element randomly assigned a value of \(1\) or \(-1\), and \(A^{+}=A^{T}\big{(}AA^{T}\big{)}^{-1}\). When \(i>\frac{\mu}{2}\), the \(i\)th joiner with a lower fitness value cannot acquire food and will fly to another location to search for food at this stage. (4) Vigilante locations are updated as follows:  
\[X_{i,j}^{t+1}= \begin{cases}X_{best}^{t}+\beta\cdot\Big{|}X_{i,j}^{t}-X_{best} ^{t}\Big{|},&f_{i}>f_{g}\\ X_{i,j}^{t}+K\bigg{(}\frac{\Big{|}X_{i,j}^{t}-X_{worst}^{t}\Big{|}}{f_{i}-f_{ \pi}+\varepsilon}\bigg{)},&f_{i}=f_{g}\end{cases}  \tag{22}\]  
where \(X_{best}\) represents the current global optimal position. \(\beta\) serves as a step control parameter, and \(\beta\) is a random number following a normal distribution with a mean of \(0\) and a variance of \(1\). \(K\in[-1,1]\) is a random number. \(f_{i}\) is the current fitness value of the individual sparrow. \(f_{g}\) and \(f_{w}\) are the current global best and worst fitness values, respectively.