# Cyber Firefly Algorithm Based on Adaptive Memory Programming for Global Optimization
## 3 Proposed Methods
### Responsive Strategies Based on Landscape Analysis  
The previous features of CFA can be more effective by incorporating the notion of responsive strategy which adaptively tunes the search strategy when observing the status transitions. The CFA adapts the strategy parameters when the search encounters the transition between the smooth and prickly landscapes manifested by the objective function. The measure of fitness distance correlation (FDC) proposed by [PERSON] and [PERSON] [23] has been proved useful for judging the suitability of a fitness landscape for various search algorithms. The FDC measures the correlation between the solution cost and the distance to the closest global optimum. Let the set of observed cost-distance pairs be \(\{(c_{1},d_{1})\),..., \((c_{m},d_{m})\}\), the correlation coefficient is defined as  
\[\text{FDC}=\frac{\frac{\frac{1}{m}\sum\limits_{i=1}^{m}\left(c_{i}-\bar{c} \right)\left(d_{i}-\bar{d}\right)}{\sigma_{c}\sigma_{d}}}{\sigma_{c}\sigma_{d}} \tag{10}\]  
where \(\bar{c}\) and \(\bar{d}\) are the mean cost and the mean distance, and \(\sigma_{c}\) and \(\sigma_{d}\). are the standard deviations of the costs and distances. Hence, a significant FDC value has the implication that on average, the better the solution quality the closer this solution is to an optimal solution. It can be contemplated that a single-modal objective function would impose a high FDC value in contrast to a multi-modal objective function whose FDC value is closer to zero because of the irrelevance between the fitness and the distance.  
Most existing research adopted the FDC technique as an off-line analysis for realizing the characteristics of the fitness landscape, while our CFA exploits the fitness landscape analysis as an online responsive strategy. We periodically conduct the fitness landscape analysis for every \(1000n\) fitness function evaluations, where \(n\) is the number of problem variables. All the visited solutions ever identified as local optima in the trajectory of a firefly within this time period are eligible for the FDC value computation because these local optima are representative solutions produced in the evolution. As the global optimum is unknown, the best solution obtained at the end of this period is considered to be the best-known solution. The FDC value is computed by using these local optima and the best solution identified in the current time period of previous \(1000n\) fitness function evaluations. Consequently, our CFA performs the adaptive landscape analysis which can predict the objective landscape within the current region explored by the firefly swarm and activate appropriate responsive strategies to make the search more effective. If the derived FDC value for the current time period is greater than a threshold (FDC \(>h_{1}\)), the local objective landscape is considered to be asymptotical single-modal, and we perform two responsive strategies as follows: (1) increasing the distance, on average, of the firefly movement by \(lb=lb/\lambda\) and \(ub=ub/\lambda\) (\(0<\lambda<1\)); (2) increasing the elapsed iterations for checking the feasibility of executing the local search and multi-start search by \(t_{1}\) = \(t_{1}/\lambda\) and \(t_{2}=t_{2}/\lambda\). The implication of the two responsive strategies is that when the local objective landscape is single-modal, the search may be more effective if the firefly movement distance is greater and the frequency for conducting the local search and the multi-start search is lower. On contrary, If the absolute FDC value for the current time period is less than a threshold (\(|\text{FDC}|<h_{2}\)), the local objective landscape is considered to be asymptotical multi-modal, and we perform two responsive strategies as follows: (1) decreasing the distance, on average, of the firefly movement by \(lb=lb\times\lambda\) and \(ub=ub\times\lambda\); (2) decreasing the elapsed iterations for checking the feasibility of executing the local search and multi-start search by \(t_{1}=t_{1}\times\lambda\) and \(t_{2}=t_{2}\times\lambda\).