# An Improved Squirrel Search Algorithm for Global Function Optimization
## 3 The improved Squirrel Search Algorithm
### The Jumping Search Method
#### 3.2.3 Characters of the Jumping Search Method  
According to the new winter search strategy introduced in Section 3.2.1 and the new summer search strategy introduced in Section 3.2.2: (1) If \(r\geq P_{dp}\), the winter search strategy takes the \(FS_{i}\) as the base vector and takes the differential vectors between \(F_{h}\) and \(FS_{i}\) as the disturbance; the summer search strategy takes the \(F_{h}\) as the base vector and takes the differential vectors between \(F_{h}\) and \(FS_{i}\) as the disturbance. As both of them evolve towards \(F_{h}\), the difference between the winter search strategy and the summer search strategy is that the former focuses on maintaining the population diversity, while the latter focuses on improving the convergence speed. (2) If \(r<P_{dp}\), the winter search strategy updates the individuals by changing the learning target and gets away from the current position, while the summer search strategy generates new individuals around \(FS_{i}\) or \(F_{h}\). In summary, the different requirements in different stages are satisfied by the coordination of the two search strategies. The pseudo code of the jumping search method is shown in Algorithm 2:```
Input:\(pop\) Output:\(pop_{new}\) if\(S_{c}^{t}\geq S_{min}\) season = twinter else season = summer end if season == winter for\(p_{1}\) = 1 to \(popsize\) (\(popsize\) is the total number of squirrels) if\(r\geq P_{dp}\) \(FS_{i}^{t+1}=FS_{i}^{t}+d_{g}\times G_{c}\times(F_{h}^{t}-FS_{j}^{t})\) end if\(r<P_{dp}\) \(FS_{i}^{t+1}=L+rand(1,D)\times(U-L)\) for\(p_{2}\) = 1 to \(nt_{1}\) (\(nt_{1}\) is the total number of threatened squirrels) \(FS_{j}^{new}=FS_{j}^{t}+d_{g}\times G_{c}\times(F_{ai}^{t}-FS_{j}^{t})-d_{g} \times G_{c}\times(FS_{i}^{t}-FS_{j}^{t})i=1,2,\ldots,N_{f_{s}}\) \(FS_{j}^{t+1}=FS_{j}^{new}\times(0.5+mnd)\)  end end end if season == summer for\(p_{1}\) = 1 to \(popsize\) if\(r\geq P_{dp}\) \(FS_{i}^{t+1}=F_{h}^{t}+d_{g}\times G_{c}\times(F_{h}^{t}-FS_{j}^{t})\)  end if\(r<P_{dp}\) \(FS_{i}^{t+1}=FS_{i}^{t}\times(0.5^{(N(0,1))})\) for\(p_{2}\) = 1 to \(nt_{2}\) (\(nt_{2}\) is the total number of dead squirrels) \(FS_{i}^{t+1}=F_{h}^{t}\times(0.5+rand)\)  end end
```

**Algorithm 2**Pseudo Code of the Jumping Search Method

### The Progressive Search Method

#### 3.3.1 The Principle of the Progressive Search Method

The progressive search method is designed to improve the robustness of SSA, compared with the jumping search method. The progressive search method has a similar thought but different details. When \(S_{c}^{t}\geq S_{min}\), the season is winter, update and mutate the individuals as follows:

If \(r\geq P_{dp}\), \(FS_{i}\) is safe, update the position according to Formula (13);

If \(r<P_{dp}\)\(FS_{i}\) is endangered, select a dimension randomly and mutate it in the range of \(FS_{L}\) and \(FS_{H}\), which is aimed at retaining the current evolutionary direction and information. When \(S_{c}^{t}<S_{min}\), the season is summer, update and mutate the individuals as follows:

If \(r\geq P_{dp}\), \(FS_{i}\) is safe, update the position according to Formula (21):

\[FS_{i}^{t+1}=F_{h}^{t}+L\prime\prime y(x)\times(F_{h}^{t}-FS_{i}^{t}) \tag{21}\]

\(L\prime\prime y(x)\) is calculated by Formulas (11) and (12), which makes the individuals search in a short distance with greater possibilities and search in a long distance occasionally. If \(r<P_{dp}\), \(FS_{i}\) is endangered, select a dimension randomly and mutate it in the range of \(L\) and \(U\)

#### 3.3.2 The Analysis of the Progressive Search Method

According to the introduction of the progressive search method above, for the winter stage, if the individuals are safe, the search strategy is the same as that in the jumping search method. However, if the individuals are endangered, mutate one dimension of the individuals randomly, and the convergence speed will slow down but more evolutionary information is retained.