# Matrix Adaptation Evolution Strategy with Multi-Objective Optimization for Multimodal Optimization
## 3 Variants of CMA-ES and MA-ES Algorithm
### MA-ES Algorithm  
The CMA-ES employs two evolution paths: one for the update of the covariance matrix and another for the learning of the covariance matrix. This increases the complexity of the algorithm. To solve this problem, the MA-ES drops one of the evolution paths and removes the covariance matrix. Briefly speaking, the MA-ES directly learns the **M** matrix from the path cumulation information.  
Different from CMA-ES, the offspring of the new generation \(g+1\) is calculated by weighted recombination, which is expressed by the following formula:  
\[\mathbf{y}^{\otimes 1}=\mathbf{x}^{g}+\sigma^{g}\langle\widetilde{\mathbf{d}}^{g} \rangle_{w} \tag{1}\]  
where \(\sigma^{g}\) is the global step size or mutation strength at generation \(g\), and \(\widetilde{\mathbf{d}}^{g}\) is considered as a search direction vector.  
The path cumulation \(\mathbf{s}^{g+1}\) can be detailed as follows [11]:  
\[\mathbf{s}^{g+1}=(1-c_{s})\mathbf{s}^{g}+\sqrt{\mu_{eff}c_{s}(2-c_{s})} \langle\widetilde{\mathbf{z}}^{g}\rangle_{w} \tag{2}\]  
where \(\langle\widetilde{\mathbf{z}}^{g}\rangle_{w}=(\mathbf{C}^{g})^{-\frac{1}{2} \frac{\mathbf{y}^{g+1}-\mathbf{y}^{g}}{\sigma^{g}}}\). \(\mathbf{C}\) is the covariance matrix. The detailed derivation of \(\langle\widetilde{\mathbf{z}}^{g}\rangle_{w}\) can be found in [11]. \(c_{s}\) can be regarded as memory time constants [12], which is defined as follows [11]:  
\[c_{s}=\frac{\mu_{eff}+2}{\mu_{eff}+D+5} \tag{3}\]  
where \(D\) is the search space dimension, and \(\mu_{eff}\) denotes the variance effective selection mass [12], which is calculated as follows [11]:  
\[\mu_{eff}=\frac{1}{\sum_{k=1}^{\mu}w_{m}^{2}} \tag{4}\]  
where \(\mu=\frac{\lambda}{2}\), \(\lambda=4+3 lnD\), \(w_{m}=\frac{1}{\mu}\).  
The learning process of the \(\mathbf{M}\) matrix instead of the covariance matrix \(\mathbf{C}\) of CMA-ES is updated according to the following equation [11]:  
\[\mathbf{M}^{g+1}=\mathbf{M}^{g}[\mathbf{I}+\frac{c_{1}}{2}(\mathbf{s}^{g+1} \times\left(\mathbf{s}^{g+1}\right)^{\mathsf{T}}-\mathbf{I})+\frac{c_{w}}{2} (\langle\widetilde{\mathbf{z}}^{g}\times\left(\widetilde{\mathbf{z}}^{g} \right)^{\mathsf{T}}\rangle_{w}-\mathbf{I})] \tag{5}\]  
where I is the identity matrix, \(c_{w}=\min(1-c_{1},\ \alpha_{cov}\frac{\mu_{eff}+\frac{1}{2}-2}{(D+2)^{2}+ \frac{\alpha_{cov}\mu_{eff}}{2}})\), \(c_{1}=\frac{\alpha_{cov}}{(D+1)^{2}+\mu_{eff}}\), and \(\alpha_{cov}=2\).  
The step-size of the mutation \(\sigma^{g}\) is updated according to the following equation [11]:  
\[\sigma^{g+1}=\sigma^{g}\exp\big{[}\frac{c_{s}}{d_{\sigma}}\bigg{(}\frac{\| \mathbf{s}^{g+1}\|}{E[\|\mathcal{N}(0,\mathbf{I})\|]}-1\bigg{)}\big{]} \tag{6}\]  
where \(E[\|\mathcal{N}(0,\mathbf{I})\|]=\sqrt{2}\Gamma(\frac{D+1}{2})/\Gamma(\frac{D} {2})\), \(d_{\sigma}=1+c_{s}+2\times\max(0,\sqrt{\frac{\mu_{eff}-1}{D+1}}-1)\).  
The pseudo-code of the MA-ES algorithm is shown in Algorithm 1[11].  
```
1: Initialize \((\mathbf{y}^{(0)},\sigma^{(0)},g=0,\mathbf{s}^{(0)}:=0,\mathbf{M}^{(0)}= \mathbf{I})\)
2:while termination condition(s) is not fulfilled
3:for\(l=1\) to \(\lambda\)do
4:\(\tilde{\mathbf{z}}_{l}^{(g)}=\mathcal{N}_{l}(0,\mathbf{I})\)
5:\(\tilde{\mathbf{d}}_{l}^{(g)}=\mathbf{M}^{(g)}\tilde{\mathbf{z}}_{l}^{(g)}\)
6:\(\tilde{f}_{l}^{(g)}=f(\mathbf{y}^{(g)}+\sigma^{(g)}\tilde{\mathbf{d}}_{l}^{(g )})\)
7:endfor
8: SortOffspringPopulation
9: Update \(\mathbf{y}^{(g+1)}\) according to (1)
10: Update \(\mathbf{s}^{(g+1)}\) according to (2)
11: Update \(\mathbf{M}^{(g+1)}\) according to (5)
12: Update \(\sigma^{(g+1)}\) according to (6)
13:\(g=g+1\)
14:endwhile
```  
**Algorithm 1**MA-ES algorithm.